X-Git-Url: http://pileus.org/git/?a=blobdiff_plain;f=crypto%2Fgcm.c;h=b4f01793900409a0398faeb958b74416a5d1637d;hb=bf3964c188d686424ff7b69a45941851b9f437f0;hp=43e1fb05ea54878cbe136231a1a92c847b6d3119;hpb=188af63c0af2d7ef395bc94e3efa173f34dae03d;p=~andy%2Flinux diff --git a/crypto/gcm.c b/crypto/gcm.c index 43e1fb05ea5..b4f01793900 100644 --- a/crypto/gcm.c +++ b/crypto/gcm.c @@ -582,7 +582,7 @@ static int crypto_gcm_verify(struct aead_request *req, crypto_xor(auth_tag, iauth_tag, 16); scatterwalk_map_and_copy(iauth_tag, req->src, cryptlen, authsize, 0); - return memcmp(iauth_tag, auth_tag, authsize) ? -EBADMSG : 0; + return crypto_memneq(iauth_tag, auth_tag, authsize) ? -EBADMSG : 0; } static void gcm_decrypt_done(struct crypto_async_request *areq, int err)