aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/security/keys/key.c
diff options
context:
space:
mode:
authorHannes Reinecke <hare@suse.de>2023-08-24 16:39:13 +0200
committerKeith Busch <kbusch@kernel.org>2023-10-11 10:11:54 -0700
commit037c34318a479294cdb98dc8018edd5d191b68c0 (patch)
tree66057f8471e73a0bdc3ac1f0589c13eacb48d598 /security/keys/key.c
parentnvme-keyring: implement nvme_tls_psk_default() (diff)
downloadwireguard-linux-037c34318a479294cdb98dc8018edd5d191b68c0.tar.xz
wireguard-linux-037c34318a479294cdb98dc8018edd5d191b68c0.zip
security/keys: export key_lookup()
For in-kernel consumers one cannot readily assign a user (eg when running from a workqueue), so the normal key search permissions cannot be applied. This patch exports the 'key_lookup()' function for a simple lookup of keys without checking for permissions. Signed-off-by: Hannes Reinecke <hare@suse.de> Reviewed-by: Sagi Grimberg <sagi@grimberg.me> Acked-by: David Howells <dhowells@redhat.com> Signed-off-by: Keith Busch <kbusch@kernel.org>
Diffstat (limited to 'security/keys/key.c')
-rw-r--r--security/keys/key.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/security/keys/key.c b/security/keys/key.c
index 5c0c7df833f8..0260a1902922 100644
--- a/security/keys/key.c
+++ b/security/keys/key.c
@@ -693,6 +693,7 @@ error:
spin_unlock(&key_serial_lock);
return key;
}
+EXPORT_SYMBOL(key_lookup);
/*
* Find and lock the specified key type against removal.