diff --git a/src/libsodium/crypto_pwhash/scryptxsalsa208sha256/pwhash_scryptxsalsa208sha256.c b/src/libsodium/crypto_pwhash/scryptxsalsa208sha256/pwhash_scryptxsalsa208sha256.c index 84fda614..3165ba2f 100644 --- a/src/libsodium/crypto_pwhash/scryptxsalsa208sha256/pwhash_scryptxsalsa208sha256.c +++ b/src/libsodium/crypto_pwhash/scryptxsalsa208sha256/pwhash_scryptxsalsa208sha256.c @@ -42,12 +42,6 @@ pickparams(const size_t memlimit, unsigned long long opslimit, return 0; } -size_t -crypto_pwhash_scryptxsalsa208sha256_bytes(void) -{ - return crypto_pwhash_scryptxsalsa208sha256_BYTES; -} - size_t crypto_pwhash_scryptxsalsa208sha256_saltbytes(void) { @@ -56,6 +50,7 @@ crypto_pwhash_scryptxsalsa208sha256_saltbytes(void) int crypto_pwhash_scryptxsalsa208sha256(unsigned char * const out, + unsigned long long outlen, const char * const passwd, unsigned long long passwdlen, const unsigned char * const salt, @@ -78,5 +73,5 @@ crypto_pwhash_scryptxsalsa208sha256(unsigned char * const out, (const uint8_t *) salt, crypto_pwhash_scryptxsalsa208sha256_SALTBYTES, (uint64_t) (1) << N_log2, r, p, - out, crypto_pwhash_scryptxsalsa208sha256_BYTES); + out, outlen); } diff --git a/src/libsodium/include/sodium/crypto_pwhash_scryptxsalsa208sha256.h b/src/libsodium/include/sodium/crypto_pwhash_scryptxsalsa208sha256.h index ee4c1fe0..c3ea1a40 100644 --- a/src/libsodium/include/sodium/crypto_pwhash_scryptxsalsa208sha256.h +++ b/src/libsodium/include/sodium/crypto_pwhash_scryptxsalsa208sha256.h @@ -6,7 +6,6 @@ #include "export.h" -#define crypto_pwhash_scryptxsalsa208sha256_BYTES 64 #define crypto_pwhash_scryptxsalsa208sha256_SALTBYTES 32 #ifdef __cplusplus @@ -16,14 +15,12 @@ extern "C" { #endif -SODIUM_EXPORT -size_t crypto_pwhash_scryptxsalsa208sha256_bytes(void); - SODIUM_EXPORT size_t crypto_pwhash_scryptxsalsa208sha256_saltbytes(void); SODIUM_EXPORT int crypto_pwhash_scryptxsalsa208sha256(unsigned char * const out, + unsigned long long outlen, const char * const passwd, unsigned long long passwdlen, const unsigned char * const salt,