Also print key agreement when printing negotiated details
With TLS 1.0 to 1.2, the used key agreement was depended on the certificates
themselves. With TLS 1.3 this is no longer the case but basically always
X25519 was used. So this information has not been very interesting so far.
With OpenSSL 3.5.0 and the new X25519MLKEM768 hybrid key agreement, the used
key agreement group actually becomes interesting information.
This commit adds printing this information for OpenSSL 3.0.0+ and uses
a compat version for OpenSSL 3.0-3.1 to avoid an additional ifdef in the
code itself.
Example output with ML-DSA-65 certificates on the server (client output):
Control Channel: TLSv1.3, cipher
TLSv1.3 TLS_AES_256_GCM_SHA384, peer certificate: 15616
bits ML-DSA-65, signature: id-ml-dsa-65, peer signing
digest/type: mldsa65 id-ml-dsa-65,
key agreement: X25519MLKEM768
with an secp384r1 certificate:
Control Channel: TLSv1.3, cipher
TLSv1.3 TLS_AES_256_GCM_SHA384, peer certificate: 384
bits ECsecp384r1, signature: ecdsa-with-SHA256, peer signing
digest/type: ecdsa_secp384r1_sha384 ECDSA,
key agreement: X25519MLKEM768
Change-Id: I90d54853fe1b1d820661cc2c099e07ec5d31ed05
Signed-off-by: Arne Schwabe <arne@rfc2549.org>
Acked-by: Gert Doering <gert@greenie.muc.de>
Message-Id: <
20250409122409.17616-1-gert@greenie.muc.de>
URL: https://www.mail-archive.com/openvpn-devel@lists.sourceforge.net/msg31393.html
Signed-off-by: Gert Doering <gert@greenie.muc.de>