net/handshake: Add new parameter 'HANDSHAKE_A_ACCEPT_KEYRING'
Subsystems (3)
PATCH 1/1 net/handshake: Add new parameter 'HANDSHAKE_A_ACCEPT_KEYRING'
From: Hannes Reinecke <[email protected]>
Add a new netlink parameter 'HANDSHAKE_A_ACCEPT_KEYRING' to provide the serial number of the keyring to use.
Signed-off-by Hannes Reinecke <[email protected]>
--- include/uapi/linux/handshake.h | 1 + net/handshake/tlshd.c | 6 ++++++ 2 files changed, 7 insertions(+)
include/uapi/linux/handshake.h +1 -0
@@ -45,6 +45,7 @@ enum {HANDSHAKE_A_ACCEPT_PEER_IDENTITY ,HANDSHAKE_A_ACCEPT_CERTIFICATE ,HANDSHAKE_A_ACCEPT_PEERNAME , +HANDSHAKE_A_ACCEPT_KEYRING , __HANDSHAKE_A_ACCEPT_MAX,HANDSHAKE_A_ACCEPT_MAX = (__HANDSHAKE_A_ACCEPT_MAX -1 )
net/handshake/tlshd.c +6 -0
@@ -230,6 +230,12 @@ static int tls_handshake_accept(struct handshake_req *req,if (ret <0 ) goto out_cancel; } +if (treq->th_keyring) { + ret =nla_put_u32 (msg,HANDSHAKE_A_ACCEPT_KEYRING , + treq->th_keyring); +if (ret <0 ) + goto out_cancel; + } ret =nla_put_u32 (msg,HANDSHAKE_A_ACCEPT_AUTH_MODE , treq->th_auth_mode);
Signature · 1 line
2.35.3
Reviewed-by Sagi Grimberg <[email protected]>
Quoted 4 lines · On 5/7/25 5:40 AM, [email protected] wrote:
From: Hannes Reinecke <[email protected]>
Add a new netlink parameter '
HANDSHAKE_A_ACCEPT_KEYRING' to provide the serial number of the keyring to use.
This needs to go through [email protected].
Acked-by Chuck Lever <[email protected]>
Quoted 35 lines
Signed-off-by Hannes Reinecke <[email protected]>--- include/uapi/linux/handshake.h | 1 + net/handshake/tlshd.c | 6 ++++++ 2 files changed, 7 insertions(+)include/uapi/linux/handshake.h +1
-0@@ -45,6 +45,7 @@ enum {HANDSHAKE_A_ACCEPT_PEER_IDENTITY ,HANDSHAKE_A_ACCEPT_CERTIFICATE ,HANDSHAKE_A_ACCEPT_PEERNAME , +HANDSHAKE_A_ACCEPT_KEYRING , __HANDSHAKE_A_ACCEPT_MAX,HANDSHAKE_A_ACCEPT_MAX = (__HANDSHAKE_A_ACCEPT_MAX -1 )net/handshake/tlshd.c +6
-0@@ -230,6 +230,12 @@ static int tls_handshake_accept(struct handshake_req *req,if (ret <0 ) goto out_cancel; } +if (treq->th_keyring) { + ret =nla_put_u32 (msg,HANDSHAKE_A_ACCEPT_KEYRING , + treq->th_keyring); +if (ret <0 ) + goto out_cancel; + } ret =nla_put_u32 (msg,HANDSHAKE_A_ACCEPT_AUTH_MODE , treq->th_auth_mode);
Signature · 1 line
Chuck Lever