com php-src: sodium ext: delete copypasta from sodium_crypto _kdf_derive_from_key(): ext/sodium/libsodium. c

From: Date: Fri, 21 Jul 2017 16:25:25 +0000
Subject: com php-src: sodium ext: delete copypasta from sodium_crypto _kdf_derive_from_key(): ext/sodium/libsodium. c
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-98694@lists.php.net to get a copy of this message
Commit: f8ffc9622ba3f9b9fbbf6d4357868d4e7901fa50 Author: Frank Denis <github@pureftpd.org> Fri, 21 Jul 2017 18:25:25 +0200 Parents: 0e2a7fc82961bfef5c947cf9c0c31c88e4add831 Branches: PHP-7.2 Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=f8ffc9622ba3f9b9fbbf6d4357868d4e7901fa50 Log: sodium ext: delete copypasta from sodium_crypto_kdf_derive_from_key() /via @fredemmott Changed paths: M ext/sodium/libsodium.c Diff: diff --git a/ext/sodium/libsodium.c b/ext/sodium/libsodium.c index 96e3f74..b61c21d 100644 --- a/ext/sodium/libsodium.c +++ b/ext/sodium/libsodium.c @@ -2989,9 +2989,6 @@ PHP_FUNCTION(sodium_crypto_kdf_derive_from_key) if (key_len != crypto_kdf_KEYBYTES) { zend_throw_exception(sodium_exception_ce, "key should be sodium_crypto_kdf_KEYBYTES bytes", 0); } - if (key_len != crypto_kdf_KEYBYTES) { - zend_throw_exception(sodium_exception_ce, "context should be sodium_crypto_kdf_KEYBYTES bytes", 0); - } memcpy(ctx_padded, ctx, crypto_kdf_CONTEXTBYTES); memset(ctx_padded + crypto_kdf_CONTEXTBYTES, 0, sizeof ctx_padded - crypto_kdf_CONTEXTBYTES); salt[0] = (unsigned char) (((uint64_t) subkey_id) );

« previous php.cvs (#98694) next »