]> git.baikalelectronics.ru Git - kernel.git/commit
KEYS: sanitize add_key() and keyctl() key payloads
authorEric Biggers <ebiggers@google.com>
Thu, 8 Jun 2017 13:48:57 +0000 (14:48 +0100)
committerJames Morris <james.l.morris@oracle.com>
Fri, 9 Jun 2017 03:29:48 +0000 (13:29 +1000)
commitd3a8c7e2c5f01c0acba5b65f011f2b82c7873d69
treebe043744d16a49c9b33fc17f6d1d6f2a6ee89102
parentf2c2bdf20186b10a49aa8566c2cb38cb00909863
KEYS: sanitize add_key() and keyctl() key payloads

Before returning from add_key() or one of the keyctl() commands that
takes in a key payload, zero the temporary buffer that was allocated to
hold the key payload copied from userspace.  This may contain sensitive
key material that should not be kept around in the slab caches.

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/keyctl.c