summaryrefslogtreecommitdiff
path: root/Userland/Libraries/LibCrypt/crypt.h
blob: c51744a6665ae285e048d72ff7ce658430d92454 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
/*
 * Copyright (c) 2018-2020, Andreas Kling <kling@serenityos.org>
 *
 * SPDX-License-Identifier: BSD-2-Clause
 */

/* standard symbolic constants and types
 *
 * values from POSIX standard unix specification
 *
 * https://pubs.opengroup.org/onlinepubs/9699919799/basedefs/unistd.h.html
 */

#pragma once

#include <sys/cdefs.h>

__BEGIN_DECLS

struct crypt_data {
    int initialized;
    char result[65];
};

char* crypt(const char* key, const char* salt);
char* crypt_r(const char* key, const char* salt, struct crypt_data* data);

__END_DECLS