From 54fbd11221e69eb2c840517b1fb7c1613930f899 Mon Sep 17 00:00:00 2001 From: Michael Brown Date: Tue, 18 Nov 2008 01:52:40 +0000 Subject: [build] Keep gcc 4.4 happy gcc 4.4 adds another few warnings, and also seems to complain if we place %ebp in the clobber list for any inline asm. --- src/include/gpxe/tls.h | 20 ++++++++++++++++++-- 1 file changed, 18 insertions(+), 2 deletions(-) (limited to 'src/include') diff --git a/src/include/gpxe/tls.h b/src/include/gpxe/tls.h index a8cf16ef3..39109452f 100644 --- a/src/include/gpxe/tls.h +++ b/src/include/gpxe/tls.h @@ -109,6 +109,22 @@ struct tls_cipherspec { void *mac_secret; }; +/** TLS pre-master secret */ +struct tls_pre_master_secret { + /** TLS version */ + uint16_t version; + /** Random data */ + uint8_t random[46]; +} __attribute__ (( packed )); + +/** TLS client random data */ +struct tls_client_random { + /** GMT Unix time */ + uint32_t gmt_unix_time; + /** Random data */ + uint8_t random[28]; +} __attribute__ (( packed )); + /** A TLS session */ struct tls_session { /** Reference counter */ @@ -128,13 +144,13 @@ struct tls_session { /** Next RX cipher specification */ struct tls_cipherspec rx_cipherspec_pending; /** Premaster secret */ - uint8_t pre_master_secret[48]; + struct tls_pre_master_secret pre_master_secret; /** Master secret */ uint8_t master_secret[48]; /** Server random bytes */ uint8_t server_random[32]; /** Client random bytes */ - uint8_t client_random[32]; + struct tls_client_random client_random; /** MD5 context for handshake verification */ uint8_t handshake_md5_ctx[MD5_CTX_SIZE]; /** SHA1 context for handshake verification */ -- cgit v1.2.3-55-g7522