Re: [RFC 1/4] net/handshake: get negotiated tls record size limit
From: Wilfred Mallawa <hidden>
Date: 2025-08-07 00:03:28
Also in:
linux-nfs, linux-nvme, lkml, netdev
From: Wilfred Mallawa <hidden>
Date: 2025-08-07 00:03:28
Also in:
linux-nfs, linux-nvme, lkml, netdev
On Tue, 2025-07-29 at 10:12 +0200, Hannes Reinecke wrote:
[snip]...
quoted
diff --git a/Documentation/networking/tls-handshake.rstb/Documentation/networking/tls-handshake.rst index 6f5ea1646a47..cd984a137779 100644--- a/Documentation/networking/tls-handshake.rst +++ b/Documentation/networking/tls-handshake.rst@@ -169,7 +169,8 @@ The synopsis of this function is:.. code-block:: c typedef void (*tls_done_func_t)(void *data, int status, - key_serial_t peerid); + key_serial_t peerid, + size_t tls_record_size_limit); The consumer provides a cookie in the @ta_data field of the tls_handshake_args structure that is returned in the @data parameter ofWhy is this exposed to the TLS handshake consumer? The TLS record size is surely required for handling and processing TLS streams in net/tls, but the consumer of that (eg NVMe-TCP, NFS) are blissfully unaware that there _are_ such things like TLS records. And they really should keep it that way. So I'd really _not_ expose that to any ULP and keep it internal to the TLS layer.
Hey Hannes, Sorry for the delay in response, and thanks for the feedback! Yeah I agree it was a bad approach from me. It definitely makes more sense to keep things in the TLS layer. I will try to address this in V2. Regards, Wilfred