This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "".
The branch, master has been updated via f09c70ad34d98c5f834868c04a72733615cef88a (commit) from cd472652f51881008020a5a56b1ffc774f813ac3 (commit)
Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below.
- Log ----------------------------------------------------------------- commit f09c70ad34d98c5f834868c04a72733615cef88a Author: Maxim Uvarov maxim.uvarov@linaro.org Date: Mon Oct 31 17:51:50 2016 +0300
linux-gen: crypto: fix aes gcm decryption
We should first initialize, then set up decryption and only then push blocks for decryption. https://bugs.linaro.org/show_bug.cgi?id=2571
Signed-off-by: Maxim Uvarov maxim.uvarov@linaro.org Reviewed-by: Balakrishna Garapati balakrishna.garapati@linaro.org
diff --git a/platform/linux-generic/odp_crypto.c b/platform/linux-generic/odp_crypto.c index c7431e6..9e09d42 100644 --- a/platform/linux-generic/odp_crypto.c +++ b/platform/linux-generic/odp_crypto.c @@ -398,6 +398,8 @@ odp_crypto_alg_err_t aes_gcm_decrypt(odp_crypto_op_params_t *params,
EVP_DecryptInit_ex(ctx, NULL, NULL, NULL, iv_enc);
+ EVP_CIPHER_CTX_ctrl(ctx, EVP_CTRL_GCM_SET_TAG, 16, tag); + /* Authenticate header data (if any) without encrypting them */ if (aad_head < cipherdata) { EVP_DecryptUpdate(ctx, NULL, &plain_len, @@ -414,8 +416,6 @@ odp_crypto_alg_err_t aes_gcm_decrypt(odp_crypto_op_params_t *params, auth_len - (aad_tail - aad_head)); }
- EVP_CIPHER_CTX_ctrl(ctx, EVP_CTRL_GCM_SET_TAG, 16, tag); - if (EVP_DecryptFinal_ex(ctx, cipherdata + cipher_len, &plain_len) < 0) return ODP_CRYPTO_ALG_ERR_ICV_CHECK;
-----------------------------------------------------------------------
Summary of changes: platform/linux-generic/odp_crypto.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
hooks/post-receive