diff options
author | David Howells <dhowells@redhat.com> | 2020-09-27 11:13:04 +0100 |
---|---|---|
committer | David Howells <dhowells@redhat.com> | 2020-11-23 18:09:29 +0000 |
commit | d5953f6543b50ccdaa550b2d25bc1a16e31a2f42 (patch) | |
tree | f883bac7ec030abc262889a849eae632e2b95340 /net/rxrpc/server_key.c | |
parent | d2ae4e918218f543214fbd906db68a6c580efbbb (diff) | |
download | lwn-d5953f6543b50ccdaa550b2d25bc1a16e31a2f42.tar.gz lwn-d5953f6543b50ccdaa550b2d25bc1a16e31a2f42.zip |
rxrpc: Allow security classes to give more info on server keys
Allow a security class to give more information on an rxrpc_s-type key when
it is viewed in /proc/keys. This will allow the upcoming RxGK security
class to show the enctype name here.
Signed-off-by: David Howells <dhowells@redhat.com>
Diffstat (limited to 'net/rxrpc/server_key.c')
-rw-r--r-- | net/rxrpc/server_key.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/net/rxrpc/server_key.c b/net/rxrpc/server_key.c index 1a2f0b63ee1d..ead3471307ee 100644 --- a/net/rxrpc/server_key.c +++ b/net/rxrpc/server_key.c @@ -105,7 +105,11 @@ static void rxrpc_destroy_s(struct key *key) static void rxrpc_describe_s(const struct key *key, struct seq_file *m) { + const struct rxrpc_security *sec = key->payload.data[1]; + seq_puts(m, key->description); + if (sec && sec->describe_server_key) + sec->describe_server_key(key, m); } /* |