KEYS: encrypted: use constant-time HMAC comparison
authorEric Biggers <ebiggers@google.com>
Thu, 8 Jun 2017 13:48:32 +0000 (14:48 +0100)
committerJames Morris <james.l.morris@oracle.com>
Fri, 9 Jun 2017 03:29:47 +0000 (13:29 +1000)
commit0f534e4a13496b02ae284f50fcb0263f6ea37007
treea5200ddfa62a42340dd2ee2e918fb5b001240382
parent64d107d3acca1565c39c044c459fd18f70943534
KEYS: encrypted: use constant-time HMAC comparison

MACs should, in general, be compared using crypto_memneq() to prevent
timing attacks.

Cc: Mimi Zohar <zohar@linux.vnet.ibm.com>
Cc: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: Eric Biggers <ebiggers@google.com>
Signed-off-by: David Howells <dhowells@redhat.com>
Signed-off-by: James Morris <james.l.morris@oracle.com>
security/keys/encrypted-keys/encrypted.c