]> git.baikalelectronics.ru Git - kernel.git/commit
keys: Provide the original description to the key preparser
authorDavid Howells <dhowells@redhat.com>
Wed, 16 Sep 2020 10:12:03 +0000 (11:12 +0100)
committerDavid Howells <dhowells@redhat.com>
Mon, 23 Nov 2020 18:09:29 +0000 (18:09 +0000)
commitb270eb848133dc93a4c485642a1c182a231ca720
treefd8ed4ababeef92b63bb64fd2e2aee70a9174f62
parentc7a3af98a39c7500e07c79e33f49881661ac4176
keys: Provide the original description to the key preparser

Provide the proposed description (add key) or the original description
(update/instantiate key) when preparsing a key so that the key type can
validate it against the data.

This is important for rxrpc server keys as we need to check that they have
the right amount of key material present - and it's better to do that when
the key is loaded rather than deep in trying to process a response packet.

Signed-off-by: David Howells <dhowells@redhat.com>
cc: Jarkko Sakkinen <jarkko.sakkinen@linux.intel.com>
cc: keyrings@vger.kernel.org
include/linux/key-type.h
security/keys/key.c