Summary
Quinn's rustls HandshakeData already exposes ALPN (protocol) and SNI
(server_name), and Connection::peer_identity() exposes peer certificates.
However, there does not seem to be a public way to read the negotiated TLS
protocol version or cipher suite for a QUIC connection.
For HTTP/1.1 and HTTP/2 over TCP, server integrations using rustls can expose
request metadata such as:
SSL_PROTOCOL
SSL_CIPHER
- client certificate subject/issuer
For HTTP/3 over Quinn, the same server can expose client certificates through
peer_identity(), and can infer TLS 1.3 because QUIC requires it, but cannot
expose the negotiated cipher suite.
Use Case
Edge/server frameworks often want H1/H2/H3 request-context parity. For example,
CGI/FastCGI/PHP-style environments commonly expose TLS metadata to application
code. With Quinn today, the HTTP/3 path cannot fill SSL_CIPHER without
reaching into Quinn/rustls internals.
The use case is connection observability and H1/H2/H3 server-framework metadata parity.
The cipher suite is the practical missing piece. Exposing the TLS protocol
version as well would make the TLS metadata complete and avoid special-casing
QUIC as "always TLS 1.3" in server integrations.
Possible Shape
Would Quinn be open to exposing negotiated TLS metadata in rustls
HandshakeData, for example:
pub struct HandshakeData {
pub protocol: Option<Vec<u8>>, // ALPN
pub server_name: Option<String>,
pub protocol_version: Option<rustls::ProtocolVersion>,
pub negotiated_cipher_suite: Option<rustls::CipherSuite>,
}
Summary
Quinn's rustls
HandshakeDataalready exposes ALPN (protocol) and SNI(
server_name), andConnection::peer_identity()exposes peer certificates.However, there does not seem to be a public way to read the negotiated TLS
protocol version or cipher suite for a QUIC connection.
For HTTP/1.1 and HTTP/2 over TCP, server integrations using rustls can expose
request metadata such as:
SSL_PROTOCOLSSL_CIPHERFor HTTP/3 over Quinn, the same server can expose client certificates through
peer_identity(), and can infer TLS 1.3 because QUIC requires it, but cannotexpose the negotiated cipher suite.
Use Case
Edge/server frameworks often want H1/H2/H3 request-context parity. For example,
CGI/FastCGI/PHP-style environments commonly expose TLS metadata to application
code. With Quinn today, the HTTP/3 path cannot fill
SSL_CIPHERwithoutreaching into Quinn/rustls internals.
The use case is connection observability and H1/H2/H3 server-framework metadata parity.
The cipher suite is the practical missing piece. Exposing the TLS protocol
version as well would make the TLS metadata complete and avoid special-casing
QUIC as "always TLS 1.3" in server integrations.
Possible Shape
Would Quinn be open to exposing negotiated TLS metadata in rustls
HandshakeData, for example: