1 #ifndef crypto_kdf_blake2b_H 2 #define crypto_kdf_blake2b_H 3 4 #include <stddef.h> 5 #include <stdint.h> 6 7 #include "crypto_kdf_blake2b.h" 8 #include "export.h" 9 10 #ifdef __cplusplus 11 # ifdef __GNUC__ 12 # pragma GCC diagnostic ignored "-Wlong-long" 13 # endif 14 extern "C" { 15 #endif 16 17 #define crypto_kdf_blake2b_BYTES_MIN 16 18 SODIUM_EXPORT 19 size_t crypto_kdf_blake2b_bytes_min(void); 20 21 #define crypto_kdf_blake2b_BYTES_MAX 64 22 SODIUM_EXPORT 23 size_t crypto_kdf_blake2b_bytes_max(void); 24 25 #define crypto_kdf_blake2b_CONTEXTBYTES 8 26 SODIUM_EXPORT 27 size_t crypto_kdf_blake2b_contextbytes(void); 28 29 #define crypto_kdf_blake2b_KEYBYTES 32 30 SODIUM_EXPORT 31 size_t crypto_kdf_blake2b_keybytes(void); 32 33 SODIUM_EXPORT 34 int crypto_kdf_blake2b_derive_from_key(unsigned char *subkey, size_t subkey_len, 35 uint64_t subkey_id, 36 const char ctx[crypto_kdf_blake2b_CONTEXTBYTES], 37 const unsigned char key[crypto_kdf_blake2b_KEYBYTES]); 38 #ifdef __cplusplus 39 } 40 #endif 41 42 #endif 43