From: Frank Denis Date: Sat, 22 Jul 2017 17:57:44 +0000 (+0200) Subject: sodium ext: define crypto_aead_chacha20poly1305_ietf_KEYBYTES if needed X-Git-Tag: php-7.2.0beta2~71 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=c499bd12f706df927bf3c6d6c21797aa065c4a52;p=php sodium ext: define crypto_aead_chacha20poly1305_ietf_KEYBYTES if needed Some old libsodium versions didn't had a dedicated constant for the IETF version of this construction. --- diff --git a/ext/sodium/libsodium.c b/ext/sodium/libsodium.c index b61c21dad2..139b807366 100644 --- a/ext/sodium/libsodium.c +++ b/ext/sodium/libsodium.c @@ -175,6 +175,10 @@ ZEND_END_ARG_INFO() # define HAVE_AESGCM 1 #endif +#ifndef crypto_aead_chacha20poly1305_ietf_KEYBYTES +# define crypto_aead_chacha20poly1305_ietf_KEYBYTES crypto_aead_chacha20poly1305_KEYBYTES +#endif + const zend_function_entry sodium_functions[] = { PHP_FE(sodium_crypto_aead_aes256gcm_is_available, AI_None) #ifdef HAVE_AESGCM