[tls] Use null handshake digest algorithm for the null cipher suite

A cipher suite's handshake digest algorithm is used only once that
cipher suite has been selected.  The null cipher suite can never be
explicitly selected, and so its handshake digest algorithm can never
be used and is currently left as a NULL pointer.

Set the null cipher suite's handshake digest algorithm to be the null
digest algorithm, to create an invariant that all pointer fields have
non-NULL values in all cipher suites.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
This commit is contained in:
Michael Brown
2026-08-25 18:13:05 +01:00
parent 7afbcac103
commit 202466d8a6
+1
View File
@@ -511,6 +511,7 @@ struct tls_cipher_suite tls_cipher_suite_null = {
.pubkey = &pubkey_null,
.cipher = &cipher_null,
.digest = &digest_null,
.handshake = &digest_null,
};
/** Number of supported cipher suites */