crypt.h 548 B

12345678910111213141516171819202122232425262728
  1. /*
  2. * Copyright (c) 2018-2020, Andreas Kling <kling@serenityos.org>
  3. *
  4. * SPDX-License-Identifier: BSD-2-Clause
  5. */
  6. /* standard symbolic constants and types
  7. *
  8. * values from POSIX standard unix specification
  9. *
  10. * https://pubs.opengroup.org/onlinepubs/9699919799/basedefs/unistd.h.html
  11. */
  12. #pragma once
  13. #include <sys/cdefs.h>
  14. __BEGIN_DECLS
  15. struct crypt_data {
  16. int initialized;
  17. char result[65];
  18. };
  19. char* crypt(char const* key, char const* salt);
  20. char* crypt_r(char const* key, char const* salt, struct crypt_data* data);
  21. __END_DECLS