-
- Downloads
Get off of deprecated GCM AES methods
Multiple compiler warnings note that the gcm_aes_* family of functions are deprecated. They have been replaced with gcm_aes<key_length>_*. This change uses the correct set of functions based on the given key size. Resolves #571. Sample compiler warning: /home/noviv/opendht/src/crypto.cpp: In function ‘dht::Blob dht::crypto::aesEncrypt(const uint8_t*, size_t, const dht::Blob&)’: /home/noviv/opendht/src/crypto.cpp:97:20: warning: ‘void nettle_gcm_aes_set_key(gcm_aes_ctx*, size_t, const uint8_t*)’ is deprecated [-Wdeprecated-declarations] 97 | gcm_aes_set_key(&aes, key.size(), key.data()); | ^ In file included from /home/noviv/opendht/src/crypto.cpp:27: /usr/include/nettle/gcm.h:276:1: note: declared here 276 | gcm_aes_set_key(struct gcm_aes_ctx *ctx, | ^~~~~~~~~~~~~~~) https://github.com/gnutls/nettle/commit/6a19845e6f71791ca98765d490ec08e776494bee marked the functions as deprecated.
Loading
Please register or sign in to comment