From c3aeef03b3e246554f6d6232e26eb030dcefa2fa Mon Sep 17 00:00:00 2001 From: Filippo Valsorda Date: Fri, 26 Jan 2024 23:22:45 +0100 Subject: [PATCH 01/39] Revert "crypto/internal/boring: upgrade module to fips-20220613" +1 This reverts commit 7383b2a4db5dc93c9b875b42d5add73d27cc4b9f ("crypto/internal/boring: upgrade module to fips-20220613") and commit 4106de901a8efe914cda6f6c4e8d45ff8c115da4 ("crypto/tls: align FIPS-only mode with BoringSSL policy"). Fixes #65321 Updates #64717 Updates #62372 Change-Id: I0938b97e5b4904e6532448b8ae76e920d03d0508 Reviewed-on: https://go-review.googlesource.com/c/go/+/558796 Reviewed-by: Michael Knyszek Reviewed-by: Roland Shoemaker Auto-Submit: Filippo Valsorda LUCI-TryBot-Result: Go LUCI --- boring.go | 26 +++++++-------- boring_test.go | 69 ++++++++++----------------------------- cipher_suites.go | 8 +---- handshake_client.go | 4 +-- handshake_client_tls13.go | 4 +++ handshake_server_test.go | 28 +++++----------- handshake_server_tls13.go | 7 ++-- notboring.go | 2 -- 8 files changed, 48 insertions(+), 100 deletions(-) diff --git a/boring.go b/boring.go index aad96b1..1827f76 100644 --- a/boring.go +++ b/boring.go @@ -6,10 +6,9 @@ package tls -import "crypto/internal/boring/fipstls" - -// The FIPS-only policies enforced here currently match BoringSSL's -// ssl_policy_fips_202205. +import ( + "crypto/internal/boring/fipstls" +) // needFIPS returns fipstls.Required(); it avoids a new import in common.go. func needFIPS() bool { @@ -18,19 +17,19 @@ func needFIPS() bool { // fipsMinVersion replaces c.minVersion in FIPS-only mode. func fipsMinVersion(c *Config) uint16 { - // FIPS requires TLS 1.2 or TLS 1.3. + // FIPS requires TLS 1.2. return VersionTLS12 } // fipsMaxVersion replaces c.maxVersion in FIPS-only mode. func fipsMaxVersion(c *Config) uint16 { - // FIPS requires TLS 1.2 or TLS 1.3. - return VersionTLS13 + // FIPS requires TLS 1.2. + return VersionTLS12 } // default defaultFIPSCurvePreferences is the FIPS-allowed curves, // in preference order (most preferable first). -var defaultFIPSCurvePreferences = []CurveID{CurveP256, CurveP384} +var defaultFIPSCurvePreferences = []CurveID{CurveP256, CurveP384, CurveP521} // fipsCurvePreferences replaces c.curvePreferences in FIPS-only mode. func fipsCurvePreferences(c *Config) []CurveID { @@ -55,6 +54,8 @@ var defaultCipherSuitesFIPS = []uint16{ TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384, TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256, TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384, + TLS_RSA_WITH_AES_128_GCM_SHA256, + TLS_RSA_WITH_AES_256_GCM_SHA384, } // fipsCipherSuites replaces c.cipherSuites in FIPS-only mode. @@ -74,14 +75,8 @@ func fipsCipherSuites(c *Config) []uint16 { return list } -// defaultCipherSuitesTLS13FIPS are the FIPS-allowed cipher suites for TLS 1.3. -var defaultCipherSuitesTLS13FIPS = []uint16{ - TLS_AES_128_GCM_SHA256, - TLS_AES_256_GCM_SHA384, -} - // fipsSupportedSignatureAlgorithms currently are a subset of -// defaultSupportedSignatureAlgorithms without Ed25519, SHA-1, and P-521. +// defaultSupportedSignatureAlgorithms without Ed25519 and SHA-1. var fipsSupportedSignatureAlgorithms = []SignatureScheme{ PSSWithSHA256, PSSWithSHA384, @@ -91,6 +86,7 @@ var fipsSupportedSignatureAlgorithms = []SignatureScheme{ PKCS1WithSHA384, ECDSAWithP384AndSHA384, PKCS1WithSHA512, + ECDSAWithP521AndSHA512, } // supportedSignatureAlgorithms returns the supported signature algorithms. diff --git a/boring_test.go b/boring_test.go index a192a65..085ff57 100644 --- a/boring_test.go +++ b/boring_test.go @@ -25,31 +25,6 @@ import ( "time" ) -func allCipherSuitesIncludingTLS13() []uint16 { - s := allCipherSuites() - for _, suite := range cipherSuitesTLS13 { - s = append(s, suite.id) - } - return s -} - -func isTLS13CipherSuite(id uint16) bool { - for _, suite := range cipherSuitesTLS13 { - if id == suite.id { - return true - } - } - return false -} - -func generateKeyShare(group CurveID) keyShare { - key, err := generateECDHEKey(rand.Reader, group) - if err != nil { - panic(err) - } - return keyShare{group: group, data: key.PublicKey().Bytes()} -} - func TestBoringServerProtocolVersion(t *testing.T) { test := func(name string, v uint16, msg string) { t.Run(name, func(t *testing.T) { @@ -58,11 +33,8 @@ func TestBoringServerProtocolVersion(t *testing.T) { clientHello := &clientHelloMsg{ vers: v, random: make([]byte, 32), - cipherSuites: allCipherSuitesIncludingTLS13(), + cipherSuites: allCipherSuites(), compressionMethods: []uint8{compressionNone}, - supportedCurves: defaultCurvePreferences, - keyShares: []keyShare{generateKeyShare(CurveP256)}, - supportedPoints: []uint8{pointFormatUncompressed}, supportedVersions: []uint16{v}, } testClientHelloFailure(t, serverConfig, clientHello, msg) @@ -76,25 +48,25 @@ func TestBoringServerProtocolVersion(t *testing.T) { fipstls.Force() defer fipstls.Abandon() - test("VersionSSL30/fipstls", VersionSSL30, "client offered only unsupported versions") - test("VersionTLS10/fipstls", VersionTLS10, "client offered only unsupported versions") - test("VersionTLS11/fipstls", VersionTLS11, "client offered only unsupported versions") - test("VersionTLS12/fipstls", VersionTLS12, "") - test("VersionTLS13/fipstls", VersionTLS13, "") + test("VersionSSL30", VersionSSL30, "client offered only unsupported versions") + test("VersionTLS10", VersionTLS10, "client offered only unsupported versions") + test("VersionTLS11", VersionTLS11, "client offered only unsupported versions") + test("VersionTLS12", VersionTLS12, "") + test("VersionTLS13", VersionTLS13, "client offered only unsupported versions") } func isBoringVersion(v uint16) bool { - return v == VersionTLS12 || v == VersionTLS13 + return v == VersionTLS12 } func isBoringCipherSuite(id uint16) bool { switch id { - case TLS_AES_128_GCM_SHA256, - TLS_AES_256_GCM_SHA384, - TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256, + case TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256, TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384, TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256, - TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384: + TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384, + TLS_RSA_WITH_AES_128_GCM_SHA256, + TLS_RSA_WITH_AES_256_GCM_SHA384: return true } return false @@ -102,7 +74,7 @@ func isBoringCipherSuite(id uint16) bool { func isBoringCurve(id CurveID) bool { switch id { - case CurveP256, CurveP384: + case CurveP256, CurveP384, CurveP521: return true } return false @@ -114,7 +86,7 @@ func isECDSA(id uint16) bool { return suite.flags&suiteECSign == suiteECSign } } - return false // TLS 1.3 cipher suites are not tied to the signature algorithm. + panic(fmt.Sprintf("unknown cipher suite %#x", id)) } func isBoringSignatureScheme(alg SignatureScheme) bool { @@ -126,6 +98,7 @@ func isBoringSignatureScheme(alg SignatureScheme) bool { PKCS1WithSHA384, ECDSAWithP384AndSHA384, PKCS1WithSHA512, + ECDSAWithP521AndSHA512, PSSWithSHA256, PSSWithSHA384, PSSWithSHA512: @@ -136,9 +109,10 @@ func isBoringSignatureScheme(alg SignatureScheme) bool { func TestBoringServerCipherSuites(t *testing.T) { serverConfig := testConfig.Clone() + serverConfig.CipherSuites = allCipherSuites() serverConfig.Certificates = make([]Certificate, 1) - for _, id := range allCipherSuitesIncludingTLS13() { + for _, id := range allCipherSuites() { if isECDSA(id) { serverConfig.Certificates[0].Certificate = [][]byte{testECDSACertificate} serverConfig.Certificates[0].PrivateKey = testECDSAPrivateKey @@ -147,19 +121,14 @@ func TestBoringServerCipherSuites(t *testing.T) { serverConfig.Certificates[0].PrivateKey = testRSAPrivateKey } serverConfig.BuildNameToCertificate() - t.Run(fmt.Sprintf("suite=%s", CipherSuiteName(id)), func(t *testing.T) { + t.Run(fmt.Sprintf("suite=%#x", id), func(t *testing.T) { clientHello := &clientHelloMsg{ vers: VersionTLS12, random: make([]byte, 32), cipherSuites: []uint16{id}, compressionMethods: []uint8{compressionNone}, supportedCurves: defaultCurvePreferences, - keyShares: []keyShare{generateKeyShare(CurveP256)}, supportedPoints: []uint8{pointFormatUncompressed}, - supportedVersions: []uint16{VersionTLS12}, - } - if isTLS13CipherSuite(id) { - clientHello.supportedVersions = []uint16{VersionTLS13} } testClientHello(t, serverConfig, clientHello) @@ -191,9 +160,7 @@ func TestBoringServerCurves(t *testing.T) { cipherSuites: []uint16{TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256}, compressionMethods: []uint8{compressionNone}, supportedCurves: []CurveID{curveid}, - keyShares: []keyShare{generateKeyShare(curveid)}, supportedPoints: []uint8{pointFormatUncompressed}, - supportedVersions: []uint16{VersionTLS12}, } testClientHello(t, serverConfig, clientHello) @@ -312,7 +279,7 @@ func TestBoringClientHello(t *testing.T) { } if !isBoringVersion(hello.vers) { - t.Errorf("client vers=%#x", hello.vers) + t.Errorf("client vers=%#x, want %#x (TLS 1.2)", hello.vers, VersionTLS12) } for _, v := range hello.supportedVersions { if !isBoringVersion(v) { diff --git a/cipher_suites.go b/cipher_suites.go index 636689b..6f5bc37 100644 --- a/cipher_suites.go +++ b/cipher_suites.go @@ -556,13 +556,7 @@ func aeadAESGCMTLS13(key, nonceMask []byte) aead { if err != nil { panic(err) } - var aead cipher.AEAD - if boring.Enabled { - aead, err = boring.NewGCMTLS13(aes) - } else { - boring.Unreachable() - aead, err = cipher.NewGCM(aes) - } + aead, err := cipher.NewGCM(aes) if err != nil { panic(err) } diff --git a/handshake_client.go b/handshake_client.go index 89004c2..f016e01 100644 --- a/handshake_client.go +++ b/handshake_client.go @@ -139,9 +139,7 @@ func (c *Conn) makeClientHello() (*clientHelloMsg, *ecdh.PrivateKey, error) { if len(hello.supportedVersions) == 1 { hello.cipherSuites = nil } - if needFIPS() { - hello.cipherSuites = append(hello.cipherSuites, defaultCipherSuitesTLS13FIPS...) - } else if hasAESGCMHardwareSupport { + if hasAESGCMHardwareSupport { hello.cipherSuites = append(hello.cipherSuites, defaultCipherSuitesTLS13...) } else { hello.cipherSuites = append(hello.cipherSuites, defaultCipherSuitesTLS13NoAES...) diff --git a/handshake_client_tls13.go b/handshake_client_tls13.go index a84cede..2f59f68 100644 --- a/handshake_client_tls13.go +++ b/handshake_client_tls13.go @@ -41,6 +41,10 @@ type clientHandshakeStateTLS13 struct { func (hs *clientHandshakeStateTLS13) handshake() error { c := hs.c + if needFIPS() { + return errors.New("tls: internal error: TLS 1.3 reached in FIPS mode") + } + // The server must not select TLS 1.3 in a renegotiation. See RFC 8446, // sections 4.1.2 and 4.1.3. if c.handshakes > 0 { diff --git a/handshake_server_test.go b/handshake_server_test.go index c0a86a4..15db760 100644 --- a/handshake_server_test.go +++ b/handshake_server_test.go @@ -27,7 +27,6 @@ import ( ) func testClientHello(t *testing.T, serverConfig *Config, m handshakeMessage) { - t.Helper() testClientHelloFailure(t, serverConfig, m, "") } @@ -53,32 +52,23 @@ func testClientHelloFailure(t *testing.T, serverConfig *Config, m handshakeMessa ctx := context.Background() conn := Server(s, serverConfig) ch, err := conn.readClientHello(ctx) - if err == nil && conn.vers == VersionTLS13 { - hs := serverHandshakeStateTLS13{ - c: conn, - ctx: ctx, - clientHello: ch, - } + hs := serverHandshakeState{ + c: conn, + ctx: ctx, + clientHello: ch, + } + if err == nil { err = hs.processClientHello() - } else if err == nil { - hs := serverHandshakeState{ - c: conn, - ctx: ctx, - clientHello: ch, - } - err = hs.processClientHello() - if err == nil { - err = hs.pickCipherSuite() - } + } + if err == nil { + err = hs.pickCipherSuite() } s.Close() if len(expectedSubStr) == 0 { if err != nil && err != io.EOF { - t.Helper() t.Errorf("Got error: %s; expected to succeed", err) } } else if err == nil || !strings.Contains(err.Error(), expectedSubStr) { - t.Helper() t.Errorf("Got error: %v; expected to match substring '%s'", err, expectedSubStr) } } diff --git a/handshake_server_tls13.go b/handshake_server_tls13.go index b68ff9d..21d798d 100644 --- a/handshake_server_tls13.go +++ b/handshake_server_tls13.go @@ -45,6 +45,10 @@ type serverHandshakeStateTLS13 struct { func (hs *serverHandshakeStateTLS13) handshake() error { c := hs.c + if needFIPS() { + return errors.New("tls: internal error: TLS 1.3 reached in FIPS mode") + } + // For an overview of the TLS 1.3 handshake, see RFC 8446, Section 2. if err := hs.processClientHello(); err != nil { return err @@ -159,9 +163,6 @@ func (hs *serverHandshakeStateTLS13) processClientHello() error { if !hasAESGCMHardwareSupport || !aesgcmPreferred(hs.clientHello.cipherSuites) { preferenceList = defaultCipherSuitesTLS13NoAES } - if needFIPS() { - preferenceList = defaultCipherSuitesTLS13FIPS - } for _, suiteID := range preferenceList { hs.suite = mutualCipherSuiteTLS13(hs.clientHello.cipherSuites, suiteID) if hs.suite != nil { diff --git a/notboring.go b/notboring.go index edccb44..7d85b39 100644 --- a/notboring.go +++ b/notboring.go @@ -18,5 +18,3 @@ func fipsCurvePreferences(c *Config) []CurveID { panic("fipsCurvePreferences") } func fipsCipherSuites(c *Config) []uint16 { panic("fipsCipherSuites") } var fipsSupportedSignatureAlgorithms []SignatureScheme - -var defaultCipherSuitesTLS13FIPS []uint16 From 97054e65fa4c94a938df318f891afad9d9f790d6 Mon Sep 17 00:00:00 2001 From: guoguangwu Date: Thu, 22 Feb 2024 01:32:06 +0000 Subject: [PATCH 02/39] crypto/tls: fix typo in comment Change-Id: I77371ef99797e2b53f1292c9d6a4eb157f116f88 GitHub-Last-Rev: 7ce7d014c0c46b320f9e4b742ae9360d1b5cf4dc GitHub-Pull-Request: golang/go#65836 Reviewed-on: https://go-review.googlesource.com/c/go/+/565440 Reviewed-by: Ian Lance Taylor Reviewed-by: qiulaidongfeng <2645477756@qq.com> Auto-Submit: Ian Lance Taylor Reviewed-by: Carlos Amedee LUCI-TryBot-Result: Go LUCI --- tls_test.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tls_test.go b/tls_test.go index 42a0272..096b4ed 100644 --- a/tls_test.go +++ b/tls_test.go @@ -211,7 +211,7 @@ func TestDialTimeout(t *testing.T) { t.Logf("Listener accepted a connection from %s", lconn.RemoteAddr()) lconn.Close() } - // Close any spurious extra connecitions from the listener. (This is + // Close any spurious extra connections from the listener. (This is // possible if there are, for example, stray Dial calls from other tests.) for extraConn := range acceptc { t.Logf("spurious extra connection from %s", extraConn.RemoteAddr()) From 7f35a0b4619d7721651005b5f3892a4c343912ca Mon Sep 17 00:00:00 2001 From: cui fliter Date: Fri, 22 Mar 2024 23:31:44 +0800 Subject: [PATCH 03/39] all: fix a large number of comments Partial typo corrections, following https://go.dev/wiki/Spelling Change-Id: I2357906ff2ea04305c6357418e4e9556e20375d1 Reviewed-on: https://go-review.googlesource.com/c/go/+/573776 LUCI-TryBot-Result: Go LUCI TryBot-Result: Gopher Robot Reviewed-by: Than McIntosh Run-TryBot: shuang cui Reviewed-by: Ian Lance Taylor Auto-Submit: Ian Lance Taylor --- conn.go | 2 +- handshake_server_test.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/conn.go b/conn.go index 0e46698..30c5f00 100644 --- a/conn.go +++ b/conn.go @@ -1040,7 +1040,7 @@ func (c *Conn) writeRecordLocked(typ recordType, data []byte) (int, error) { } // writeHandshakeRecord writes a handshake message to the connection and updates -// the record layer state. If transcript is non-nil the marshalled message is +// the record layer state. If transcript is non-nil the marshaled message is // written to it. func (c *Conn) writeHandshakeRecord(msg handshakeMessage, transcript transcriptHash) (int, error) { c.out.Lock() diff --git a/handshake_server_test.go b/handshake_server_test.go index 15db760..ff0b479 100644 --- a/handshake_server_test.go +++ b/handshake_server_test.go @@ -998,7 +998,7 @@ func TestHandshakeServerSNI(t *testing.T) { runServerTestTLS12(t, test) } -// TestHandshakeServerSNICertForName is similar to TestHandshakeServerSNI, but +// TestHandshakeServerSNIGetCertificate is similar to TestHandshakeServerSNI, but // tests the dynamic GetCertificate method func TestHandshakeServerSNIGetCertificate(t *testing.T) { config := testConfig.Clone() From 0cb1694084fcc5e654912048f229b9b432324742 Mon Sep 17 00:00:00 2001 From: Jes Cok Date: Wed, 27 Mar 2024 20:44:18 +0800 Subject: [PATCH 04/39] all: make use of builtin clear Change-Id: I1df0685c75fc1044ba46003a69ecc7dfc53bbc2b Reviewed-on: https://go-review.googlesource.com/c/go/+/574675 Reviewed-by: Ian Lance Taylor Reviewed-by: Than McIntosh LUCI-TryBot-Result: Go LUCI Auto-Submit: Ian Lance Taylor --- example_test.go | 5 +---- handshake_test.go | 5 +---- 2 files changed, 2 insertions(+), 8 deletions(-) diff --git a/example_test.go b/example_test.go index 6389fd7..95e4953 100644 --- a/example_test.go +++ b/example_test.go @@ -18,10 +18,7 @@ import ( type zeroSource struct{} func (zeroSource) Read(b []byte) (n int, err error) { - for i := range b { - b[i] = 0 - } - + clear(b) return len(b), nil } diff --git a/handshake_test.go b/handshake_test.go index bacc8b7..ddcf977 100644 --- a/handshake_test.go +++ b/handshake_test.go @@ -310,10 +310,7 @@ Dialing: type zeroSource struct{} func (zeroSource) Read(b []byte) (n int, err error) { - for i := range b { - b[i] = 0 - } - + clear(b) return len(b), nil } From 8d53a491d103c1683953992b870c3b04f33a4d37 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20Mart=C3=AD?= Date: Sun, 17 Sep 2023 21:46:35 +0100 Subject: [PATCH 05/39] crypto/tls,regexp: remove always-nil error results MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit These were harmless, but added unnecessary verbosity to the code. This can happen as a result of refactors: for example, the method sessionState used to return errors in some cases. Change-Id: I4e6dacc01ae6a49b528c672979f95cbb86795a85 Reviewed-on: https://go-review.googlesource.com/c/go/+/528995 Reviewed-by: Leo Isla LUCI-TryBot-Result: Go LUCI Reviewed-by: Than McIntosh Reviewed-by: Olivier Mengué Reviewed-by: Dmitri Shuralyov Reviewed-by: qiulaidongfeng <2645477756@qq.com> Reviewed-by: Quim Muntal --- handshake_client.go | 5 +---- handshake_client_tls13.go | 6 +----- handshake_server.go | 6 ++---- handshake_server_tls13.go | 9 +++------ ticket.go | 4 ++-- 5 files changed, 9 insertions(+), 21 deletions(-) diff --git a/handshake_client.go b/handshake_client.go index f016e01..0b35dee 100644 --- a/handshake_client.go +++ b/handshake_client.go @@ -915,10 +915,7 @@ func (hs *clientHandshakeState) saveSessionTicket() error { return nil } - session, err := c.sessionState() - if err != nil { - return err - } + session := c.sessionState() session.secret = hs.masterSecret cs := &ClientSessionState{ticket: hs.ticket, session: session} diff --git a/handshake_client_tls13.go b/handshake_client_tls13.go index 2f59f68..a0fc413 100644 --- a/handshake_client_tls13.go +++ b/handshake_client_tls13.go @@ -753,11 +753,7 @@ func (c *Conn) handleNewSessionTicket(msg *newSessionTicketMsgTLS13) error { psk := cipherSuite.expandLabel(c.resumptionSecret, "resumption", msg.nonce, cipherSuite.hash.Size()) - session, err := c.sessionState() - if err != nil { - c.sendAlert(alertInternalError) - return err - } + session := c.sessionState() session.secret = psk session.useBy = uint64(c.config.time().Add(lifetime).Unix()) session.ageAdd = msg.ageAdd diff --git a/handshake_server.go b/handshake_server.go index 8129e9c..eb87ee0 100644 --- a/handshake_server.go +++ b/handshake_server.go @@ -810,10 +810,7 @@ func (hs *serverHandshakeState) sendSessionTicket() error { c := hs.c m := new(newSessionTicketMsg) - state, err := c.sessionState() - if err != nil { - return err - } + state := c.sessionState() state.secret = hs.masterSecret if hs.sessionState != nil { // If this is re-wrapping an old key, then keep @@ -821,6 +818,7 @@ func (hs *serverHandshakeState) sendSessionTicket() error { state.createdAt = hs.sessionState.createdAt } if c.config.WrapSession != nil { + var err error m.ticket, err = c.config.WrapSession(c.connectionStateLocked(), state) if err != nil { return err diff --git a/handshake_server_tls13.go b/handshake_server_tls13.go index 21d798d..60a3883 100644 --- a/handshake_server_tls13.go +++ b/handshake_server_tls13.go @@ -837,13 +837,11 @@ func (c *Conn) sendSessionTicket(earlyData bool) error { m := new(newSessionTicketMsgTLS13) - state, err := c.sessionState() - if err != nil { - return err - } + state := c.sessionState() state.secret = psk state.EarlyData = earlyData if c.config.WrapSession != nil { + var err error m.label, err = c.config.WrapSession(c.connectionStateLocked(), state) if err != nil { return err @@ -865,8 +863,7 @@ func (c *Conn) sendSessionTicket(earlyData bool) error { // The value is not stored anywhere; we never need to check the ticket age // because 0-RTT is not supported. ageAdd := make([]byte, 4) - _, err = c.config.rand().Read(ageAdd) - if err != nil { + if _, err := c.config.rand().Read(ageAdd); err != nil { return err } m.ageAdd = binary.LittleEndian.Uint32(ageAdd) diff --git a/ticket.go b/ticket.go index b71e3af..04e1dd6 100644 --- a/ticket.go +++ b/ticket.go @@ -289,7 +289,7 @@ func ParseSessionState(data []byte) (*SessionState, error) { // sessionState returns a partially filled-out [SessionState] with information // from the current connection. -func (c *Conn) sessionState() (*SessionState, error) { +func (c *Conn) sessionState() *SessionState { return &SessionState{ version: c.vers, cipherSuite: c.cipherSuite, @@ -302,7 +302,7 @@ func (c *Conn) sessionState() (*SessionState, error) { isClient: c.isClient, extMasterSecret: c.extMasterSecret, verifiedChains: c.verifiedChains, - }, nil + } } // EncryptTicket encrypts a ticket with the [Config]'s configured (or default) From c16fc29ae80aca256649c505f901751a91e84907 Mon Sep 17 00:00:00 2001 From: Roland Shoemaker Date: Wed, 19 Apr 2023 11:56:30 -0700 Subject: [PATCH 06/39] crypto/tls: add a bogo shim Run the BoGo test suite. For now a number of tests are disabled, so that we can land the shim. Once the shim is in the tree I'll work on fixing tests, and aligning the TLS stack with the boringssl stack. Eventually we should also remove the --loose-errors flag. Fixes #51434 Change-Id: Ic8339fc34552936b798acf834011a129e375750e Reviewed-on: https://go-review.googlesource.com/c/go/+/486495 LUCI-TryBot-Result: Go LUCI Auto-Submit: Roland Shoemaker Reviewed-by: Damien Neil --- bogo_config.json | 175 +++++++++++++++++++++++++++++ bogo_shim_test.go | 277 ++++++++++++++++++++++++++++++++++++++++++++++ handshake_test.go | 22 +++- 3 files changed, 471 insertions(+), 3 deletions(-) create mode 100644 bogo_config.json create mode 100644 bogo_shim_test.go diff --git a/bogo_config.json b/bogo_config.json new file mode 100644 index 0000000..d548a61 --- /dev/null +++ b/bogo_config.json @@ -0,0 +1,175 @@ +{ + "DisabledTests": { + "*QUIC*": "No QUIC support", + "Compliance-fips*": "No FIPS", + "*DTLS*": "No DTLS", + "SendEmptyRecords*": "crypto/tls doesn't implement spam protections", + "SendWarningAlerts*": "crypto/tls doesn't implement spam protections", + "TooManyKeyUpdates": "crypto/tls doesn't implement spam protections (TODO: I think?)", + "SkipNewSessionTicket": "TODO confusing? maybe bug", + "SendUserCanceledAlerts*": "TODO may be a real bug?", + "GREASE-Server-TLS13": "TODO ???", + "GarbageCertificate*": "TODO ask davidben, alertDecode vs alertBadCertificate", + "SendBogusAlertType": "sending wrong alert type", + "EchoTLS13CompatibilitySessionID": "TODO reject compat session ID", + "*ECH-Server*": "no ECH server support", + "TLS-ECH-Client-UnsolictedHRRExtension": "TODO", + "SupportTicketsWithSessionID": "TODO: first pass, this should be fixed", + "NoNullCompression-TLS12": "TODO: first pass, this should be fixed", + "KeyUpdate-RequestACK": "TODO: first pass, this should be fixed", + "TLS13-HRR-InvalidCompressionMethod": "TODO: first pass, this should be fixed", + "InvalidCompressionMethod": "TODO: first pass, this should be fixed", + "TLS-TLS12-RSA_WITH_AES_128_GCM_SHA256-LargeRecord": "TODO: first pass, this should be fixed", + "TLS-TLS1-RSA_WITH_AES_128_CBC_SHA-LargeRecord": "TODO: first pass, this should be fixed", + "TLS-TLS11-RSA_WITH_AES_128_CBC_SHA-LargeRecord": "TODO: first pass, this should be fixed", + "TLS-TLS12-RSA_WITH_AES_128_CBC_SHA-LargeRecord": "TODO: first pass, this should be fixed", + "TLS-TLS12-RSA_WITH_AES_256_GCM_SHA384-LargeRecord": "TODO: first pass, this should be fixed", + "TLS-TLS1-RSA_WITH_AES_256_CBC_SHA-LargeRecord": "TODO: first pass, this should be fixed", + "TLS-TLS11-RSA_WITH_AES_256_CBC_SHA-LargeRecord": "TODO: first pass, this should be fixed", + "TLS-TLS12-RSA_WITH_AES_256_CBC_SHA-LargeRecord": "TODO: first pass, this should be fixed", + "TLS-TLS12-ECDHE_RSA_WITH_AES_128_CBC_SHA256-LargeRecord": "TODO: first pass, this should be fixed", + "RequireAnyClientCertificate-TLS1": "TODO: first pass, this should be fixed", + "RequireAnyClientCertificate-TLS11": "TODO: first pass, this should be fixed", + "RequireAnyClientCertificate-TLS12": "TODO: first pass, this should be fixed", + "ClientHelloVersionTooHigh": "TODO: first pass, this should be fixed", + "MinorVersionTolerance": "TODO: first pass, this should be fixed", + "IgnoreClientVersionOrder": "TODO: first pass, this should be fixed", + "SupportedVersionSelection-TLS12": "TODO: first pass, this should be fixed", + "MajorVersionTolerance": "TODO: first pass, this should be fixed", + "DuplicateExtensionServer-TLS-TLS1": "TODO: first pass, this should be fixed", + "DuplicateExtensionClient-TLS-TLS1": "TODO: first pass, this should be fixed", + "UnsolicitedServerNameAck-TLS-TLS1": "TODO: first pass, this should be fixed", + "TicketSessionIDLength-33-TLS-TLS1": "TODO: first pass, this should be fixed", + "DuplicateExtensionServer-TLS-TLS11": "TODO: first pass, this should be fixed", + "DuplicateExtensionClient-TLS-TLS11": "TODO: first pass, this should be fixed", + "UnsolicitedServerNameAck-TLS-TLS11": "TODO: first pass, this should be fixed", + "TicketSessionIDLength-33-TLS-TLS11": "TODO: first pass, this should be fixed", + "DuplicateExtensionServer-TLS-TLS12": "TODO: first pass, this should be fixed", + "DuplicateExtensionClient-TLS-TLS12": "TODO: first pass, this should be fixed", + "UnsolicitedServerNameAck-TLS-TLS12": "TODO: first pass, this should be fixed", + "TicketSessionIDLength-33-TLS-TLS12": "TODO: first pass, this should be fixed", + "DuplicateExtensionClient-TLS-TLS13": "TODO: first pass, this should be fixed", + "DuplicateExtensionServer-TLS-TLS13": "TODO: first pass, this should be fixed", + "UnsolicitedServerNameAck-TLS-TLS13": "TODO: first pass, this should be fixed", + "RenegotiationInfo-Forbidden-TLS13": "TODO: first pass, this should be fixed", + "EMS-Forbidden-TLS13": "TODO: first pass, this should be fixed", + "SendUnsolicitedOCSPOnCertificate-TLS13": "TODO: first pass, this should be fixed", + "SendUnsolicitedSCTOnCertificate-TLS13": "TODO: first pass, this should be fixed", + "SendUnknownExtensionOnCertificate-TLS13": "TODO: first pass, this should be fixed", + "Resume-Server-NoTickets-TLS1-TLS1-TLS": "TODO: first pass, this should be fixed", + "Resume-Server-NoTickets-TLS11-TLS11-TLS": "TODO: first pass, this should be fixed", + "Resume-Server-NoTickets-TLS12-TLS12-TLS": "TODO: first pass, this should be fixed", + "Resume-Server-NoPSKBinder": "TODO: first pass, this should be fixed", + "Resume-Server-PSKBinderFirstExtension": "TODO: first pass, this should be fixed", + "Resume-Server-PSKBinderFirstExtension-SecondBinder": "TODO: first pass, this should be fixed", + "Resume-Server-NoPSKBinder-SecondBinder": "TODO: first pass, this should be fixed", + "Resume-Server-OmitPSKsOnSecondClientHello": "TODO: first pass, this should be fixed", + "Renegotiate-Server-Forbidden": "TODO: first pass, this should be fixed", + "Renegotiate-Client-Forbidden-1": "TODO: first pass, this should be fixed", + "Client-Sign-RSA_PKCS1_SHA1-TLS13": "TODO: first pass, this should be fixed", + "Client-Sign-RSA_PKCS1_SHA256-TLS13": "TODO: first pass, this should be fixed", + "Client-Sign-RSA_PKCS1_SHA384-TLS13": "TODO: first pass, this should be fixed", + "Client-Sign-RSA_PKCS1_SHA512-TLS13": "TODO: first pass, this should be fixed", + "Client-Sign-ECDSA_SHA1-TLS13": "TODO: first pass, this should be fixed", + "Client-Sign-ECDSA_P224_SHA256-TLS13": "TODO: first pass, this should be fixed", + "ClientAuth-NoFallback-TLS13": "TODO: first pass, this should be fixed", + "ClientAuth-NoFallback-ECDSA": "TODO: first pass, this should be fixed", + "ClientAuth-NoFallback-RSA": "TODO: first pass, this should be fixed", + "ECDSACurveMismatch-Verify-TLS13": "TODO: first pass, this should be fixed", + "Ed25519DefaultDisable-NoAdvertise": "TODO: first pass, this should be fixed", + "Ed25519DefaultDisable-NoAccept": "TODO: first pass, this should be fixed", + "NoCommonSignatureAlgorithms-TLS12-Fallback": "TODO: first pass, this should be fixed", + "UnknownExtension-Client": "TODO: first pass, this should be fixed", + "UnknownUnencryptedExtension-Client-TLS13": "TODO: first pass, this should be fixed", + "UnofferedExtension-Client-TLS13": "TODO: first pass, this should be fixed", + "UnknownExtension-Client-TLS13": "TODO: first pass, this should be fixed", + "SendClientVersion-RSA": "TODO: first pass, this should be fixed", + "NoCommonCurves": "TODO: first pass, this should be fixed", + "PointFormat-EncryptedExtensions-TLS13": "TODO: first pass, this should be fixed", + "PointFormat-Client-MissingUncompressed": "TODO: first pass, this should be fixed", + "TLS13-SendNoKEMModesWithPSK-Server": "TODO: first pass, this should be fixed", + "TLS13-DuplicateTicketEarlyDataSupport": "TODO: first pass, this should be fixed", + "Basic-Client-NoTicket-TLS-Sync": "TODO: first pass, this should be fixed", + "Basic-Server-RSA-TLS-Sync": "TODO: first pass, this should be fixed", + "Basic-Client-NoTicket-TLS-Sync-SplitHandshakeRecords": "TODO: first pass, this should be fixed", + "Basic-Server-RSA-TLS-Sync-SplitHandshakeRecords": "TODO: first pass, this should be fixed", + "Basic-Client-NoTicket-TLS-Sync-PackHandshake": "TODO: first pass, this should be fixed", + "Basic-Server-RSA-TLS-Sync-PackHandshake": "TODO: first pass, this should be fixed", + "PartialSecondClientHelloAfterFirst": "TODO: first pass, this should be fixed", + "PartialServerHelloWithHelloRetryRequest": "TODO: first pass, this should be fixed", + "TrailingDataWithFinished-Server-TLS1": "TODO: first pass, this should be fixed", + "PartialClientKeyExchangeWithClientHello": "TODO: first pass, this should be fixed", + "TrailingDataWithFinished-Resume-Server-TLS1": "TODO: first pass, this should be fixed", + "TrailingDataWithFinished-Resume-Client-TLS11": "TODO: first pass, this should be fixed", + "TrailingDataWithFinished-Client-TLS1": "TODO: first pass, this should be fixed", + "TrailingDataWithFinished-Client-TLS11": "TODO: first pass, this should be fixed", + "TrailingDataWithFinished-Client-TLS12": "TODO: first pass, this should be fixed", + "TrailingDataWithFinished-Client-TLS13": "TODO: first pass, this should be fixed", + "PartialNewSessionTicketWithServerHelloDone": "TODO: first pass, this should be fixed", + "TrailingDataWithFinished-Server-TLS11": "TODO: first pass, this should be fixed", + "TrailingDataWithFinished-Server-TLS12": "TODO: first pass, this should be fixed", + "TrailingDataWithFinished-Resume-Server-TLS11": "TODO: first pass, this should be fixed", + "TrailingDataWithFinished-Resume-Client-TLS12": "TODO: first pass, this should be fixed", + "TrailingDataWithFinished-Resume-Server-TLS12": "TODO: first pass, this should be fixed", + "TrailingDataWithFinished-Resume-Client-TLS13": "TODO: first pass, this should be fixed", + "TrailingDataWithFinished-Resume-Client-TLS1": "TODO: first pass, this should be fixed", + "TrailingMessageData-ClientHello-TLS": "TODO: first pass, this should be fixed", + "TrailingMessageData-ServerHello-TLS": "TODO: first pass, this should be fixed", + "TrailingMessageData-ServerCertificate-TLS": "TODO: first pass, this should be fixed", + "TrailingMessageData-ServerHelloDone-TLS": "TODO: first pass, this should be fixed", + "TrailingMessageData-ServerKeyExchange-TLS": "TODO: first pass, this should be fixed", + "TrailingMessageData-CertificateRequest-TLS": "TODO: first pass, this should be fixed", + "TrailingMessageData-CertificateVerify-TLS": "TODO: first pass, this should be fixed", + "TrailingMessageData-ServerFinished-TLS": "TODO: first pass, this should be fixed", + "TrailingMessageData-ClientKeyExchange-TLS": "TODO: first pass, this should be fixed", + "TrailingMessageData-TLS13-ClientHello-TLS": "TODO: first pass, this should be fixed", + "TrailingMessageData-ClientFinished-TLS": "TODO: first pass, this should be fixed", + "TrailingMessageData-NewSessionTicket-TLS": "TODO: first pass, this should be fixed", + "TrailingMessageData-ClientCertificate-TLS": "TODO: first pass, this should be fixed", + "TrailingMessageData-TLS13-CertificateRequest-TLS": "TODO: first pass, this should be fixed", + "TrailingMessageData-TLS13-ServerCertificateVerify-TLS": "TODO: first pass, this should be fixed", + "TrailingMessageData-TLS13-EncryptedExtensions-TLS": "TODO: first pass, this should be fixed", + "TrailingMessageData-TLS13-ClientCertificate-TLS": "TODO: first pass, this should be fixed", + "TrailingMessageData-TLS13-ClientCertificateVerify-TLS": "TODO: first pass, this should be fixed", + "TrailingMessageData-TLS13-ServerCertificate-TLS": "TODO: first pass, this should be fixed", + "ResumeTLS12SessionID-TLS13": "TODO: first pass, this should be fixed", + "SkipEarlyData-TLS13": "TODO: first pass, this should be fixed", + "DuplicateKeyShares-TLS13": "TODO: first pass, this should be fixed", + "Server-TooLongSessionID-TLS13": "TODO: first pass, this should be fixed", + "Client-TooLongSessionID": "TODO: first pass, this should be fixed", + "Client-ShortSessionID": "TODO: first pass, this should be fixed", + "TLS12NoSessionID-TLS13": "TODO: first pass, this should be fixed", + "Server-TooLongSessionID-TLS12": "TODO: first pass, this should be fixed", + "EmptyEncryptedExtensions-TLS13": "TODO: first pass, this should be fixed", + "SkipEarlyData-SecondClientHelloEarlyData-TLS13": "TODO: first pass, this should be fixed", + "EncryptedExtensionsWithKeyShare-TLS13": "TODO: first pass, this should be fixed", + "HelloRetryRequest-DuplicateCurve-TLS13": "TODO: first pass, this should be fixed", + "HelloRetryRequest-DuplicateCookie-TLS13": "TODO: first pass, this should be fixed", + "HelloRetryRequest-Unknown-TLS13": "TODO: first pass, this should be fixed", + "SendPostHandshakeChangeCipherSpec-TLS13": "TODO: first pass, this should be fixed", + "ECDSAKeyUsage-Server-TLS12": "TODO: first pass, this should be fixed", + "ECDSAKeyUsage-Server-TLS13": "TODO: first pass, this should be fixed", + "RSAKeyUsage-Client-WantEncipherment-GotEnciphermentTLS1": "TODO: first pass, this should be fixed", + "RSAKeyUsage-Server-WantSignature-GotEncipherment-TLS1": "TODO: first pass, this should be fixed", + "RSAKeyUsage-Client-WantSignature-GotSignature-TLS1": "TODO: first pass, this should be fixed", + "RSAKeyUsage-Client-WantEncipherment-GotEnciphermentTLS11": "TODO: first pass, this should be fixed", + "RSAKeyUsage-Client-WantSignature-GotSignature-TLS11": "TODO: first pass, this should be fixed", + "RSAKeyUsage-Client-WantEncipherment-GotEnciphermentTLS12": "TODO: first pass, this should be fixed", + "RSAKeyUsage-Server-WantSignature-GotEncipherment-TLS12": "TODO: first pass, this should be fixed", + "RSAKeyUsage-Server-WantSignature-GotEncipherment-TLS11": "TODO: first pass, this should be fixed", + "RSAKeyUsage-Client-WantSignature-GotSignature-TLS12": "TODO: first pass, this should be fixed", + "RSAKeyUsage-Client-WantSignature-GotSignature-TLS13": "TODO: first pass, this should be fixed", + "RSAKeyUsage-Server-WantSignature-GotEncipherment-TLS13": "TODO: first pass, this should be fixed", + "EmptyExtensions-ClientHello-TLS1": "TODO: first pass, this should be fixed", + "OmitExtensions-ClientHello-TLS1": "TODO: first pass, this should be fixed", + "EmptyExtensions-ClientHello-TLS12": "TODO: first pass, this should be fixed", + "OmitExtensions-ClientHello-TLS12": "TODO: first pass, this should be fixed", + "EmptyExtensions-ClientHello-TLS11": "TODO: first pass, this should be fixed", + "OmitExtensions-ClientHello-TLS11": "TODO: first pass, this should be fixed", + "DuplicateCertCompressionExt-TLS12": "TODO: first pass, this should be fixed", + "DuplicateCertCompressionExt-TLS13": "TODO: first pass, this should be fixed", + "Client-RejectJDK11DowngradeRandom": "TODO: first pass, this should be fixed", + "CheckClientCertificateTypes": "TODO: first pass, this should be fixed", + "CheckECDSACurve-TLS12": "TODO: first pass, this should be fixed" + } +} \ No newline at end of file diff --git a/bogo_shim_test.go b/bogo_shim_test.go new file mode 100644 index 0000000..f12733a --- /dev/null +++ b/bogo_shim_test.go @@ -0,0 +1,277 @@ +package tls + +import ( + "crypto/x509" + "encoding/binary" + "encoding/json" + "encoding/pem" + "flag" + "fmt" + "internal/testenv" + "io" + "log" + "net" + "os" + "os/exec" + "path/filepath" + "testing" +) + +var ( + port = flag.String("port", "", "") + server = flag.Bool("server", false, "") + + isHandshakerSupported = flag.Bool("is-handshaker-supported", false, "") + + keyfile = flag.String("key-file", "", "") + certfile = flag.String("cert-file", "", "") + + trustCert = flag.String("trust-cert", "", "") + + minVersion = flag.Int("min-version", VersionSSL30, "") + maxVersion = flag.Int("max-version", VersionTLS13, "") + + noTLS13 = flag.Bool("no-tls13", false, "") + + requireAnyClientCertificate = flag.Bool("require-any-client-certificate", false, "") + + shimWritesFirst = flag.Bool("shim-writes-first", false, "") + + resumeCount = flag.Int("resume-count", 0, "") + + shimID = flag.Uint64("shim-id", 0, "") + _ = flag.Bool("ipv6", false, "") + + // Unimplemented flags + // -advertise-alpn + // -advertise-npn + // -allow-hint-mismatch + // -async + // -check-close-notify + // -cipher + // -curves + // -delegated-credential + // -dtls + // -ech-config-list + // -ech-server-config + // -enable-channel-id + // -enable-early-data + // -enable-ech-grease + // -enable-grease + // -enable-ocsp-stapling + // -enable-signed-cert-timestamps + // -expect-advertised-alpn + // -expect-certificate-types + // -expect-channel-id + // -expect-cipher-aes + // -expect-client-ca-list + // -expect-curve-id + // -expect-early-data-reason + // -expect-extended-master-secret + // -expect-hrr + // -expect-key-usage-invalid + // -expect-msg-callback + // -expect-no-session + // -expect-peer-cert-file + // -expect-peer-signature-algorithm + // -expect-peer-verify-pref + // -expect-secure-renegotiation + // -expect-server-name + // -expect-ticket-supports-early-data + // -export-keying-material + // -export-traffic-secrets + // -fail-cert-callback + // -fail-early-callback + // -fallback-scsv + // -false-start + // -forbid-renegotiation-after-handshake + // -handshake-twice + // -host-name + // -ignore-rsa-key-usage + // -implicit-handshake + // -install-cert-compression-algs + // -install-ddos-callback + // -install-one-cert-compression-alg + // -jdk11-workaround + // -key-update + // -max-cert-list + // -max-send-fragment + // -no-ticket + // -no-tls1 + // -no-tls11 + // -no-tls12 + // -ocsp-response + // -on-resume-expect-accept-early-data + // -on-resume-expect-reject-early-data + // -on-shim-cipher + // -on-shim-curves + // -peek-then-read + // -psk + // -read-with-unfinished-write + // -reject-alpn + // -renegotiate-explicit + // -renegotiate-freely + // -renegotiate-ignore + // -renegotiate-once + // -select-alpn + // -select-next-proto + // -send-alert + // -send-channel-id + // -server-preference + // -shim-shuts-down + // -signed-cert-timestamps + // -signing-prefs + // -srtp-profiles + // -tls-unique + // -use-client-ca-list + // -use-ocsp-callback + // -use-old-client-cert-callback + // -verify-fail + // -verify-peer + // -verify-prefs +) + +func bogoShim() { + if *isHandshakerSupported { + fmt.Println("No") + return + } + + cfg := &Config{ + ServerName: "test", + + MinVersion: uint16(*minVersion), + MaxVersion: uint16(*maxVersion), + + ClientSessionCache: NewLRUClientSessionCache(0), + } + + if *noTLS13 && cfg.MaxVersion == VersionTLS13 { + cfg.MaxVersion = VersionTLS12 + } + + if *keyfile != "" || *certfile != "" { + pair, err := LoadX509KeyPair(*certfile, *keyfile) + if err != nil { + log.Fatalf("load key-file err: %s", err) + } + cfg.Certificates = []Certificate{pair} + } + if *trustCert != "" { + pool := x509.NewCertPool() + certFile, err := os.ReadFile(*trustCert) + if err != nil { + log.Fatalf("load trust-cert err: %s", err) + } + block, _ := pem.Decode(certFile) + cert, err := x509.ParseCertificate(block.Bytes) + if err != nil { + log.Fatalf("parse trust-cert err: %s", err) + } + pool.AddCert(cert) + cfg.RootCAs = pool + } + + if *requireAnyClientCertificate { + cfg.ClientAuth = RequireAnyClientCert + } + + for i := 0; i < *resumeCount+1; i++ { + conn, err := net.Dial("tcp", net.JoinHostPort("localhost", *port)) + if err != nil { + log.Fatalf("dial err: %s", err) + } + defer conn.Close() + + // Write the shim ID we were passed as a little endian uint64 + shimIDBytes := make([]byte, 8) + binary.LittleEndian.PutUint64(shimIDBytes, *shimID) + if _, err := conn.Write(shimIDBytes); err != nil { + log.Fatalf("failed to write shim id: %s", err) + } + + var tlsConn *Conn + if *server { + tlsConn = Server(conn, cfg) + } else { + tlsConn = Client(conn, cfg) + } + + if *shimWritesFirst { + if _, err := tlsConn.Write([]byte("hello")); err != nil { + log.Fatalf("write err: %s", err) + } + } + + for { + buf := make([]byte, 500) + n, err := tlsConn.Read(buf) + if err == io.EOF { + break + } + if err != nil { + log.Fatalf("read err: %s", err) + } + buf = buf[:n] + for i := range buf { + buf[i] ^= 0xff + } + if _, err := tlsConn.Write(buf); err != nil { + log.Fatalf("write err: %s", err) + } + } + } +} + +func TestBogoSuite(t *testing.T) { + testenv.SkipIfShortAndSlow(t) + testenv.MustHaveExternalNetwork(t) + testenv.MustHaveGoRun(t) + testenv.MustHaveExec(t) + + if testing.Short() { + t.Skip("skipping in short mode") + } + + const boringsslModVer = "v0.0.0-20240412155355-1c6e10495e4f" + output, err := exec.Command("go", "mod", "download", "-json", "github.com/google/boringssl@"+boringsslModVer).CombinedOutput() + if err != nil { + t.Fatalf("failed to download boringssl: %s", err) + } + var j struct { + Dir string + } + if err := json.Unmarshal(output, &j); err != nil { + t.Fatalf("failed to parse 'go mod download' output: %s", err) + } + + cwd, err := os.Getwd() + if err != nil { + t.Fatal(err) + } + + args := []string{ + "test", + ".", + fmt.Sprintf("-shim-config=%s", filepath.Join(cwd, "bogo_config.json")), + fmt.Sprintf("-shim-path=%s", os.Args[0]), + "-shim-extra-flags=-bogo-mode", + "-allow-unimplemented", + "-loose-errors", // TODO(roland): this should be removed eventually + } + if *bogoFilter != "" { + args = append(args, fmt.Sprintf("-test=%s", *bogoFilter)) + } + + goCmd, err := testenv.GoTool() + if err != nil { + t.Fatal(err) + } + cmd := exec.Command(goCmd, args...) + cmd.Stdout, cmd.Stderr = os.Stdout, os.Stderr + cmd.Dir = filepath.Join(j.Dir, "ssl/test/runner") + err = cmd.Run() + if err != nil { + t.Fatalf("bogo failed: %s", err) + } +} diff --git a/handshake_test.go b/handshake_test.go index ddcf977..e365a79 100644 --- a/handshake_test.go +++ b/handshake_test.go @@ -41,9 +41,11 @@ import ( // reference connection will always change. var ( - update = flag.Bool("update", false, "update golden files on failure") - fast = flag.Bool("fast", false, "impose a quick, possibly flaky timeout on recorded tests") - keyFile = flag.String("keylog", "", "destination file for KeyLogWriter") + update = flag.Bool("update", false, "update golden files on failure") + fast = flag.Bool("fast", false, "impose a quick, possibly flaky timeout on recorded tests") + keyFile = flag.String("keylog", "", "destination file for KeyLogWriter") + bogoMode = flag.Bool("bogo-mode", false, "Enabled bogo shim mode, ignore everything else") + bogoFilter = flag.String("bogo-filter", "", "BoGo test filter") ) func runTestAndUpdateIfNeeded(t *testing.T, name string, run func(t *testing.T, update bool), wait bool) { @@ -326,7 +328,21 @@ func allCipherSuites() []uint16 { var testConfig *Config func TestMain(m *testing.M) { + flag.Usage = func() { + fmt.Fprintf(flag.CommandLine.Output(), "Usage of %s:\n", os.Args) + flag.PrintDefaults() + if *bogoMode { + os.Exit(89) + } + } + flag.Parse() + + if *bogoMode { + bogoShim() + os.Exit(0) + } + os.Exit(runMain(m)) } From 990f5260035d51503befc3a6620b602968a31d5d Mon Sep 17 00:00:00 2001 From: Roland Shoemaker Date: Thu, 18 Apr 2024 10:51:25 -0700 Subject: [PATCH 07/39] crypto/tls: don't cache marshal'd bytes MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Only cache the wire representation for clientHelloMsg and serverHelloMsg during unmarshal, which are the only places we actually need to hold onto them. For everything else, remove the raw field. This appears to have zero performance impact: name old time/op new time/op delta CertCache/0-10 177µs ± 2% 189µs ±11% ~ (p=0.700 n=3+3) CertCache/1-10 184µs ± 3% 182µs ± 6% ~ (p=1.000 n=3+3) CertCache/2-10 187µs ±12% 187µs ± 2% ~ (p=1.000 n=3+3) CertCache/3-10 204µs ±21% 187µs ± 1% ~ (p=0.700 n=3+3) HandshakeServer/RSA-10 410µs ± 2% 410µs ± 3% ~ (p=1.000 n=3+3) HandshakeServer/ECDHE-P256-RSA/TLSv13-10 473µs ± 3% 460µs ± 2% ~ (p=0.200 n=3+3) HandshakeServer/ECDHE-P256-RSA/TLSv12-10 498µs ± 3% 489µs ± 2% ~ (p=0.700 n=3+3) HandshakeServer/ECDHE-P256-ECDSA-P256/TLSv13-10 140µs ± 5% 138µs ± 5% ~ (p=1.000 n=3+3) HandshakeServer/ECDHE-P256-ECDSA-P256/TLSv12-10 132µs ± 1% 133µs ± 2% ~ (p=0.400 n=3+3) HandshakeServer/ECDHE-X25519-ECDSA-P256/TLSv13-10 168µs ± 1% 171µs ± 4% ~ (p=1.000 n=3+3) HandshakeServer/ECDHE-X25519-ECDSA-P256/TLSv12-10 166µs ± 3% 163µs ± 0% ~ (p=0.700 n=3+3) HandshakeServer/ECDHE-P521-ECDSA-P521/TLSv13-10 1.87ms ± 2% 1.81ms ± 0% ~ (p=0.100 n=3+3) HandshakeServer/ECDHE-P521-ECDSA-P521/TLSv12-10 1.86ms ± 0% 1.86ms ± 1% ~ (p=1.000 n=3+3) Throughput/MaxPacket/1MB/TLSv12-10 6.79ms ± 3% 6.73ms ± 0% ~ (p=1.000 n=3+3) Throughput/MaxPacket/1MB/TLSv13-10 6.73ms ± 1% 6.75ms ± 0% ~ (p=0.700 n=3+3) Throughput/MaxPacket/2MB/TLSv12-10 12.8ms ± 2% 12.7ms ± 0% ~ (p=0.700 n=3+3) Throughput/MaxPacket/2MB/TLSv13-10 13.1ms ± 3% 12.8ms ± 1% ~ (p=0.400 n=3+3) Throughput/MaxPacket/4MB/TLSv12-10 24.9ms ± 2% 24.7ms ± 1% ~ (p=1.000 n=3+3) Throughput/MaxPacket/4MB/TLSv13-10 26.0ms ± 4% 24.9ms ± 1% ~ (p=0.100 n=3+3) Throughput/MaxPacket/8MB/TLSv12-10 50.0ms ± 3% 48.9ms ± 0% ~ (p=0.200 n=3+3) Throughput/MaxPacket/8MB/TLSv13-10 49.8ms ± 2% 49.3ms ± 1% ~ (p=0.400 n=3+3) Throughput/MaxPacket/16MB/TLSv12-10 97.3ms ± 1% 97.4ms ± 0% ~ (p=0.700 n=3+3) Throughput/MaxPacket/16MB/TLSv13-10 97.9ms ± 0% 97.9ms ± 1% ~ (p=1.000 n=3+3) Throughput/MaxPacket/32MB/TLSv12-10 195ms ± 0% 194ms ± 1% ~ (p=0.400 n=3+3) Throughput/MaxPacket/32MB/TLSv13-10 196ms ± 0% 196ms ± 1% ~ (p=0.700 n=3+3) Throughput/MaxPacket/64MB/TLSv12-10 405ms ± 3% 385ms ± 0% ~ (p=0.100 n=3+3) Throughput/MaxPacket/64MB/TLSv13-10 391ms ± 1% 388ms ± 1% ~ (p=0.200 n=3+3) Throughput/DynamicPacket/1MB/TLSv12-10 6.75ms ± 0% 6.75ms ± 1% ~ (p=0.700 n=3+3) Throughput/DynamicPacket/1MB/TLSv13-10 6.84ms ± 1% 6.77ms ± 0% ~ (p=0.100 n=3+3) Throughput/DynamicPacket/2MB/TLSv12-10 12.8ms ± 1% 12.8ms ± 1% ~ (p=0.400 n=3+3) Throughput/DynamicPacket/2MB/TLSv13-10 12.8ms ± 1% 13.0ms ± 1% ~ (p=0.200 n=3+3) Throughput/DynamicPacket/4MB/TLSv12-10 24.8ms ± 1% 24.8ms ± 0% ~ (p=1.000 n=3+3) Throughput/DynamicPacket/4MB/TLSv13-10 25.1ms ± 2% 25.1ms ± 1% ~ (p=1.000 n=3+3) Throughput/DynamicPacket/8MB/TLSv12-10 49.2ms ± 2% 48.9ms ± 0% ~ (p=0.700 n=3+3) Throughput/DynamicPacket/8MB/TLSv13-10 49.3ms ± 1% 49.4ms ± 1% ~ (p=0.700 n=3+3) Throughput/DynamicPacket/16MB/TLSv12-10 97.1ms ± 0% 98.0ms ± 1% ~ (p=0.200 n=3+3) Throughput/DynamicPacket/16MB/TLSv13-10 98.8ms ± 1% 98.4ms ± 1% ~ (p=0.700 n=3+3) Throughput/DynamicPacket/32MB/TLSv12-10 192ms ± 0% 198ms ± 5% ~ (p=0.100 n=3+3) Throughput/DynamicPacket/32MB/TLSv13-10 194ms ± 0% 196ms ± 1% ~ (p=0.400 n=3+3) Throughput/DynamicPacket/64MB/TLSv12-10 385ms ± 1% 384ms ± 0% ~ (p=0.700 n=3+3) Throughput/DynamicPacket/64MB/TLSv13-10 387ms ± 0% 388ms ± 0% ~ (p=0.400 n=3+3) Latency/MaxPacket/200kbps/TLSv12-10 694ms ± 0% 694ms ± 0% ~ (p=0.700 n=3+3) Latency/MaxPacket/200kbps/TLSv13-10 699ms ± 0% 699ms ± 0% ~ (p=0.700 n=3+3) Latency/MaxPacket/500kbps/TLSv12-10 278ms ± 0% 278ms ± 0% ~ (p=0.400 n=3+3) Latency/MaxPacket/500kbps/TLSv13-10 280ms ± 0% 280ms ± 0% ~ (p=1.000 n=3+3) Latency/MaxPacket/1000kbps/TLSv12-10 140ms ± 1% 140ms ± 0% ~ (p=0.700 n=3+3) Latency/MaxPacket/1000kbps/TLSv13-10 141ms ± 0% 141ms ± 0% ~ (p=1.000 n=3+3) Latency/MaxPacket/2000kbps/TLSv12-10 70.5ms ± 0% 70.4ms ± 0% ~ (p=0.700 n=3+3) Latency/MaxPacket/2000kbps/TLSv13-10 70.7ms ± 0% 70.7ms ± 0% ~ (p=0.700 n=3+3) Latency/MaxPacket/5000kbps/TLSv12-10 28.8ms ± 0% 28.8ms ± 0% ~ (p=0.700 n=3+3) Latency/MaxPacket/5000kbps/TLSv13-10 28.9ms ± 0% 28.9ms ± 0% ~ (p=0.700 n=3+3) Latency/DynamicPacket/200kbps/TLSv12-10 134ms ± 0% 134ms ± 0% ~ (p=0.700 n=3+3) Latency/DynamicPacket/200kbps/TLSv13-10 138ms ± 0% 138ms ± 0% ~ (p=1.000 n=3+3) Latency/DynamicPacket/500kbps/TLSv12-10 54.1ms ± 0% 54.1ms ± 0% ~ (p=1.000 n=3+3) Latency/DynamicPacket/500kbps/TLSv13-10 55.7ms ± 0% 55.7ms ± 0% ~ (p=0.100 n=3+3) Latency/DynamicPacket/1000kbps/TLSv12-10 27.6ms ± 0% 27.6ms ± 0% ~ (p=0.200 n=3+3) Latency/DynamicPacket/1000kbps/TLSv13-10 28.4ms ± 0% 28.4ms ± 0% ~ (p=0.200 n=3+3) Latency/DynamicPacket/2000kbps/TLSv12-10 14.4ms ± 0% 14.4ms ± 0% ~ (p=1.000 n=3+3) Latency/DynamicPacket/2000kbps/TLSv13-10 14.6ms ± 0% 14.6ms ± 0% ~ (p=1.000 n=3+3) Latency/DynamicPacket/5000kbps/TLSv12-10 6.44ms ± 0% 6.45ms ± 0% ~ (p=0.100 n=3+3) Latency/DynamicPacket/5000kbps/TLSv13-10 6.49ms ± 0% 6.49ms ± 0% ~ (p=0.700 n=3+3) name old speed new speed delta Throughput/MaxPacket/1MB/TLSv12-10 155MB/s ± 3% 156MB/s ± 0% ~ (p=1.000 n=3+3) Throughput/MaxPacket/1MB/TLSv13-10 156MB/s ± 1% 155MB/s ± 0% ~ (p=0.700 n=3+3) Throughput/MaxPacket/2MB/TLSv12-10 163MB/s ± 2% 165MB/s ± 0% ~ (p=0.700 n=3+3) Throughput/MaxPacket/2MB/TLSv13-10 160MB/s ± 3% 164MB/s ± 1% ~ (p=0.400 n=3+3) Throughput/MaxPacket/4MB/TLSv12-10 168MB/s ± 2% 170MB/s ± 1% ~ (p=1.000 n=3+3) Throughput/MaxPacket/4MB/TLSv13-10 162MB/s ± 4% 168MB/s ± 1% ~ (p=0.100 n=3+3) Throughput/MaxPacket/8MB/TLSv12-10 168MB/s ± 3% 172MB/s ± 0% ~ (p=0.200 n=3+3) Throughput/MaxPacket/8MB/TLSv13-10 168MB/s ± 2% 170MB/s ± 1% ~ (p=0.400 n=3+3) Throughput/MaxPacket/16MB/TLSv12-10 172MB/s ± 1% 172MB/s ± 0% ~ (p=0.700 n=3+3) Throughput/MaxPacket/16MB/TLSv13-10 171MB/s ± 0% 171MB/s ± 1% ~ (p=1.000 n=3+3) Throughput/MaxPacket/32MB/TLSv12-10 172MB/s ± 0% 173MB/s ± 1% ~ (p=0.400 n=3+3) Throughput/MaxPacket/32MB/TLSv13-10 171MB/s ± 0% 172MB/s ± 1% ~ (p=0.700 n=3+3) Throughput/MaxPacket/64MB/TLSv12-10 166MB/s ± 3% 174MB/s ± 0% ~ (p=0.100 n=3+3) Throughput/MaxPacket/64MB/TLSv13-10 171MB/s ± 1% 173MB/s ± 1% ~ (p=0.200 n=3+3) Throughput/DynamicPacket/1MB/TLSv12-10 155MB/s ± 0% 155MB/s ± 1% ~ (p=0.700 n=3+3) Throughput/DynamicPacket/1MB/TLSv13-10 153MB/s ± 1% 155MB/s ± 0% ~ (p=0.100 n=3+3) Throughput/DynamicPacket/2MB/TLSv12-10 164MB/s ± 1% 164MB/s ± 1% ~ (p=0.400 n=3+3) Throughput/DynamicPacket/2MB/TLSv13-10 163MB/s ± 1% 162MB/s ± 1% ~ (p=0.200 n=3+3) Throughput/DynamicPacket/4MB/TLSv12-10 169MB/s ± 1% 169MB/s ± 0% ~ (p=1.000 n=3+3) Throughput/DynamicPacket/4MB/TLSv13-10 167MB/s ± 1% 167MB/s ± 1% ~ (p=1.000 n=3+3) Throughput/DynamicPacket/8MB/TLSv12-10 170MB/s ± 2% 171MB/s ± 0% ~ (p=0.700 n=3+3) Throughput/DynamicPacket/8MB/TLSv13-10 170MB/s ± 1% 170MB/s ± 1% ~ (p=0.700 n=3+3) Throughput/DynamicPacket/16MB/TLSv12-10 173MB/s ± 0% 171MB/s ± 1% ~ (p=0.200 n=3+3) Throughput/DynamicPacket/16MB/TLSv13-10 170MB/s ± 1% 170MB/s ± 1% ~ (p=0.700 n=3+3) Throughput/DynamicPacket/32MB/TLSv12-10 175MB/s ± 0% 170MB/s ± 5% ~ (p=0.100 n=3+3) Throughput/DynamicPacket/32MB/TLSv13-10 173MB/s ± 0% 171MB/s ± 1% ~ (p=0.300 n=3+3) Throughput/DynamicPacket/64MB/TLSv12-10 174MB/s ± 1% 175MB/s ± 0% ~ (p=0.700 n=3+3) Throughput/DynamicPacket/64MB/TLSv13-10 174MB/s ± 0% 173MB/s ± 0% ~ (p=0.400 n=3+3) Change-Id: Ifa79cce002011850ed8b2835edd34f60e014eea8 Cq-Include-Trybots: luci.golang.try:gotip-linux-amd64-longtest,gotip-linux-arm64-longtest Reviewed-on: https://go-review.googlesource.com/c/go/+/580215 LUCI-TryBot-Result: Go LUCI Reviewed-by: Damien Neil Reviewed-by: Filippo Valsorda Auto-Submit: Roland Shoemaker --- common.go | 9 ++ handshake_client_tls13.go | 1 - handshake_messages.go | 211 ++++++++++--------------------------- handshake_messages_test.go | 82 ++++++++------ 4 files changed, 114 insertions(+), 189 deletions(-) diff --git a/common.go b/common.go index 849e8b0..58dc0c2 100644 --- a/common.go +++ b/common.go @@ -1445,6 +1445,15 @@ type handshakeMessage interface { unmarshal([]byte) bool } +type handshakeMessageWithOriginalBytes interface { + handshakeMessage + + // originalBytes should return the original bytes that were passed to + // unmarshal to create the message. If the message was not produced by + // unmarshal, it should return nil. + originalBytes() []byte +} + // lruSessionCache is a ClientSessionCache implementation that uses an LRU // caching strategy. type lruSessionCache struct { diff --git a/handshake_client_tls13.go b/handshake_client_tls13.go index a0fc413..bc8670a 100644 --- a/handshake_client_tls13.go +++ b/handshake_client_tls13.go @@ -249,7 +249,6 @@ func (hs *clientHandshakeStateTLS13) processHelloRetryRequest() error { hs.hello.keyShares = []keyShare{{group: curveID, data: key.PublicKey().Bytes()}} } - hs.hello.raw = nil if len(hs.hello.pskIdentities) > 0 { pskSuite := cipherSuiteTLS13ByID(hs.session.cipherSuite) if pskSuite == nil { diff --git a/handshake_messages.go b/handshake_messages.go index a86055a..b1920db 100644 --- a/handshake_messages.go +++ b/handshake_messages.go @@ -68,7 +68,7 @@ func readUint24LengthPrefixed(s *cryptobyte.String, out *[]byte) bool { } type clientHelloMsg struct { - raw []byte + original []byte vers uint16 random []byte sessionId []byte @@ -98,10 +98,6 @@ type clientHelloMsg struct { } func (m *clientHelloMsg) marshal() ([]byte, error) { - if m.raw != nil { - return m.raw, nil - } - var exts cryptobyte.Builder if len(m.serverName) > 0 { // RFC 6066, Section 3 @@ -310,8 +306,7 @@ func (m *clientHelloMsg) marshal() ([]byte, error) { } }) - m.raw, err = b.Bytes() - return m.raw, err + return b.Bytes() } // marshalWithoutBinders returns the ClientHello through the @@ -324,16 +319,21 @@ func (m *clientHelloMsg) marshalWithoutBinders() ([]byte, error) { bindersLen += len(binder) } - fullMessage, err := m.marshal() - if err != nil { - return nil, err + var fullMessage []byte + if m.original != nil { + fullMessage = m.original + } else { + var err error + fullMessage, err = m.marshal() + if err != nil { + return nil, err + } } return fullMessage[:len(fullMessage)-bindersLen], nil } -// updateBinders updates the m.pskBinders field, if necessary updating the -// cached marshaled representation. The supplied binders must have the same -// length as the current m.pskBinders. +// updateBinders updates the m.pskBinders field. The supplied binders must have +// the same length as the current m.pskBinders. func (m *clientHelloMsg) updateBinders(pskBinders [][]byte) error { if len(pskBinders) != len(m.pskBinders) { return errors.New("tls: internal error: pskBinders length mismatch") @@ -344,30 +344,12 @@ func (m *clientHelloMsg) updateBinders(pskBinders [][]byte) error { } } m.pskBinders = pskBinders - if m.raw != nil { - helloBytes, err := m.marshalWithoutBinders() - if err != nil { - return err - } - lenWithoutBinders := len(helloBytes) - b := cryptobyte.NewFixedBuilder(m.raw[:lenWithoutBinders]) - b.AddUint16LengthPrefixed(func(b *cryptobyte.Builder) { - for _, binder := range m.pskBinders { - b.AddUint8LengthPrefixed(func(b *cryptobyte.Builder) { - b.AddBytes(binder) - }) - } - }) - if out, err := b.Bytes(); err != nil || len(out) != len(m.raw) { - return errors.New("tls: internal error: failed to update binders") - } - } return nil } func (m *clientHelloMsg) unmarshal(data []byte) bool { - *m = clientHelloMsg{raw: data} + *m = clientHelloMsg{original: data} s := cryptobyte.String(data) if !s.Skip(4) || // message type and uint24 length field @@ -625,8 +607,12 @@ func (m *clientHelloMsg) unmarshal(data []byte) bool { return true } +func (m *clientHelloMsg) originalBytes() []byte { + return m.original +} + type serverHelloMsg struct { - raw []byte + original []byte vers uint16 random []byte sessionId []byte @@ -651,10 +637,6 @@ type serverHelloMsg struct { } func (m *serverHelloMsg) marshal() ([]byte, error) { - if m.raw != nil { - return m.raw, nil - } - var exts cryptobyte.Builder if m.ocspStapling { exts.AddUint16(extensionStatusRequest) @@ -766,12 +748,11 @@ func (m *serverHelloMsg) marshal() ([]byte, error) { } }) - m.raw, err = b.Bytes() - return m.raw, err + return b.Bytes() } func (m *serverHelloMsg) unmarshal(data []byte) bool { - *m = serverHelloMsg{raw: data} + *m = serverHelloMsg{original: data} s := cryptobyte.String(data) if !s.Skip(4) || // message type and uint24 length field @@ -888,18 +869,17 @@ func (m *serverHelloMsg) unmarshal(data []byte) bool { return true } +func (m *serverHelloMsg) originalBytes() []byte { + return m.original +} + type encryptedExtensionsMsg struct { - raw []byte alpnProtocol string quicTransportParameters []byte earlyData bool } func (m *encryptedExtensionsMsg) marshal() ([]byte, error) { - if m.raw != nil { - return m.raw, nil - } - var b cryptobyte.Builder b.AddUint8(typeEncryptedExtensions) b.AddUint24LengthPrefixed(func(b *cryptobyte.Builder) { @@ -929,13 +909,11 @@ func (m *encryptedExtensionsMsg) marshal() ([]byte, error) { }) }) - var err error - m.raw, err = b.Bytes() - return m.raw, err + return b.Bytes() } func (m *encryptedExtensionsMsg) unmarshal(data []byte) bool { - *m = encryptedExtensionsMsg{raw: data} + *m = encryptedExtensionsMsg{} s := cryptobyte.String(data) var extensions cryptobyte.String @@ -998,15 +976,10 @@ func (m *endOfEarlyDataMsg) unmarshal(data []byte) bool { } type keyUpdateMsg struct { - raw []byte updateRequested bool } func (m *keyUpdateMsg) marshal() ([]byte, error) { - if m.raw != nil { - return m.raw, nil - } - var b cryptobyte.Builder b.AddUint8(typeKeyUpdate) b.AddUint24LengthPrefixed(func(b *cryptobyte.Builder) { @@ -1017,13 +990,10 @@ func (m *keyUpdateMsg) marshal() ([]byte, error) { } }) - var err error - m.raw, err = b.Bytes() - return m.raw, err + return b.Bytes() } func (m *keyUpdateMsg) unmarshal(data []byte) bool { - m.raw = data s := cryptobyte.String(data) var updateRequested uint8 @@ -1043,7 +1013,6 @@ func (m *keyUpdateMsg) unmarshal(data []byte) bool { } type newSessionTicketMsgTLS13 struct { - raw []byte lifetime uint32 ageAdd uint32 nonce []byte @@ -1052,10 +1021,6 @@ type newSessionTicketMsgTLS13 struct { } func (m *newSessionTicketMsgTLS13) marshal() ([]byte, error) { - if m.raw != nil { - return m.raw, nil - } - var b cryptobyte.Builder b.AddUint8(typeNewSessionTicket) b.AddUint24LengthPrefixed(func(b *cryptobyte.Builder) { @@ -1078,13 +1043,11 @@ func (m *newSessionTicketMsgTLS13) marshal() ([]byte, error) { }) }) - var err error - m.raw, err = b.Bytes() - return m.raw, err + return b.Bytes() } func (m *newSessionTicketMsgTLS13) unmarshal(data []byte) bool { - *m = newSessionTicketMsgTLS13{raw: data} + *m = newSessionTicketMsgTLS13{} s := cryptobyte.String(data) var extensions cryptobyte.String @@ -1125,7 +1088,6 @@ func (m *newSessionTicketMsgTLS13) unmarshal(data []byte) bool { } type certificateRequestMsgTLS13 struct { - raw []byte ocspStapling bool scts bool supportedSignatureAlgorithms []SignatureScheme @@ -1134,10 +1096,6 @@ type certificateRequestMsgTLS13 struct { } func (m *certificateRequestMsgTLS13) marshal() ([]byte, error) { - if m.raw != nil { - return m.raw, nil - } - var b cryptobyte.Builder b.AddUint8(typeCertificateRequest) b.AddUint24LengthPrefixed(func(b *cryptobyte.Builder) { @@ -1194,13 +1152,11 @@ func (m *certificateRequestMsgTLS13) marshal() ([]byte, error) { }) }) - var err error - m.raw, err = b.Bytes() - return m.raw, err + return b.Bytes() } func (m *certificateRequestMsgTLS13) unmarshal(data []byte) bool { - *m = certificateRequestMsgTLS13{raw: data} + *m = certificateRequestMsgTLS13{} s := cryptobyte.String(data) var context, extensions cryptobyte.String @@ -1276,15 +1232,10 @@ func (m *certificateRequestMsgTLS13) unmarshal(data []byte) bool { } type certificateMsg struct { - raw []byte certificates [][]byte } func (m *certificateMsg) marshal() ([]byte, error) { - if m.raw != nil { - return m.raw, nil - } - var i int for _, slice := range m.certificates { i += len(slice) @@ -1311,8 +1262,7 @@ func (m *certificateMsg) marshal() ([]byte, error) { y = y[3+len(slice):] } - m.raw = x - return m.raw, nil + return x, nil } func (m *certificateMsg) unmarshal(data []byte) bool { @@ -1320,7 +1270,6 @@ func (m *certificateMsg) unmarshal(data []byte) bool { return false } - m.raw = data certsLen := uint32(data[4])<<16 | uint32(data[5])<<8 | uint32(data[6]) if uint32(len(data)) != certsLen+7 { return false @@ -1353,17 +1302,12 @@ func (m *certificateMsg) unmarshal(data []byte) bool { } type certificateMsgTLS13 struct { - raw []byte certificate Certificate ocspStapling bool scts bool } func (m *certificateMsgTLS13) marshal() ([]byte, error) { - if m.raw != nil { - return m.raw, nil - } - var b cryptobyte.Builder b.AddUint8(typeCertificate) b.AddUint24LengthPrefixed(func(b *cryptobyte.Builder) { @@ -1379,9 +1323,7 @@ func (m *certificateMsgTLS13) marshal() ([]byte, error) { marshalCertificate(b, certificate) }) - var err error - m.raw, err = b.Bytes() - return m.raw, err + return b.Bytes() } func marshalCertificate(b *cryptobyte.Builder, certificate Certificate) { @@ -1422,7 +1364,7 @@ func marshalCertificate(b *cryptobyte.Builder, certificate Certificate) { } func (m *certificateMsgTLS13) unmarshal(data []byte) bool { - *m = certificateMsgTLS13{raw: data} + *m = certificateMsgTLS13{} s := cryptobyte.String(data) var context cryptobyte.String @@ -1500,14 +1442,10 @@ func unmarshalCertificate(s *cryptobyte.String, certificate *Certificate) bool { } type serverKeyExchangeMsg struct { - raw []byte key []byte } func (m *serverKeyExchangeMsg) marshal() ([]byte, error) { - if m.raw != nil { - return m.raw, nil - } length := len(m.key) x := make([]byte, length+4) x[0] = typeServerKeyExchange @@ -1516,12 +1454,10 @@ func (m *serverKeyExchangeMsg) marshal() ([]byte, error) { x[3] = uint8(length) copy(x[4:], m.key) - m.raw = x return x, nil } func (m *serverKeyExchangeMsg) unmarshal(data []byte) bool { - m.raw = data if len(data) < 4 { return false } @@ -1530,15 +1466,10 @@ func (m *serverKeyExchangeMsg) unmarshal(data []byte) bool { } type certificateStatusMsg struct { - raw []byte response []byte } func (m *certificateStatusMsg) marshal() ([]byte, error) { - if m.raw != nil { - return m.raw, nil - } - var b cryptobyte.Builder b.AddUint8(typeCertificateStatus) b.AddUint24LengthPrefixed(func(b *cryptobyte.Builder) { @@ -1548,13 +1479,10 @@ func (m *certificateStatusMsg) marshal() ([]byte, error) { }) }) - var err error - m.raw, err = b.Bytes() - return m.raw, err + return b.Bytes() } func (m *certificateStatusMsg) unmarshal(data []byte) bool { - m.raw = data s := cryptobyte.String(data) var statusType uint8 @@ -1580,14 +1508,10 @@ func (m *serverHelloDoneMsg) unmarshal(data []byte) bool { } type clientKeyExchangeMsg struct { - raw []byte ciphertext []byte } func (m *clientKeyExchangeMsg) marshal() ([]byte, error) { - if m.raw != nil { - return m.raw, nil - } length := len(m.ciphertext) x := make([]byte, length+4) x[0] = typeClientKeyExchange @@ -1596,12 +1520,10 @@ func (m *clientKeyExchangeMsg) marshal() ([]byte, error) { x[3] = uint8(length) copy(x[4:], m.ciphertext) - m.raw = x return x, nil } func (m *clientKeyExchangeMsg) unmarshal(data []byte) bool { - m.raw = data if len(data) < 4 { return false } @@ -1614,28 +1536,20 @@ func (m *clientKeyExchangeMsg) unmarshal(data []byte) bool { } type finishedMsg struct { - raw []byte verifyData []byte } func (m *finishedMsg) marshal() ([]byte, error) { - if m.raw != nil { - return m.raw, nil - } - var b cryptobyte.Builder b.AddUint8(typeFinished) b.AddUint24LengthPrefixed(func(b *cryptobyte.Builder) { b.AddBytes(m.verifyData) }) - var err error - m.raw, err = b.Bytes() - return m.raw, err + return b.Bytes() } func (m *finishedMsg) unmarshal(data []byte) bool { - m.raw = data s := cryptobyte.String(data) return s.Skip(1) && readUint24LengthPrefixed(&s, &m.verifyData) && @@ -1643,7 +1557,6 @@ func (m *finishedMsg) unmarshal(data []byte) bool { } type certificateRequestMsg struct { - raw []byte // hasSignatureAlgorithm indicates whether this message includes a list of // supported signature algorithms. This change was introduced with TLS 1.2. hasSignatureAlgorithm bool @@ -1654,10 +1567,6 @@ type certificateRequestMsg struct { } func (m *certificateRequestMsg) marshal() ([]byte, error) { - if m.raw != nil { - return m.raw, nil - } - // See RFC 4346, Section 7.4.4. length := 1 + len(m.certificateTypes) + 2 casLength := 0 @@ -1704,13 +1613,10 @@ func (m *certificateRequestMsg) marshal() ([]byte, error) { y = y[len(ca):] } - m.raw = x - return m.raw, nil + return x, nil } func (m *certificateRequestMsg) unmarshal(data []byte) bool { - m.raw = data - if len(data) < 5 { return false } @@ -1785,17 +1691,12 @@ func (m *certificateRequestMsg) unmarshal(data []byte) bool { } type certificateVerifyMsg struct { - raw []byte hasSignatureAlgorithm bool // format change introduced in TLS 1.2 signatureAlgorithm SignatureScheme signature []byte } func (m *certificateVerifyMsg) marshal() ([]byte, error) { - if m.raw != nil { - return m.raw, nil - } - var b cryptobyte.Builder b.AddUint8(typeCertificateVerify) b.AddUint24LengthPrefixed(func(b *cryptobyte.Builder) { @@ -1807,13 +1708,10 @@ func (m *certificateVerifyMsg) marshal() ([]byte, error) { }) }) - var err error - m.raw, err = b.Bytes() - return m.raw, err + return b.Bytes() } func (m *certificateVerifyMsg) unmarshal(data []byte) bool { - m.raw = data s := cryptobyte.String(data) if !s.Skip(4) { // message type and uint24 length field @@ -1828,15 +1726,10 @@ func (m *certificateVerifyMsg) unmarshal(data []byte) bool { } type newSessionTicketMsg struct { - raw []byte ticket []byte } func (m *newSessionTicketMsg) marshal() ([]byte, error) { - if m.raw != nil { - return m.raw, nil - } - // See RFC 5077, Section 3.3. ticketLen := len(m.ticket) length := 2 + 4 + ticketLen @@ -1849,14 +1742,10 @@ func (m *newSessionTicketMsg) marshal() ([]byte, error) { x[9] = uint8(ticketLen) copy(x[10:], m.ticket) - m.raw = x - - return m.raw, nil + return x, nil } func (m *newSessionTicketMsg) unmarshal(data []byte) bool { - m.raw = data - if len(data) < 10 { return false } @@ -1891,9 +1780,25 @@ type transcriptHash interface { Write([]byte) (int, error) } -// transcriptMsg is a helper used to marshal and hash messages which typically -// are not written to the wire, and as such aren't hashed during Conn.writeRecord. +// transcriptMsg is a helper used to hash messages which are not hashed when +// they are read from, or written to, the wire. This is typically the case for +// messages which are either not sent, or need to be hashed out of order from +// when they are read/written. +// +// For most messages, the message is marshalled using their marshal method, +// since their wire representation is idempotent. For clientHelloMsg and +// serverHelloMsg, we store the original wire representation of the message and +// use that for hashing, since unmarshal/marshal are not idempotent due to +// extension ordering and other malleable fields, which may cause differences +// between what was received and what we marshal. func transcriptMsg(msg handshakeMessage, h transcriptHash) error { + if msgWithOrig, ok := msg.(handshakeMessageWithOriginalBytes); ok { + if orig := msgWithOrig.originalBytes(); orig != nil { + h.Write(msgWithOrig.originalBytes()) + return nil + } + } + data, err := msg.marshal() if err != nil { return err diff --git a/handshake_messages_test.go b/handshake_messages_test.go index 72e8bd8..6c083f1 100644 --- a/handshake_messages_test.go +++ b/handshake_messages_test.go @@ -53,49 +53,61 @@ func TestMarshalUnmarshal(t *testing.T) { for i, m := range tests { ty := reflect.ValueOf(m).Type() - - n := 100 - if testing.Short() { - n = 5 - } - for j := 0; j < n; j++ { - v, ok := quick.Value(ty, rand) - if !ok { - t.Errorf("#%d: failed to create value", i) - break + t.Run(ty.String(), func(t *testing.T) { + n := 100 + if testing.Short() { + n = 5 } + for j := 0; j < n; j++ { + v, ok := quick.Value(ty, rand) + if !ok { + t.Errorf("#%d: failed to create value", i) + break + } - m1 := v.Interface().(handshakeMessage) - marshaled := mustMarshal(t, m1) - if !m.unmarshal(marshaled) { - t.Errorf("#%d failed to unmarshal %#v %x", i, m1, marshaled) - break - } - m.marshal() // to fill any marshal cache in the message + m1 := v.Interface().(handshakeMessage) + marshaled := mustMarshal(t, m1) + if !m.unmarshal(marshaled) { + t.Errorf("#%d failed to unmarshal %#v %x", i, m1, marshaled) + break + } - if m, ok := m.(*SessionState); ok { - m.activeCertHandles = nil - } + if m, ok := m.(*SessionState); ok { + m.activeCertHandles = nil + } - if !reflect.DeepEqual(m1, m) { - t.Errorf("#%d got:%#v want:%#v %x", i, m, m1, marshaled) - break - } + // clientHelloMsg and serverHelloMsg, when unmarshalled, store + // their original representation, for later use in the handshake + // transcript. In order to prevent DeepEqual from failing since + // we didn't create the original message via unmarshalling, nil + // the field. + switch t := m.(type) { + case *clientHelloMsg: + t.original = nil + case *serverHelloMsg: + t.original = nil + } - if i >= 3 { - // The first three message types (ClientHello, - // ServerHello and Finished) are allowed to - // have parsable prefixes because the extension - // data is optional and the length of the - // Finished varies across versions. - for j := 0; j < len(marshaled); j++ { - if m.unmarshal(marshaled[0:j]) { - t.Errorf("#%d unmarshaled a prefix of length %d of %#v", i, j, m1) - break + if !reflect.DeepEqual(m1, m) { + t.Errorf("#%d got:%#v want:%#v %x", i, m, m1, marshaled) + break + } + + if i >= 3 { + // The first three message types (ClientHello, + // ServerHello and Finished) are allowed to + // have parsable prefixes because the extension + // data is optional and the length of the + // Finished varies across versions. + for j := 0; j < len(marshaled); j++ { + if m.unmarshal(marshaled[0:j]) { + t.Errorf("#%d unmarshaled a prefix of length %d of %#v", i, j, m1) + break + } } } } - } + }) } } From eae001cbd45989fd5f7dda8b0c713bc019b05283 Mon Sep 17 00:00:00 2001 From: Roland Shoemaker Date: Wed, 24 Apr 2024 10:04:01 -0700 Subject: [PATCH 08/39] crypto/tls: skip bogo suite on windows builders Updates #66913 Change-Id: Ie6bb262ee95593d23a93ef06656a561a7b1006ba Reviewed-on: https://go-review.googlesource.com/c/go/+/581515 Auto-Submit: Roland Shoemaker LUCI-TryBot-Result: Go LUCI Reviewed-by: Michael Matloob --- bogo_shim_test.go | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/bogo_shim_test.go b/bogo_shim_test.go index f12733a..731fcd6 100644 --- a/bogo_shim_test.go +++ b/bogo_shim_test.go @@ -14,6 +14,7 @@ import ( "os" "os/exec" "path/filepath" + "runtime" "testing" ) @@ -233,6 +234,10 @@ func TestBogoSuite(t *testing.T) { t.Skip("skipping in short mode") } + if testenv.Builder() != "" && runtime.GOOS == "windows" { + t.Skip("#66913: windows network connections are flakey on builders") + } + const boringsslModVer = "v0.0.0-20240412155355-1c6e10495e4f" output, err := exec.Command("go", "mod", "download", "-json", "github.com/google/boringssl@"+boringsslModVer).CombinedOutput() if err != nil { From 5197ef458951f31f354ca4a30ac3f021494ce78d Mon Sep 17 00:00:00 2001 From: Mateusz Poliwczak Date: Sat, 11 May 2024 09:37:50 +0000 Subject: [PATCH 09/39] crypto: replace encoding/binary in favour of internal/byteorder Updates #54097 Change-Id: I827a5efd1736ce057b76f079466f2d9ead225898 GitHub-Last-Rev: 40af10469d85ce9f4bef4b40025589d9e44f43d6 GitHub-Pull-Request: golang/go#67321 Reviewed-on: https://go-review.googlesource.com/c/go/+/585017 Reviewed-by: Keith Randall Reviewed-by: Keith Randall Auto-Submit: Keith Randall Commit-Queue: Ian Lance Taylor LUCI-TryBot-Result: Go LUCI Auto-Submit: Ian Lance Taylor Reviewed-by: Ian Lance Taylor --- bogo_shim_test.go | 4 ++-- handshake_client_test.go | 4 ++-- handshake_server_tls13.go | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/bogo_shim_test.go b/bogo_shim_test.go index 731fcd6..e1a393c 100644 --- a/bogo_shim_test.go +++ b/bogo_shim_test.go @@ -2,11 +2,11 @@ package tls import ( "crypto/x509" - "encoding/binary" "encoding/json" "encoding/pem" "flag" "fmt" + "internal/byteorder" "internal/testenv" "io" "log" @@ -186,7 +186,7 @@ func bogoShim() { // Write the shim ID we were passed as a little endian uint64 shimIDBytes := make([]byte, 8) - binary.LittleEndian.PutUint64(shimIDBytes, *shimID) + byteorder.LePutUint64(shimIDBytes, *shimID) if _, err := conn.Write(shimIDBytes); err != nil { log.Fatalf("failed to write shim id: %s", err) } diff --git a/handshake_client_test.go b/handshake_client_test.go index ee9e79a..157c67f 100644 --- a/handshake_client_test.go +++ b/handshake_client_test.go @@ -10,10 +10,10 @@ import ( "crypto/rsa" "crypto/x509" "encoding/base64" - "encoding/binary" "encoding/pem" "errors" "fmt" + "internal/byteorder" "io" "math/big" "net" @@ -202,7 +202,7 @@ func (test *clientTest) connFromCommand() (conn *recordingConn, child *exec.Cmd, var serverInfo bytes.Buffer for _, ext := range test.extensions { pem.Encode(&serverInfo, &pem.Block{ - Type: fmt.Sprintf("SERVERINFO FOR EXTENSION %d", binary.BigEndian.Uint16(ext)), + Type: fmt.Sprintf("SERVERINFO FOR EXTENSION %d", byteorder.BeUint16(ext)), Bytes: ext, }) } diff --git a/handshake_server_tls13.go b/handshake_server_tls13.go index 60a3883..7f15d05 100644 --- a/handshake_server_tls13.go +++ b/handshake_server_tls13.go @@ -10,9 +10,9 @@ import ( "crypto" "crypto/hmac" "crypto/rsa" - "encoding/binary" "errors" "hash" + "internal/byteorder" "io" "time" ) @@ -866,7 +866,7 @@ func (c *Conn) sendSessionTicket(earlyData bool) error { if _, err := c.config.rand().Read(ageAdd); err != nil { return err } - m.ageAdd = binary.LittleEndian.Uint32(ageAdd) + m.ageAdd = byteorder.LeUint32(ageAdd) if earlyData { // RFC 9001, Section 4.6.1 From ce8a8c0012b0e4c83ffb5817c11a92c10c1f4de5 Mon Sep 17 00:00:00 2001 From: Mike Beaumont Date: Mon, 29 Apr 2024 12:14:32 +0200 Subject: [PATCH 10/39] crypto/tls: don't call tlsrsakex.IncNonDefault with FIPS We haven't called tlsrsakex.Value() yet at this point if we're using FIPS, like if CipherSuites != nil. This adds needFIPS as a gate next to CipherSuites != nil. FIPS specifies suites that would be skipped if tlsarsakex were set. Fixes #65991 Change-Id: I8070d8f43f27c04067490af8cc7ec5e787f2b9bd Reviewed-on: https://go-review.googlesource.com/c/go/+/582315 Reviewed-by: Filippo Valsorda Reviewed-by: Cherry Mui TryBot-Bypass: Filippo Valsorda Auto-Submit: Filippo Valsorda Reviewed-by: Dmitri Shuralyov --- handshake_client.go | 2 +- handshake_server.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/handshake_client.go b/handshake_client.go index 0b35dee..d046c86 100644 --- a/handshake_client.go +++ b/handshake_client.go @@ -526,7 +526,7 @@ func (hs *clientHandshakeState) pickCipherSuite() error { return errors.New("tls: server chose an unconfigured cipher suite") } - if hs.c.config.CipherSuites == nil && rsaKexCiphers[hs.suite.id] { + if hs.c.config.CipherSuites == nil && !needFIPS() && rsaKexCiphers[hs.suite.id] { tlsrsakex.IncNonDefault() } diff --git a/handshake_server.go b/handshake_server.go index eb87ee0..d5f8cc8 100644 --- a/handshake_server.go +++ b/handshake_server.go @@ -370,7 +370,7 @@ func (hs *serverHandshakeState) pickCipherSuite() error { } c.cipherSuite = hs.suite.id - if c.config.CipherSuites == nil && rsaKexCiphers[hs.suite.id] { + if c.config.CipherSuites == nil && !needFIPS() && rsaKexCiphers[hs.suite.id] { tlsrsakex.IncNonDefault() } From 2a85364a0932e4cd1cb28ba055e5c462109cd5ef Mon Sep 17 00:00:00 2001 From: Cherry Mui Date: Thu, 16 May 2024 17:19:15 -0400 Subject: [PATCH 11/39] all: add push linknames to allow legacy pull linknames CL 585358 adds restrictions to disallow pull-only linknames (currently off by default). Currently, there are quite some pull- only linknames in user code in the wild. In order not to break those, we add push linknames to allow them to be pulled. This CL includes linknames found in a large code corpus (thanks Matthew Dempsky and Michael Pratt for the analysis!), that are not currently linknamed. Updates #67401. Change-Id: I32f5fc0c7a6abbd7a11359a025cfa2bf458fe767 Reviewed-on: https://go-review.googlesource.com/c/go/+/586137 Reviewed-by: Russ Cox LUCI-TryBot-Result: Go LUCI --- badlinkname.go | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 badlinkname.go diff --git a/badlinkname.go b/badlinkname.go new file mode 100644 index 0000000..97350e4 --- /dev/null +++ b/badlinkname.go @@ -0,0 +1,27 @@ +// Copyright 2024 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +package tls + +import _ "unsafe" + +// As of Go 1.22, the symbols below are found to be pulled via +// linkname in the wild. We provide a push linkname here, to +// keep them accessible with pull linknames. +// This may change in the future. Please do not depend on them +// in new code. + +//go:linkname aeadAESGCMTLS13 +//go:linkname cipherSuiteTLS13ByID +//go:linkname cipherSuitesTLS13 +//go:linkname defaultCipherSuitesTLS13 +//go:linkname defaultCipherSuitesTLS13NoAES +//go:linkname errShutdown + +// The compiler doesn't allow linknames on methods, for good reasons. +// We use this trick to push linknames of the methods. +// Do not call them in this package. + +//go:linkname badlinkname_halfConn_incSeq crypto/tls.(*halfConn).incSeq +func badlinkname_halfConn_incSeq(*halfConn) From 245de0a13b1cd91e81a22eef1c5215a35e37c15a Mon Sep 17 00:00:00 2001 From: Filippo Valsorda Date: Sat, 18 May 2024 19:35:39 +0200 Subject: [PATCH 12/39] crypto/tls: clarify group selection logic I initially thought the logic was broken, but writing the test I realized it was actually very clever (derogative). It was relying on the outer loop continuing after a supported match without a key share, allowing a later key share to override it (but not a later supported match because of the "if selectedGroup != 0 { continue }"). Replaced the clever loop with two hopefully more understandable loops, and added a test (which was already passing). We were however not checking that the selected group is in the supported list if we found it in key shares first. (This was only a MAY.) Fixed. Fixes #65686 Change-Id: I09ea44f90167ffa36809deb78255ed039a217b6d Reviewed-on: https://go-review.googlesource.com/c/go/+/586655 Reviewed-by: Roland Shoemaker Reviewed-by: Dmitri Shuralyov LUCI-TryBot-Result: Go LUCI Auto-Submit: Filippo Valsorda --- boring_test.go | 69 ++++++++------- common.go | 3 + conn.go | 2 + handshake_client_test.go | 6 ++ handshake_client_tls13.go | 1 + handshake_server_test.go | 80 ++++++++++++++--- handshake_server_tls13.go | 32 ++++--- handshake_test.go | 14 +-- testdata/Server-TLSv13-KeySharePreference | 101 ++++++++++++++++++++++ 9 files changed, 248 insertions(+), 60 deletions(-) create mode 100644 testdata/Server-TLSv13-KeySharePreference diff --git a/boring_test.go b/boring_test.go index 085ff57..77374ab 100644 --- a/boring_test.go +++ b/boring_test.go @@ -26,33 +26,42 @@ import ( ) func TestBoringServerProtocolVersion(t *testing.T) { - test := func(name string, v uint16, msg string) { + test := func(t *testing.T, name string, v uint16, msg string) { t.Run(name, func(t *testing.T) { serverConfig := testConfig.Clone() serverConfig.MinVersion = VersionSSL30 - clientHello := &clientHelloMsg{ - vers: v, - random: make([]byte, 32), - cipherSuites: allCipherSuites(), - compressionMethods: []uint8{compressionNone}, - supportedVersions: []uint16{v}, + clientConfig := testConfig.Clone() + clientConfig.MinVersion = v + clientConfig.MaxVersion = v + _, _, err := testHandshake(t, clientConfig, serverConfig) + if msg == "" { + if err != nil { + t.Fatalf("got error: %v, expected success", err) + } + } else { + if err == nil { + t.Fatalf("got success, expected error") + } + if !strings.Contains(err.Error(), msg) { + t.Fatalf("got error %v, expected %q", err, msg) + } } - testClientHelloFailure(t, serverConfig, clientHello, msg) }) } - test("VersionTLS10", VersionTLS10, "") - test("VersionTLS11", VersionTLS11, "") - test("VersionTLS12", VersionTLS12, "") - test("VersionTLS13", VersionTLS13, "") + test(t, "VersionTLS10", VersionTLS10, "") + test(t, "VersionTLS11", VersionTLS11, "") + test(t, "VersionTLS12", VersionTLS12, "") + test(t, "VersionTLS13", VersionTLS13, "") - fipstls.Force() - defer fipstls.Abandon() - test("VersionSSL30", VersionSSL30, "client offered only unsupported versions") - test("VersionTLS10", VersionTLS10, "client offered only unsupported versions") - test("VersionTLS11", VersionTLS11, "client offered only unsupported versions") - test("VersionTLS12", VersionTLS12, "") - test("VersionTLS13", VersionTLS13, "client offered only unsupported versions") + t.Run("fipstls", func(t *testing.T) { + fipstls.Force() + defer fipstls.Abandon() + test(t, "VersionTLS10", VersionTLS10, "supported versions") + test(t, "VersionTLS11", VersionTLS11, "supported versions") + test(t, "VersionTLS12", VersionTLS12, "") + test(t, "VersionTLS13", VersionTLS13, "supported versions") + }) } func isBoringVersion(v uint16) bool { @@ -154,26 +163,22 @@ func TestBoringServerCurves(t *testing.T) { for _, curveid := range defaultCurvePreferences { t.Run(fmt.Sprintf("curve=%d", curveid), func(t *testing.T) { - clientHello := &clientHelloMsg{ - vers: VersionTLS12, - random: make([]byte, 32), - cipherSuites: []uint16{TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256}, - compressionMethods: []uint8{compressionNone}, - supportedCurves: []CurveID{curveid}, - supportedPoints: []uint8{pointFormatUncompressed}, + clientConfig := testConfig.Clone() + clientConfig.CurvePreferences = []CurveID{curveid} + if _, _, err := testHandshake(t, clientConfig, serverConfig); err != nil { + t.Fatalf("got error: %v, expected success", err) } - testClientHello(t, serverConfig, clientHello) - // With fipstls forced, bad curves should be rejected. t.Run("fipstls", func(t *testing.T) { fipstls.Force() defer fipstls.Abandon() - msg := "" - if !isBoringCurve(curveid) { - msg = "no cipher suite supported by both client and server" + _, _, err := testHandshake(t, clientConfig, serverConfig) + if err != nil && isBoringCurve(curveid) { + t.Fatalf("got error: %v, expected success", err) + } else if err == nil && !isBoringCurve(curveid) { + t.Fatalf("got success, expected error") } - testClientHelloFailure(t, serverConfig, clientHello, msg) }) }) } diff --git a/common.go b/common.go index 58dc0c2..34a3013 100644 --- a/common.go +++ b/common.go @@ -299,6 +299,9 @@ type ConnectionState struct { // ekm is a closure exposed via ExportKeyingMaterial. ekm func(label string, context []byte, length int) ([]byte, error) + + // testingOnlyDidHRR is true if a HelloRetryRequest was sent/received. + testingOnlyDidHRR bool } // ExportKeyingMaterial returns length bytes of exported key material in a new diff --git a/conn.go b/conn.go index 30c5f00..c44f651 100644 --- a/conn.go +++ b/conn.go @@ -48,6 +48,7 @@ type Conn struct { handshakes int extMasterSecret bool didResume bool // whether this connection was a session resumption + didHRR bool // whether a HelloRetryRequest was sent/received cipherSuite uint16 ocspResponse []byte // stapled OCSP response scts [][]byte // signed certificate timestamps from server @@ -1608,6 +1609,7 @@ func (c *Conn) connectionStateLocked() ConnectionState { state.Version = c.vers state.NegotiatedProtocol = c.clientProtocol state.DidResume = c.didResume + state.testingOnlyDidHRR = c.didHRR state.NegotiatedProtocolIsMutual = true state.ServerName = c.serverName state.CipherSuite = c.cipherSuite diff --git a/handshake_client_test.go b/handshake_client_test.go index 157c67f..eb0fe36 100644 --- a/handshake_client_test.go +++ b/handshake_client_test.go @@ -659,6 +659,12 @@ func TestHandshakeClientHelloRetryRequest(t *testing.T) { name: "HelloRetryRequest", args: []string{"-cipher", "ECDHE-RSA-AES128-GCM-SHA256", "-curves", "P-256"}, config: config, + validate: func(cs ConnectionState) error { + if !cs.testingOnlyDidHRR { + return errors.New("expected HelloRetryRequest") + } + return nil + }, } runClientTestTLS13(t, test) diff --git a/handshake_client_tls13.go b/handshake_client_tls13.go index bc8670a..88ec383 100644 --- a/handshake_client_tls13.go +++ b/handshake_client_tls13.go @@ -307,6 +307,7 @@ func (hs *clientHandshakeStateTLS13) processHelloRetryRequest() error { return err } + c.didHRR = true return nil } diff --git a/handshake_server_test.go b/handshake_server_test.go index ff0b479..813495d 100644 --- a/handshake_server_test.go +++ b/handshake_server_test.go @@ -52,16 +52,33 @@ func testClientHelloFailure(t *testing.T, serverConfig *Config, m handshakeMessa ctx := context.Background() conn := Server(s, serverConfig) ch, err := conn.readClientHello(ctx) - hs := serverHandshakeState{ - c: conn, - ctx: ctx, - clientHello: ch, - } - if err == nil { - err = hs.processClientHello() - } - if err == nil { - err = hs.pickCipherSuite() + if conn.vers == VersionTLS13 { + hs := serverHandshakeStateTLS13{ + c: conn, + ctx: ctx, + clientHello: ch, + } + if err == nil { + err = hs.processClientHello() + } + if err == nil { + err = hs.checkForResumption() + } + if err == nil { + err = hs.pickCertificate() + } + } else { + hs := serverHandshakeState{ + c: conn, + ctx: ctx, + clientHello: ch, + } + if err == nil { + err = hs.processClientHello() + } + if err == nil { + err = hs.pickCipherSuite() + } } s.Close() if len(expectedSubStr) == 0 { @@ -903,10 +920,52 @@ func TestHandshakeServerHelloRetryRequest(t *testing.T) { name: "HelloRetryRequest", command: []string{"openssl", "s_client", "-no_ticket", "-ciphersuites", "TLS_CHACHA20_POLY1305_SHA256", "-curves", "X25519:P-256"}, config: config, + validate: func(cs ConnectionState) error { + if !cs.testingOnlyDidHRR { + return errors.New("expected HelloRetryRequest") + } + return nil + }, } runServerTestTLS13(t, test) } +// TestHandshakeServerKeySharePreference checks that we prefer a key share even +// if it's later in the CurvePreferences order. +func TestHandshakeServerKeySharePreference(t *testing.T) { + config := testConfig.Clone() + config.CurvePreferences = []CurveID{X25519, CurveP256} + + test := &serverTest{ + name: "KeySharePreference", + command: []string{"openssl", "s_client", "-no_ticket", "-ciphersuites", "TLS_CHACHA20_POLY1305_SHA256", "-curves", "P-256:X25519"}, + config: config, + validate: func(cs ConnectionState) error { + if cs.testingOnlyDidHRR { + return errors.New("unexpected HelloRetryRequest") + } + return nil + }, + } + runServerTestTLS13(t, test) +} + +// TestHandshakeServerUnsupportedKeyShare tests a client that sends a key share +// that's not in the supported groups list. +func TestHandshakeServerUnsupportedKeyShare(t *testing.T) { + pk, _ := ecdh.X25519().GenerateKey(rand.Reader) + clientHello := &clientHelloMsg{ + vers: VersionTLS12, + random: make([]byte, 32), + supportedVersions: []uint16{VersionTLS13}, + cipherSuites: []uint16{TLS_CHACHA20_POLY1305_SHA256}, + compressionMethods: []uint8{compressionNone}, + keyShares: []keyShare{{group: X25519, data: pk.PublicKey().Bytes()}}, + supportedCurves: []CurveID{CurveP256}, + } + testClientHelloFailure(t, testConfig, clientHello, "client sent key share for group it does not support") +} + func TestHandshakeServerALPN(t *testing.T) { config := testConfig.Clone() config.NextProtos = []string{"proto1", "proto2"} @@ -1932,6 +1991,7 @@ func TestAESCipherReorderingTLS13(t *testing.T) { supportedVersions: []uint16{VersionTLS13}, compressionMethods: []uint8{compressionNone}, keyShares: []keyShare{{group: X25519, data: pk.PublicKey().Bytes()}}, + supportedCurves: []CurveID{X25519}, }, } diff --git a/handshake_server_tls13.go b/handshake_server_tls13.go index 7f15d05..a7d3890 100644 --- a/handshake_server_tls13.go +++ b/handshake_server_tls13.go @@ -14,6 +14,7 @@ import ( "hash" "internal/byteorder" "io" + "slices" "time" ) @@ -181,21 +182,25 @@ func (hs *serverHandshakeStateTLS13) processClientHello() error { // groups with a key share, to avoid a HelloRetryRequest round-trip. var selectedGroup CurveID var clientKeyShare *keyShare -GroupSelection: - for _, preferredGroup := range c.config.curvePreferences() { - for _, ks := range hs.clientHello.keyShares { - if ks.group == preferredGroup { - selectedGroup = ks.group - clientKeyShare = &ks - break GroupSelection + preferredGroups := c.config.curvePreferences() + for _, preferredGroup := range preferredGroups { + ki := slices.IndexFunc(hs.clientHello.keyShares, func(ks keyShare) bool { + return ks.group == preferredGroup + }) + if ki != -1 { + clientKeyShare = &hs.clientHello.keyShares[ki] + selectedGroup = clientKeyShare.group + if !slices.Contains(hs.clientHello.supportedCurves, selectedGroup) { + c.sendAlert(alertIllegalParameter) + return errors.New("tls: client sent key share for group it does not support") } + break } - if selectedGroup != 0 { - continue - } - for _, group := range hs.clientHello.supportedCurves { - if group == preferredGroup { - selectedGroup = group + } + if selectedGroup == 0 { + for _, preferredGroup := range preferredGroups { + if slices.Contains(hs.clientHello.supportedCurves, preferredGroup) { + selectedGroup = preferredGroup break } } @@ -532,6 +537,7 @@ func (hs *serverHandshakeStateTLS13) doHelloRetryRequest(selectedGroup CurveID) return errors.New("tls: client illegally modified second ClientHello") } + c.didHRR = true hs.clientHello = clientHello return nil } diff --git a/handshake_test.go b/handshake_test.go index e365a79..f5e467b 100644 --- a/handshake_test.go +++ b/handshake_test.go @@ -296,6 +296,8 @@ Dialing: case c2 := <-localListener.ch: if c2.RemoteAddr().String() == c1.LocalAddr().String() { + t.Cleanup(func() { c1.Close() }) + t.Cleanup(func() { c2.Close() }) return c1, c2 } t.Logf("localPipe: unexpected connection: %v != %v", c2.RemoteAddr(), c1.LocalAddr()) @@ -399,7 +401,7 @@ func runMain(m *testing.M) int { func testHandshake(t *testing.T, clientConfig, serverConfig *Config) (serverState, clientState ConnectionState, err error) { const sentinel = "SENTINEL\n" c, s := localPipe(t) - errChan := make(chan error) + errChan := make(chan error, 1) go func() { cli := Client(c, clientConfig) err := cli.Handshake() @@ -408,7 +410,7 @@ func testHandshake(t *testing.T, clientConfig, serverConfig *Config) (serverStat c.Close() return } - defer cli.Close() + defer func() { errChan <- nil }() clientState = cli.ConnectionState() buf, err := io.ReadAll(cli) if err != nil { @@ -417,7 +419,9 @@ func testHandshake(t *testing.T, clientConfig, serverConfig *Config) (serverStat if got := string(buf); got != sentinel { t.Errorf("read %q from TLS connection, but expected %q", got, sentinel) } - errChan <- nil + if err := cli.Close(); err != nil { + t.Errorf("failed to call cli.Close: %v", err) + } }() server := Server(s, serverConfig) err = server.Handshake() @@ -429,11 +433,11 @@ func testHandshake(t *testing.T, clientConfig, serverConfig *Config) (serverStat if err := server.Close(); err != nil { t.Errorf("failed to call server.Close: %v", err) } - err = <-errChan } else { + err = fmt.Errorf("server: %v", err) s.Close() - <-errChan } + err = errors.Join(err, <-errChan) return } diff --git a/testdata/Server-TLSv13-KeySharePreference b/testdata/Server-TLSv13-KeySharePreference new file mode 100644 index 0000000..fc79cc6 --- /dev/null +++ b/testdata/Server-TLSv13-KeySharePreference @@ -0,0 +1,101 @@ +>>> Flow 1 (client to server) +00000000 16 03 01 00 e5 01 00 00 e1 03 03 58 2d 84 f2 4f |...........X-..O| +00000010 6d 10 9d f6 5a 67 c7 92 78 e6 7d 96 96 fe db 37 |m...Zg..x.}....7| +00000020 07 44 e3 2e 85 3f 1a 5f f1 2a 24 20 cb e8 e8 c4 |.D...?._.*$ ....| +00000030 e9 28 01 21 9f 82 d2 da 6b 3e a0 7f 0d 20 95 12 |.(.!....k>... ..| +00000040 39 5b 3f f8 04 86 df 9b 72 3b 74 e2 00 04 13 03 |9[?.....r;t.....| +00000050 00 ff 01 00 00 94 00 0b 00 04 03 00 01 02 00 0a |................| +00000060 00 06 00 04 00 17 00 1d 00 16 00 00 00 17 00 00 |................| +00000070 00 0d 00 1e 00 1c 04 03 05 03 06 03 08 07 08 08 |................| +00000080 08 09 08 0a 08 0b 08 04 08 05 08 06 04 01 05 01 |................| +00000090 06 01 00 2b 00 03 02 03 04 00 2d 00 02 01 01 00 |...+......-.....| +000000a0 33 00 47 00 45 00 17 00 41 04 63 03 f6 90 df 1f |3.G.E...A.c.....| +000000b0 d0 03 96 24 21 3d e4 c0 5d 38 5f 53 85 a4 9c d8 |...$!=..]8_S....| +000000c0 f7 b0 9c 64 5f 53 c3 66 9b f5 e0 5a 60 0b b2 e8 |...d_S.f...Z`...| +000000d0 2b d0 6a a2 ff 1d 07 8b 5f a8 37 e4 74 35 15 b1 |+.j....._.7.t5..| +000000e0 06 de 79 3b f4 69 52 2a ad 66 |..y;.iR*.f| +>>> Flow 2 (server to client) +00000000 16 03 03 00 9b 02 00 00 97 03 03 00 00 00 00 00 |................| +00000010 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |................| +00000020 00 00 00 00 00 00 00 00 00 00 00 20 cb e8 e8 c4 |........... ....| +00000030 e9 28 01 21 9f 82 d2 da 6b 3e a0 7f 0d 20 95 12 |.(.!....k>... ..| +00000040 39 5b 3f f8 04 86 df 9b 72 3b 74 e2 13 03 00 00 |9[?.....r;t.....| +00000050 4f 00 2b 00 02 03 04 00 33 00 45 00 17 00 41 04 |O.+.....3.E...A.| +00000060 1e 18 37 ef 0d 19 51 88 35 75 71 b5 e5 54 5b 12 |..7...Q.5uq..T[.| +00000070 2e 8f 09 67 fd a7 24 20 3e b2 56 1c ce 97 28 5e |...g..$ >.V...(^| +00000080 f8 2b 2d 4f 9e f1 07 9f 6c 4b 5b 83 56 e2 32 42 |.+-O....lK[.V.2B| +00000090 e9 58 b6 d7 49 a6 b5 68 1a 41 03 56 6b dc 5a 89 |.X..I..h.A.Vk.Z.| +000000a0 14 03 03 00 01 01 17 03 03 00 17 f8 6a 35 d1 d7 |............j5..| +000000b0 a0 09 48 20 66 ea 1d 4e a4 05 2b d6 24 ea 0d cb |..H f..N..+.$...| +000000c0 68 8b 17 03 03 02 6d 16 c5 3b c2 80 85 49 51 1f |h.....m..;...IQ.| +000000d0 4e 0e 8a 11 63 95 9b 83 46 a9 19 43 90 ee 55 ae |N...c...F..C..U.| +000000e0 4f 09 ae cf fd 64 dd a9 c0 af 31 fd 95 29 20 9f |O....d....1..) .| +000000f0 da d4 27 97 2c da da 2c c8 e7 e5 c2 6b 24 5f dd |..'.,..,....k$_.| +00000100 68 86 b1 9b 01 95 8a 78 bb 10 26 66 24 d4 59 df |h......x..&f$.Y.| +00000110 6d b4 56 c4 23 56 5d 3c fc 6d 69 ce eb e2 9c 30 |m.V.#V]<.mi....0| +00000120 da 34 39 32 80 a7 26 d6 e2 11 33 a5 c1 5d 75 07 |.492..&...3..]u.| +00000130 f5 f6 98 9e f2 26 49 96 52 fb 56 6d 34 67 45 15 |.....&I.R.Vm4gE.| +00000140 97 0d 0d 5e 7e 63 6b 42 0e 6f 2c 3b 11 06 d5 a4 |...^~ckB.o,;....| +00000150 00 92 2d 39 62 ea f4 28 04 ee e4 f4 78 f4 d2 72 |..-9b..(....x..r| +00000160 f7 65 61 43 76 12 59 90 a3 15 71 07 78 dc 61 cf |.eaCv.Y...q.x.a.| +00000170 62 6e 7d 2d 7e b0 0f e3 ca 21 1b 13 96 ef 96 23 |bn}-~....!.....#| +00000180 86 31 2a 53 b0 13 a3 23 29 74 2c 98 3b 75 a2 96 |.1*S...#)t,.;u..| +00000190 7b 4a cb 22 f3 63 84 17 9b 25 a8 10 75 88 3c fd |{J.".c...%..u.<.| +000001a0 d5 49 c3 97 c3 78 83 c1 24 f3 7f 21 63 e8 b2 01 |.I...x..$..!c...| +000001b0 b0 92 b8 8b f2 83 64 2f a8 8f b9 18 14 44 54 6a |......d/.....DTj| +000001c0 a9 d6 68 5c be 50 69 8d 35 16 5e 8d 9a 6a f0 5b |..h\.Pi.5.^..j.[| +000001d0 a4 f1 5b 51 3e 5b d4 d1 41 06 3c c7 09 27 96 a8 |..[Q>[..A.<..'..| +000001e0 81 07 d2 33 27 3c a6 a9 bb 7b 80 28 58 e4 b0 dd |...3'<...{.(X...| +000001f0 a8 9e b2 61 ed 5b 57 c8 b2 a2 7f 6b f7 0f ee 3d |...a.[W....k...=| +00000200 9c 6d a1 76 55 3e af aa 17 c8 a8 ec c6 14 31 77 |.m.vU>........1w| +00000210 38 a3 9c 15 3f 0e cc 63 43 8f b0 c1 14 97 ee 85 |8...?..cC.......| +00000220 30 08 b1 95 0c 7f 5b 95 4d 4f 18 26 d8 45 cb b4 |0.....[.MO.&.E..| +00000230 b7 1b f5 a5 d5 e5 21 da 53 88 57 09 ed 30 fe d1 |......!.S.W..0..| +00000240 ac ee c7 80 ee a9 96 31 92 4c a1 e2 2c a8 f5 b1 |.......1.L..,...| +00000250 d9 3c bd c8 e6 1b ba 7c 91 d6 6c d4 ae 0a 15 50 |.<.....|..l....P| +00000260 b9 24 80 14 ff 28 98 94 a7 7f d4 13 16 1f 03 bf |.$...(..........| +00000270 72 83 94 a3 8a 6d b6 d7 b2 c7 22 56 38 f2 15 e1 |r....m...."V8...| +00000280 ea 1f 78 d0 ff ac c4 19 54 a1 c6 2d 8a da cd f3 |..x.....T..-....| +00000290 6e 45 b3 a4 dc e3 a0 6e f8 18 af a6 c6 20 ce a7 |nE.....n..... ..| +000002a0 eb dc 42 06 bd d4 bf a0 ef 36 4c f6 38 42 3d f7 |..B......6L.8B=.| +000002b0 a3 a5 ac 4d b3 71 36 9b 00 ee 1f 40 fa bc b3 d4 |...M.q6....@....| +000002c0 5b 49 79 4f 16 fd 3e 4f ab 8e cc 92 7d f3 1d c7 |[IyO..>O....}...| +000002d0 13 76 49 56 1c 59 13 56 3b 6b 33 ed 1a 85 9c b7 |.vIV.Y.V;k3.....| +000002e0 a1 55 84 83 a1 df d6 53 0c c1 b6 63 63 b2 58 84 |.U.....S...cc.X.| +000002f0 12 f6 99 7a ac c5 ee 53 69 9e 86 76 88 aa 7b 2f |...z...Si..v..{/| +00000300 f8 48 0b 05 e1 2a 1c 0d 56 ae 79 9e 68 4f b5 85 |.H...*..V.y.hO..| +00000310 df cc 11 05 33 94 55 e6 16 d4 d5 78 b4 d1 c3 2c |....3.U....x...,| +00000320 2d 3c ac 45 6e fd 1e e0 79 5c 23 c3 57 66 3e d2 |-<.En...y\#.Wf>.| +00000330 22 39 21 df 17 03 03 00 99 a9 e3 ac d5 82 cc bd |"9!.............| +00000340 74 c3 92 13 4d 32 fc ff e4 63 ec ea 81 40 47 bb |t...M2...c...@G.| +00000350 3f ad 65 d4 fe 4f 0c c0 6a b0 78 c4 4f 0d e8 73 |?.e..O..j.x.O..s| +00000360 7c ee 9b ff 61 f8 4b 17 32 92 5d e5 49 ea 7b 38 ||...a.K.2.].I.{8| +00000370 6b db a2 4b 64 1d 7f 42 ce 4d f0 d8 dc 9c 93 f4 |k..Kd..B.M......| +00000380 23 5d d5 dd 34 90 51 42 3d 0e bf 69 31 d8 0f e6 |#]..4.QB=..i1...| +00000390 14 5a ec 52 1e d5 41 a6 25 7c 9b 40 f5 92 58 17 |.Z.R..A.%|.@..X.| +000003a0 80 68 a2 43 58 d3 d9 7c 7a 1f 90 4f a5 08 f8 0f |.h.CX..|z..O....| +000003b0 31 7b bd cc 74 3d f8 73 7d 0a 6c 12 25 53 b3 99 |1{..t=.s}.l.%S..| +000003c0 c7 f2 4c 99 5d 7c 56 cd 29 5c 30 91 93 6f a2 00 |..L.]|V.)\0..o..| +000003d0 c4 97 17 03 03 00 35 81 b3 9e 92 c5 dc 08 b3 f3 |......5.........| +000003e0 70 56 52 40 16 d4 75 34 1e e8 b7 ce 5e 5a 7e 47 |pVR@..u4....^Z~G| +000003f0 ec d0 75 68 24 06 a6 1b 87 73 6c b0 ff e4 3c 6d |..uh$....sl......kOC.`.U.u...| +00000460 27 64 8b 0f 15 db 95 47 36 b3 14 e0 da a2 21 1e |'d.....G6.....!.| +00000470 bf 0d 40 79 c8 6c 3b 9f eb 96 1a cf 9d 09 f7 a9 |..@y.l;.........| +00000480 22 e5 13 c4 2a 69 5e 95 d1 40 e5 00 26 20 ae 16 |"...*i^..@..& ..| +00000490 55 27 51 a1 c7 e3 2e 1d 32 6c d5 0d |U'Q.....2l..| +>>> Flow 3 (client to server) +00000000 14 03 03 00 01 01 17 03 03 00 35 71 16 57 df 09 |..........5q.W..| +00000010 d7 73 e4 f2 c4 8a 10 b1 d8 73 dc 5b 87 8f 56 51 |.s.......s.[..VQ| +00000020 6a ed 61 66 c9 d4 0d fe 28 0c 6f c7 4d ef e6 90 |j.af....(.o.M...| +00000030 ba e2 fb c3 c9 4a 94 a2 e5 7f 23 e2 66 2b 4f 9e |.....J....#.f+O.| +>>> Flow 4 (server to client) +00000000 17 03 03 00 1e 6a c8 6d 0d b6 f7 c8 33 cd c6 25 |.....j.m....3..%| +00000010 98 0e bb ac de 69 61 9d ec a3 c0 be 7e 53 44 cb |.....ia.....~SD.| +00000020 1f d5 97 17 03 03 00 13 be 18 cc 16 91 88 1e d1 |................| +00000030 b5 7c 58 17 fb 39 b2 80 76 7b a8 |.|X..9..v{.| From 7e8209f81c35c0a06378ff9f2502973281472721 Mon Sep 17 00:00:00 2001 From: Filippo Valsorda Date: Mon, 20 May 2024 11:07:28 +0200 Subject: [PATCH 13/39] crypto/tls: ensure GODEBUGs are initialized IncNonDefault panics if Value was not called. That's too much DoS risk in crypto/tls, when the call to Value is distant from the call to IncNonDefault (see #65991). Value is cheap, though, so we can just call it before each isolated IncNonDefault. Change-Id: I6dbed345381e60e029b0a5ef2232e846aa089736 Reviewed-on: https://go-review.googlesource.com/c/go/+/586755 Reviewed-by: Roland Shoemaker Reviewed-by: Dmitri Shuralyov Auto-Submit: Filippo Valsorda LUCI-TryBot-Result: Go LUCI --- handshake_client.go | 1 + handshake_server.go | 2 ++ 2 files changed, 3 insertions(+) diff --git a/handshake_client.go b/handshake_client.go index d046c86..cc3efe1 100644 --- a/handshake_client.go +++ b/handshake_client.go @@ -527,6 +527,7 @@ func (hs *clientHandshakeState) pickCipherSuite() error { } if hs.c.config.CipherSuites == nil && !needFIPS() && rsaKexCiphers[hs.suite.id] { + tlsrsakex.Value() // ensure godebug is initialized tlsrsakex.IncNonDefault() } diff --git a/handshake_server.go b/handshake_server.go index d5f8cc8..f5d3c5b 100644 --- a/handshake_server.go +++ b/handshake_server.go @@ -169,6 +169,7 @@ func (c *Conn) readClientHello(ctx context.Context) (*clientHelloMsg, error) { c.out.version = c.vers if c.config.MinVersion == 0 && c.vers < VersionTLS12 { + tls10server.Value() // ensure godebug is initialized tls10server.IncNonDefault() } @@ -371,6 +372,7 @@ func (hs *serverHandshakeState) pickCipherSuite() error { c.cipherSuite = hs.suite.id if c.config.CipherSuites == nil && !needFIPS() && rsaKexCiphers[hs.suite.id] { + tlsrsakex.Value() // ensure godebug is initialized tlsrsakex.IncNonDefault() } From a81de4f2e085522964e14aabea0340a6ccd8654b Mon Sep 17 00:00:00 2001 From: Filippo Valsorda Date: Sat, 18 May 2024 20:15:38 +0200 Subject: [PATCH 14/39] crypto/tls: implement X25519Kyber768Draft00 Forced the testConfig CurvePreferences to exclude X25519Kyber768Draft00 to avoid bloating the transcripts, but I manually tested it and the tests all update and pass successfully, causing 7436 insertions(+), 3251 deletions(-). Fixes #67061 Change-Id: If6f13bca561835777ab0889a490487b7c2366c3c Reviewed-on: https://go-review.googlesource.com/c/go/+/586656 Auto-Submit: Filippo Valsorda Reviewed-by: Dmitri Shuralyov Reviewed-by: Roland Shoemaker LUCI-TryBot-Result: Go LUCI --- bogo_config.json | 12 +++- bogo_shim_test.go | 60 ++++++++++++++++- boring_test.go | 4 ++ common.go | 42 +++++++++--- common_string.go | 6 +- conn.go | 3 + handshake_client.go | 104 +++++++++++++++++------------ handshake_client_tls13.go | 67 +++++++++++++------ handshake_server.go | 10 ++- handshake_server_test.go | 1 + handshake_server_tls13.go | 66 +++++++++++++------ handshake_test.go | 1 + key_agreement.go | 8 +-- key_schedule.go | 41 ++++++++++++ key_schedule_test.go | 37 +++++++++++ tls_test.go | 133 ++++++++++++++++++++++++++++++++++++++ 16 files changed, 493 insertions(+), 102 deletions(-) diff --git a/bogo_config.json b/bogo_config.json index d548a61..21ee32c 100644 --- a/bogo_config.json +++ b/bogo_config.json @@ -6,6 +6,10 @@ "SendEmptyRecords*": "crypto/tls doesn't implement spam protections", "SendWarningAlerts*": "crypto/tls doesn't implement spam protections", "TooManyKeyUpdates": "crypto/tls doesn't implement spam protections (TODO: I think?)", + "KyberNotEnabledByDefaultInClients": "crypto/tls intentionally enables it", + "JustConfiguringKyberWorks": "we always send a X25519 key share with Kyber", + "KyberKeyShareIncludedSecond": "we always send the Kyber key share first", + "KyberKeyShareIncludedThird": "we always send the Kyber key share first", "SkipNewSessionTicket": "TODO confusing? maybe bug", "SendUserCanceledAlerts*": "TODO may be a real bug?", "GREASE-Server-TLS13": "TODO ???", @@ -14,6 +18,12 @@ "EchoTLS13CompatibilitySessionID": "TODO reject compat session ID", "*ECH-Server*": "no ECH server support", "TLS-ECH-Client-UnsolictedHRRExtension": "TODO", + "*Client-P-224*": "no P-224 support", + "*Server-P-224*": "no P-224 support", + "CurveID-Resume*": "unexposed curveID is not stored in the ticket yet", + "CheckLeafCurve": "TODO: first pass, this should be fixed", + "DisabledCurve-HelloRetryRequest-TLS13": "TODO: first pass, this should be fixed", + "UnsupportedCurve": "TODO: first pass, this should be fixed", "SupportTicketsWithSessionID": "TODO: first pass, this should be fixed", "NoNullCompression-TLS12": "TODO: first pass, this should be fixed", "KeyUpdate-RequestACK": "TODO: first pass, this should be fixed", @@ -172,4 +182,4 @@ "CheckClientCertificateTypes": "TODO: first pass, this should be fixed", "CheckECDSACurve-TLS12": "TODO: first pass, this should be fixed" } -} \ No newline at end of file +} diff --git a/bogo_shim_test.go b/bogo_shim_test.go index e1a393c..4a95dc1 100644 --- a/bogo_shim_test.go +++ b/bogo_shim_test.go @@ -15,6 +15,8 @@ import ( "os/exec" "path/filepath" "runtime" + "strconv" + "strings" "testing" ) @@ -40,6 +42,9 @@ var ( resumeCount = flag.Int("resume-count", 0, "") + curves = flagStringSlice("curves", "") + expectedCurve = flag.String("expect-curve-id", "", "") + shimID = flag.Uint64("shim-id", 0, "") _ = flag.Bool("ipv6", false, "") @@ -132,6 +137,23 @@ var ( // -verify-prefs ) +type stringSlice []string + +func flagStringSlice(name, usage string) *stringSlice { + f := &stringSlice{} + flag.Var(f, name, usage) + return f +} + +func (saf stringSlice) String() string { + return strings.Join(saf, ",") +} + +func (saf stringSlice) Set(s string) error { + saf = append(saf, s) + return nil +} + func bogoShim() { if *isHandshakerSupported { fmt.Println("No") @@ -177,6 +199,16 @@ func bogoShim() { cfg.ClientAuth = RequireAnyClientCert } + if len(*curves) != 0 { + for _, curveStr := range *curves { + id, err := strconv.Atoi(curveStr) + if err != nil { + log.Fatalf("failed to parse curve id %q: %s", curveStr, err) + } + cfg.CurvePreferences = append(cfg.CurvePreferences, CurveID(id)) + } + } + for i := 0; i < *resumeCount+1; i++ { conn, err := net.Dial("tcp", net.JoinHostPort("localhost", *port)) if err != nil { @@ -221,6 +253,16 @@ func bogoShim() { log.Fatalf("write err: %s", err) } } + + if *expectedCurve != "" { + expectedCurveID, err := strconv.Atoi(*expectedCurve) + if err != nil { + log.Fatalf("failed to parse -expect-curve-id: %s", err) + } + if tlsConn.curveID != CurveID(expectedCurveID) { + log.Fatalf("unexpected curve id: want %d, got %d", expectedCurveID, tlsConn.curveID) + } + } } } @@ -238,7 +280,7 @@ func TestBogoSuite(t *testing.T) { t.Skip("#66913: windows network connections are flakey on builders") } - const boringsslModVer = "v0.0.0-20240412155355-1c6e10495e4f" + const boringsslModVer = "v0.0.0-20240517213134-ba62c812f01f" output, err := exec.Command("go", "mod", "download", "-json", "github.com/google/boringssl@"+boringsslModVer).CombinedOutput() if err != nil { t.Fatalf("failed to download boringssl: %s", err) @@ -263,6 +305,8 @@ func TestBogoSuite(t *testing.T) { "-shim-extra-flags=-bogo-mode", "-allow-unimplemented", "-loose-errors", // TODO(roland): this should be removed eventually + "-pipe", + "-v", } if *bogoFilter != "" { args = append(args, fmt.Sprintf("-test=%s", *bogoFilter)) @@ -273,10 +317,22 @@ func TestBogoSuite(t *testing.T) { t.Fatal(err) } cmd := exec.Command(goCmd, args...) - cmd.Stdout, cmd.Stderr = os.Stdout, os.Stderr + out := &strings.Builder{} + cmd.Stdout, cmd.Stderr = io.MultiWriter(os.Stdout, out), os.Stderr cmd.Dir = filepath.Join(j.Dir, "ssl/test/runner") err = cmd.Run() if err != nil { t.Fatalf("bogo failed: %s", err) } + + if *bogoFilter == "" { + assertPass := func(t *testing.T, name string) { + t.Helper() + if !strings.Contains(out.String(), "PASSED ("+name+")\n") { + t.Errorf("Expected test %s did not run", name) + } + } + assertPass(t, "CurveTest-Client-Kyber-TLS13") + assertPass(t, "CurveTest-Server-Kyber-TLS13") + } } diff --git a/boring_test.go b/boring_test.go index 77374ab..4a658f0 100644 --- a/boring_test.go +++ b/boring_test.go @@ -165,6 +165,10 @@ func TestBoringServerCurves(t *testing.T) { t.Run(fmt.Sprintf("curve=%d", curveid), func(t *testing.T) { clientConfig := testConfig.Clone() clientConfig.CurvePreferences = []CurveID{curveid} + if curveid == x25519Kyber768Draft00 { + // x25519Kyber768Draft00 is not supported standalone. + clientConfig.CurvePreferences = append(clientConfig.CurvePreferences, X25519) + } if _, _, err := testHandshake(t, clientConfig, serverConfig); err != nil { t.Fatalf("got error: %v, expected success", err) } diff --git a/common.go b/common.go index 34a3013..14a8dae 100644 --- a/common.go +++ b/common.go @@ -130,11 +130,13 @@ const ( scsvRenegotiation uint16 = 0x00ff ) -// CurveID is the type of a TLS identifier for an elliptic curve. See +// CurveID is the type of a TLS identifier for a key exchange mechanism. See // https://www.iana.org/assignments/tls-parameters/tls-parameters.xml#tls-parameters-8. // -// In TLS 1.3, this type is called NamedGroup, but at this time this library -// only supports Elliptic Curve based groups. See RFC 8446, Section 4.2.7. +// In TLS 1.2, this registry used to support only elliptic curves. In TLS 1.3, +// it was extended to other groups and renamed NamedGroup. See RFC 8446, Section +// 4.2.7. It was then also extended to other mechanisms, such as hybrid +// post-quantum KEMs. type CurveID uint16 const ( @@ -142,6 +144,11 @@ const ( CurveP384 CurveID = 24 CurveP521 CurveID = 25 X25519 CurveID = 29 + + // Experimental codepoint for X25519Kyber768Draft00, specified in + // draft-tls-westerbaan-xyber768d00-03. Not exported, as support might be + // removed in the future. + x25519Kyber768Draft00 CurveID = 0x6399 // X25519Kyber768Draft00 ) // TLS 1.3 Key Share. See RFC 8446, Section 4.2.8. @@ -302,6 +309,10 @@ type ConnectionState struct { // testingOnlyDidHRR is true if a HelloRetryRequest was sent/received. testingOnlyDidHRR bool + + // testingOnlyCurveID is the selected CurveID, or zero if an RSA exchanges + // is performed. + testingOnlyCurveID CurveID } // ExportKeyingMaterial returns length bytes of exported key material in a new @@ -375,7 +386,7 @@ type ClientSessionCache interface { Put(sessionKey string, cs *ClientSessionState) } -//go:generate stringer -type=SignatureScheme,CurveID,ClientAuthType -output=common_string.go +//go:generate stringer -linecomment -type=SignatureScheme,CurveID,ClientAuthType -output=common_string.go // SignatureScheme identifies a signature algorithm supported by TLS. See // RFC 8446, Section 4.2.3. @@ -757,6 +768,10 @@ type Config struct { // an ECDHE handshake, in preference order. If empty, the default will // be used. The client will use the first preference as the type for // its key share in TLS 1.3. This may change in the future. + // + // From Go 1.23, the default includes the X25519Kyber768Draft00 hybrid + // post-quantum key exchange. To disable it, set CurvePreferences explicitly + // or use the GODEBUG=tlskyber=0 environment variable. CurvePreferences []CurveID // DynamicRecordSizingDisabled disables adaptive sizing of TLS records. @@ -1084,20 +1099,27 @@ func supportedVersionsFromMax(maxVersion uint16) []uint16 { return versions } -var defaultCurvePreferences = []CurveID{X25519, CurveP256, CurveP384, CurveP521} +var tlskyber = godebug.New("tlskyber") -func (c *Config) curvePreferences() []CurveID { +var defaultCurvePreferences = []CurveID{x25519Kyber768Draft00, X25519, CurveP256, CurveP384, CurveP521} + +var defaultCurvePreferencesWithoutKyber = []CurveID{X25519, CurveP256, CurveP384, CurveP521} + +func (c *Config) curvePreferences(version uint16) []CurveID { if needFIPS() { return fipsCurvePreferences(c) } if c == nil || len(c.CurvePreferences) == 0 { + if version < VersionTLS13 || tlskyber.Value() == "0" { + return defaultCurvePreferencesWithoutKyber + } return defaultCurvePreferences } return c.CurvePreferences } -func (c *Config) supportsCurve(curve CurveID) bool { - for _, cc := range c.curvePreferences() { +func (c *Config) supportsCurve(version uint16, curve CurveID) bool { + for _, cc := range c.curvePreferences(version) { if cc == curve { return true } @@ -1256,7 +1278,7 @@ func (chi *ClientHelloInfo) SupportsCertificate(c *Certificate) error { } // The only signed key exchange we support is ECDHE. - if !supportsECDHE(config, chi.SupportedCurves, chi.SupportedPoints) { + if !supportsECDHE(config, vers, chi.SupportedCurves, chi.SupportedPoints) { return supportsRSAFallback(errors.New("client doesn't support ECDHE, can only use legacy RSA key exchange")) } @@ -1277,7 +1299,7 @@ func (chi *ClientHelloInfo) SupportsCertificate(c *Certificate) error { } var curveOk bool for _, c := range chi.SupportedCurves { - if c == curve && config.supportsCurve(c) { + if c == curve && config.supportsCurve(vers, c) { curveOk = true break } diff --git a/common_string.go b/common_string.go index 2381088..1752f81 100644 --- a/common_string.go +++ b/common_string.go @@ -1,4 +1,4 @@ -// Code generated by "stringer -type=SignatureScheme,CurveID,ClientAuthType -output=common_string.go"; DO NOT EDIT. +// Code generated by "stringer -linecomment -type=SignatureScheme,CurveID,ClientAuthType -output=common_string.go"; DO NOT EDIT. package tls @@ -71,11 +71,13 @@ func _() { _ = x[CurveP384-24] _ = x[CurveP521-25] _ = x[X25519-29] + _ = x[x25519Kyber768Draft00-25497] } const ( _CurveID_name_0 = "CurveP256CurveP384CurveP521" _CurveID_name_1 = "X25519" + _CurveID_name_2 = "X25519Kyber768Draft00" ) var ( @@ -89,6 +91,8 @@ func (i CurveID) String() string { return _CurveID_name_0[_CurveID_index_0[i]:_CurveID_index_0[i+1]] case i == 29: return _CurveID_name_1 + case i == 25497: + return _CurveID_name_2 default: return "CurveID(" + strconv.FormatInt(int64(i), 10) + ")" } diff --git a/conn.go b/conn.go index c44f651..3ffd26d 100644 --- a/conn.go +++ b/conn.go @@ -50,6 +50,7 @@ type Conn struct { didResume bool // whether this connection was a session resumption didHRR bool // whether a HelloRetryRequest was sent/received cipherSuite uint16 + curveID CurveID ocspResponse []byte // stapled OCSP response scts [][]byte // signed certificate timestamps from server peerCertificates []*x509.Certificate @@ -1610,6 +1611,8 @@ func (c *Conn) connectionStateLocked() ConnectionState { state.NegotiatedProtocol = c.clientProtocol state.DidResume = c.didResume state.testingOnlyDidHRR = c.didHRR + // c.curveID is not set on TLS 1.0–1.2 resumptions. Fix that before exposing it. + state.testingOnlyCurveID = c.curveID state.NegotiatedProtocolIsMutual = true state.ServerName = c.serverName state.CipherSuite = c.cipherSuite diff --git a/handshake_client.go b/handshake_client.go index cc3efe1..53d4f90 100644 --- a/handshake_client.go +++ b/handshake_client.go @@ -8,15 +8,16 @@ import ( "bytes" "context" "crypto" - "crypto/ecdh" "crypto/ecdsa" "crypto/ed25519" + "crypto/internal/mlkem768" "crypto/rsa" "crypto/subtle" "crypto/x509" "errors" "fmt" "hash" + "internal/byteorder" "internal/godebug" "io" "net" @@ -39,7 +40,7 @@ type clientHandshakeState struct { var testingOnlyForceClientHelloSignatureAlgorithms []SignatureScheme -func (c *Conn) makeClientHello() (*clientHelloMsg, *ecdh.PrivateKey, error) { +func (c *Conn) makeClientHello() (*clientHelloMsg, *keySharePrivateKeys, error) { config := c.config if len(config.ServerName) == 0 && !config.InsecureSkipVerify { return nil, nil, errors.New("tls: either ServerName or InsecureSkipVerify must be specified in the tls.Config") @@ -61,30 +62,30 @@ func (c *Conn) makeClientHello() (*clientHelloMsg, *ecdh.PrivateKey, error) { if len(supportedVersions) == 0 { return nil, nil, errors.New("tls: no supported versions satisfy MinVersion and MaxVersion") } - - clientHelloVersion := config.maxSupportedVersion(roleClient) - // The version at the beginning of the ClientHello was capped at TLS 1.2 - // for compatibility reasons. The supported_versions extension is used - // to negotiate versions now. See RFC 8446, Section 4.2.1. - if clientHelloVersion > VersionTLS12 { - clientHelloVersion = VersionTLS12 - } + maxVersion := config.maxSupportedVersion(roleClient) hello := &clientHelloMsg{ - vers: clientHelloVersion, + vers: maxVersion, compressionMethods: []uint8{compressionNone}, random: make([]byte, 32), extendedMasterSecret: true, ocspStapling: true, scts: true, serverName: hostnameInSNI(config.ServerName), - supportedCurves: config.curvePreferences(), + supportedCurves: config.curvePreferences(maxVersion), supportedPoints: []uint8{pointFormatUncompressed}, secureRenegotiationSupported: true, alpnProtocols: config.NextProtos, supportedVersions: supportedVersions, } + // The version at the beginning of the ClientHello was capped at TLS 1.2 + // for compatibility reasons. The supported_versions extension is used + // to negotiate versions now. See RFC 8446, Section 4.2.1. + if hello.vers > VersionTLS12 { + hello.vers = VersionTLS12 + } + if c.handshakes > 0 { hello.secureRenegotiation = c.clientFinished[:] } @@ -103,7 +104,7 @@ func (c *Conn) makeClientHello() (*clientHelloMsg, *ecdh.PrivateKey, error) { } // Don't advertise TLS 1.2-only cipher suites unless // we're attempting TLS 1.2. - if hello.vers < VersionTLS12 && suite.flags&suiteTLS12 != 0 { + if maxVersion < VersionTLS12 && suite.flags&suiteTLS12 != 0 { continue } hello.cipherSuites = append(hello.cipherSuites, suiteId) @@ -126,14 +127,14 @@ func (c *Conn) makeClientHello() (*clientHelloMsg, *ecdh.PrivateKey, error) { } } - if hello.vers >= VersionTLS12 { + if maxVersion >= VersionTLS12 { hello.supportedSignatureAlgorithms = supportedSignatureAlgorithms() } if testingOnlyForceClientHelloSignatureAlgorithms != nil { hello.supportedSignatureAlgorithms = testingOnlyForceClientHelloSignatureAlgorithms } - var key *ecdh.PrivateKey + var keyShareKeys *keySharePrivateKeys if hello.supportedVersions[0] == VersionTLS13 { // Reset the list of ciphers when the client only supports TLS 1.3. if len(hello.supportedVersions) == 1 { @@ -145,15 +146,40 @@ func (c *Conn) makeClientHello() (*clientHelloMsg, *ecdh.PrivateKey, error) { hello.cipherSuites = append(hello.cipherSuites, defaultCipherSuitesTLS13NoAES...) } - curveID := config.curvePreferences()[0] - if _, ok := curveForCurveID(curveID); !ok { - return nil, nil, errors.New("tls: CurvePreferences includes unsupported curve") + curveID := config.curvePreferences(maxVersion)[0] + keyShareKeys = &keySharePrivateKeys{curveID: curveID} + if curveID == x25519Kyber768Draft00 { + keyShareKeys.ecdhe, err = generateECDHEKey(config.rand(), X25519) + if err != nil { + return nil, nil, err + } + seed := make([]byte, mlkem768.SeedSize) + if _, err := io.ReadFull(config.rand(), seed); err != nil { + return nil, nil, err + } + keyShareKeys.kyber, err = mlkem768.NewKeyFromSeed(seed) + if err != nil { + return nil, nil, err + } + // For draft-tls-westerbaan-xyber768d00-03, we send both a hybrid + // and a standard X25519 key share, since most servers will only + // support the latter. We reuse the same X25519 ephemeral key for + // both, as allowed by draft-ietf-tls-hybrid-design-09, Section 3.2. + hello.keyShares = []keyShare{ + {group: x25519Kyber768Draft00, data: append(keyShareKeys.ecdhe.PublicKey().Bytes(), + keyShareKeys.kyber.EncapsulationKey()...)}, + {group: X25519, data: keyShareKeys.ecdhe.PublicKey().Bytes()}, + } + } else { + if _, ok := curveForCurveID(curveID); !ok { + return nil, nil, errors.New("tls: CurvePreferences includes unsupported curve") + } + keyShareKeys.ecdhe, err = generateECDHEKey(config.rand(), curveID) + if err != nil { + return nil, nil, err + } + hello.keyShares = []keyShare{{group: curveID, data: keyShareKeys.ecdhe.PublicKey().Bytes()}} } - key, err = generateECDHEKey(config.rand(), curveID) - if err != nil { - return nil, nil, err - } - hello.keyShares = []keyShare{{group: curveID, data: key.PublicKey().Bytes()}} } if c.quic != nil { @@ -167,7 +193,7 @@ func (c *Conn) makeClientHello() (*clientHelloMsg, *ecdh.PrivateKey, error) { hello.quicTransportParameters = p } - return hello, key, nil + return hello, keyShareKeys, nil } func (c *Conn) clientHandshake(ctx context.Context) (err error) { @@ -179,7 +205,7 @@ func (c *Conn) clientHandshake(ctx context.Context) (err error) { // need to be reset. c.didResume = false - hello, ecdheKey, err := c.makeClientHello() + hello, keyShareKeys, err := c.makeClientHello() if err != nil { return err } @@ -249,17 +275,15 @@ func (c *Conn) clientHandshake(ctx context.Context) (err error) { if c.vers == VersionTLS13 { hs := &clientHandshakeStateTLS13{ - c: c, - ctx: ctx, - serverHello: serverHello, - hello: hello, - ecdheKey: ecdheKey, - session: session, - earlySecret: earlySecret, - binderKey: binderKey, + c: c, + ctx: ctx, + serverHello: serverHello, + hello: hello, + keyShareKeys: keyShareKeys, + session: session, + earlySecret: earlySecret, + binderKey: binderKey, } - - // In TLS 1.3, session tickets are delivered after the handshake. return hs.handshake() } @@ -270,12 +294,7 @@ func (c *Conn) clientHandshake(ctx context.Context) (err error) { hello: hello, session: session, } - - if err := hs.handshake(); err != nil { - return err - } - - return nil + return hs.handshake() } func (c *Conn) loadSession(hello *clientHelloMsg) ( @@ -603,6 +622,9 @@ func (hs *clientHandshakeState) doFullHandshake() error { c.sendAlert(alertUnexpectedMessage) return err } + if len(skx.key) >= 3 && skx.key[0] == 3 /* named curve */ { + c.curveID = CurveID(byteorder.BeUint16(skx.key[1:])) + } msg, err = c.readHandshake(&hs.finishedHash) if err != nil { diff --git a/handshake_client_tls13.go b/handshake_client_tls13.go index 88ec383..06f3f82 100644 --- a/handshake_client_tls13.go +++ b/handshake_client_tls13.go @@ -8,20 +8,21 @@ import ( "bytes" "context" "crypto" - "crypto/ecdh" "crypto/hmac" + "crypto/internal/mlkem768" "crypto/rsa" "errors" "hash" + "slices" "time" ) type clientHandshakeStateTLS13 struct { - c *Conn - ctx context.Context - serverHello *serverHelloMsg - hello *clientHelloMsg - ecdheKey *ecdh.PrivateKey + c *Conn + ctx context.Context + serverHello *serverHelloMsg + hello *clientHelloMsg + keyShareKeys *keySharePrivateKeys session *SessionState earlySecret []byte @@ -36,7 +37,7 @@ type clientHandshakeStateTLS13 struct { trafficSecret []byte // client_application_traffic_secret_0 } -// handshake requires hs.c, hs.hello, hs.serverHello, hs.ecdheKey, and, +// handshake requires hs.c, hs.hello, hs.serverHello, hs.keyShareKeys, and, // optionally, hs.session, hs.earlySecret and hs.binderKey to be set. func (hs *clientHandshakeStateTLS13) handshake() error { c := hs.c @@ -53,7 +54,7 @@ func (hs *clientHandshakeStateTLS13) handshake() error { } // Consistency check on the presence of a keyShare and its parameters. - if hs.ecdheKey == nil || len(hs.hello.keyShares) != 1 { + if hs.keyShareKeys == nil || hs.keyShareKeys.ecdhe == nil || len(hs.hello.keyShares) == 0 { return c.sendAlert(alertInternalError) } @@ -221,21 +222,22 @@ func (hs *clientHandshakeStateTLS13) processHelloRetryRequest() error { // a group we advertised but did not send a key share for, and send a key // share for it this time. if curveID := hs.serverHello.selectedGroup; curveID != 0 { - curveOK := false - for _, id := range hs.hello.supportedCurves { - if id == curveID { - curveOK = true - break - } - } - if !curveOK { + if !slices.Contains(hs.hello.supportedCurves, curveID) { c.sendAlert(alertIllegalParameter) return errors.New("tls: server selected unsupported group") } - if sentID, _ := curveIDForCurve(hs.ecdheKey.Curve()); sentID == curveID { + if slices.ContainsFunc(hs.hello.keyShares, func(ks keyShare) bool { + return ks.group == curveID + }) { c.sendAlert(alertIllegalParameter) return errors.New("tls: server sent an unnecessary HelloRetryRequest key_share") } + // Note: we don't support selecting X25519Kyber768Draft00 in a HRR, + // because we currently only support it at all when CurvePreferences is + // empty, which will cause us to also send a key share for it. + // + // This will have to change once we support selecting hybrid KEMs + // without sending key shares for them. if _, ok := curveForCurveID(curveID); !ok { c.sendAlert(alertInternalError) return errors.New("tls: CurvePreferences includes unsupported curve") @@ -245,7 +247,7 @@ func (hs *clientHandshakeStateTLS13) processHelloRetryRequest() error { c.sendAlert(alertInternalError) return err } - hs.ecdheKey = key + hs.keyShareKeys = &keySharePrivateKeys{curveID: curveID, ecdhe: key} hs.hello.keyShares = []keyShare{{group: curveID, data: key.PublicKey().Bytes()}} } @@ -333,7 +335,9 @@ func (hs *clientHandshakeStateTLS13) processServerHello() error { c.sendAlert(alertIllegalParameter) return errors.New("tls: server did not send a key share") } - if sentID, _ := curveIDForCurve(hs.ecdheKey.Curve()); hs.serverHello.serverShare.group != sentID { + if !slices.ContainsFunc(hs.hello.keyShares, func(ks keyShare) bool { + return ks.group == hs.serverHello.serverShare.group + }) { c.sendAlert(alertIllegalParameter) return errors.New("tls: server selected unsupported group") } @@ -372,16 +376,37 @@ func (hs *clientHandshakeStateTLS13) processServerHello() error { func (hs *clientHandshakeStateTLS13) establishHandshakeKeys() error { c := hs.c - peerKey, err := hs.ecdheKey.Curve().NewPublicKey(hs.serverHello.serverShare.data) + ecdhePeerData := hs.serverHello.serverShare.data + if hs.serverHello.serverShare.group == x25519Kyber768Draft00 { + if len(ecdhePeerData) != x25519PublicKeySize+mlkem768.CiphertextSize { + c.sendAlert(alertIllegalParameter) + return errors.New("tls: invalid server key share") + } + ecdhePeerData = hs.serverHello.serverShare.data[:x25519PublicKeySize] + } + peerKey, err := hs.keyShareKeys.ecdhe.Curve().NewPublicKey(ecdhePeerData) if err != nil { c.sendAlert(alertIllegalParameter) return errors.New("tls: invalid server key share") } - sharedKey, err := hs.ecdheKey.ECDH(peerKey) + sharedKey, err := hs.keyShareKeys.ecdhe.ECDH(peerKey) if err != nil { c.sendAlert(alertIllegalParameter) return errors.New("tls: invalid server key share") } + if hs.serverHello.serverShare.group == x25519Kyber768Draft00 { + if hs.keyShareKeys.kyber == nil { + return c.sendAlert(alertInternalError) + } + ciphertext := hs.serverHello.serverShare.data[x25519PublicKeySize:] + kyberShared, err := kyberDecapsulate(hs.keyShareKeys.kyber, ciphertext) + if err != nil { + c.sendAlert(alertIllegalParameter) + return errors.New("tls: invalid Kyber server key share") + } + sharedKey = append(sharedKey, kyberShared...) + } + c.curveID = hs.serverHello.serverShare.group earlySecret := hs.earlySecret if !hs.usingPSK { diff --git a/handshake_server.go b/handshake_server.go index f5d3c5b..09ca8a4 100644 --- a/handshake_server.go +++ b/handshake_server.go @@ -15,6 +15,7 @@ import ( "errors" "fmt" "hash" + "internal/byteorder" "io" "time" ) @@ -247,7 +248,7 @@ func (hs *serverHandshakeState) processClientHello() error { hs.hello.scts = hs.cert.SignedCertificateTimestamps } - hs.ecdheOk = supportsECDHE(c.config, hs.clientHello.supportedCurves, hs.clientHello.supportedPoints) + hs.ecdheOk = supportsECDHE(c.config, c.vers, hs.clientHello.supportedCurves, hs.clientHello.supportedPoints) if hs.ecdheOk && len(hs.clientHello.supportedPoints) > 0 { // Although omitting the ec_point_formats extension is permitted, some @@ -318,10 +319,10 @@ func negotiateALPN(serverProtos, clientProtos []string, quic bool) (string, erro // supportsECDHE returns whether ECDHE key exchanges can be used with this // pre-TLS 1.3 client. -func supportsECDHE(c *Config, supportedCurves []CurveID, supportedPoints []uint8) bool { +func supportsECDHE(c *Config, version uint16, supportedCurves []CurveID, supportedPoints []uint8) bool { supportsCurve := false for _, curve := range supportedCurves { - if c.supportsCurve(curve) { + if c.supportsCurve(version, curve) { supportsCurve = true break } @@ -587,6 +588,9 @@ func (hs *serverHandshakeState) doFullHandshake() error { return err } if skx != nil { + if len(skx.key) >= 3 && skx.key[0] == 3 /* named curve */ { + c.curveID = CurveID(byteorder.BeUint16(skx.key[1:])) + } if _, err := hs.c.writeHandshakeRecord(skx, &hs.finishedHash); err != nil { return err } diff --git a/handshake_server_test.go b/handshake_server_test.go index 813495d..bc45a28 100644 --- a/handshake_server_test.go +++ b/handshake_server_test.go @@ -81,6 +81,7 @@ func testClientHelloFailure(t *testing.T, serverConfig *Config, m handshakeMessa } } s.Close() + t.Helper() if len(expectedSubStr) == 0 { if err != nil && err != io.EOF { t.Errorf("Got error: %s; expected to succeed", err) diff --git a/handshake_server_tls13.go b/handshake_server_tls13.go index a7d3890..3bc3e91 100644 --- a/handshake_server_tls13.go +++ b/handshake_server_tls13.go @@ -9,6 +9,7 @@ import ( "context" "crypto" "crypto/hmac" + "crypto/internal/mlkem768" "crypto/rsa" "errors" "hash" @@ -178,11 +179,11 @@ func (hs *serverHandshakeStateTLS13) processClientHello() error { hs.hello.cipherSuite = hs.suite.id hs.transcript = hs.suite.hash.New() - // Pick the ECDHE group in server preference order, but give priority to - // groups with a key share, to avoid a HelloRetryRequest round-trip. + // Pick the key exchange method in server preference order, but give + // priority to key shares, to avoid a HelloRetryRequest round-trip. var selectedGroup CurveID var clientKeyShare *keyShare - preferredGroups := c.config.curvePreferences() + preferredGroups := c.config.curvePreferences(c.vers) for _, preferredGroup := range preferredGroups { ki := slices.IndexFunc(hs.clientHello.keyShares, func(ks keyShare) bool { return ks.group == preferredGroup @@ -210,23 +211,35 @@ func (hs *serverHandshakeStateTLS13) processClientHello() error { return errors.New("tls: no ECDHE curve supported by both client and server") } if clientKeyShare == nil { - if err := hs.doHelloRetryRequest(selectedGroup); err != nil { + ks, err := hs.doHelloRetryRequest(selectedGroup) + if err != nil { return err } - clientKeyShare = &hs.clientHello.keyShares[0] + clientKeyShare = ks } + c.curveID = selectedGroup - if _, ok := curveForCurveID(selectedGroup); !ok { + ecdhGroup := selectedGroup + ecdhData := clientKeyShare.data + if selectedGroup == x25519Kyber768Draft00 { + ecdhGroup = X25519 + if len(ecdhData) != x25519PublicKeySize+mlkem768.EncapsulationKeySize { + c.sendAlert(alertIllegalParameter) + return errors.New("tls: invalid Kyber client key share") + } + ecdhData = ecdhData[:x25519PublicKeySize] + } + if _, ok := curveForCurveID(ecdhGroup); !ok { c.sendAlert(alertInternalError) return errors.New("tls: CurvePreferences includes unsupported curve") } - key, err := generateECDHEKey(c.config.rand(), selectedGroup) + key, err := generateECDHEKey(c.config.rand(), ecdhGroup) if err != nil { c.sendAlert(alertInternalError) return err } hs.hello.serverShare = keyShare{group: selectedGroup, data: key.PublicKey().Bytes()} - peerKey, err := key.Curve().NewPublicKey(clientKeyShare.data) + peerKey, err := key.Curve().NewPublicKey(ecdhData) if err != nil { c.sendAlert(alertIllegalParameter) return errors.New("tls: invalid client key share") @@ -236,6 +249,15 @@ func (hs *serverHandshakeStateTLS13) processClientHello() error { c.sendAlert(alertIllegalParameter) return errors.New("tls: invalid client key share") } + if selectedGroup == x25519Kyber768Draft00 { + ciphertext, kyberShared, err := kyberEncapsulate(clientKeyShare.data[x25519PublicKeySize:]) + if err != nil { + c.sendAlert(alertIllegalParameter) + return errors.New("tls: invalid Kyber client key share") + } + hs.sharedKey = append(hs.sharedKey, kyberShared...) + hs.hello.serverShare.data = append(hs.hello.serverShare.data, ciphertext...) + } selectedProto, err := negotiateALPN(c.config.NextProtos, hs.clientHello.alpnProtocols, c.quic != nil) if err != nil { @@ -479,13 +501,13 @@ func (hs *serverHandshakeStateTLS13) sendDummyChangeCipherSpec() error { return hs.c.writeChangeCipherRecord() } -func (hs *serverHandshakeStateTLS13) doHelloRetryRequest(selectedGroup CurveID) error { +func (hs *serverHandshakeStateTLS13) doHelloRetryRequest(selectedGroup CurveID) (*keyShare, error) { c := hs.c // The first ClientHello gets double-hashed into the transcript upon a // HelloRetryRequest. See RFC 8446, Section 4.4.1. if err := transcriptMsg(hs.clientHello, hs.transcript); err != nil { - return err + return nil, err } chHash := hs.transcript.Sum(nil) hs.transcript.Reset() @@ -503,43 +525,49 @@ func (hs *serverHandshakeStateTLS13) doHelloRetryRequest(selectedGroup CurveID) } if _, err := hs.c.writeHandshakeRecord(helloRetryRequest, hs.transcript); err != nil { - return err + return nil, err } if err := hs.sendDummyChangeCipherSpec(); err != nil { - return err + return nil, err } // clientHelloMsg is not included in the transcript. msg, err := c.readHandshake(nil) if err != nil { - return err + return nil, err } clientHello, ok := msg.(*clientHelloMsg) if !ok { c.sendAlert(alertUnexpectedMessage) - return unexpectedMessageError(clientHello, msg) + return nil, unexpectedMessageError(clientHello, msg) } - if len(clientHello.keyShares) != 1 || clientHello.keyShares[0].group != selectedGroup { + if len(clientHello.keyShares) != 1 { c.sendAlert(alertIllegalParameter) - return errors.New("tls: client sent invalid key share in second ClientHello") + return nil, errors.New("tls: client didn't send one key share in second ClientHello") + } + ks := &clientHello.keyShares[0] + + if ks.group != selectedGroup { + c.sendAlert(alertIllegalParameter) + return nil, errors.New("tls: client sent unexpected key share in second ClientHello") } if clientHello.earlyData { c.sendAlert(alertIllegalParameter) - return errors.New("tls: client indicated early data in second ClientHello") + return nil, errors.New("tls: client indicated early data in second ClientHello") } if illegalClientHelloChange(clientHello, hs.clientHello) { c.sendAlert(alertIllegalParameter) - return errors.New("tls: client illegally modified second ClientHello") + return nil, errors.New("tls: client illegally modified second ClientHello") } c.didHRR = true hs.clientHello = clientHello - return nil + return ks, nil } // illegalClientHelloChange reports whether the two ClientHello messages are diff --git a/handshake_test.go b/handshake_test.go index f5e467b..480e050 100644 --- a/handshake_test.go +++ b/handshake_test.go @@ -378,6 +378,7 @@ func runMain(m *testing.M) int { Certificates: make([]Certificate, 2), InsecureSkipVerify: true, CipherSuites: allCipherSuites(), + CurvePreferences: []CurveID{X25519, CurveP256, CurveP384, CurveP521}, MinVersion: VersionTLS10, MaxVersion: VersionTLS13, } diff --git a/key_agreement.go b/key_agreement.go index 2c8c5b8..3e96242 100644 --- a/key_agreement.go +++ b/key_agreement.go @@ -16,8 +16,8 @@ import ( "io" ) -// a keyAgreement implements the client and server side of a TLS key agreement -// protocol by generating and processing key exchange messages. +// A keyAgreement implements the client and server side of a TLS 1.0–1.2 key +// agreement protocol by generating and processing key exchange messages. type keyAgreement interface { // On the server side, the first two methods are called in order. @@ -126,7 +126,7 @@ func md5SHA1Hash(slices [][]byte) []byte { } // hashForServerKeyExchange hashes the given slices and returns their digest -// using the given hash function (for >= TLS 1.2) or using a default based on +// using the given hash function (for TLS 1.2) or using a default based on // the sigType (for earlier TLS versions). For Ed25519 signatures, which don't // do pre-hashing, it returns the concatenation of the slices. func hashForServerKeyExchange(sigType uint8, hashFunc crypto.Hash, version uint16, slices ...[]byte) []byte { @@ -169,7 +169,7 @@ type ecdheKeyAgreement struct { func (ka *ecdheKeyAgreement) generateServerKeyExchange(config *Config, cert *Certificate, clientHello *clientHelloMsg, hello *serverHelloMsg) (*serverKeyExchangeMsg, error) { var curveID CurveID for _, c := range clientHello.supportedCurves { - if config.supportsCurve(c) { + if config.supportsCurve(ka.version, c) { curveID = c break } diff --git a/key_schedule.go b/key_schedule.go index d7f082c..1636baf 100644 --- a/key_schedule.go +++ b/key_schedule.go @@ -7,6 +7,7 @@ package tls import ( "crypto/ecdh" "crypto/hmac" + "crypto/internal/mlkem768" "errors" "fmt" "hash" @@ -14,6 +15,7 @@ import ( "golang.org/x/crypto/cryptobyte" "golang.org/x/crypto/hkdf" + "golang.org/x/crypto/sha3" ) // This file contains the functions necessary to compute the TLS 1.3 key @@ -117,6 +119,45 @@ func (c *cipherSuiteTLS13) exportKeyingMaterial(masterSecret []byte, transcript } } +type keySharePrivateKeys struct { + curveID CurveID + ecdhe *ecdh.PrivateKey + kyber *mlkem768.DecapsulationKey +} + +// kyberDecapsulate implements decapsulation according to Kyber Round 3. +func kyberDecapsulate(dk *mlkem768.DecapsulationKey, c []byte) ([]byte, error) { + K, err := mlkem768.Decapsulate(dk, c) + if err != nil { + return nil, err + } + return kyberSharedSecret(K, c), nil +} + +// kyberEncapsulate implements encapsulation according to Kyber Round 3. +func kyberEncapsulate(ek []byte) (c, ss []byte, err error) { + c, ss, err = mlkem768.Encapsulate(ek) + if err != nil { + return nil, nil, err + } + return c, kyberSharedSecret(ss, c), nil +} + +func kyberSharedSecret(K, c []byte) []byte { + // Package mlkem768 implements ML-KEM, which compared to Kyber removed a + // final hashing step. Compute SHAKE-256(K || SHA3-256(c), 32) to match Kyber. + // See https://words.filippo.io/mlkem768/#bonus-track-using-a-ml-kem-implementation-as-kyber-v3. + h := sha3.NewShake256() + h.Write(K) + ch := sha3.Sum256(c) + h.Write(ch[:]) + out := make([]byte, 32) + h.Read(out) + return out +} + +const x25519PublicKeySize = 32 + // generateECDHEKey returns a PrivateKey that implements Diffie-Hellman // according to RFC 8446, Section 4.2.8.2. func generateECDHEKey(rand io.Reader, curveID CurveID) (*ecdh.PrivateKey, error) { diff --git a/key_schedule_test.go b/key_schedule_test.go index 79ff6a6..3ffdf6c 100644 --- a/key_schedule_test.go +++ b/key_schedule_test.go @@ -6,6 +6,7 @@ package tls import ( "bytes" + "crypto/internal/mlkem768" "encoding/hex" "hash" "strings" @@ -173,3 +174,39 @@ func TestExtract(t *testing.T) { }) } } + +func TestKyberDecapsulate(t *testing.T) { + // From https://pq-crystals.org/kyber/data/kyber-submission-nist-round3.zip + dkBytes, _ := hex.DecodeString("07638FB69868F3D320E5862BD96933FEB311B362093C9B5D50170BCED43F1B536D9A204BB1F22695950BA1F2A9E8EB828B284488760B3FC84FABA04275D5628E39C5B2471374283C503299C0AB49B66B8BBB56A4186624F919A2BA59BB08D8551880C2BEFC4F87F25F59AB587A79C327D792D54C974A69262FF8A78938289E9A87B688B083E0595FE218B6BB1505941CE2E81A5A64C5AAC60417256985349EE47A52420A5F97477B7236AC76BC70E8288729287EE3E34A3DBC3683C0B7B10029FC203418537E7466BA6385A8FF301EE12708F82AAA1E380FC7A88F8F205AB7E88D7E95952A55BA20D09B79A47141D62BF6EB7DD307B08ECA13A5BC5F6B68581C6865B27BBCDDAB142F4B2CBFF488C8A22705FAA98A2B9EEA3530C76662335CC7EA3A00777725EBCCCD2A4636B2D9122FF3AB77123CE0883C1911115E50C9E8A94194E48DD0D09CFFB3ADCD2C1E92430903D07ADBF00532031575AA7F9E7B5A1F3362DEC936D4043C05F2476C07578BC9CBAF2AB4E382727AD41686A96B2548820BB03B32F11B2811AD62F489E951632ABA0D1DF89680CC8A8B53B481D92A68D70B4EA1C3A6A561C0692882B5CA8CC942A8D495AFCB06DE89498FB935B775908FE7A03E324D54CC19D4E1AABD3593B38B19EE1388FE492B43127E5A504253786A0D69AD32601C28E2C88504A5BA599706023A61363E17C6B9BB59BDC697452CD059451983D738CA3FD034E3F5988854CA05031DB09611498988197C6B30D258DFE26265541C89A4B31D6864E9389B03CB74F7EC4323FB9421A4B9790A26D17B0398A26767350909F84D57B6694DF830664CA8B3C3C03ED2AE67B89006868A68527CCD666459AB7F056671000C6164D3A7F266A14D97CBD7004D6C92CACA770B844A4FA9B182E7B18CA885082AC5646FCB4A14E1685FEB0C9CE3372AB95365C04FD83084F80A23FF10A05BF15F7FA5ACC6C0CB462C33CA524FA6B8BB359043BA68609EAA2536E81D08463B19653B5435BA946C9ADDEB202B04B031CC960DCC12E4518D428B32B257A4FC7313D3A7980D80082E934F9D95C32B0A0191A23604384DD9E079BBBAA266D14C3F756B9F2133107433A4E83FA7187282A809203A4FAF841851833D121AC383843A5E55BC2381425E16C7DB4CC9AB5C1B0D91A47E2B8DE0E582C86B6B0D907BB360B97F40AB5D038F6B75C814B27D9B968D419832BC8C2BEE605EF6E5059D33100D90485D378450014221736C07407CAC260408AA64926619788B8601C2A752D1A6CBF820D7C7A04716203225B3895B9342D147A8185CFC1BB65BA06B4142339903C0AC4651385B45D98A8B19D28CD6BAB088787F7EE1B12461766B43CBCCB96434427D93C065550688F6948ED1B5475A425F1B85209D061C08B56C1CC069F6C0A7C6F29358CAB911087732A649D27C9B98F9A48879387D9B00C25959A71654D6F6A946164513E47A75D005986C2363C09F6B537ECA78B9303A5FA457608A586A653A347DB04DFCC19175B3A301172536062A658A95277570C8852CA8973F4AE123A334047DD711C8927A634A03388A527B034BF7A8170FA702C1F7C23EC32D18A2374890BE9C787A9409C82D192C4BB705A2F996CE405DA72C2D9C843EE9F8313ECC7F86D6294D59159D9A879A542E260922ADF999051CC45200C9FFDB60449C49465979272367C083A7D6267A3ED7A7FD47957C219327F7CA73A4007E1627F00B11CC80573C15AEE6640FB8562DFA6B240CA0AD351AC4AC155B96C14C8AB13DD262CDFD51C4BB5572FD616553D17BDD430ACBEA3E95F0B698D66990AB51E5D03783A8B3D278A5720454CF9695CFDCA08485BA099C51CD92A7EA7587C1D15C28E609A81852601B0604010679AA482D51261EC36E36B8719676217FD74C54786488F4B4969C05A8BA27CA3A77CCE73B965923CA554E422B9B61F4754641608AC16C9B8587A32C1C5DD788F88B36B717A46965635DEB67F45B129B99070909C93EB80B42C2B3F3F70343A7CF37E8520E7BCFC416ACA4F18C7981262BA2BFC756AE03278F0EC66DC2057696824BA6769865A601D7148EF6F54E5AF5686AA2906F994CE38A5E0B938F239007003022C03392DF3401B1E4A3A7EBC6161449F73374C8B0140369343D9295FDF511845C4A46EBAAB6CA5492F6800B98C0CC803653A4B1D6E6AAED1932BACC5FEFAA818BA502859BA5494C5F5402C8536A9C4C1888150617F80098F6B2A99C39BC5DC7CF3B5900A21329AB59053ABAA64ED163E859A8B3B3CA3359B750CCC3E710C7AC43C8191CB5D68870C06391C0CB8AEC72B897AC6BE7FBAACC676ED66314C83630E89448C88A1DF04ACEB23ABF2E409EF333C622289C18A2134E650C45257E47475FA33AA537A5A8F7680214716C50D470E3284963CA64F54677AEC54B5272162BF52BC8142E1D4183FC017454A6B5A496831759064024745978CBD51A6CEDC8955DE4CC6D363670A47466E82BE5C23603A17BF22ACDB7CC984AF08C87E14E27753CF587A8EC3447E62C649E887A67C36C9CE98721B697213275646B194F36758673A8ED11284455AFC7A8529F69C97A3C2D7B8C636C0BA55614B768E624E712930F776169B01715725351BC74B47395ED52B25A1313C95164814C34C979CBDFAB85954662CAB485E75087A98CC74BB82CA2D1B5BF2803238480638C40E90B43C7460E7AA917F010151FAB1169987B372ABB59271F7006C24E60236B84B9DDD600623704254617FB498D89E58B0368BCB2103E79353EB587860C1422E476162E425BC2381DB82C6592737E1DD602864B0167A71EC1F223305C02FE25052AF2B3B5A55A0D7A2022D9A798DC0C5874A98702AAF4054C5D80338A5248B5B7BD09C53B5E2A084B047D277A861B1A73BB51488DE04EF573C85230A0470B73175C9FA50594F66A5F50B4150054C93B68186F8B5CBC49316C8548A642B2B36A1D454C7489AC33B2D2CE6668096782A2C1E0866D21A65E16B585E7AF8618BDF3184C1986878508917277B93E10706B1614972B2A94C7310FE9C708C231A1A8AC8D9314A529A97F469BF64962D820648443099A076D55D4CEA824A58304844F99497C10A25148618A315D72CA857D1B04D575B94F85C01D19BEF211BF0AA3362E7041FD16596D808E867B44C4C00D1CDA3418967717F147D0EB21B42AAEE74AC35D0B92414B958531AADF463EC6305AE5ECAF79174002F26DDECC813BF32672E8529D95A4E730A7AB4A3E8F8A8AF979A665EAFD465FC64A0C5F8F3F9003489415899D59A543D8208C54A3166529B53922D4EC143B50F01423B177895EDEE22BB739F647ECF85F50BC25EF7B5A725DEE868626ED79D451140800E03B59B956F8210E556067407D13DC90FA9E8B872BFB8F") + dk, err := mlkem768.NewKeyFromExtendedEncoding(dkBytes) + if err != nil { + t.Fatal(err) + } + ct, _ := hex.DecodeString("B52C56B92A4B7CE9E4CB7C5B1B163167A8A1675B2FDEF84A5B67CA15DB694C9F11BD027C30AE22EC921A1D911599AF0585E48D20DA70DF9F39E32EF95D4C8F44BFEFDAA5DA64F1054631D04D6D3CFD0A540DD7BA3886E4B5F13E878788604C95C096EAB3919F427521419A946C26CC041475D7124CDC01D0373E5B09C7A70603CFDB4FB3405023F2264DC3F983C4FC02A2D1B268F2208A1F6E2A6209BFF12F6F465F0B069C3A7F84F606D8A94064003D6EC114C8E808D3053884C1D5A142FBF20112EB360FDA3F0F28B172AE50F5E7D83801FB3F0064B687187074BD7FE30EDDAA334CF8FC04FA8CED899CEADE4B4F28B68372BAF98FF482A415B731155B75CEB976BE0EA0285BA01A27F1857A8FB377A3AE0C23B2AA9A079BFABFF0D5B2F1CD9B718BEA03C42F343A39B4F142D01AD8ACBB50E38853CF9A50C8B44C3CF671A4A9043B26DDBB24959AD6715C08521855C79A23B9C3D6471749C40725BDD5C2776D43AED20204BAA141EFB3304917474B7F9F7A4B08B1A93DAED98C67495359D37D67F7438BEE5E43585634B26C6B3810D7CDCBC0F6EB877A6087E68ACB8480D3A8CF6900447E49B417F15A53B607A0E216B855970D37406870B4568722DA77A4084703816784E2F16BED18996532C5D8B7F5D214464E5F3F6E905867B0CE119E252A66713253544685D208E1723908A0CE97834652E08AE7BDC881A131B73C71E84D20D68FDEFF4F5D70CD1AF57B78E3491A9865942321800A203C05ED1FEEB5A28E584E19F6535E7F84E4A24F84A72DCAF5648B4A4235DD664464482F03176E888C28BFC6C1CB238CFFA35A321E71791D9EA8ED0878C61121BF8D2A4AB2C1A5E120BC40ABB1892D1715090A0EE48252CA297A99AA0E510CF26B1ADD06CA543E1C5D6BDCD3B9C585C8538045DB5C252EC3C8C3C954D9BE5907094A894E60EAB43538CFEE82E8FFC0791B0D0F43AC1627830A61D56DAD96C62958B0DE780B78BD47A604550DAB83FFF227C324049471F35248CFB849B25724FF704D5277AA352D550958BE3B237DFF473EC2ADBAEA48CA2658AEFCC77BBD4264AB374D70EAE5B964416CE8226A7E3255A0F8D7E2ADCA062BCD6D78D60D1B32E11405BE54B66EF0FDDD567702A3BCCFEDE3C584701269ED14809F06F8968356BB9267FE86E514252E88BB5C30A7ECB3D0E621021EE0FBF7871B09342BF84F55C97EAF86C48189C7FF4DF389F077E2806E5FA73B3E9458A16C7E275F4F602275580EB7B7135FB537FA0CD95D6EA58C108CD8943D70C1643111F4F01CA8A8276A902666ED81B78D168B006F16AAA3D8E4CE4F4D0FB0997E41AEFFB5B3DAA838732F357349447F387776C793C0479DE9E99498CC356FDB0075A703F23C55D47B550EC89B02ADE89329086A50843456FEDC3788AC8D97233C54560467EE1D0F024B18428F0D73B30E19F5C63B9ABF11415BEA4D0170130BAABD33C05E6524E5FB5581B22B0433342248266D0F1053B245CC2462DC44D34965102482A8ED9E4E964D5683E5D45D0C8269") + ss, err := kyberDecapsulate(dk, ct) + if err != nil { + t.Fatal(err) + } + exp, _ := hex.DecodeString("914CB67FE5C38E73BF74181C0AC50428DEDF7750A98058F7D536708774535B29") + if !bytes.Equal(ss, exp) { + t.Fatalf("got %x, want %x", ss, exp) + } +} + +func TestKyberEncapsulate(t *testing.T) { + dk, err := mlkem768.GenerateKey() + if err != nil { + t.Fatal(err) + } + ct, ss, err := kyberEncapsulate(dk.EncapsulationKey()) + if err != nil { + t.Fatal(err) + } + dkSS, err := kyberDecapsulate(dk, ct) + if err != nil { + t.Fatal(err) + } + if !bytes.Equal(ss, dkSS) { + t.Fatalf("got %x, want %x", ss, dkSS) + } +} diff --git a/tls_test.go b/tls_test.go index 096b4ed..ce1c967 100644 --- a/tls_test.go +++ b/tls_test.go @@ -18,6 +18,7 @@ import ( "net" "os" "reflect" + "slices" "sort" "strings" "testing" @@ -1805,3 +1806,135 @@ func testVerifyCertificates(t *testing.T, version uint16) { }) } } + +func TestHandshakeKyber(t *testing.T) { + if x25519Kyber768Draft00.String() != "X25519Kyber768Draft00" { + t.Fatalf("unexpected CurveID string: %v", x25519Kyber768Draft00.String()) + } + + var tests = []struct { + name string + clientConfig func(*Config) + serverConfig func(*Config) + preparation func(*testing.T) + expectClientSupport bool + expectKyber bool + expectHRR bool + }{ + { + name: "Default", + expectClientSupport: true, + expectKyber: true, + expectHRR: false, + }, + { + name: "ClientCurvePreferences", + clientConfig: func(config *Config) { + config.CurvePreferences = []CurveID{X25519} + }, + expectClientSupport: false, + }, + { + name: "ServerCurvePreferencesX25519", + serverConfig: func(config *Config) { + config.CurvePreferences = []CurveID{X25519} + }, + expectClientSupport: true, + expectKyber: false, + expectHRR: false, + }, + { + name: "ServerCurvePreferencesHRR", + serverConfig: func(config *Config) { + config.CurvePreferences = []CurveID{CurveP256} + }, + expectClientSupport: true, + expectKyber: false, + expectHRR: true, + }, + { + name: "ClientTLSv12", + clientConfig: func(config *Config) { + config.MaxVersion = VersionTLS12 + }, + expectClientSupport: false, + }, + { + name: "ServerTLSv12", + serverConfig: func(config *Config) { + config.MaxVersion = VersionTLS12 + }, + expectClientSupport: true, + expectKyber: false, + }, + { + name: "GODEBUG", + preparation: func(t *testing.T) { + t.Setenv("GODEBUG", "tlskyber=0") + }, + expectClientSupport: false, + }, + } + + baseConfig := testConfig.Clone() + baseConfig.CurvePreferences = nil + for _, test := range tests { + t.Run(test.name, func(t *testing.T) { + if test.preparation != nil { + test.preparation(t) + } else { + t.Parallel() + } + serverConfig := baseConfig.Clone() + if test.serverConfig != nil { + test.serverConfig(serverConfig) + } + serverConfig.GetConfigForClient = func(hello *ClientHelloInfo) (*Config, error) { + if !test.expectClientSupport && slices.Contains(hello.SupportedCurves, x25519Kyber768Draft00) { + return nil, errors.New("client supports Kyber768Draft00") + } else if test.expectClientSupport && !slices.Contains(hello.SupportedCurves, x25519Kyber768Draft00) { + return nil, errors.New("client does not support Kyber768Draft00") + } + return nil, nil + } + clientConfig := baseConfig.Clone() + if test.clientConfig != nil { + test.clientConfig(clientConfig) + } + ss, cs, err := testHandshake(t, clientConfig, serverConfig) + if err != nil { + t.Fatal(err) + } + if test.expectKyber { + if ss.testingOnlyCurveID != x25519Kyber768Draft00 { + t.Errorf("got CurveID %v (server), expected %v", ss.testingOnlyCurveID, x25519Kyber768Draft00) + } + if cs.testingOnlyCurveID != x25519Kyber768Draft00 { + t.Errorf("got CurveID %v (client), expected %v", cs.testingOnlyCurveID, x25519Kyber768Draft00) + } + } else { + if ss.testingOnlyCurveID == x25519Kyber768Draft00 { + t.Errorf("got CurveID %v (server), expected not Kyber", ss.testingOnlyCurveID) + } + if cs.testingOnlyCurveID == x25519Kyber768Draft00 { + t.Errorf("got CurveID %v (client), expected not Kyber", cs.testingOnlyCurveID) + } + } + if test.expectHRR { + if !ss.testingOnlyDidHRR { + t.Error("server did not use HRR") + } + if !cs.testingOnlyDidHRR { + t.Error("client did not use HRR") + } + } else { + if ss.testingOnlyDidHRR { + t.Error("server used HRR") + } + if cs.testingOnlyDidHRR { + t.Error("client used HRR") + } + } + }) + } +} From 833bba2d07636d68ca9f517c77744e94dc4b605a Mon Sep 17 00:00:00 2001 From: Damien Neil Date: Sun, 22 Oct 2023 16:31:59 -0400 Subject: [PATCH 15/39] crypto/tls: improved 0-RTT QUIC API Add synchronous management of stored sessions to QUICConn. This adds QUICStoreSession and QUICResumeSession events, permitting a QUIC implementation to handle session resumption as part of its regular event loop processing. Fixes #63691 Change-Id: I9fe16207cc1986eac084869675bc36e227cbf3f0 Reviewed-on: https://go-review.googlesource.com/c/go/+/536935 LUCI-TryBot-Result: Go LUCI Reviewed-by: Marten Seemann Reviewed-by: Roland Shoemaker --- handshake_client.go | 13 ++-- handshake_client_test.go | 6 +- handshake_client_tls13.go | 8 ++- handshake_server_tls13.go | 11 ++- quic.go | 91 ++++++++++++++++++++++-- quic_test.go | 145 +++++++++++++++++++++++++++++++++++--- ticket.go | 10 ++- 7 files changed, 254 insertions(+), 30 deletions(-) diff --git a/handshake_client.go b/handshake_client.go index 53d4f90..1a17385 100644 --- a/handshake_client.go +++ b/handshake_client.go @@ -366,7 +366,7 @@ func (c *Conn) loadSession(hello *clientHelloMsg) ( return nil, nil, nil, nil } - hello.sessionTicket = cs.ticket + hello.sessionTicket = session.ticket return } @@ -394,10 +394,12 @@ func (c *Conn) loadSession(hello *clientHelloMsg) ( return nil, nil, nil, nil } - if c.quic != nil && session.EarlyData { + if c.quic != nil { + c.quicResumeSession(session) + // For 0-RTT, the cipher suite has to match exactly, and we need to be // offering the same ALPN. - if mutualCipherSuiteTLS13(hello.cipherSuites, session.cipherSuite) != nil { + if session.EarlyData && mutualCipherSuiteTLS13(hello.cipherSuites, session.cipherSuite) != nil { for _, alpn := range hello.alpnProtocols { if alpn == session.alpnProtocol { hello.earlyData = true @@ -410,7 +412,7 @@ func (c *Conn) loadSession(hello *clientHelloMsg) ( // Set the pre_shared_key extension. See RFC 8446, Section 4.2.11.1. ticketAge := c.config.time().Sub(time.Unix(int64(session.createdAt), 0)) identity := pskIdentity{ - label: cs.ticket, + label: session.ticket, obfuscatedTicketAge: uint32(ticketAge/time.Millisecond) + session.ageAdd, } hello.pskIdentities = []pskIdentity{identity} @@ -940,8 +942,9 @@ func (hs *clientHandshakeState) saveSessionTicket() error { session := c.sessionState() session.secret = hs.masterSecret + session.ticket = hs.ticket - cs := &ClientSessionState{ticket: hs.ticket, session: session} + cs := &ClientSessionState{session: session} c.config.ClientSessionCache.Put(cacheKey, cs) return nil } diff --git a/handshake_client_test.go b/handshake_client_test.go index eb0fe36..a32b48a 100644 --- a/handshake_client_test.go +++ b/handshake_client_test.go @@ -923,7 +923,7 @@ func testResumption(t *testing.T, version uint16) { } getTicket := func() []byte { - return clientConfig.ClientSessionCache.(*lruSessionCache).q.Front().Value.(*lruSessionCacheEntry).state.ticket + return clientConfig.ClientSessionCache.(*lruSessionCache).q.Front().Value.(*lruSessionCacheEntry).state.session.ticket } deleteTicket := func() { ticketKey := clientConfig.ClientSessionCache.(*lruSessionCache).q.Front().Value.(*lruSessionCacheEntry).sessionKey @@ -1107,6 +1107,10 @@ func (c *serializingClientCache) Get(sessionKey string) (session *ClientSessionS } func (c *serializingClientCache) Put(sessionKey string, cs *ClientSessionState) { + if cs == nil { + c.ticket, c.state = nil, nil + return + } ticket, state, err := cs.ResumptionState() if err != nil { c.t.Error(err) diff --git a/handshake_client_tls13.go b/handshake_client_tls13.go index 06f3f82..820532b 100644 --- a/handshake_client_tls13.go +++ b/handshake_client_tls13.go @@ -783,8 +783,12 @@ func (c *Conn) handleNewSessionTicket(msg *newSessionTicketMsgTLS13) error { session.useBy = uint64(c.config.time().Add(lifetime).Unix()) session.ageAdd = msg.ageAdd session.EarlyData = c.quic != nil && msg.maxEarlyData == 0xffffffff // RFC 9001, Section 4.6.1 - cs := &ClientSessionState{ticket: msg.label, session: session} - + session.ticket = msg.label + if c.quic != nil && c.quic.enableStoreSessionEvent { + c.quicStoreSession(session) + return nil + } + cs := &ClientSessionState{session: session} if cacheKey := c.clientSessionCacheKey(); cacheKey != "" { c.config.ClientSessionCache.Put(cacheKey, cs) } diff --git a/handshake_server_tls13.go b/handshake_server_tls13.go index 3bc3e91..f24c267 100644 --- a/handshake_server_tls13.go +++ b/handshake_server_tls13.go @@ -377,6 +377,12 @@ func (hs *serverHandshakeStateTLS13) checkForResumption() error { continue } + if c.quic != nil { + if err := c.quicResumeSession(sessionState); err != nil { + return err + } + } + hs.earlySecret = hs.suite.extract(sessionState.secret, nil) binderKey := hs.suite.deriveSecret(hs.earlySecret, resumptionBinderLabel, nil) // Clone the transcript in case a HelloRetryRequest was recorded. @@ -856,10 +862,10 @@ func (hs *serverHandshakeStateTLS13) sendSessionTickets() error { if !hs.shouldSendSessionTickets() { return nil } - return c.sendSessionTicket(false) + return c.sendSessionTicket(false, nil) } -func (c *Conn) sendSessionTicket(earlyData bool) error { +func (c *Conn) sendSessionTicket(earlyData bool, extra [][]byte) error { suite := cipherSuiteTLS13ByID(c.cipherSuite) if suite == nil { return errors.New("tls: internal error: unknown cipher suite") @@ -874,6 +880,7 @@ func (c *Conn) sendSessionTicket(earlyData bool) error { state := c.sessionState() state.secret = psk state.EarlyData = earlyData + state.Extra = extra if c.config.WrapSession != nil { var err error m.label, err = c.config.WrapSession(c.connectionStateLocked(), state) diff --git a/quic.go b/quic.go index 3518169..8e722c6 100644 --- a/quic.go +++ b/quic.go @@ -49,6 +49,13 @@ type QUICConn struct { // A QUICConfig configures a [QUICConn]. type QUICConfig struct { TLSConfig *Config + + // EnableStoreSessionEvent may be set to true to enable the + // [QUICStoreSession] event for client connections. + // When this event is enabled, sessions are not automatically + // stored in the client session cache. + // The application should use [QUICConn.StoreSession] to store sessions. + EnableStoreSessionEvent bool } // A QUICEventKind is a type of operation on a QUIC connection. @@ -87,10 +94,29 @@ const ( // QUICRejectedEarlyData indicates that the server rejected 0-RTT data even // if we offered it. It's returned before QUICEncryptionLevelApplication // keys are returned. + // This event only occurs on client connections. QUICRejectedEarlyData // QUICHandshakeDone indicates that the TLS handshake has completed. QUICHandshakeDone + + // QUICResumeSession indicates that a client is attempting to resume a previous session. + // [QUICEvent.SessionState] is set. + // + // For client connections, this event occurs when the session ticket is selected. + // For server connections, this event occurs when receiving the client's session ticket. + // + // The application may set [QUICEvent.SessionState.EarlyData] to false before the + // next call to [QUICConn.NextEvent] to decline 0-RTT even if the session supports it. + QUICResumeSession + + // QUICStoreSession indicates that the server has provided state permitting + // the client to resume the session. + // [QUICEvent.SessionState] is set. + // The application should use [QUICConn.Store] session to store the [SessionState]. + // The application may modify the [SessionState] before storing it. + // This event only occurs on client connections. + QUICStoreSession ) // A QUICEvent is an event occurring on a QUIC connection. @@ -109,6 +135,9 @@ type QUICEvent struct { // Set for QUICSetReadSecret and QUICSetWriteSecret. Suite uint16 + + // Set for QUICResumeSession and QUICStoreSession. + SessionState *SessionState } type quicState struct { @@ -127,12 +156,16 @@ type quicState struct { cancelc <-chan struct{} // handshake has been canceled cancel context.CancelFunc + waitingForDrain bool + // readbuf is shared between HandleData and the handshake goroutine. // HandshakeCryptoData passes ownership to the handshake goroutine by // reading from signalc, and reclaims ownership by reading from blockedc. readbuf []byte transportParams []byte // to send to the peer + + enableStoreSessionEvent bool } // QUICClient returns a new TLS client side connection using QUICTransport as the @@ -140,7 +173,7 @@ type quicState struct { // // The config's MinVersion must be at least TLS 1.3. func QUICClient(config *QUICConfig) *QUICConn { - return newQUICConn(Client(nil, config.TLSConfig)) + return newQUICConn(Client(nil, config.TLSConfig), config) } // QUICServer returns a new TLS server side connection using QUICTransport as the @@ -148,13 +181,14 @@ func QUICClient(config *QUICConfig) *QUICConn { // // The config's MinVersion must be at least TLS 1.3. func QUICServer(config *QUICConfig) *QUICConn { - return newQUICConn(Server(nil, config.TLSConfig)) + return newQUICConn(Server(nil, config.TLSConfig), config) } -func newQUICConn(conn *Conn) *QUICConn { +func newQUICConn(conn *Conn, config *QUICConfig) *QUICConn { conn.quic = &quicState{ - signalc: make(chan struct{}), - blockedc: make(chan struct{}), + signalc: make(chan struct{}), + blockedc: make(chan struct{}), + enableStoreSessionEvent: config.EnableStoreSessionEvent, } conn.quic.events = conn.quic.eventArr[:0] return &QUICConn{ @@ -190,6 +224,11 @@ func (q *QUICConn) NextEvent() QUICEvent { // to catch callers erroniously retaining it. qs.events[last].Data[0] = 0 } + if qs.nextEvent >= len(qs.events) && qs.waitingForDrain { + qs.waitingForDrain = false + <-qs.signalc + <-qs.blockedc + } if qs.nextEvent >= len(qs.events) { qs.events = qs.events[:0] qs.nextEvent = 0 @@ -255,6 +294,7 @@ func (q *QUICConn) HandleData(level QUICEncryptionLevel, data []byte) error { type QUICSessionTicketOptions struct { // EarlyData specifies whether the ticket may be used for 0-RTT. EarlyData bool + Extra [][]byte } // SendSessionTicket sends a session ticket to the client. @@ -272,7 +312,25 @@ func (q *QUICConn) SendSessionTicket(opts QUICSessionTicketOptions) error { return quicError(errors.New("tls: SendSessionTicket called multiple times")) } q.sessionTicketSent = true - return quicError(c.sendSessionTicket(opts.EarlyData)) + return quicError(c.sendSessionTicket(opts.EarlyData, opts.Extra)) +} + +// StoreSession stores a session previously received in a QUICStoreSession event +// in the ClientSessionCache. +// The application may process additional events or modify the SessionState +// before storing the session. +func (q *QUICConn) StoreSession(session *SessionState) error { + c := q.conn + if !c.isClient { + return quicError(errors.New("tls: StoreSessionTicket called on the server")) + } + cacheKey := c.clientSessionCacheKey() + if cacheKey == "" { + return nil + } + cs := &ClientSessionState{session: session} + c.config.ClientSessionCache.Put(cacheKey, cs) + return nil } // ConnectionState returns basic TLS details about the connection. @@ -356,6 +414,27 @@ func (c *Conn) quicWriteCryptoData(level QUICEncryptionLevel, data []byte) { last.Data = append(last.Data, data...) } +func (c *Conn) quicResumeSession(session *SessionState) error { + c.quic.events = append(c.quic.events, QUICEvent{ + Kind: QUICResumeSession, + SessionState: session, + }) + c.quic.waitingForDrain = true + for c.quic.waitingForDrain { + if err := c.quicWaitForSignal(); err != nil { + return err + } + } + return nil +} + +func (c *Conn) quicStoreSession(session *SessionState) { + c.quic.events = append(c.quic.events, QUICEvent{ + Kind: QUICStoreSession, + SessionState: session, + }) +} + func (c *Conn) quicSetTransportParameters(params []byte) { c.quic.events = append(c.quic.events, QUICEvent{ Kind: QUICTransportParameters, diff --git a/quic_test.go b/quic_test.go index 323906a..5a6f66e 100644 --- a/quic_test.go +++ b/quic_test.go @@ -5,6 +5,7 @@ package tls import ( + "bytes" "context" "errors" "reflect" @@ -12,12 +13,15 @@ import ( ) type testQUICConn struct { - t *testing.T - conn *QUICConn - readSecret map[QUICEncryptionLevel]suiteSecret - writeSecret map[QUICEncryptionLevel]suiteSecret - gotParams []byte - complete bool + t *testing.T + conn *QUICConn + readSecret map[QUICEncryptionLevel]suiteSecret + writeSecret map[QUICEncryptionLevel]suiteSecret + ticketOpts QUICSessionTicketOptions + onResumeSession func(*SessionState) + gotParams []byte + earlyDataRejected bool + complete bool } func newTestQUICClient(t *testing.T, config *Config) *testQUICConn { @@ -48,7 +52,7 @@ type suiteSecret struct { } func (q *testQUICConn) setReadSecret(level QUICEncryptionLevel, suite uint16, secret []byte) { - if _, ok := q.writeSecret[level]; !ok { + if _, ok := q.writeSecret[level]; !ok && level != QUICEncryptionLevelEarly { q.t.Errorf("SetReadSecret for level %v called before SetWriteSecret", level) } if level == QUICEncryptionLevelApplication && !q.complete { @@ -61,7 +65,9 @@ func (q *testQUICConn) setReadSecret(level QUICEncryptionLevel, suite uint16, se q.readSecret = map[QUICEncryptionLevel]suiteSecret{} } switch level { - case QUICEncryptionLevelHandshake, QUICEncryptionLevelApplication: + case QUICEncryptionLevelHandshake, + QUICEncryptionLevelEarly, + QUICEncryptionLevelApplication: q.readSecret[level] = suiteSecret{suite, secret} default: q.t.Errorf("SetReadSecret for unexpected level %v", level) @@ -76,7 +82,9 @@ func (q *testQUICConn) setWriteSecret(level QUICEncryptionLevel, suite uint16, s q.writeSecret = map[QUICEncryptionLevel]suiteSecret{} } switch level { - case QUICEncryptionLevelHandshake, QUICEncryptionLevelApplication: + case QUICEncryptionLevelHandshake, + QUICEncryptionLevelEarly, + QUICEncryptionLevelApplication: q.writeSecret[level] = suiteSecret{suite, secret} default: q.t.Errorf("SetWriteSecret for unexpected level %v", level) @@ -128,11 +136,16 @@ func runTestQUICConnection(ctx context.Context, cli, srv *testQUICConn, onEvent case QUICHandshakeDone: a.complete = true if a == srv { - opts := QUICSessionTicketOptions{} - if err := srv.conn.SendSessionTicket(opts); err != nil { + if err := srv.conn.SendSessionTicket(srv.ticketOpts); err != nil { return err } } + case QUICResumeSession: + if a.onResumeSession != nil { + a.onResumeSession(e.SessionState) + } + case QUICRejectedEarlyData: + a.earlyDataRejected = true } if e.Kind != QUICNoEvent { idleCount = 0 @@ -487,3 +500,113 @@ func TestQUICCanceledWaitingForTransportParams(t *testing.T) { t.Errorf("conn.Close() = %v, want alertCloseNotify", err) } } + +func TestQUICEarlyData(t *testing.T) { + clientConfig := testConfig.Clone() + clientConfig.MinVersion = VersionTLS13 + clientConfig.ClientSessionCache = NewLRUClientSessionCache(1) + clientConfig.ServerName = "example.go.dev" + clientConfig.NextProtos = []string{"h3"} + + serverConfig := testConfig.Clone() + serverConfig.MinVersion = VersionTLS13 + serverConfig.NextProtos = []string{"h3"} + + cli := newTestQUICClient(t, clientConfig) + cli.conn.SetTransportParameters(nil) + srv := newTestQUICServer(t, serverConfig) + srv.conn.SetTransportParameters(nil) + srv.ticketOpts.EarlyData = true + if err := runTestQUICConnection(context.Background(), cli, srv, nil); err != nil { + t.Fatalf("error during first connection handshake: %v", err) + } + if cli.conn.ConnectionState().DidResume { + t.Errorf("first connection unexpectedly used session resumption") + } + + cli2 := newTestQUICClient(t, clientConfig) + cli2.conn.SetTransportParameters(nil) + srv2 := newTestQUICServer(t, serverConfig) + srv2.conn.SetTransportParameters(nil) + if err := runTestQUICConnection(context.Background(), cli2, srv2, nil); err != nil { + t.Fatalf("error during second connection handshake: %v", err) + } + if !cli2.conn.ConnectionState().DidResume { + t.Errorf("second connection did not use session resumption") + } + cliSecret := cli2.writeSecret[QUICEncryptionLevelEarly] + if cliSecret.secret == nil { + t.Errorf("client did not receive early data write secret") + } + srvSecret := srv2.readSecret[QUICEncryptionLevelEarly] + if srvSecret.secret == nil { + t.Errorf("server did not receive early data read secret") + } + if cliSecret.suite != srvSecret.suite || !bytes.Equal(cliSecret.secret, srvSecret.secret) { + t.Errorf("client early data secret does not match server") + } +} + +func TestQUICEarlyDataDeclined(t *testing.T) { + t.Run("server", func(t *testing.T) { + testQUICEarlyDataDeclined(t, true) + }) + t.Run("client", func(t *testing.T) { + testQUICEarlyDataDeclined(t, false) + }) +} + +func testQUICEarlyDataDeclined(t *testing.T, server bool) { + clientConfig := testConfig.Clone() + clientConfig.MinVersion = VersionTLS13 + clientConfig.ClientSessionCache = NewLRUClientSessionCache(1) + clientConfig.ServerName = "example.go.dev" + clientConfig.NextProtos = []string{"h3"} + + serverConfig := testConfig.Clone() + serverConfig.MinVersion = VersionTLS13 + serverConfig.NextProtos = []string{"h3"} + + cli := newTestQUICClient(t, clientConfig) + cli.conn.SetTransportParameters(nil) + srv := newTestQUICServer(t, serverConfig) + srv.conn.SetTransportParameters(nil) + srv.ticketOpts.EarlyData = true + if err := runTestQUICConnection(context.Background(), cli, srv, nil); err != nil { + t.Fatalf("error during first connection handshake: %v", err) + } + if cli.conn.ConnectionState().DidResume { + t.Errorf("first connection unexpectedly used session resumption") + } + + cli2 := newTestQUICClient(t, clientConfig) + cli2.conn.SetTransportParameters(nil) + srv2 := newTestQUICServer(t, serverConfig) + srv2.conn.SetTransportParameters(nil) + declineEarlyData := func(state *SessionState) { + state.EarlyData = false + } + if server { + srv2.onResumeSession = declineEarlyData + } else { + cli2.onResumeSession = declineEarlyData + } + if err := runTestQUICConnection(context.Background(), cli2, srv2, nil); err != nil { + t.Fatalf("error during second connection handshake: %v", err) + } + if !cli2.conn.ConnectionState().DidResume { + t.Errorf("second connection did not use session resumption") + } + _, cliEarlyData := cli2.writeSecret[QUICEncryptionLevelEarly] + if server { + if !cliEarlyData { + t.Errorf("client did not receive early data write secret") + } + if !cli2.earlyDataRejected { + t.Errorf("client did not receive QUICEarlyDataRejected") + } + } + if _, srvEarlyData := srv2.readSecret[QUICEncryptionLevelEarly]; srvEarlyData { + t.Errorf("server received early data read secret") + } +} diff --git a/ticket.go b/ticket.go index 04e1dd6..06aec5a 100644 --- a/ticket.go +++ b/ticket.go @@ -96,6 +96,7 @@ type SessionState struct { // Client-side TLS 1.3-only fields. useBy uint64 // seconds since UNIX epoch ageAdd uint32 + ticket []byte } // Bytes encodes the session, including any private fields, so that it can be @@ -396,7 +397,6 @@ func (c *Config) decryptTicket(encrypted []byte, ticketKeys []ticketKey) []byte // ClientSessionState contains the state needed by a client to // resume a previous TLS session. type ClientSessionState struct { - ticket []byte session *SessionState } @@ -406,7 +406,10 @@ type ClientSessionState struct { // It can be called by [ClientSessionCache.Put] to serialize (with // [SessionState.Bytes]) and store the session. func (cs *ClientSessionState) ResumptionState() (ticket []byte, state *SessionState, err error) { - return cs.ticket, cs.session, nil + if cs == nil || cs.session == nil { + return nil, nil, nil + } + return cs.session.ticket, cs.session, nil } // NewResumptionState returns a state value that can be returned by @@ -415,7 +418,8 @@ func (cs *ClientSessionState) ResumptionState() (ticket []byte, state *SessionSt // state needs to be returned by [ParseSessionState], and the ticket and session // state must have been returned by [ClientSessionState.ResumptionState]. func NewResumptionState(ticket []byte, state *SessionState) (*ClientSessionState, error) { + state.ticket = ticket return &ClientSessionState{ - ticket: ticket, session: state, + session: state, }, nil } From bbd7da73e1e17204eb37baf7c3b34758a4d07aba Mon Sep 17 00:00:00 2001 From: Filippo Valsorda Date: Sat, 18 May 2024 20:15:38 +0200 Subject: [PATCH 16/39] crypto/tls: remove typeNextProtocol Was this strictly necessary? No. Did this deserve its own CL? Maybe not. But I have a personal vendetta against NPN. Change-Id: Ide1ad1092259dc23e3ead5c1d5269fc5cb2793d7 Reviewed-on: https://go-review.googlesource.com/c/go/+/587275 Reviewed-by: Roland Shoemaker Auto-Submit: Filippo Valsorda Reviewed-by: Dmitri Shuralyov LUCI-TryBot-Result: Go LUCI --- common.go | 1 - 1 file changed, 1 deletion(-) diff --git a/common.go b/common.go index 14a8dae..1b0f19d 100644 --- a/common.go +++ b/common.go @@ -93,7 +93,6 @@ const ( typeFinished uint8 = 20 typeCertificateStatus uint8 = 22 typeKeyUpdate uint8 = 24 - typeNextProtocol uint8 = 67 // Not IANA assigned typeMessageHash uint8 = 254 // synthetic message ) From 470b5f1f9d7c40bde03144a44632a4d4c6e06841 Mon Sep 17 00:00:00 2001 From: Filippo Valsorda Date: Wed, 22 May 2024 11:39:41 +0200 Subject: [PATCH 17/39] crypto/tls: disable 3-DES by default Fixes #66214 Change-Id: Iba8006a17fc7cd33c7485ab1a1ef8f56531c0ed1 Reviewed-on: https://go-review.googlesource.com/c/go/+/587295 LUCI-TryBot-Result: Go LUCI Reviewed-by: Roland Shoemaker Reviewed-by: Dmitri Shuralyov Auto-Submit: Filippo Valsorda --- cipher_suites.go | 33 +++++++++++++++++++-------------- common.go | 11 ++++------- handshake_client.go | 4 ++++ handshake_server.go | 4 ++++ tls_test.go | 13 ++++++++++--- 5 files changed, 41 insertions(+), 24 deletions(-) diff --git a/cipher_suites.go b/cipher_suites.go index 6f5bc37..622ad9b 100644 --- a/cipher_suites.go +++ b/cipher_suites.go @@ -17,7 +17,9 @@ import ( "fmt" "hash" "internal/cpu" + "internal/godebug" "runtime" + "slices" "golang.org/x/crypto/chacha20poly1305" ) @@ -334,6 +336,8 @@ var disabledCipherSuites = map[uint16]bool{ TLS_RSA_WITH_RC4_128_SHA: true, } +var tlsrsakex = godebug.New("tlsrsakex") + // rsaKexCiphers contains the ciphers which use RSA based key exchange, // which we also disable by default unless a GODEBUG is set. var rsaKexCiphers = map[uint16]bool{ @@ -346,21 +350,22 @@ var rsaKexCiphers = map[uint16]bool{ TLS_RSA_WITH_AES_256_GCM_SHA384: true, } -var defaultCipherSuites []uint16 -var defaultCipherSuitesWithRSAKex []uint16 +var tls3des = godebug.New("tls3des") -func init() { - defaultCipherSuites = make([]uint16, 0, len(cipherSuitesPreferenceOrder)) - defaultCipherSuitesWithRSAKex = make([]uint16, 0, len(cipherSuitesPreferenceOrder)) - for _, c := range cipherSuitesPreferenceOrder { - if disabledCipherSuites[c] { - continue - } - if !rsaKexCiphers[c] { - defaultCipherSuites = append(defaultCipherSuites, c) - } - defaultCipherSuitesWithRSAKex = append(defaultCipherSuitesWithRSAKex, c) - } +// tdesCiphers contains 3DES ciphers, +// which we also disable by default unless a GODEBUG is set. +var tdesCiphers = map[uint16]bool{ + TLS_ECDHE_RSA_WITH_3DES_EDE_CBC_SHA: true, + TLS_RSA_WITH_3DES_EDE_CBC_SHA: true, +} + +func defaultCipherSuites() []uint16 { + suites := slices.Clone(cipherSuitesPreferenceOrder) + return slices.DeleteFunc(suites, func(c uint16) bool { + return disabledCipherSuites[c] || + tlsrsakex.Value() != "1" && rsaKexCiphers[c] || + tls3des.Value() != "1" && tdesCiphers[c] + }) } // defaultCipherSuitesTLS13 is also the preference order, since there are no diff --git a/common.go b/common.go index 1b0f19d..dcefa2a 100644 --- a/common.go +++ b/common.go @@ -687,7 +687,9 @@ type Config struct { // If CipherSuites is nil, a safe default list is used. The default cipher // suites might change over time. In Go 1.22 RSA key exchange based cipher // suites were removed from the default list, but can be re-added with the - // GODEBUG setting tlsrsakex=1. + // GODEBUG setting tlsrsakex=1. In Go 1.23 3DES cipher suites were removed + // from the default list, but can be re-added with the GODEBUG setting + // tls3des=1. CipherSuites []uint16 // PreferServerCipherSuites is a legacy field and has no effect. @@ -1025,8 +1027,6 @@ func (c *Config) time() time.Time { return t() } -var tlsrsakex = godebug.New("tlsrsakex") - func (c *Config) cipherSuites() []uint16 { if needFIPS() { return fipsCipherSuites(c) @@ -1034,10 +1034,7 @@ func (c *Config) cipherSuites() []uint16 { if c.CipherSuites != nil { return c.CipherSuites } - if tlsrsakex.Value() == "1" { - return defaultCipherSuitesWithRSAKex - } - return defaultCipherSuites + return defaultCipherSuites() } var supportedVersions = []uint16{ diff --git a/handshake_client.go b/handshake_client.go index 1a17385..d80b232 100644 --- a/handshake_client.go +++ b/handshake_client.go @@ -551,6 +551,10 @@ func (hs *clientHandshakeState) pickCipherSuite() error { tlsrsakex.Value() // ensure godebug is initialized tlsrsakex.IncNonDefault() } + if hs.c.config.CipherSuites == nil && !needFIPS() && tdesCiphers[hs.suite.id] { + tls3des.Value() // ensure godebug is initialized + tls3des.IncNonDefault() + } hs.c.cipherSuite = hs.suite.id return nil diff --git a/handshake_server.go b/handshake_server.go index 09ca8a4..ac3d915 100644 --- a/handshake_server.go +++ b/handshake_server.go @@ -376,6 +376,10 @@ func (hs *serverHandshakeState) pickCipherSuite() error { tlsrsakex.Value() // ensure godebug is initialized tlsrsakex.IncNonDefault() } + if c.config.CipherSuites == nil && !needFIPS() && tdesCiphers[hs.suite.id] { + tls3des.Value() // ensure godebug is initialized + tls3des.IncNonDefault() + } for _, id := range hs.clientHello.cipherSuites { if id == TLS_FALLBACK_SCSV { diff --git a/tls_test.go b/tls_test.go index ce1c967..69b57de 100644 --- a/tls_test.go +++ b/tls_test.go @@ -1458,6 +1458,16 @@ func TestCipherSuites(t *testing.T) { t.Errorf("%#04x: suite TLS 1.0-1.2, but SupportedVersions is %v", c.id, cc.SupportedVersions) } + if cc.Insecure { + if slices.Contains(defaultCipherSuites(), c.id) { + t.Errorf("%#04x: insecure suite in default list", c.id) + } + } else { + if !slices.Contains(defaultCipherSuites(), c.id) { + t.Errorf("%#04x: secure suite not in default list", c.id) + } + } + if got := CipherSuiteName(c.id); got != cc.Name { t.Errorf("%#04x: unexpected CipherSuiteName: got %q, expected %q", c.id, got, cc.Name) } @@ -1491,9 +1501,6 @@ func TestCipherSuites(t *testing.T) { if len(cipherSuitesPreferenceOrderNoAES) != len(cipherSuitesPreferenceOrder) { t.Errorf("cipherSuitesPreferenceOrderNoAES is not the same size as cipherSuitesPreferenceOrder") } - if len(defaultCipherSuites) >= len(defaultCipherSuitesWithRSAKex) { - t.Errorf("defaultCipherSuitesWithRSAKex should be longer than defaultCipherSuites") - } // Check that disabled suites are marked insecure. for _, badSuites := range []map[uint16]bool{disabledCipherSuites, rsaKexCiphers} { From 72f81ff7ec1312db949fcf56a2a8d9b87368f62a Mon Sep 17 00:00:00 2001 From: Filippo Valsorda Date: Wed, 22 May 2024 12:51:03 +0200 Subject: [PATCH 18/39] crypto/tls: move defaults into defaults.go Fixes #65265 Updates #60790 Change-Id: Iaa5f475d614d3ed87f091c93a3f888b7eb3433f2 Reviewed-on: https://go-review.googlesource.com/c/go/+/587296 Auto-Submit: Filippo Valsorda Reviewed-by: Roland Shoemaker LUCI-TryBot-Result: Go LUCI Reviewed-by: Dmitri Shuralyov Reviewed-by: Derek Parker --- auth.go | 2 +- boring.go | 89 ++------------------------------------- boring_test.go | 6 +-- cipher_suites.go | 30 ------------- common.go | 77 +++++++++++++++++----------------- defaults.go | 107 +++++++++++++++++++++++++++++++++++++++++++++++ notboring.go | 11 ----- 7 files changed, 152 insertions(+), 170 deletions(-) create mode 100644 defaults.go diff --git a/auth.go b/auth.go index 7c5675c..5bb202c 100644 --- a/auth.go +++ b/auth.go @@ -242,7 +242,7 @@ func selectSignatureScheme(vers uint16, c *Certificate, peerAlgs []SignatureSche // Pick signature scheme in the peer's preference order, as our // preference order is not configurable. for _, preferredAlg := range peerAlgs { - if needFIPS() && !isSupportedSignatureAlgorithm(preferredAlg, fipsSupportedSignatureAlgorithms) { + if needFIPS() && !isSupportedSignatureAlgorithm(preferredAlg, defaultSupportedSignatureAlgorithmsFIPS) { continue } if isSupportedSignatureAlgorithm(preferredAlg, supportedAlgs) { diff --git a/boring.go b/boring.go index 1827f76..c44ae92 100644 --- a/boring.go +++ b/boring.go @@ -6,93 +6,10 @@ package tls -import ( - "crypto/internal/boring/fipstls" -) +import "crypto/internal/boring/fipstls" -// needFIPS returns fipstls.Required(); it avoids a new import in common.go. +// needFIPS returns fipstls.Required(), which is not available without the +// boringcrypto build tag. func needFIPS() bool { return fipstls.Required() } - -// fipsMinVersion replaces c.minVersion in FIPS-only mode. -func fipsMinVersion(c *Config) uint16 { - // FIPS requires TLS 1.2. - return VersionTLS12 -} - -// fipsMaxVersion replaces c.maxVersion in FIPS-only mode. -func fipsMaxVersion(c *Config) uint16 { - // FIPS requires TLS 1.2. - return VersionTLS12 -} - -// default defaultFIPSCurvePreferences is the FIPS-allowed curves, -// in preference order (most preferable first). -var defaultFIPSCurvePreferences = []CurveID{CurveP256, CurveP384, CurveP521} - -// fipsCurvePreferences replaces c.curvePreferences in FIPS-only mode. -func fipsCurvePreferences(c *Config) []CurveID { - if c == nil || len(c.CurvePreferences) == 0 { - return defaultFIPSCurvePreferences - } - var list []CurveID - for _, id := range c.CurvePreferences { - for _, allowed := range defaultFIPSCurvePreferences { - if id == allowed { - list = append(list, id) - break - } - } - } - return list -} - -// defaultCipherSuitesFIPS are the FIPS-allowed cipher suites. -var defaultCipherSuitesFIPS = []uint16{ - TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256, - TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384, - TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256, - TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384, - TLS_RSA_WITH_AES_128_GCM_SHA256, - TLS_RSA_WITH_AES_256_GCM_SHA384, -} - -// fipsCipherSuites replaces c.cipherSuites in FIPS-only mode. -func fipsCipherSuites(c *Config) []uint16 { - if c == nil || c.CipherSuites == nil { - return defaultCipherSuitesFIPS - } - list := make([]uint16, 0, len(defaultCipherSuitesFIPS)) - for _, id := range c.CipherSuites { - for _, allowed := range defaultCipherSuitesFIPS { - if id == allowed { - list = append(list, id) - break - } - } - } - return list -} - -// fipsSupportedSignatureAlgorithms currently are a subset of -// defaultSupportedSignatureAlgorithms without Ed25519 and SHA-1. -var fipsSupportedSignatureAlgorithms = []SignatureScheme{ - PSSWithSHA256, - PSSWithSHA384, - PSSWithSHA512, - PKCS1WithSHA256, - ECDSAWithP256AndSHA256, - PKCS1WithSHA384, - ECDSAWithP384AndSHA384, - PKCS1WithSHA512, - ECDSAWithP521AndSHA512, -} - -// supportedSignatureAlgorithms returns the supported signature algorithms. -func supportedSignatureAlgorithms() []SignatureScheme { - if !needFIPS() { - return defaultSupportedSignatureAlgorithms - } - return fipsSupportedSignatureAlgorithms -} diff --git a/boring_test.go b/boring_test.go index 4a658f0..be10b71 100644 --- a/boring_test.go +++ b/boring_test.go @@ -136,7 +136,7 @@ func TestBoringServerCipherSuites(t *testing.T) { random: make([]byte, 32), cipherSuites: []uint16{id}, compressionMethods: []uint8{compressionNone}, - supportedCurves: defaultCurvePreferences, + supportedCurves: defaultCurvePreferences(), supportedPoints: []uint8{pointFormatUncompressed}, } @@ -161,7 +161,7 @@ func TestBoringServerCurves(t *testing.T) { serverConfig.Certificates[0].PrivateKey = testECDSAPrivateKey serverConfig.BuildNameToCertificate() - for _, curveid := range defaultCurvePreferences { + for _, curveid := range defaultCurvePreferences() { t.Run(fmt.Sprintf("curve=%d", curveid), func(t *testing.T) { clientConfig := testConfig.Clone() clientConfig.CurvePreferences = []CurveID{curveid} @@ -274,7 +274,7 @@ func TestBoringClientHello(t *testing.T) { clientConfig.MinVersion = VersionSSL30 clientConfig.MaxVersion = VersionTLS13 clientConfig.CipherSuites = allCipherSuites() - clientConfig.CurvePreferences = defaultCurvePreferences + clientConfig.CurvePreferences = defaultCurvePreferences() go Client(c, clientConfig).Handshake() srv := Server(s, testConfig) diff --git a/cipher_suites.go b/cipher_suites.go index 622ad9b..83301f3 100644 --- a/cipher_suites.go +++ b/cipher_suites.go @@ -17,9 +17,7 @@ import ( "fmt" "hash" "internal/cpu" - "internal/godebug" "runtime" - "slices" "golang.org/x/crypto/chacha20poly1305" ) @@ -336,8 +334,6 @@ var disabledCipherSuites = map[uint16]bool{ TLS_RSA_WITH_RC4_128_SHA: true, } -var tlsrsakex = godebug.New("tlsrsakex") - // rsaKexCiphers contains the ciphers which use RSA based key exchange, // which we also disable by default unless a GODEBUG is set. var rsaKexCiphers = map[uint16]bool{ @@ -350,8 +346,6 @@ var rsaKexCiphers = map[uint16]bool{ TLS_RSA_WITH_AES_256_GCM_SHA384: true, } -var tls3des = godebug.New("tls3des") - // tdesCiphers contains 3DES ciphers, // which we also disable by default unless a GODEBUG is set. var tdesCiphers = map[uint16]bool{ @@ -359,30 +353,6 @@ var tdesCiphers = map[uint16]bool{ TLS_RSA_WITH_3DES_EDE_CBC_SHA: true, } -func defaultCipherSuites() []uint16 { - suites := slices.Clone(cipherSuitesPreferenceOrder) - return slices.DeleteFunc(suites, func(c uint16) bool { - return disabledCipherSuites[c] || - tlsrsakex.Value() != "1" && rsaKexCiphers[c] || - tls3des.Value() != "1" && tdesCiphers[c] - }) -} - -// defaultCipherSuitesTLS13 is also the preference order, since there are no -// disabled by default TLS 1.3 cipher suites. The same AES vs ChaCha20 logic as -// cipherSuitesPreferenceOrder applies. -var defaultCipherSuitesTLS13 = []uint16{ - TLS_AES_128_GCM_SHA256, - TLS_AES_256_GCM_SHA384, - TLS_CHACHA20_POLY1305_SHA256, -} - -var defaultCipherSuitesTLS13NoAES = []uint16{ - TLS_CHACHA20_POLY1305_SHA256, - TLS_AES_128_GCM_SHA256, - TLS_AES_256_GCM_SHA384, -} - var ( hasGCMAsmAMD64 = cpu.X86.HasAES && cpu.X86.HasPCLMULQDQ hasGCMAsmARM64 = cpu.ARM64.HasAES && cpu.ARM64.HasPMULL diff --git a/common.go b/common.go index dcefa2a..945b3dd 100644 --- a/common.go +++ b/common.go @@ -21,6 +21,7 @@ import ( "internal/godebug" "io" "net" + "slices" "strings" "sync" "time" @@ -200,25 +201,6 @@ const ( // hash function associated with the Ed25519 signature scheme. var directSigning crypto.Hash = 0 -// defaultSupportedSignatureAlgorithms contains the signature and hash algorithms that -// the code advertises as supported in a TLS 1.2+ ClientHello and in a TLS 1.2+ -// CertificateRequest. The two fields are merged to match with TLS 1.3. -// Note that in TLS 1.2, the ECDSA algorithms are not constrained to P-256, etc. -var defaultSupportedSignatureAlgorithms = []SignatureScheme{ - PSSWithSHA256, - ECDSAWithP256AndSHA256, - Ed25519, - PSSWithSHA384, - PSSWithSHA512, - PKCS1WithSHA256, - PKCS1WithSHA384, - PKCS1WithSHA512, - ECDSAWithP384AndSHA384, - ECDSAWithP521AndSHA512, - PKCS1WithSHA1, - ECDSAWithSHA1, -} - // helloRetryRequestRandom is set as the Random value of a ServerHello // to signal that the message is actually a HelloRetryRequest. var helloRetryRequestRandom = []byte{ // See RFC 8446, Section 4.1.3. @@ -1028,13 +1010,19 @@ func (c *Config) time() time.Time { } func (c *Config) cipherSuites() []uint16 { + if c.CipherSuites == nil { + if needFIPS() { + return defaultCipherSuitesFIPS + } + return defaultCipherSuites() + } if needFIPS() { - return fipsCipherSuites(c) + cipherSuites := slices.Clone(c.CipherSuites) + return slices.DeleteFunc(cipherSuites, func(id uint16) bool { + return !slices.Contains(defaultCipherSuitesFIPS, id) + }) } - if c.CipherSuites != nil { - return c.CipherSuites - } - return defaultCipherSuites() + return c.CipherSuites } var supportedVersions = []uint16{ @@ -1054,7 +1042,7 @@ var tls10server = godebug.New("tls10server") func (c *Config) supportedVersions(isClient bool) []uint16 { versions := make([]uint16, 0, len(supportedVersions)) for _, v := range supportedVersions { - if needFIPS() && (v < fipsMinVersion(c) || v > fipsMaxVersion(c)) { + if needFIPS() && !slices.Contains(defaultSupportedVersionsFIPS, v) { continue } if (c == nil || c.MinVersion == 0) && v < VersionTLS12 { @@ -1095,23 +1083,26 @@ func supportedVersionsFromMax(maxVersion uint16) []uint16 { return versions } -var tlskyber = godebug.New("tlskyber") - -var defaultCurvePreferences = []CurveID{x25519Kyber768Draft00, X25519, CurveP256, CurveP384, CurveP521} - -var defaultCurvePreferencesWithoutKyber = []CurveID{X25519, CurveP256, CurveP384, CurveP521} - func (c *Config) curvePreferences(version uint16) []CurveID { - if needFIPS() { - return fipsCurvePreferences(c) - } - if c == nil || len(c.CurvePreferences) == 0 { - if version < VersionTLS13 || tlskyber.Value() == "0" { - return defaultCurvePreferencesWithoutKyber + var curvePreferences []CurveID + if c != nil && len(c.CurvePreferences) != 0 { + curvePreferences = slices.Clone(c.CurvePreferences) + if needFIPS() { + return slices.DeleteFunc(curvePreferences, func(c CurveID) bool { + return !slices.Contains(defaultCurvePreferencesFIPS, c) + }) } - return defaultCurvePreferences + } else if needFIPS() { + curvePreferences = slices.Clone(defaultCurvePreferencesFIPS) + } else { + curvePreferences = defaultCurvePreferences() } - return c.CurvePreferences + if version < VersionTLS13 { + return slices.DeleteFunc(curvePreferences, func(c CurveID) bool { + return c == x25519Kyber768Draft00 + }) + } + return curvePreferences } func (c *Config) supportsCurve(version uint16, curve CurveID) bool { @@ -1562,6 +1553,14 @@ func unexpectedMessageError(wanted, got any) error { return fmt.Errorf("tls: received unexpected handshake message of type %T when waiting for %T", got, wanted) } +// supportedSignatureAlgorithms returns the supported signature algorithms. +func supportedSignatureAlgorithms() []SignatureScheme { + if !needFIPS() { + return defaultSupportedSignatureAlgorithms + } + return defaultSupportedSignatureAlgorithmsFIPS +} + func isSupportedSignatureAlgorithm(sigAlg SignatureScheme, supportedSignatureAlgorithms []SignatureScheme) bool { for _, s := range supportedSignatureAlgorithms { if s == sigAlg { diff --git a/defaults.go b/defaults.go new file mode 100644 index 0000000..df64def --- /dev/null +++ b/defaults.go @@ -0,0 +1,107 @@ +// Copyright 2024 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +package tls + +import ( + "internal/godebug" + "slices" +) + +// Defaults are collected in this file to allow distributions to more easily patch +// them to apply local policies. + +var tlskyber = godebug.New("tlskyber") + +func defaultCurvePreferences() []CurveID { + if tlskyber.Value() == "0" { + return []CurveID{X25519, CurveP256, CurveP384, CurveP521} + } + // For now, x25519Kyber768Draft00 must always be followed by X25519. + return []CurveID{x25519Kyber768Draft00, X25519, CurveP256, CurveP384, CurveP521} +} + +// defaultSupportedSignatureAlgorithms contains the signature and hash algorithms that +// the code advertises as supported in a TLS 1.2+ ClientHello and in a TLS 1.2+ +// CertificateRequest. The two fields are merged to match with TLS 1.3. +// Note that in TLS 1.2, the ECDSA algorithms are not constrained to P-256, etc. +var defaultSupportedSignatureAlgorithms = []SignatureScheme{ + PSSWithSHA256, + ECDSAWithP256AndSHA256, + Ed25519, + PSSWithSHA384, + PSSWithSHA512, + PKCS1WithSHA256, + PKCS1WithSHA384, + PKCS1WithSHA512, + ECDSAWithP384AndSHA384, + ECDSAWithP521AndSHA512, + PKCS1WithSHA1, + ECDSAWithSHA1, +} + +var tlsrsakex = godebug.New("tlsrsakex") +var tls3des = godebug.New("tls3des") + +func defaultCipherSuites() []uint16 { + suites := slices.Clone(cipherSuitesPreferenceOrder) + return slices.DeleteFunc(suites, func(c uint16) bool { + return disabledCipherSuites[c] || + tlsrsakex.Value() != "1" && rsaKexCiphers[c] || + tls3des.Value() != "1" && tdesCiphers[c] + }) +} + +// defaultCipherSuitesTLS13 is also the preference order, since there are no +// disabled by default TLS 1.3 cipher suites. The same AES vs ChaCha20 logic as +// cipherSuitesPreferenceOrder applies. +var defaultCipherSuitesTLS13 = []uint16{ + TLS_AES_128_GCM_SHA256, + TLS_AES_256_GCM_SHA384, + TLS_CHACHA20_POLY1305_SHA256, +} + +var defaultCipherSuitesTLS13NoAES = []uint16{ + TLS_CHACHA20_POLY1305_SHA256, + TLS_AES_128_GCM_SHA256, + TLS_AES_256_GCM_SHA384, +} + +var defaultSupportedVersionsFIPS = []uint16{ + VersionTLS12, +} + +// defaultCurvePreferencesFIPS are the FIPS-allowed curves, +// in preference order (most preferable first). +var defaultCurvePreferencesFIPS = []CurveID{CurveP256, CurveP384, CurveP521} + +// defaultSupportedSignatureAlgorithmsFIPS currently are a subset of +// defaultSupportedSignatureAlgorithms without Ed25519 and SHA-1. +var defaultSupportedSignatureAlgorithmsFIPS = []SignatureScheme{ + PSSWithSHA256, + PSSWithSHA384, + PSSWithSHA512, + PKCS1WithSHA256, + ECDSAWithP256AndSHA256, + PKCS1WithSHA384, + ECDSAWithP384AndSHA384, + PKCS1WithSHA512, + ECDSAWithP521AndSHA512, +} + +// defaultCipherSuitesFIPS are the FIPS-allowed cipher suites. +var defaultCipherSuitesFIPS = []uint16{ + TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256, + TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384, + TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256, + TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384, + TLS_RSA_WITH_AES_128_GCM_SHA256, + TLS_RSA_WITH_AES_256_GCM_SHA384, +} + +// defaultCipherSuitesTLS13FIPS are the FIPS-allowed cipher suites for TLS 1.3. +var defaultCipherSuitesTLS13FIPS = []uint16{ + TLS_AES_128_GCM_SHA256, + TLS_AES_256_GCM_SHA384, +} diff --git a/notboring.go b/notboring.go index 7d85b39..bdbc32e 100644 --- a/notboring.go +++ b/notboring.go @@ -7,14 +7,3 @@ package tls func needFIPS() bool { return false } - -func supportedSignatureAlgorithms() []SignatureScheme { - return defaultSupportedSignatureAlgorithms -} - -func fipsMinVersion(c *Config) uint16 { panic("fipsMinVersion") } -func fipsMaxVersion(c *Config) uint16 { panic("fipsMaxVersion") } -func fipsCurvePreferences(c *Config) []CurveID { panic("fipsCurvePreferences") } -func fipsCipherSuites(c *Config) []uint16 { panic("fipsCipherSuites") } - -var fipsSupportedSignatureAlgorithms []SignatureScheme From 55782064790a6a9f6ca17c042c7727a69dc1ab4c Mon Sep 17 00:00:00 2001 From: Roland Shoemaker Date: Tue, 14 May 2024 11:22:16 -0700 Subject: [PATCH 19/39] crypto/tls: reorder client_hello extensions This sets us up for ECH, which need compressible extensions to be contiguous. Put them at the end to make things easier for everyone. Change-Id: I2a51f76d5fcd1b6d82325f5a4a8cde6d75f1be0c Reviewed-on: https://go-review.googlesource.com/c/go/+/585437 Reviewed-by: Filippo Valsorda Auto-Submit: Roland Shoemaker LUCI-TryBot-Result: Go LUCI Reviewed-by: Dmitri Shuralyov --- handshake_messages.go | 94 +-- testdata/Client-TLSv10-ClientCert-ECDSA-ECDSA | 90 +-- testdata/Client-TLSv10-ClientCert-ECDSA-RSA | 92 +-- testdata/Client-TLSv10-ClientCert-RSA-ECDSA | 96 +-- testdata/Client-TLSv10-ClientCert-RSA-RSA | 90 +-- testdata/Client-TLSv10-ECDHE-ECDSA-AES | 76 +-- testdata/Client-TLSv10-ECDHE-RSA-AES | 72 +-- testdata/Client-TLSv10-ExportKeyingMaterial | 72 +-- testdata/Client-TLSv10-RSA-RC4 | 40 +- testdata/Client-TLSv11-ECDHE-ECDSA-AES | 72 +-- testdata/Client-TLSv11-ECDHE-RSA-AES | 72 +-- testdata/Client-TLSv11-RSA-RC4 | 40 +- testdata/Client-TLSv12-AES128-GCM-SHA256 | 44 +- testdata/Client-TLSv12-AES128-SHA256 | 58 +- testdata/Client-TLSv12-AES256-GCM-SHA384 | 44 +- testdata/Client-TLSv12-ALPN | 64 +- testdata/Client-TLSv12-ClientCert-ECDSA-ECDSA | 106 ++-- testdata/Client-TLSv12-ClientCert-ECDSA-RSA | 88 +-- testdata/Client-TLSv12-ClientCert-Ed25519 | 74 +-- ...nt-TLSv12-ClientCert-RSA-AES256-GCM-SHA384 | 86 +-- testdata/Client-TLSv12-ClientCert-RSA-ECDSA | 102 ++-- testdata/Client-TLSv12-ClientCert-RSA-RSA | 86 +-- .../Client-TLSv12-ClientCert-RSA-RSAPKCS1v15 | 86 +-- testdata/Client-TLSv12-ClientCert-RSA-RSAPSS | 84 +-- testdata/Client-TLSv12-ECDHE-ECDSA-AES | 76 +-- testdata/Client-TLSv12-ECDHE-ECDSA-AES-GCM | 70 +-- .../Client-TLSv12-ECDHE-ECDSA-AES128-SHA256 | 84 +-- ...lient-TLSv12-ECDHE-ECDSA-AES256-GCM-SHA384 | 70 +-- ...lient-TLSv12-ECDHE-ECDSA-CHACHA20-POLY1305 | 66 +-- testdata/Client-TLSv12-ECDHE-RSA-AES | 74 +-- .../Client-TLSv12-ECDHE-RSA-AES128-SHA256 | 82 +-- .../Client-TLSv12-ECDHE-RSA-CHACHA20-POLY1305 | 66 +-- testdata/Client-TLSv12-Ed25519 | 54 +- testdata/Client-TLSv12-ExportKeyingMaterial | 64 +- testdata/Client-TLSv12-P256-ECDHE | 72 +-- testdata/Client-TLSv12-RSA-RC4 | 40 +- testdata/Client-TLSv12-RenegotiateOnce | 362 ++++++------ testdata/Client-TLSv12-RenegotiateTwice | 554 +++++++++--------- .../Client-TLSv12-RenegotiateTwiceRejected | 368 ++++++------ testdata/Client-TLSv12-RenegotiationRejected | 70 +-- testdata/Client-TLSv12-SCT | 62 +- testdata/Client-TLSv12-X25519-ECDHE | 68 +-- testdata/Client-TLSv13-AES128-SHA256 | 148 ++--- testdata/Client-TLSv13-AES256-SHA384 | 152 ++--- testdata/Client-TLSv13-ALPN | 152 ++--- testdata/Client-TLSv13-CHACHA20-SHA256 | 148 ++--- testdata/Client-TLSv13-ClientCert-ECDSA-RSA | 246 ++++---- testdata/Client-TLSv13-ClientCert-Ed25519 | 212 +++---- testdata/Client-TLSv13-ClientCert-RSA-ECDSA | 236 ++++---- testdata/Client-TLSv13-ClientCert-RSA-RSAPSS | 254 ++++---- testdata/Client-TLSv13-ECDSA | 140 ++--- testdata/Client-TLSv13-Ed25519 | 104 ++-- testdata/Client-TLSv13-ExportKeyingMaterial | 148 ++--- testdata/Client-TLSv13-HelloRetryRequest | 158 ++--- testdata/Client-TLSv13-KeyUpdate | 164 +++--- testdata/Client-TLSv13-P256-ECDHE | 150 ++--- testdata/Client-TLSv13-X25519-ECDHE | 148 ++--- 57 files changed, 3345 insertions(+), 3345 deletions(-) diff --git a/handshake_messages.go b/handshake_messages.go index b1920db..86ec493 100644 --- a/handshake_messages.go +++ b/handshake_messages.go @@ -111,6 +111,53 @@ func (m *clientHelloMsg) marshal() ([]byte, error) { }) }) } + if len(m.supportedPoints) > 0 { + // RFC 4492, Section 5.1.2 + exts.AddUint16(extensionSupportedPoints) + exts.AddUint16LengthPrefixed(func(exts *cryptobyte.Builder) { + exts.AddUint8LengthPrefixed(func(exts *cryptobyte.Builder) { + exts.AddBytes(m.supportedPoints) + }) + }) + } + if m.ticketSupported { + // RFC 5077, Section 3.2 + exts.AddUint16(extensionSessionTicket) + exts.AddUint16LengthPrefixed(func(exts *cryptobyte.Builder) { + exts.AddBytes(m.sessionTicket) + }) + } + if m.secureRenegotiationSupported { + // RFC 5746, Section 3.2 + exts.AddUint16(extensionRenegotiationInfo) + exts.AddUint16LengthPrefixed(func(exts *cryptobyte.Builder) { + exts.AddUint8LengthPrefixed(func(exts *cryptobyte.Builder) { + exts.AddBytes(m.secureRenegotiation) + }) + }) + } + if m.extendedMasterSecret { + // RFC 7627 + exts.AddUint16(extensionExtendedMasterSecret) + exts.AddUint16(0) // empty extension_data + } + if m.scts { + // RFC 6962, Section 3.3.1 + exts.AddUint16(extensionSCT) + exts.AddUint16(0) // empty extension_data + } + if m.earlyData { + // RFC 8446, Section 4.2.10 + exts.AddUint16(extensionEarlyData) + exts.AddUint16(0) // empty extension_data + } + if m.quicTransportParameters != nil { // marshal zero-length parameters when present + // RFC 9001, Section 8.2 + exts.AddUint16(extensionQUICTransportParameters) + exts.AddUint16LengthPrefixed(func(exts *cryptobyte.Builder) { + exts.AddBytes(m.quicTransportParameters) + }) + } if m.ocspStapling { // RFC 4366, Section 3.6 exts.AddUint16(extensionStatusRequest) @@ -131,22 +178,6 @@ func (m *clientHelloMsg) marshal() ([]byte, error) { }) }) } - if len(m.supportedPoints) > 0 { - // RFC 4492, Section 5.1.2 - exts.AddUint16(extensionSupportedPoints) - exts.AddUint16LengthPrefixed(func(exts *cryptobyte.Builder) { - exts.AddUint8LengthPrefixed(func(exts *cryptobyte.Builder) { - exts.AddBytes(m.supportedPoints) - }) - }) - } - if m.ticketSupported { - // RFC 5077, Section 3.2 - exts.AddUint16(extensionSessionTicket) - exts.AddUint16LengthPrefixed(func(exts *cryptobyte.Builder) { - exts.AddBytes(m.sessionTicket) - }) - } if len(m.supportedSignatureAlgorithms) > 0 { // RFC 5246, Section 7.4.1.4.1 exts.AddUint16(extensionSignatureAlgorithms) @@ -169,20 +200,6 @@ func (m *clientHelloMsg) marshal() ([]byte, error) { }) }) } - if m.secureRenegotiationSupported { - // RFC 5746, Section 3.2 - exts.AddUint16(extensionRenegotiationInfo) - exts.AddUint16LengthPrefixed(func(exts *cryptobyte.Builder) { - exts.AddUint8LengthPrefixed(func(exts *cryptobyte.Builder) { - exts.AddBytes(m.secureRenegotiation) - }) - }) - } - if m.extendedMasterSecret { - // RFC 7627 - exts.AddUint16(extensionExtendedMasterSecret) - exts.AddUint16(0) // empty extension_data - } if len(m.alpnProtocols) > 0 { // RFC 7301, Section 3.1 exts.AddUint16(extensionALPN) @@ -196,11 +213,6 @@ func (m *clientHelloMsg) marshal() ([]byte, error) { }) }) } - if m.scts { - // RFC 6962, Section 3.3.1 - exts.AddUint16(extensionSCT) - exts.AddUint16(0) // empty extension_data - } if len(m.supportedVersions) > 0 { // RFC 8446, Section 4.2.1 exts.AddUint16(extensionSupportedVersions) @@ -235,11 +247,6 @@ func (m *clientHelloMsg) marshal() ([]byte, error) { }) }) } - if m.earlyData { - // RFC 8446, Section 4.2.10 - exts.AddUint16(extensionEarlyData) - exts.AddUint16(0) // empty extension_data - } if len(m.pskModes) > 0 { // RFC 8446, Section 4.2.9 exts.AddUint16(extensionPSKModes) @@ -249,13 +256,6 @@ func (m *clientHelloMsg) marshal() ([]byte, error) { }) }) } - if m.quicTransportParameters != nil { // marshal zero-length parameters when present - // RFC 9001, Section 8.2 - exts.AddUint16(extensionQUICTransportParameters) - exts.AddUint16LengthPrefixed(func(exts *cryptobyte.Builder) { - exts.AddBytes(m.quicTransportParameters) - }) - } if len(m.pskIdentities) > 0 { // pre_shared_key must be the last extension // RFC 8446, Section 4.2.11 exts.AddUint16(extensionPreSharedKey) diff --git a/testdata/Client-TLSv10-ClientCert-ECDSA-ECDSA b/testdata/Client-TLSv10-ClientCert-ECDSA-ECDSA index e018e87..a35aa57 100644 --- a/testdata/Client-TLSv10-ClientCert-ECDSA-ECDSA +++ b/testdata/Client-TLSv10-ClientCert-ECDSA-ECDSA @@ -7,21 +7,21 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 7f 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 0a 00 08 00 1d 00 17 00 18 00 19 00 0b 00 02 01 |................| -000000a0 00 00 0d 00 1a 00 18 08 04 04 03 08 07 08 05 08 |................| -000000b0 06 04 01 05 01 06 01 05 03 06 03 02 01 02 03 ff |................| -000000c0 01 00 01 00 00 17 00 00 00 12 00 00 00 2b 00 09 |.............+..| +00000080 01 00 00 7f 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 19 00 0d |................| +000000b0 00 1a 00 18 08 04 04 03 08 07 08 05 08 06 04 01 |................| +000000c0 05 01 06 01 05 03 06 03 02 01 02 03 00 2b 00 09 |.............+..| 000000d0 08 03 04 03 03 03 02 03 01 00 33 00 26 00 24 00 |..........3.&.$.| 000000e0 1d 00 20 2f e5 7d a3 47 cd 62 43 15 28 da ac 5f |.. /.}.G.bC.(.._| 000000f0 bb 29 07 30 ff f6 84 af c4 cf c2 ed 90 99 5f 58 |.).0.........._X| 00000100 cb 3b 74 |.;t| >>> Flow 2 (server to client) -00000000 16 03 01 00 5d 02 00 00 59 03 01 8d 16 c0 c7 69 |....]...Y......i| -00000010 4a 19 df eb e0 a2 f1 43 43 d6 4a ac 8c cd ee 58 |J......CC.J....X| -00000020 2e f9 f2 7d d2 61 df 54 0c e8 4e 20 2e 1c 65 31 |...}.a.T..N ..e1| -00000030 60 6d 7f f9 10 9b fd d1 31 fa 0c 45 01 ca 06 e3 |`m......1..E....| -00000040 30 9a ab b4 b7 96 b3 99 de 8c 10 84 c0 09 00 00 |0...............| +00000000 16 03 01 00 5d 02 00 00 59 03 01 60 8a bf 2b 6f |....]...Y..`..+o| +00000010 c1 f0 f3 7b d4 78 2c d9 15 3f 33 6a 4b 96 aa 83 |...{.x,..?3jK...| +00000020 54 ae 66 8f 0f e7 b1 68 31 00 39 20 d8 4d f2 2c |T.f....h1.9 .M.,| +00000030 8b 85 98 d6 af e0 07 98 d5 cb 89 72 fb 8d c0 73 |...........r...s| +00000040 cc 68 cf 58 21 4a 8a fc c3 8e 90 0a c0 09 00 00 |.h.X!J..........| 00000050 11 ff 01 00 01 00 00 0b 00 04 03 00 01 02 00 17 |................| 00000060 00 00 16 03 01 02 0e 0b 00 02 0a 00 02 07 00 02 |................| 00000070 04 30 82 02 00 30 82 01 62 02 09 00 b8 bf 2d 47 |.0...0..b.....-G| @@ -57,17 +57,17 @@ 00000250 c9 86 2e dd d7 11 69 7f 85 7c 56 de fb 31 78 2b |......i..|V..1x+| 00000260 e4 c7 78 0d ae cb be 9e 4e 36 24 31 7b 6a 0f 39 |..x.....N6$1{j.9| 00000270 95 12 07 8f 2a 16 03 01 00 b5 0c 00 00 b1 03 00 |....*...........| -00000280 1d 20 2a 39 4c 47 2f 16 34 c1 2b 55 8b 1f 26 bb |. *9LG/.4.+U..&.| -00000290 f7 27 e1 e1 6c 62 e3 76 16 ed ff 23 bf 07 09 3c |.'..lb.v...#...<| -000002a0 24 1c 00 8b 30 81 88 02 42 01 34 ea 39 ef 28 c1 |$...0...B.4.9.(.| -000002b0 f9 00 fc a9 37 0e a8 ce 4e 17 0e 8d c3 3d 27 9b |....7...N....='.| -000002c0 87 ce b2 d1 31 e3 82 9b 7b e6 40 19 c9 da ba 7f |....1...{.@.....| -000002d0 03 f9 57 01 c9 f0 28 66 64 1a f6 f7 6a 67 09 b4 |..W...(fd...jg..| -000002e0 b9 c7 ef 1f 37 fd 7c 04 ba 4e ef 02 42 00 e1 15 |....7.|..N..B...| -000002f0 c9 22 ae 13 8d bc 24 26 ce 62 09 9e c4 95 80 65 |."....$&.b.....e| -00000300 b3 dc a4 df 98 c8 cd 95 8c 55 c7 af 27 b1 31 2c |.........U..'.1,| -00000310 df 62 72 47 b4 e8 df 76 43 16 60 7f 42 60 b0 eb |.brG...vC.`.B`..| -00000320 b8 f7 75 75 ef d6 7e aa d9 c5 9c 9d f0 0d d8 16 |..uu..~.........| +00000280 1d 20 68 5a 6f c6 20 26 b5 5c 47 c6 5e fb 23 c4 |. hZo. &.\G.^.#.| +00000290 bc 9c 3f 3a 9b ed d6 8e a3 c8 66 7d 9b cb d0 30 |..?:......f}...0| +000002a0 f9 60 00 8b 30 81 88 02 42 01 b2 fb f8 5f d0 14 |.`..0...B...._..| +000002b0 9d 3c 55 0f 16 50 6f d5 0c 4c 3e 73 2e a9 23 5f |.s..#_| +000002c0 e8 9c 02 5d 4c 6d b0 c1 9e 0d ac 59 36 6c d5 c2 |...]Lm.....Y6l..| +000002d0 4c 94 94 94 6f a4 df 26 1a 54 f5 74 b8 49 75 49 |L...o..&.T.t.IuI| +000002e0 9c aa cd 91 24 f3 52 88 6a 1e 80 02 42 01 81 a2 |....$.R.j...B...| +000002f0 76 e2 e8 b0 2a 8e 4e ed 6d be 2f e3 ca 4c ff f2 |v...*.N.m./..L..| +00000300 d3 14 c0 b5 f8 c5 53 04 97 de 14 b2 8e af 77 86 |......S.......w.| +00000310 de bf 4a 59 cf 7b 8a 73 d3 95 c3 28 ca 25 63 8e |..JY.{.s...(.%c.| +00000320 9e 02 7f 8a 04 bb 69 1e 41 31 76 2b 5a 54 ed 16 |......i.A1v+ZT..| 00000330 03 01 00 0a 0d 00 00 06 03 01 02 40 00 00 16 03 |...........@....| 00000340 01 00 04 0e 00 00 00 |.......| >>> Flow 3 (client to server) @@ -107,29 +107,29 @@ 00000210 03 01 00 25 10 00 00 21 20 2f e5 7d a3 47 cd 62 |...%...! /.}.G.b| 00000220 43 15 28 da ac 5f bb 29 07 30 ff f6 84 af c4 cf |C.(.._.).0......| 00000230 c2 ed 90 99 5f 58 cb 3b 74 16 03 01 00 91 0f 00 |...._X.;t.......| -00000240 00 8d 00 8b 30 81 88 02 42 01 9a ce de b0 79 2f |....0...B.....y/| -00000250 8b f3 6a ab 71 75 38 58 6a 85 d5 eb 60 ee de d0 |..j.qu8Xj...`...| -00000260 c8 61 46 fc 41 2a d7 dd b5 db cd d8 74 4e a2 62 |.aF.A*......tN.b| -00000270 c8 a5 1c f6 62 7a 04 ea 0b 70 39 cd 68 75 d2 b6 |....bz...p9.hu..| -00000280 cc f9 71 ee f2 cc 9a a2 12 78 bc 02 42 01 4d 03 |..q......x..B.M.| -00000290 1a 75 bb 13 64 ab 08 c5 fb f3 ff 18 74 c5 25 dd |.u..d.......t.%.| -000002a0 27 99 5b ad 76 7a a7 e2 4d a7 1d d7 ba 6e e4 e7 |'.[.vz..M....n..| -000002b0 32 00 70 4a 35 6c c4 bb 03 5b 83 d5 e5 fc 53 e4 |2.pJ5l...[....S.| -000002c0 7e 1b f3 e7 18 79 b3 d4 76 ac 0f 74 6e 8f f7 14 |~....y..v..tn...| -000002d0 03 01 00 01 01 16 03 01 00 30 1a 3f 4b ba 4c e4 |.........0.?K.L.| -000002e0 6d 21 25 4d 90 2b 94 01 2b 82 f6 0a 0f a9 f9 95 |m!%M.+..+.......| -000002f0 03 1f 13 ee cf 27 d2 84 8a 59 cd ca 8d a8 c1 07 |.....'...Y......| -00000300 3f f6 c3 2b d5 91 21 2a 84 23 |?..+..!*.#| +00000240 00 8d 00 8b 30 81 88 02 42 01 57 eb e6 90 3c fe |....0...B.W...<.| +00000250 10 8d e9 7d 50 a5 d3 83 43 64 e7 d0 cb 65 ef b9 |...}P...Cd...e..| +00000260 56 59 b9 52 09 e8 52 d7 d7 4d a7 57 09 dd 1f 83 |VY.R..R..M.W....| +00000270 22 0e 4c 4e 8b 50 0d 68 72 26 9e 2a 8b 6d cb 88 |".LN.P.hr&.*.m..| +00000280 c8 f4 0d 7d 85 80 e2 ec 7f f1 be 02 42 01 68 5d |...}........B.h]| +00000290 f8 91 45 82 61 7f 57 e2 2e b2 54 7d f3 11 11 44 |..E.a.W...T}...D| +000002a0 2f ee 48 91 17 5c 04 3d b8 0e eb ed 66 33 b1 62 |/.H..\.=....f3.b| +000002b0 61 a1 03 e8 77 cf 44 4b 93 fc 4f 12 24 2f d1 67 |a...w.DK..O.$/.g| +000002c0 c8 4b 07 e3 cb a8 7d 5d 82 d4 a2 ec d7 0b f8 14 |.K....}]........| +000002d0 03 01 00 01 01 16 03 01 00 30 28 45 dc 18 db 52 |.........0(E...R| +000002e0 a7 b5 1e 68 7a 06 03 8a 23 87 07 ea 79 38 29 ec |...hz...#...y8).| +000002f0 1b b7 b9 cb 1b 04 ac ba 1d b2 d5 8e 71 e0 27 30 |............q.'0| +00000300 02 d1 c9 4d 35 69 38 71 c9 c7 |...M5i8q..| >>> Flow 4 (server to client) -00000000 14 03 01 00 01 01 16 03 01 00 30 ac 6a 3b cf 6b |..........0.j;.k| -00000010 fc d7 25 1d ee d1 c0 61 65 73 be df 21 65 07 b8 |..%....aes..!e..| -00000020 9d 88 13 b9 b2 23 9c 90 a5 b4 71 31 75 b9 2e 97 |.....#....q1u...| -00000030 73 a1 c0 85 cc 6c f5 ac 49 2e 5f |s....l..I._| +00000000 14 03 01 00 01 01 16 03 01 00 30 3d a8 df 2e 80 |..........0=....| +00000010 26 22 66 32 fb 6e bc 9e f5 d6 6a 5e 0a 18 34 92 |&"f2.n....j^..4.| +00000020 f9 42 40 e4 9c b1 7a 28 d2 52 e9 b8 13 ce 89 01 |.B@...z(.R......| +00000030 23 44 ab 2e 75 3e c2 96 f5 59 61 |#D..u>...Ya| >>> Flow 5 (client to server) -00000000 17 03 01 00 20 46 71 8d 32 ba c1 05 5c 59 bc 82 |.... Fq.2...\Y..| -00000010 e1 bc 6f eb de 23 26 8d 9c b2 b4 e8 c8 69 f3 46 |..o..#&......i.F| -00000020 0b 07 61 69 ae 17 03 01 00 20 e5 a5 ea 4c 59 7d |..ai..... ...LY}| -00000030 74 cd b8 0a 66 b6 ec 95 b0 8a 86 3a 9c e3 f5 11 |t...f......:....| -00000040 5b 05 62 9a ce 2e 87 8e 41 f4 15 03 01 00 20 be |[.b.....A..... .| -00000050 0a 29 47 93 e8 ef ad d4 5d f9 e1 a4 46 1a 51 98 |.)G.....]...F.Q.| -00000060 f0 8c be 3b fc cc a0 ed 7c 18 ac bf 94 35 93 |...;....|....5.| +00000000 17 03 01 00 20 64 ac d2 1b 98 4d 4e ec 22 25 35 |.... d....MN."%5| +00000010 7c 7c 79 15 a8 54 0d 93 1a b3 3e ff 68 27 d0 d5 |||y..T....>.h'..| +00000020 82 24 7b dc e7 17 03 01 00 20 98 da 6d 26 de b8 |.${...... ..m&..| +00000030 4b d0 ee 2c 18 52 05 86 59 b0 b6 e7 42 74 54 ea |K..,.R..Y...BtT.| +00000040 e6 96 de ec 82 dc 1f 3a 6c 5c 15 03 01 00 20 cc |.......:l\.... .| +00000050 11 da e4 75 e5 0c 06 84 e5 89 3e a4 ef 3c 28 10 |...u......>..<(.| +00000060 68 0a 6f d4 6e ae 14 a6 ca 7c ba 98 c4 28 7e |h.o.n....|...(~| diff --git a/testdata/Client-TLSv10-ClientCert-ECDSA-RSA b/testdata/Client-TLSv10-ClientCert-ECDSA-RSA index 364d33d..687eba4 100644 --- a/testdata/Client-TLSv10-ClientCert-ECDSA-RSA +++ b/testdata/Client-TLSv10-ClientCert-ECDSA-RSA @@ -7,21 +7,21 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 7f 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 0a 00 08 00 1d 00 17 00 18 00 19 00 0b 00 02 01 |................| -000000a0 00 00 0d 00 1a 00 18 08 04 04 03 08 07 08 05 08 |................| -000000b0 06 04 01 05 01 06 01 05 03 06 03 02 01 02 03 ff |................| -000000c0 01 00 01 00 00 17 00 00 00 12 00 00 00 2b 00 09 |.............+..| +00000080 01 00 00 7f 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 19 00 0d |................| +000000b0 00 1a 00 18 08 04 04 03 08 07 08 05 08 06 04 01 |................| +000000c0 05 01 06 01 05 03 06 03 02 01 02 03 00 2b 00 09 |.............+..| 000000d0 08 03 04 03 03 03 02 03 01 00 33 00 26 00 24 00 |..........3.&.$.| 000000e0 1d 00 20 2f e5 7d a3 47 cd 62 43 15 28 da ac 5f |.. /.}.G.bC.(.._| 000000f0 bb 29 07 30 ff f6 84 af c4 cf c2 ed 90 99 5f 58 |.).0.........._X| 00000100 cb 3b 74 |.;t| >>> Flow 2 (server to client) -00000000 16 03 01 00 5d 02 00 00 59 03 01 a1 07 34 d5 08 |....]...Y....4..| -00000010 09 17 79 08 6e 26 2b b3 2f e5 35 08 54 b4 5b 0e |..y.n&+./.5.T.[.| -00000020 c8 58 57 2b 5a 75 8d e8 d2 9e 35 20 ae bf 94 16 |.XW+Zu....5 ....| -00000030 e5 a9 f6 05 18 1f 7f a4 1e e9 cd 4a c0 7d a6 4d |...........J.}.M| -00000040 75 4f 06 de e0 6c 79 b3 39 5c a7 ed c0 13 00 00 |uO...ly.9\......| +00000000 16 03 01 00 5d 02 00 00 59 03 01 48 c6 a1 aa 01 |....]...Y..H....| +00000010 b8 4b a1 f5 6d 71 28 f7 fd 76 9d 12 50 d3 56 e2 |.K..mq(..v..P.V.| +00000020 ca 77 d4 82 07 65 e2 c5 12 40 35 20 e3 ee 0a df |.w...e...@5 ....| +00000030 1f 4a d9 b3 a6 6f a0 24 49 8d ab d9 d8 3c 24 36 |.J...o.$I....<$6| +00000040 35 ba 64 8b 7d ec 29 91 d9 26 5e 61 c0 13 00 00 |5.d.}.)..&^a....| 00000050 11 ff 01 00 01 00 00 0b 00 04 03 00 01 02 00 17 |................| 00000060 00 00 16 03 01 02 59 0b 00 02 55 00 02 52 00 02 |......Y...U..R..| 00000070 4f 30 82 02 4b 30 82 01 b4 a0 03 02 01 02 02 09 |O0..K0..........| @@ -61,17 +61,17 @@ 00000290 73 bb b3 43 77 8d 0c 1c f1 0f a1 d8 40 83 61 c9 |s..Cw.......@.a.| 000002a0 4c 72 2b 9d ae db 46 06 06 4d f4 c1 b3 3e c0 d1 |Lr+...F..M...>..| 000002b0 bd 42 d4 db fe 3d 13 60 84 5c 21 d3 3b e9 fa e7 |.B...=.`.\!.;...| -000002c0 16 03 01 00 aa 0c 00 00 a6 03 00 1d 20 6d 79 f8 |............ my.| -000002d0 b3 f9 f8 39 10 ea 9a f0 d7 40 a7 94 b4 5b 87 fc |...9.....@...[..| -000002e0 63 e1 7f 82 f8 cd e9 02 f7 0c 83 e0 48 00 80 cc |c...........H...| -000002f0 23 b7 af c6 3b 6a ed cd 07 be 81 cd 81 f9 85 f1 |#...;j..........| -00000300 a2 32 82 3b 1c 02 3e 02 20 da 71 e0 3a cc 4b 49 |.2.;..>. .q.:.KI| -00000310 09 36 af 1e 9e b5 14 6e 4c d1 4d df 87 38 92 52 |.6.....nL.M..8.R| -00000320 47 0c e7 e8 2b 2e 65 38 e3 c4 d7 24 db bb fb 2c |G...+.e8...$...,| -00000330 04 2c 9e e5 a7 9d 4b 03 b8 cb 71 c6 62 e0 42 f7 |.,....K...q.b.B.| -00000340 d7 1e 62 7e 21 e0 4d 37 e2 67 46 fa 82 df 49 62 |..b~!.M7.gF...Ib| -00000350 33 fe e1 44 fd 62 31 46 b7 66 27 ce 85 99 00 b2 |3..D.b1F.f'.....| -00000360 2c 94 1b c1 66 7b 95 a9 2c d2 33 5c 57 50 f1 16 |,...f{..,.3\WP..| +000002c0 16 03 01 00 aa 0c 00 00 a6 03 00 1d 20 55 51 65 |............ UQe| +000002d0 bb 06 22 d7 d6 97 39 d1 f4 dc 95 06 b3 a4 a7 00 |.."...9.........| +000002e0 d1 e5 98 bc 97 12 03 25 03 12 ab 20 4f 00 80 71 |.......%... O..q| +000002f0 8d 3c 54 44 ba df 73 92 76 16 d1 ec b1 de a2 27 |.>> Flow 3 (client to server) @@ -110,30 +110,30 @@ 00000200 e4 fa cc b1 8a ce e2 23 a0 87 f0 e1 67 51 eb 16 |.......#....gQ..| 00000210 03 01 00 25 10 00 00 21 20 2f e5 7d a3 47 cd 62 |...%...! /.}.G.b| 00000220 43 15 28 da ac 5f bb 29 07 30 ff f6 84 af c4 cf |C.(.._.).0......| -00000230 c2 ed 90 99 5f 58 cb 3b 74 16 03 01 00 91 0f 00 |...._X.;t.......| -00000240 00 8d 00 8b 30 81 88 02 42 00 f7 1a 73 32 b1 a7 |....0...B...s2..| -00000250 04 a2 26 85 14 53 5a 70 76 c4 44 4c 0d f8 5a a6 |..&..SZpv.DL..Z.| -00000260 bc 64 44 88 3f 01 80 a4 0d 17 ce 30 ca 92 4c 29 |.dD.?......0..L)| -00000270 b2 f3 a4 65 1e 28 55 bc b8 47 64 39 b7 49 20 05 |...e.(U..Gd9.I .| -00000280 9d a4 84 6b 1b 8b df eb b6 f6 b9 02 42 01 68 c8 |...k........B.h.| -00000290 fd 3c ad 36 ad 15 28 4f f2 ac b3 7f 63 28 30 5c |.<.6..(O....c(0\| -000002a0 68 59 f5 84 b2 cf 23 d6 dd 3b f5 7b 2b 1a ac 32 |hY....#..;.{+..2| -000002b0 20 da 76 af 63 2a 68 6e 18 cd 07 82 41 6f 50 91 | .v.c*hn....AoP.| -000002c0 d0 51 3b 9b ab 71 84 d4 be 15 dd 4b 8c 57 b7 14 |.Q;..q.....K.W..| -000002d0 03 01 00 01 01 16 03 01 00 30 e3 e6 b9 cb 0b 0f |.........0......| -000002e0 71 55 4e 15 53 85 5c 2a 55 ac 83 cc e9 71 69 eb |qUN.S.\*U....qi.| -000002f0 dd 64 cb 2f 9f 74 b4 e6 80 52 9e a0 08 e3 7e 14 |.d./.t...R....~.| -00000300 2c 5e 15 e4 81 38 11 aa fb ab |,^...8....| +00000230 c2 ed 90 99 5f 58 cb 3b 74 16 03 01 00 90 0f 00 |...._X.;t.......| +00000240 00 8c 00 8a 30 81 87 02 41 79 c5 57 74 46 9a 18 |....0...Ay.WtF..| +00000250 ad e0 b0 ba 68 f5 0e e2 58 94 dc 73 84 5a f8 86 |....h...X..s.Z..| +00000260 86 8e 2a 37 82 02 a1 4b 19 cd 71 b3 99 04 64 b0 |..*7...K..q...d.| +00000270 db 4a cc 41 a6 17 28 38 f1 67 bd 59 16 97 71 32 |.J.A..(8.g.Y..q2| +00000280 06 71 24 2c f3 df 34 1b a3 b8 02 42 01 2f 2f db |.q$,..4....B.//.| +00000290 45 07 94 53 89 81 59 0b 92 9d 1a 05 42 b3 1c 40 |E..S..Y.....B..@| +000002a0 38 50 a1 8e a6 35 15 76 ca 75 7e fc 8d 7b 36 f3 |8P...5.v.u~..{6.| +000002b0 e3 e7 bf f9 bd 94 35 a0 c5 2b 35 88 be 5d ee f1 |......5..+5..]..| +000002c0 00 f9 9c a8 01 a8 92 5d d6 17 b6 54 98 e4 14 03 |.......]...T....| +000002d0 01 00 01 01 16 03 01 00 30 1f d6 11 ac 58 b3 20 |........0....X. | +000002e0 31 6d 3b f5 83 98 50 75 ff 4f 79 61 2b fc 0f 6c |1m;...Pu.Oya+..l| +000002f0 a6 4d 9e 65 38 e3 ca 12 76 0a 56 1e dd 73 da e1 |.M.e8...v.V..s..| +00000300 66 5a 33 62 8f 7d c3 ed ad |fZ3b.}...| >>> Flow 4 (server to client) -00000000 14 03 01 00 01 01 16 03 01 00 30 bb 2d 20 48 7a |..........0.- Hz| -00000010 53 bf 3a ee c3 91 ec 1b be cf 4a 18 57 5a c4 a7 |S.:.......J.WZ..| -00000020 57 d7 51 fa 4a 69 8a bf cd ff 2e 64 e7 76 a7 49 |W.Q.Ji.....d.v.I| -00000030 1e 19 34 8d 4f c3 40 14 5d 68 8c |..4.O.@.]h.| +00000000 14 03 01 00 01 01 16 03 01 00 30 92 36 25 46 a5 |..........0.6%F.| +00000010 44 e6 31 25 cd 24 15 df 13 f8 5b a3 af 7c 12 43 |D.1%.$....[..|.C| +00000020 b8 8c 39 84 bc 25 06 02 02 86 78 20 1b ec 98 1a |..9..%....x ....| +00000030 31 b3 b8 cf 82 92 77 ff 08 87 fb |1.....w....| >>> Flow 5 (client to server) -00000000 17 03 01 00 20 c6 82 9a ee a3 de fe 3f cd 56 92 |.... .......?.V.| -00000010 20 b3 27 ae 5d db 4c 6c a3 a9 01 ba ce 98 c5 d7 | .'.].Ll........| -00000020 af be 49 92 50 17 03 01 00 20 35 a5 2d 8e 5a 4f |..I.P.... 5.-.ZO| -00000030 0d a8 ea 08 f8 dd 6c 01 04 d9 a7 2b 71 b1 c9 84 |......l....+q...| -00000040 9d de d3 ce 69 4c 7a 3e 3c 7b 15 03 01 00 20 5c |....iLz><{.... \| -00000050 00 f6 57 56 dc f9 fc 36 15 85 71 01 7b 18 ae 11 |..WV...6..q.{...| -00000060 51 0b f7 a3 e4 f8 d9 d8 ae 1d 0b 68 0f 4c 87 |Q..........h.L.| +00000000 17 03 01 00 20 2f bd ab e0 2f 9a 81 58 99 35 bb |.... /.../..X.5.| +00000010 86 61 6e 15 be 31 d7 ad 44 1d d9 cf 2f fc d9 f6 |.an..1..D.../...| +00000020 da b6 48 32 27 17 03 01 00 20 76 70 b7 7d 1b 05 |..H2'.... vp.}..| +00000030 ee 54 99 bf 89 79 79 b5 68 c1 84 3c 6d 47 5c d1 |.T...yy.h..>> Flow 2 (server to client) -00000000 16 03 01 00 5d 02 00 00 59 03 01 53 6b 9f 42 b4 |....]...Y..Sk.B.| -00000010 38 d0 d3 ef 17 52 44 10 a5 70 61 35 8c ae a9 52 |8....RD..pa5...R| -00000020 6c d6 e2 c3 bd c4 3c b9 3c 09 83 20 aa 22 81 b5 |l.....<.<.. ."..| -00000030 02 b5 aa e6 24 88 e6 75 70 1c 32 9a 3b 2c 2f 05 |....$..up.2.;,/.| -00000040 e0 eb 59 65 4c 9e 45 82 fd d7 37 5e c0 09 00 00 |..YeL.E...7^....| +00000000 16 03 01 00 5d 02 00 00 59 03 01 6f 48 26 41 da |....]...Y..oH&A.| +00000010 73 82 d1 cf 84 ad 06 e9 76 39 dc e4 c8 34 af 53 |s.......v9...4.S| +00000020 06 ed ed 68 56 5f 76 11 4e f6 ff 20 55 fd 29 c5 |...hV_v.N.. U.).| +00000030 aa 56 af bd 5d 67 74 4f 08 8a 52 a1 7e cd b9 ac |.V..]gtO..R.~...| +00000040 31 a0 2f 45 25 1f b2 24 71 26 80 17 c0 09 00 00 |1./E%..$q&......| 00000050 11 ff 01 00 01 00 00 0b 00 04 03 00 01 02 00 17 |................| 00000060 00 00 16 03 01 02 0e 0b 00 02 0a 00 02 07 00 02 |................| 00000070 04 30 82 02 00 30 82 01 62 02 09 00 b8 bf 2d 47 |.0...0..b.....-G| @@ -56,20 +56,20 @@ 00000240 8c 25 c1 33 13 83 0d 94 06 bb d4 37 7a f6 ec 7a |.%.3.......7z..z| 00000250 c9 86 2e dd d7 11 69 7f 85 7c 56 de fb 31 78 2b |......i..|V..1x+| 00000260 e4 c7 78 0d ae cb be 9e 4e 36 24 31 7b 6a 0f 39 |..x.....N6$1{j.9| -00000270 95 12 07 8f 2a 16 03 01 00 b5 0c 00 00 b1 03 00 |....*...........| -00000280 1d 20 fc 74 81 8e 09 19 14 86 d3 4d 8d cf 7d 00 |. .t.......M..}.| -00000290 c1 83 83 b5 9a 32 f1 38 01 ae a9 9b a1 d9 26 54 |.....2.8......&T| -000002a0 a4 08 00 8b 30 81 88 02 42 00 a1 56 29 a7 ba 25 |....0...B..V)..%| -000002b0 bb 6a 12 51 77 c1 28 35 1e 4b 3e a8 01 63 e6 f6 |.j.Qw.(5.K>..c..| -000002c0 f3 99 05 7b 0f 1f 21 dd 9e de c9 c1 08 c6 bc 23 |...{..!........#| -000002d0 71 87 1e a1 30 07 0c 5d f6 9f bf 45 7d 60 3c c2 |q...0..]...E}`<.| -000002e0 48 65 3d 3f a3 b4 67 89 90 1d 12 02 42 00 93 43 |He=?..g.....B..C| -000002f0 12 c1 46 b5 6d 2e cc 60 50 11 95 86 bd 36 53 fc |..F.m..`P....6S.| -00000300 92 01 6a 11 92 97 69 c2 cf c9 b0 a0 4a 42 0b d2 |..j...i.....JB..| -00000310 c4 0c 84 e5 9e f6 2c a3 91 70 45 25 1f 78 17 b0 |......,..pE%.x..| -00000320 1f 0e f7 a2 d5 4d 1c 77 ec f9 04 ca ab 68 26 16 |.....M.w.....h&.| -00000330 03 01 00 0a 0d 00 00 06 03 01 02 40 00 00 16 03 |...........@....| -00000340 01 00 04 0e 00 00 00 |.......| +00000270 95 12 07 8f 2a 16 03 01 00 b3 0c 00 00 af 03 00 |....*...........| +00000280 1d 20 51 4c 6f eb 08 70 52 20 15 78 d3 f8 65 5e |. QLo..pR .x..e^| +00000290 0f 59 03 b7 d1 0e e9 7e be 42 d2 cd f3 57 c6 24 |.Y.....~.B...W.$| +000002a0 6b 2c 00 89 30 81 86 02 41 7b 1b ec 11 08 f4 8f |k,..0...A{......| +000002b0 db 2c c5 1b 33 b2 b0 b4 da 76 b9 a7 78 ed ee 0e |.,..3....v..x...| +000002c0 23 5c 4b b0 10 6e 41 12 b9 d4 68 c1 15 ea 70 0a |#\K..nA...h...p.| +000002d0 0c 91 c1 8d 4a 4d 41 c1 c3 25 f1 90 ef 95 f3 e1 |....JMA..%......| +000002e0 a8 30 4d ce 4d d1 eb 8c cf 9a 02 41 09 e0 8c 8e |.0M.M......A....| +000002f0 70 01 f1 5d b2 8a d1 61 bc 86 f4 85 2f 6c ac 2c |p..]...a..../l.,| +00000300 e8 bf 20 c7 81 46 21 6e 9b bd c1 83 71 34 8d 65 |.. ..F!n....q4.e| +00000310 fc 35 07 be c8 ad d4 3a c6 7b 40 1c f7 17 e3 d9 |.5.....:.{@.....| +00000320 96 19 d4 cd 0d d0 8c 4f b2 09 6a 4b 05 16 03 01 |.......O..jK....| +00000330 00 0a 0d 00 00 06 03 01 02 40 00 00 16 03 01 00 |.........@......| +00000340 04 0e 00 00 00 |.....| >>> Flow 3 (client to server) 00000000 16 03 01 01 fd 0b 00 01 f9 00 01 f6 00 01 f3 30 |...............0| 00000010 82 01 ef 30 82 01 58 a0 03 02 01 02 02 10 5c 19 |...0..X.......\.| @@ -106,29 +106,29 @@ 00000200 e5 35 16 03 01 00 25 10 00 00 21 20 2f e5 7d a3 |.5....%...! /.}.| 00000210 47 cd 62 43 15 28 da ac 5f bb 29 07 30 ff f6 84 |G.bC.(.._.).0...| 00000220 af c4 cf c2 ed 90 99 5f 58 cb 3b 74 16 03 01 00 |......._X.;t....| -00000230 86 0f 00 00 82 00 80 3b af ba ad 44 f1 06 e4 79 |.......;...D...y| -00000240 d7 fa 41 42 2a 7e 45 3d fc 9d f7 5d a9 13 b9 35 |..AB*~E=...]...5| -00000250 49 ea 28 6a 03 48 0b 14 c9 43 69 16 32 b7 6b b5 |I.(j.H...Ci.2.k.| -00000260 a7 11 44 15 26 61 04 ea f8 1e a0 32 3d 6b 26 be |..D.&a.....2=k&.| -00000270 37 44 34 0e 06 62 ee cf b9 41 4c 84 ba 3f aa 5f |7D4..b...AL..?._| -00000280 d7 ea 31 c8 77 07 13 38 66 ba ec b4 b0 6c 44 ee |..1.w..8f....lD.| -00000290 8e d4 49 1d 9e 7b 2d b2 48 23 a0 06 04 22 9b 3a |..I..{-.H#...".:| -000002a0 3f 71 13 13 ce 67 3f e8 84 0f a4 8d ff 2c de f5 |?q...g?......,..| -000002b0 ce 8d 15 8d 64 bc 5e 14 03 01 00 01 01 16 03 01 |....d.^.........| -000002c0 00 30 f6 42 8a 63 15 7b 24 63 62 dc f7 6a ab 38 |.0.B.c.{$cb..j.8| -000002d0 33 32 6d c6 44 5e 10 8a 7a f8 f0 77 e7 5c 2a 6e |32m.D^..z..w.\*n| -000002e0 8f 18 72 c6 e2 42 66 c0 f7 7a 45 fb 68 01 30 8a |..r..Bf..zE.h.0.| -000002f0 59 1a |Y.| +00000230 86 0f 00 00 82 00 80 59 18 58 aa 18 70 84 a3 26 |.......Y.X..p..&| +00000240 8c 1d 77 52 a7 2d 00 e5 00 dc 24 1c f6 9b 9f 63 |..wR.-....$....c| +00000250 c8 84 8b dc e7 61 78 9c 28 0d 4c 3a 1e 5f a7 ce |.....ax.(.L:._..| +00000260 35 17 1c b1 de e0 01 32 35 6f 85 59 22 73 50 2a |5......25o.Y"sP*| +00000270 36 df 39 0c c8 c1 45 70 a2 e4 53 bb de e6 0e 6a |6.9...Ep..S....j| +00000280 fd 45 8e 4d eb 1f de 86 d3 fb 94 e4 8d 22 cd 30 |.E.M.........".0| +00000290 e7 29 de 65 f0 2a cd b8 3d b5 be 91 a3 7d 3b 30 |.).e.*..=....};0| +000002a0 1a a5 63 bd 84 1f 95 19 d1 fe 25 40 b8 8f ab 96 |..c.......%@....| +000002b0 59 42 e6 31 93 c0 39 14 03 01 00 01 01 16 03 01 |YB.1..9.........| +000002c0 00 30 a9 f7 c0 97 f4 b8 06 65 a6 7c fb 80 a1 79 |.0.......e.|...y| +000002d0 5f 44 72 55 13 d1 ca e3 9a 91 5d 1e 08 93 6d b5 |_DrU......]...m.| +000002e0 1c 5e 52 24 b1 ec db aa 3b bc fe db 18 0b 18 fe |.^R$....;.......| +000002f0 51 6a |Qj| >>> Flow 4 (server to client) -00000000 14 03 01 00 01 01 16 03 01 00 30 1f a1 61 8d 3e |..........0..a.>| -00000010 6e 5d 29 bd d0 14 80 ec 55 fc 7d b2 02 bd 6d c5 |n]).....U.}...m.| -00000020 93 50 67 30 4f ce d5 8a 8b 80 3c 9a a6 0f ac be |.Pg0O.....<.....| -00000030 dd b0 1b 22 0d 89 dc cd 73 ba 99 |..."....s..| +00000000 14 03 01 00 01 01 16 03 01 00 30 e6 36 50 e7 a3 |..........0.6P..| +00000010 72 0a 6a 9f 18 17 91 51 ad 48 19 54 c8 6b c0 45 |r.j....Q.H.T.k.E| +00000020 d5 9b cb 08 34 d3 3a 73 74 04 3a 3d 24 b0 95 48 |....4.:st.:=$..H| +00000030 97 9e c5 83 4f 20 29 c8 dd 93 6c |....O )...l| >>> Flow 5 (client to server) -00000000 17 03 01 00 20 23 4b ba 47 65 fb 41 fb ad c6 06 |.... #K.Ge.A....| -00000010 c2 c7 ed 6e b4 d0 42 48 6b 68 60 69 7c f0 91 85 |...n..BHkh`i|...| -00000020 f3 a2 ea b1 5b 17 03 01 00 20 d2 fa 3c a5 d2 ea |....[.... ..<...| -00000030 b8 81 7a fb 31 95 bc e5 e3 4d 1a 15 e7 e3 96 8e |..z.1....M......| -00000040 bc 77 26 b1 5c b5 61 14 99 7c 15 03 01 00 20 b2 |.w&.\.a..|.... .| -00000050 0c 6a 3d 02 6b 32 2f 43 9e 5e ac f1 c3 97 e2 27 |.j=.k2/C.^.....'| -00000060 c1 a1 b9 b6 b7 11 36 17 27 0a 7a 8d 53 18 d6 |......6.'.z.S..| +00000000 17 03 01 00 20 58 a1 0a 68 2c 04 68 7d e9 13 ce |.... X..h,.h}...| +00000010 69 4b 53 4a f6 fc e0 c8 0e 05 ad 19 d8 b3 37 67 |iKSJ..........7g| +00000020 f2 1f 3b 33 62 17 03 01 00 20 c2 e7 d3 d2 38 ba |..;3b.... ....8.| +00000030 27 13 ed d1 73 fc 9b f5 4f 61 f0 35 27 8e 54 52 |'...s...Oa.5'.TR| +00000040 b7 ce bd 6a 05 c6 61 95 1e 8a 15 03 01 00 20 6e |...j..a....... n| +00000050 07 21 86 31 f8 74 6b 45 4d 10 2f 5d e7 2b 64 77 |.!.1.tkEM./].+dw| +00000060 a9 7f 1e 49 ed d5 d4 1e 2e f2 b1 c5 4d 02 46 |...I........M.F| diff --git a/testdata/Client-TLSv10-ClientCert-RSA-RSA b/testdata/Client-TLSv10-ClientCert-RSA-RSA index b3157bb..48eb1ce 100644 --- a/testdata/Client-TLSv10-ClientCert-RSA-RSA +++ b/testdata/Client-TLSv10-ClientCert-RSA-RSA @@ -7,21 +7,21 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 7f 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 0a 00 08 00 1d 00 17 00 18 00 19 00 0b 00 02 01 |................| -000000a0 00 00 0d 00 1a 00 18 08 04 04 03 08 07 08 05 08 |................| -000000b0 06 04 01 05 01 06 01 05 03 06 03 02 01 02 03 ff |................| -000000c0 01 00 01 00 00 17 00 00 00 12 00 00 00 2b 00 09 |.............+..| +00000080 01 00 00 7f 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 19 00 0d |................| +000000b0 00 1a 00 18 08 04 04 03 08 07 08 05 08 06 04 01 |................| +000000c0 05 01 06 01 05 03 06 03 02 01 02 03 00 2b 00 09 |.............+..| 000000d0 08 03 04 03 03 03 02 03 01 00 33 00 26 00 24 00 |..........3.&.$.| 000000e0 1d 00 20 2f e5 7d a3 47 cd 62 43 15 28 da ac 5f |.. /.}.G.bC.(.._| 000000f0 bb 29 07 30 ff f6 84 af c4 cf c2 ed 90 99 5f 58 |.).0.........._X| 00000100 cb 3b 74 |.;t| >>> Flow 2 (server to client) -00000000 16 03 01 00 5d 02 00 00 59 03 01 a1 43 a5 02 b9 |....]...Y...C...| -00000010 48 81 74 51 b7 89 df 36 43 1c a3 5e f3 11 7e 81 |H.tQ...6C..^..~.| -00000020 2d 43 b5 86 e8 4a f4 fe 5e 5e 92 20 10 31 08 7a |-C...J..^^. .1.z| -00000030 cc 0e 5a 90 0e 07 aa 2f c7 17 b8 c9 d5 93 36 e3 |..Z..../......6.| -00000040 ca 34 ed a2 e2 3d 6c 0c fd 56 d9 64 c0 13 00 00 |.4...=l..V.d....| +00000000 16 03 01 00 5d 02 00 00 59 03 01 24 71 03 c6 1d |....]...Y..$q...| +00000010 d4 f5 09 b2 3c d8 88 51 57 4c 90 07 4b 74 fe 1d |....<..QWL..Kt..| +00000020 c9 7f 00 78 9b a3 b2 1b ef 43 66 20 07 97 7c a6 |...x.....Cf ..|.| +00000030 9b c6 a9 47 42 ae 99 bf 59 fe 52 f6 da d9 1c 68 |...GB...Y.R....h| +00000040 c2 7a 53 3f 27 0d 11 87 9a 47 81 5c c0 13 00 00 |.zS?'....G.\....| 00000050 11 ff 01 00 01 00 00 0b 00 04 03 00 01 02 00 17 |................| 00000060 00 00 16 03 01 02 59 0b 00 02 55 00 02 52 00 02 |......Y...U..R..| 00000070 4f 30 82 02 4b 30 82 01 b4 a0 03 02 01 02 02 09 |O0..K0..........| @@ -61,17 +61,17 @@ 00000290 73 bb b3 43 77 8d 0c 1c f1 0f a1 d8 40 83 61 c9 |s..Cw.......@.a.| 000002a0 4c 72 2b 9d ae db 46 06 06 4d f4 c1 b3 3e c0 d1 |Lr+...F..M...>..| 000002b0 bd 42 d4 db fe 3d 13 60 84 5c 21 d3 3b e9 fa e7 |.B...=.`.\!.;...| -000002c0 16 03 01 00 aa 0c 00 00 a6 03 00 1d 20 62 23 e4 |............ b#.| -000002d0 5c 02 03 2d 62 41 93 e8 99 9d 01 cb 55 2c 7d 8d |\..-bA......U,}.| -000002e0 fd db d6 ac c6 99 d0 78 0f 27 27 37 70 00 80 6a |.......x.''7p..j| -000002f0 58 5e 29 6b 93 82 42 fa a2 b7 5c 06 d8 ac ae 85 |X^)k..B...\.....| -00000300 48 37 98 35 cf 31 09 8e d6 a3 37 26 d1 e5 b3 3b |H7.5.1....7&...;| -00000310 98 53 dc b5 d2 9d 73 80 89 04 35 20 e6 e7 ac 48 |.S....s...5 ...H| -00000320 88 6f 42 ac 1b 46 d3 78 6a f0 5d a0 68 e1 83 db |.oB..F.xj.].h...| -00000330 8a f3 bc f0 d2 35 b7 ae 8d 38 75 9f d6 76 01 ce |.....5...8u..v..| -00000340 d7 a9 0f 69 11 09 75 4a 20 b4 3b ec 14 fd 2b 7b |...i..uJ .;...+{| -00000350 e1 cf 12 89 d2 a2 94 3d 76 d5 b8 65 b4 17 24 43 |.......=v..e..$C| -00000360 96 68 c4 c9 cc a2 08 e7 ca bc 2d 14 90 fa 53 16 |.h........-...S.| +000002c0 16 03 01 00 aa 0c 00 00 a6 03 00 1d 20 ad a7 d5 |............ ...| +000002d0 fc 63 e1 22 f8 1f 8d ad 50 09 1a 92 a4 57 ea 88 |.c."....P....W..| +000002e0 6d 9c 20 70 f1 8b 85 15 ec 8e b2 b3 07 00 80 b1 |m. p............| +000002f0 03 03 a7 cf 8f 73 e2 a3 29 0d 55 4a 06 72 db e5 |.....s..).UJ.r..| +00000300 65 41 44 49 05 1c 37 17 1c 02 6e b1 f4 e8 a9 bb |eADI..7...n.....| +00000310 00 24 3e 3a 3c d6 1c f6 dd 21 a4 e3 61 b0 1d 2e |.$>:<....!..a...| +00000320 77 11 53 51 4d 49 1e 07 bf 07 61 d1 54 f4 c7 24 |w.SQMI....a.T..$| +00000330 4f 7d 5c 5a fb 84 c0 9d 0e 52 12 b6 40 72 37 fd |O}\Z.....R..@r7.| +00000340 8c bd d0 8a b1 9e 2c 18 bc 04 a3 c2 90 a3 33 4c |......,.......3L| +00000350 06 7c 14 a8 73 7d d2 23 30 f9 31 12 56 31 60 19 |.|..s}.#0.1.V1`.| +00000360 d1 0d 31 c1 3c 25 66 62 5c 9b 13 5e 34 c6 69 16 |..1.<%fb\..^4.i.| 00000370 03 01 00 0a 0d 00 00 06 03 01 02 40 00 00 16 03 |...........@....| 00000380 01 00 04 0e 00 00 00 |.......| >>> Flow 3 (client to server) @@ -110,29 +110,29 @@ 00000200 e5 35 16 03 01 00 25 10 00 00 21 20 2f e5 7d a3 |.5....%...! /.}.| 00000210 47 cd 62 43 15 28 da ac 5f bb 29 07 30 ff f6 84 |G.bC.(.._.).0...| 00000220 af c4 cf c2 ed 90 99 5f 58 cb 3b 74 16 03 01 00 |......._X.;t....| -00000230 86 0f 00 00 82 00 80 3d 7f 32 50 ff aa 3d ff 0f |.......=.2P..=..| -00000240 f8 68 64 fb 2d 34 b8 5b 5e 4b 49 04 b8 eb f7 07 |.hd.-4.[^KI.....| -00000250 b7 bf 55 17 e5 11 66 87 23 16 3e ba 87 2f 58 23 |..U...f.#.>../X#| -00000260 28 d4 df 15 75 eb 7b f6 38 94 a8 73 8a d2 1f 51 |(...u.{.8..s...Q| -00000270 0f b5 90 16 0f db f9 23 a0 bc a5 96 48 ac a6 fa |.......#....H...| -00000280 fd e7 b4 94 5e c6 d4 a6 69 61 97 1a c3 ed 1e 5a |....^...ia.....Z| -00000290 db d9 c5 8f 58 97 6c 2a 88 f8 fb 52 14 10 a6 5a |....X.l*...R...Z| -000002a0 62 7a f8 37 40 e7 fd 27 c6 27 32 12 10 75 83 e3 |bz.7@..'.'2..u..| -000002b0 66 c1 77 78 90 38 5d 14 03 01 00 01 01 16 03 01 |f.wx.8].........| -000002c0 00 30 47 b5 75 6f 94 df 88 65 2d fc 45 33 29 d0 |.0G.uo...e-.E3).| -000002d0 be 8d c0 72 59 be 7e 57 aa d8 42 d5 61 95 24 53 |...rY.~W..B.a.$S| -000002e0 19 94 06 5b 48 34 22 44 6e 6e bf 2a 3d 0d 83 f6 |...[H4"Dnn.*=...| -000002f0 a7 3b |.;| +00000230 86 0f 00 00 82 00 80 59 e2 7d 00 66 f0 59 a0 19 |.......Y.}.f.Y..| +00000240 b6 4f 26 80 ad 31 b4 b3 c2 56 af 84 bf 88 15 7f |.O&..1...V......| +00000250 dc 29 fc 51 f2 cf 0d ec 52 46 c5 c5 cd 24 c1 93 |.).Q....RF...$..| +00000260 5b f6 06 09 ad bb 9a 4a ae 5d ec 57 f8 96 a8 b1 |[......J.].W....| +00000270 4b 81 45 7d 34 38 59 ea 76 47 76 1c 7f 7b 68 e9 |K.E}48Y.vGv..{h.| +00000280 89 7b 5d 4c b9 bc 5a 26 e1 f7 6c 42 f7 c6 6d bb |.{]L..Z&..lB..m.| +00000290 c0 c7 bd f6 5e 9e 51 d8 30 ec 9f da 56 0a b7 2a |....^.Q.0...V..*| +000002a0 6c 5e 50 d1 74 48 70 4a 88 62 16 a1 ba f2 01 e5 |l^P.tHpJ.b......| +000002b0 00 b6 eb cb e3 18 cf 14 03 01 00 01 01 16 03 01 |................| +000002c0 00 30 61 51 84 02 46 3c 10 62 b5 2a a2 8b 4e 2d |.0aQ..F<.b.*..N-| +000002d0 57 55 26 c5 46 f2 5d a1 f5 20 46 0d 63 fd 48 5a |WU&.F.].. F.c.HZ| +000002e0 f3 65 90 8c 1a bd 59 6e 5f d1 5c b6 ee 33 49 12 |.e....Yn_.\..3I.| +000002f0 46 ec |F.| >>> Flow 4 (server to client) -00000000 14 03 01 00 01 01 16 03 01 00 30 c1 88 7e 9e de |..........0..~..| -00000010 d3 2d 1d 27 bf d5 49 c5 a7 67 cc 0b fc ca a6 9b |.-.'..I..g......| -00000020 1b c7 96 59 ff 4f b9 7d a0 7a 5e ed eb 77 04 5f |...Y.O.}.z^..w._| -00000030 ba b6 ea 33 80 b0 28 ef 96 ba 6a |...3..(...j| +00000000 14 03 01 00 01 01 16 03 01 00 30 b1 3c 7f c3 15 |..........0.<...| +00000010 e4 fe bc 1a ee 0d ec 28 ce b0 f7 fd a4 0a e4 79 |.......(.......y| +00000020 37 09 68 de 58 f8 e8 76 7d 9c 09 35 42 7e 00 8e |7.h.X..v}..5B~..| +00000030 4c 8d d1 60 26 d4 09 c5 8b d0 96 |L..`&......| >>> Flow 5 (client to server) -00000000 17 03 01 00 20 55 4a e0 a0 68 5f 32 17 9a a3 fd |.... UJ..h_2....| -00000010 01 e9 2c fa 19 12 56 6f c6 d7 a7 8d b7 8b 74 8a |..,...Vo......t.| -00000020 3a ae 72 9f 1e 17 03 01 00 20 b2 07 ca 31 62 b7 |:.r...... ...1b.| -00000030 cb 46 d4 33 61 6c 81 11 d8 8b f3 cf 6a ac a8 c7 |.F.3al......j...| -00000040 06 9c dc d9 49 ad 39 2a 6a ea 15 03 01 00 20 ee |....I.9*j..... .| -00000050 53 44 2e a0 bc 8d 74 8c 12 6b 3d a8 3e a5 98 00 |SD....t..k=.>...| -00000060 03 e8 bb 34 f5 a9 29 81 0a 6f e6 d3 0e ad 9d |...4..)..o.....| +00000000 17 03 01 00 20 6c bb 09 ee 1d 96 6c 63 5b b6 69 |.... l.....lc[.i| +00000010 bf ea ad 7a 85 36 a2 4b d2 f0 73 18 91 b1 42 e5 |...z.6.K..s...B.| +00000020 77 d0 6c ff ab 17 03 01 00 20 ed 85 78 3b bd 49 |w.l...... ..x;.I| +00000030 2c f3 02 24 f2 18 72 96 a0 49 6b 06 bd bb 54 25 |,..$..r..Ik...T%| +00000040 0a 3e ff 07 45 6b 6c cc a6 d2 15 03 01 00 20 07 |.>..Ekl....... .| +00000050 9a fb b7 cc 01 cd f7 b6 90 d3 b6 a7 31 15 99 e2 |............1...| +00000060 e7 e8 2b a5 c0 e8 a9 9d fe 4e 11 0d 4a d4 b7 |..+......N..J..| diff --git a/testdata/Client-TLSv10-ECDHE-ECDSA-AES b/testdata/Client-TLSv10-ECDHE-ECDSA-AES index d146d79..ac354c5 100644 --- a/testdata/Client-TLSv10-ECDHE-ECDSA-AES +++ b/testdata/Client-TLSv10-ECDHE-ECDSA-AES @@ -7,21 +7,21 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 7f 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 0a 00 08 00 1d 00 17 00 18 00 19 00 0b 00 02 01 |................| -000000a0 00 00 0d 00 1a 00 18 08 04 04 03 08 07 08 05 08 |................| -000000b0 06 04 01 05 01 06 01 05 03 06 03 02 01 02 03 ff |................| -000000c0 01 00 01 00 00 17 00 00 00 12 00 00 00 2b 00 09 |.............+..| +00000080 01 00 00 7f 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 19 00 0d |................| +000000b0 00 1a 00 18 08 04 04 03 08 07 08 05 08 06 04 01 |................| +000000c0 05 01 06 01 05 03 06 03 02 01 02 03 00 2b 00 09 |.............+..| 000000d0 08 03 04 03 03 03 02 03 01 00 33 00 26 00 24 00 |..........3.&.$.| 000000e0 1d 00 20 2f e5 7d a3 47 cd 62 43 15 28 da ac 5f |.. /.}.G.bC.(.._| 000000f0 bb 29 07 30 ff f6 84 af c4 cf c2 ed 90 99 5f 58 |.).0.........._X| 00000100 cb 3b 74 |.;t| >>> Flow 2 (server to client) -00000000 16 03 01 00 5d 02 00 00 59 03 01 1c a5 a3 a1 49 |....]...Y......I| -00000010 4e 93 54 cf 5a a2 8b 57 e7 f9 7b ce 53 48 fb 5b |N.T.Z..W..{.SH.[| -00000020 82 51 d6 0d aa c7 8b 40 44 5f 18 20 e3 b4 ca 5c |.Q.....@D_. ...\| -00000030 fd 20 e3 ae d2 a4 df e6 af db 4f 8b e9 95 41 1e |. ........O...A.| -00000040 8f 6f 1e 0a 33 e4 0b 0b 1b aa 54 a7 c0 09 00 00 |.o..3.....T.....| +00000000 16 03 01 00 5d 02 00 00 59 03 01 70 d2 b8 0b 74 |....]...Y..p...t| +00000010 93 b4 60 d7 ab 1d 0f f3 7c d0 b5 f8 a2 78 45 30 |..`.....|....xE0| +00000020 b1 41 9b b6 73 bd 05 d8 85 16 66 20 e8 26 8d 7a |.A..s.....f .&.z| +00000030 e2 da e0 a0 7a c9 19 d1 dd db 2b bc b4 b2 56 39 |....z.....+...V9| +00000040 9f e6 62 75 29 96 40 b3 0d c0 db 65 c0 09 00 00 |..bu).@....e....| 00000050 11 ff 01 00 01 00 00 0b 00 04 03 00 01 02 00 17 |................| 00000060 00 00 16 03 01 02 0e 0b 00 02 0a 00 02 07 00 02 |................| 00000070 04 30 82 02 00 30 82 01 62 02 09 00 b8 bf 2d 47 |.0...0..b.....-G| @@ -56,37 +56,37 @@ 00000240 8c 25 c1 33 13 83 0d 94 06 bb d4 37 7a f6 ec 7a |.%.3.......7z..z| 00000250 c9 86 2e dd d7 11 69 7f 85 7c 56 de fb 31 78 2b |......i..|V..1x+| 00000260 e4 c7 78 0d ae cb be 9e 4e 36 24 31 7b 6a 0f 39 |..x.....N6$1{j.9| -00000270 95 12 07 8f 2a 16 03 01 00 b5 0c 00 00 b1 03 00 |....*...........| -00000280 1d 20 d8 71 32 54 18 4e 03 b2 c7 dd 0d 04 2f c5 |. .q2T.N....../.| -00000290 c4 da f0 c8 72 b5 c0 b8 c1 a9 f7 e3 8d 1f 0d 3b |....r..........;| -000002a0 2a 08 00 8b 30 81 88 02 42 01 b6 59 64 4b 72 d6 |*...0...B..YdKr.| -000002b0 ef 9e 3e 18 1d d4 da 89 e1 59 91 96 47 55 09 cd |..>......Y..GU..| -000002c0 ee a1 e9 0c db c9 6c bc 09 82 e1 4e 03 e7 c9 c5 |......l....N....| -000002d0 78 bd 2f 28 dc fc 6a 8c ed e7 43 74 4e e0 06 f6 |x./(..j...CtN...| -000002e0 ee 85 f5 0f f9 c4 92 96 7d 69 4e 02 42 01 3f cc |........}iN.B.?.| -000002f0 89 ce 81 42 00 4f 89 28 3d 6d 6a 70 5a 6c d9 87 |...B.O.(=mjpZl..| -00000300 a3 80 36 7f fa c1 a1 50 57 4b 93 bf a3 16 01 f5 |..6....PWK......| -00000310 d4 07 4d fd 33 4a 2f 50 36 83 82 40 ef 8d aa 10 |..M.3J/P6..@....| -00000320 6d d0 e0 24 bd d6 33 d0 96 87 ce 43 28 44 86 16 |m..$..3....C(D..| -00000330 03 01 00 04 0e 00 00 00 |........| +00000270 95 12 07 8f 2a 16 03 01 00 b4 0c 00 00 b0 03 00 |....*...........| +00000280 1d 20 5f 81 8f 18 31 4e 64 fe 87 f2 da c6 45 45 |. _...1Nd.....EE| +00000290 54 e3 54 c6 a0 bb bf bd d1 01 c5 7b 08 d8 32 6b |T.T........{..2k| +000002a0 a8 31 00 8a 30 81 87 02 42 01 21 7e c2 26 cb 5e |.1..0...B.!~.&.^| +000002b0 f1 2a d2 9b 7f 3f b4 d4 28 5e 63 5a 20 aa 28 87 |.*...?..(^cZ .(.| +000002c0 bb dd 5c 6a 91 a2 2d 03 7a 69 67 8b ca 84 a6 1f |..\j..-.zig.....| +000002d0 d3 58 40 eb 5c 54 95 96 05 d0 37 63 e4 a6 1b 51 |.X@.\T....7c...Q| +000002e0 9a d0 93 31 82 e6 8e a0 af 29 64 02 41 4c ff ac |...1.....)d.AL..| +000002f0 44 74 e0 04 2c ab 1c 23 91 dc 06 36 ff 19 a1 60 |Dt..,..#...6...`| +00000300 19 d4 e5 d3 78 f5 ed d8 09 7b de 61 6f 65 2c 69 |....x....{.aoe,i| +00000310 a1 d2 5d 07 bf 99 26 2b 70 fa 34 26 30 41 59 3b |..]...&+p.4&0AY;| +00000320 bc a3 10 9c 92 fa 60 a7 df ea e4 8a 3a 76 16 03 |......`.....:v..| +00000330 01 00 04 0e 00 00 00 |.......| >>> Flow 3 (client to server) 00000000 16 03 01 00 25 10 00 00 21 20 2f e5 7d a3 47 cd |....%...! /.}.G.| 00000010 62 43 15 28 da ac 5f bb 29 07 30 ff f6 84 af c4 |bC.(.._.).0.....| 00000020 cf c2 ed 90 99 5f 58 cb 3b 74 14 03 01 00 01 01 |....._X.;t......| -00000030 16 03 01 00 30 56 e4 5e 74 7d 22 11 ce 6a 97 42 |....0V.^t}"..j.B| -00000040 9f 6f 71 26 d4 a3 0f e4 03 1d 96 e1 ed a5 bd e4 |.oq&............| -00000050 a5 96 7c b0 49 d4 bf fe b2 3e d4 ed b0 52 f0 1b |..|.I....>...R..| -00000060 72 f4 45 ab a3 |r.E..| +00000030 16 03 01 00 30 6d 2a 91 d7 c3 8f 1c d8 d4 cc 67 |....0m*........g| +00000040 ed 07 41 c2 9c 48 0d bd 7f 11 61 00 58 23 55 88 |..A..H....a.X#U.| +00000050 f9 bd da 92 bc e4 8d 47 c0 ac 72 43 7f 2d 0f b5 |.......G..rC.-..| +00000060 de bb 67 6e 9f |..gn.| >>> Flow 4 (server to client) -00000000 14 03 01 00 01 01 16 03 01 00 30 85 b6 39 e7 4e |..........0..9.N| -00000010 2d d9 aa 9c a7 a7 e9 13 a7 05 cb a4 c0 11 62 67 |-.............bg| -00000020 34 6f b1 33 05 1e d0 a6 d1 20 f3 cc 47 7d ea 63 |4o.3..... ..G}.c| -00000030 99 dc 34 46 8e 47 eb 5f 2c 1b b5 |..4F.G._,..| +00000000 14 03 01 00 01 01 16 03 01 00 30 be 25 a7 fa 04 |..........0.%...| +00000010 a5 dd 58 c1 5f a6 31 f8 fc fc db 27 a1 c7 0b 7c |..X._.1....'...|| +00000020 a5 9a 0f bd 07 09 d9 9b 95 bf f4 a5 80 c7 7d bd |..............}.| +00000030 a0 37 25 68 46 63 37 37 5f 3d b2 |.7%hFc77_=.| >>> Flow 5 (client to server) -00000000 17 03 01 00 20 35 6d 66 48 4a a0 ee 5a b7 2a 15 |.... 5mfHJ..Z.*.| -00000010 c8 0c f7 86 16 f1 6a 96 51 28 9b 81 14 fd ac 92 |......j.Q(......| -00000020 7b d0 9d be 24 17 03 01 00 20 08 f2 38 45 8e a3 |{...$.... ..8E..| -00000030 89 50 5d 7f c8 5e 4f 71 7e 23 17 da 9b 99 a9 9d |.P]..^Oq~#......| -00000040 ed 51 8b 1a c8 67 fe 6c c8 2a 15 03 01 00 20 e1 |.Q...g.l.*.... .| -00000050 ef 54 d4 d3 e3 1e 5a db c0 e9 92 8c 27 e5 86 dd |.T....Z.....'...| -00000060 29 78 cc 90 6b a7 9c 7b b4 9b 1b 5d 1a 65 18 |)x..k..{...].e.| +00000000 17 03 01 00 20 98 6e bd 0c 0e 46 88 05 6d 67 b3 |.... .n...F..mg.| +00000010 a7 92 7a 3c f2 98 8b ab 07 9e 80 bc 7a 5e 70 1a |..z<........z^p.| +00000020 2b 3d 2f 28 c9 17 03 01 00 20 f1 a8 ac 45 f6 60 |+=/(..... ...E.`| +00000030 ac 76 4e 66 1b a1 23 65 9c 55 6b 0b d4 cb 0a 43 |.vNf..#e.Uk....C| +00000040 42 d1 1e 1b 61 45 16 8e a8 c2 15 03 01 00 20 3d |B...aE........ =| +00000050 c0 ac 27 49 be 69 0e 23 cd 1b ea 01 0f 97 66 34 |..'I.i.#......f4| +00000060 f8 bd a6 40 35 af 5b 1f cf 42 25 54 aa 2f 2e |...@5.[..B%T./.| diff --git a/testdata/Client-TLSv10-ECDHE-RSA-AES b/testdata/Client-TLSv10-ECDHE-RSA-AES index e66b88a..694cd4c 100644 --- a/testdata/Client-TLSv10-ECDHE-RSA-AES +++ b/testdata/Client-TLSv10-ECDHE-RSA-AES @@ -7,21 +7,21 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 7f 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 0a 00 08 00 1d 00 17 00 18 00 19 00 0b 00 02 01 |................| -000000a0 00 00 0d 00 1a 00 18 08 04 04 03 08 07 08 05 08 |................| -000000b0 06 04 01 05 01 06 01 05 03 06 03 02 01 02 03 ff |................| -000000c0 01 00 01 00 00 17 00 00 00 12 00 00 00 2b 00 09 |.............+..| +00000080 01 00 00 7f 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 19 00 0d |................| +000000b0 00 1a 00 18 08 04 04 03 08 07 08 05 08 06 04 01 |................| +000000c0 05 01 06 01 05 03 06 03 02 01 02 03 00 2b 00 09 |.............+..| 000000d0 08 03 04 03 03 03 02 03 01 00 33 00 26 00 24 00 |..........3.&.$.| 000000e0 1d 00 20 2f e5 7d a3 47 cd 62 43 15 28 da ac 5f |.. /.}.G.bC.(.._| 000000f0 bb 29 07 30 ff f6 84 af c4 cf c2 ed 90 99 5f 58 |.).0.........._X| 00000100 cb 3b 74 |.;t| >>> Flow 2 (server to client) -00000000 16 03 01 00 5d 02 00 00 59 03 01 4c dc 79 d9 cc |....]...Y..L.y..| -00000010 4d 3e e9 7d b2 7c 46 0d 2d 2f ff 27 47 b1 e3 52 |M>.}.|F.-/.'G..R| -00000020 b1 b4 34 80 6e 60 d5 b6 2d ab bd 20 d4 59 df e1 |..4.n`..-.. .Y..| -00000030 99 75 36 f3 ac 26 40 99 74 f3 78 43 20 e0 da 18 |.u6..&@.t.xC ...| -00000040 ae 5c bb bc b5 cc 3f c5 32 7e 3c ba c0 13 00 00 |.\....?.2~<.....| +00000000 16 03 01 00 5d 02 00 00 59 03 01 5a a9 a1 6f fa |....]...Y..Z..o.| +00000010 19 95 38 9e 68 42 d7 0f 73 23 09 3f 01 5f e8 ae |..8.hB..s#.?._..| +00000020 d7 06 a2 9b d3 01 0f 0d 23 53 7d 20 55 2b 67 4e |........#S} U+gN| +00000030 8b 44 94 a5 25 ef b7 fb e1 c7 85 e8 15 60 f9 d7 |.D..%........`..| +00000040 6d a4 3f 3d 42 d7 78 a6 41 49 b7 12 c0 13 00 00 |m.?=B.x.AI......| 00000050 11 ff 01 00 01 00 00 0b 00 04 03 00 01 02 00 17 |................| 00000060 00 00 16 03 01 02 59 0b 00 02 55 00 02 52 00 02 |......Y...U..R..| 00000070 4f 30 82 02 4b 30 82 01 b4 a0 03 02 01 02 02 09 |O0..K0..........| @@ -61,36 +61,36 @@ 00000290 73 bb b3 43 77 8d 0c 1c f1 0f a1 d8 40 83 61 c9 |s..Cw.......@.a.| 000002a0 4c 72 2b 9d ae db 46 06 06 4d f4 c1 b3 3e c0 d1 |Lr+...F..M...>..| 000002b0 bd 42 d4 db fe 3d 13 60 84 5c 21 d3 3b e9 fa e7 |.B...=.`.\!.;...| -000002c0 16 03 01 00 aa 0c 00 00 a6 03 00 1d 20 ee 7b 17 |............ .{.| -000002d0 15 a8 03 82 b4 bc ec 9a 6f 77 a8 29 29 2f ed 2e |........ow.))/..| -000002e0 65 91 4f 38 b4 e3 a8 f6 48 be c9 c4 26 00 80 ae |e.O8....H...&...| -000002f0 ef 11 b3 78 c2 8b 4d 86 38 c6 4e 86 1c 26 57 24 |...x..M.8.N..&W$| -00000300 cf 21 12 b1 74 13 eb 12 c4 90 5a a2 eb 2c 9b 97 |.!..t.....Z..,..| -00000310 23 f6 8f 4f 25 b8 70 fe b1 dc 95 b5 0c 8f 0b 0d |#..O%.p.........| -00000320 d9 23 40 a9 48 c3 52 08 0f 4b d4 7d 9f f3 e3 4e |.#@.H.R..K.}...N| -00000330 8e 14 98 7c ac e9 ee a3 53 0c 25 bf 8e 06 a5 cb |...|....S.%.....| -00000340 6e 96 76 37 be 8a c8 2e c3 72 cc 8d 12 78 bc 20 |n.v7.....r...x. | -00000350 8c 53 0e e7 72 59 4d 46 34 72 27 37 6d 2c 88 d6 |.S..rYMF4r'7m,..| -00000360 cd 0f ab 6d e1 2d a0 3c df 04 35 d9 d2 2d f5 16 |...m.-.<..5..-..| +000002c0 16 03 01 00 aa 0c 00 00 a6 03 00 1d 20 a7 ec f4 |............ ...| +000002d0 c7 51 5e a0 fb 55 5a 01 34 cc d1 a6 22 df d6 00 |.Q^..UZ.4..."...| +000002e0 f5 73 e0 9e b8 9d 2a a9 49 3a 99 ba 17 00 80 14 |.s....*.I:......| +000002f0 95 47 77 a1 48 b4 e7 ba 6a e8 0e 4e ee 55 25 f5 |.Gw.H...j..N.U%.| +00000300 ea 82 65 b4 3f db a2 94 03 cc d3 6c 4a e6 cf 57 |..e.?......lJ..W| +00000310 25 4c 79 b8 fb ab dd 1f 68 e4 55 87 b1 46 12 30 |%Ly.....h.U..F.0| +00000320 5e 9f 3d 4a 52 24 76 50 c8 54 83 a2 b9 f5 a6 e0 |^.=JR$vP.T......| +00000330 ec e1 fb ae dd ca d2 c9 b2 31 d5 d4 73 f4 c0 0a |.........1..s...| +00000340 29 1c d3 8e 87 4c b4 0a 37 e8 77 e4 e2 a7 e9 9c |)....L..7.w.....| +00000350 04 ba af 31 dc 2e 5a b3 2e f3 58 e6 21 0a e2 1c |...1..Z...X.!...| +00000360 d4 c6 be b1 70 83 22 05 f8 78 12 6e bd 53 22 16 |....p."..x.n.S".| 00000370 03 01 00 04 0e 00 00 00 |........| >>> Flow 3 (client to server) 00000000 16 03 01 00 25 10 00 00 21 20 2f e5 7d a3 47 cd |....%...! /.}.G.| 00000010 62 43 15 28 da ac 5f bb 29 07 30 ff f6 84 af c4 |bC.(.._.).0.....| 00000020 cf c2 ed 90 99 5f 58 cb 3b 74 14 03 01 00 01 01 |....._X.;t......| -00000030 16 03 01 00 30 af af 7d 17 17 49 08 86 ba 49 c7 |....0..}..I...I.| -00000040 01 e9 f2 85 f4 70 2d 37 38 b3 38 4d c3 23 0f f5 |.....p-78.8M.#..| -00000050 fe f3 22 58 6a ec cd ee 17 92 d0 fe aa d8 68 ff |.."Xj.........h.| -00000060 1d b1 7a 5b 6a |..z[j| +00000030 16 03 01 00 30 0f 56 a4 2c c6 11 a2 0a a8 f7 ff |....0.V.,.......| +00000040 6e 71 19 e9 e5 c0 e2 6b 86 9b b1 5d 46 8d 62 93 |nq.....k...]F.b.| +00000050 69 7c 28 6f 25 3d dc ce fa 6f 91 9e b8 8c 15 cd |i|(o%=...o......| +00000060 6a b1 72 ce a8 |j.r..| >>> Flow 4 (server to client) -00000000 14 03 01 00 01 01 16 03 01 00 30 30 b9 1b da 00 |..........00....| -00000010 85 eb 23 f3 69 6a 96 34 f1 03 b8 51 c4 0c 09 a7 |..#.ij.4...Q....| -00000020 62 4c 14 c6 fb ee b0 2b f0 fc e6 9b b6 97 47 83 |bL.....+......G.| -00000030 20 3d fe c4 42 43 6f c1 2f 09 6a | =..BCo./.j| +00000000 14 03 01 00 01 01 16 03 01 00 30 d0 aa 00 27 9e |..........0...'.| +00000010 fb 56 22 9f 65 ab 3c cf 34 d9 a0 92 08 62 f2 fe |.V".e.<.4....b..| +00000020 29 4b 0c 14 b0 72 f5 c0 f8 2b 7e 1f 38 ad 68 7e |)K...r...+~.8.h~| +00000030 37 c3 fb 26 5a 5b 42 39 83 33 c0 |7..&Z[B9.3.| >>> Flow 5 (client to server) -00000000 17 03 01 00 20 42 e3 37 32 c0 b5 bb fb 9b 26 9e |.... B.72.....&.| -00000010 1b b1 28 ee c7 44 c3 7c c8 51 88 3a e9 5a c7 2f |..(..D.|.Q.:.Z./| -00000020 b6 0d 73 ee 3e 17 03 01 00 20 20 33 1e 5f 0f 81 |..s.>.... 3._..| -00000030 aa 06 15 f1 e6 24 f3 12 07 ad 78 a6 0f 18 ad 33 |.....$....x....3| -00000040 67 d4 1c ec 28 15 65 de e2 6e 15 03 01 00 20 b0 |g...(.e..n.... .| -00000050 93 62 04 fe 6e 3f 41 a5 c8 e8 6c 9d a7 96 59 ba |.b..n?A...l...Y.| -00000060 aa 81 c8 ff ef 66 91 89 5f 9c ba d1 aa e7 ef |.....f.._......| +00000000 17 03 01 00 20 0e 54 7f 5d b9 f2 73 9d a5 49 25 |.... .T.]..s..I%| +00000010 c6 b9 03 1e fb 84 76 a9 69 ca 25 79 c3 a4 60 18 |......v.i.%y..`.| +00000020 94 ff 92 47 4f 17 03 01 00 20 cd 19 d2 cd 7d 7d |...GO.... ....}}| +00000030 3b a1 65 ee 4e a2 f2 02 55 02 28 54 28 92 c9 ec |;.e.N...U.(T(...| +00000040 db 59 f6 7d 2f 9e 7b 66 0e be 15 03 01 00 20 4f |.Y.}/.{f...... O| +00000050 ab cd 12 5b c4 f4 03 0e 57 03 3d f5 4e 09 8b 83 |...[....W.=.N...| +00000060 8b c6 9c c7 eb 30 8c f2 43 f6 10 30 14 80 c5 |.....0..C..0...| diff --git a/testdata/Client-TLSv10-ExportKeyingMaterial b/testdata/Client-TLSv10-ExportKeyingMaterial index 8225f78..92ae092 100644 --- a/testdata/Client-TLSv10-ExportKeyingMaterial +++ b/testdata/Client-TLSv10-ExportKeyingMaterial @@ -7,21 +7,21 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 7f 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 0a 00 08 00 1d 00 17 00 18 00 19 00 0b 00 02 01 |................| -000000a0 00 00 0d 00 1a 00 18 08 04 04 03 08 07 08 05 08 |................| -000000b0 06 04 01 05 01 06 01 05 03 06 03 02 01 02 03 ff |................| -000000c0 01 00 01 00 00 17 00 00 00 12 00 00 00 2b 00 09 |.............+..| +00000080 01 00 00 7f 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 19 00 0d |................| +000000b0 00 1a 00 18 08 04 04 03 08 07 08 05 08 06 04 01 |................| +000000c0 05 01 06 01 05 03 06 03 02 01 02 03 00 2b 00 09 |.............+..| 000000d0 08 03 04 03 03 03 02 03 01 00 33 00 26 00 24 00 |..........3.&.$.| 000000e0 1d 00 20 2f e5 7d a3 47 cd 62 43 15 28 da ac 5f |.. /.}.G.bC.(.._| 000000f0 bb 29 07 30 ff f6 84 af c4 cf c2 ed 90 99 5f 58 |.).0.........._X| 00000100 cb 3b 74 |.;t| >>> Flow 2 (server to client) -00000000 16 03 01 00 5d 02 00 00 59 03 01 b7 20 c3 67 7b |....]...Y... .g{| -00000010 94 6e d7 da ea e0 77 4e 05 ad e0 9b a2 97 59 e3 |.n....wN......Y.| -00000020 de 61 a2 49 d0 2f 27 7d fc 7c 4e 20 9a 18 52 f9 |.a.I./'}.|N ..R.| -00000030 bf ec 13 7d 28 1a 44 14 ea 77 25 7a 30 81 36 1e |...}(.D..w%z0.6.| -00000040 18 b3 23 37 79 dc 10 e8 f2 18 90 c7 c0 13 00 00 |..#7y...........| +00000000 16 03 01 00 5d 02 00 00 59 03 01 6f 36 7b f5 f4 |....]...Y..o6{..| +00000010 3b 49 31 64 aa 42 a7 8c a2 4d 00 a7 9c b9 b6 9c |;I1d.B...M......| +00000020 0d 2f 09 81 e8 ab 74 77 11 fe 0b 20 e0 b9 92 4d |./....tw... ...M| +00000030 e2 70 fd 58 ec 58 02 f2 b3 44 d2 3d 7f c9 ad ca |.p.X.X...D.=....| +00000040 5c 78 fe f9 36 67 a8 b7 a8 0f 7a 1a c0 13 00 00 |\x..6g....z.....| 00000050 11 ff 01 00 01 00 00 0b 00 04 03 00 01 02 00 17 |................| 00000060 00 00 16 03 01 02 59 0b 00 02 55 00 02 52 00 02 |......Y...U..R..| 00000070 4f 30 82 02 4b 30 82 01 b4 a0 03 02 01 02 02 09 |O0..K0..........| @@ -61,36 +61,36 @@ 00000290 73 bb b3 43 77 8d 0c 1c f1 0f a1 d8 40 83 61 c9 |s..Cw.......@.a.| 000002a0 4c 72 2b 9d ae db 46 06 06 4d f4 c1 b3 3e c0 d1 |Lr+...F..M...>..| 000002b0 bd 42 d4 db fe 3d 13 60 84 5c 21 d3 3b e9 fa e7 |.B...=.`.\!.;...| -000002c0 16 03 01 00 aa 0c 00 00 a6 03 00 1d 20 99 c4 bc |............ ...| -000002d0 cb 82 39 73 e7 54 86 b6 36 ae 7a 82 4e 4a fc 6a |..9s.T..6.z.NJ.j| -000002e0 19 ed 81 7b 53 03 2f 90 92 de 2a 84 65 00 80 01 |...{S./...*.e...| -000002f0 4d 05 a7 5b ac 30 c4 47 68 1b 27 ce f9 9b bd 31 |M..[.0.Gh.'....1| -00000300 08 90 21 16 c9 20 3c 72 da e4 8b ce 6b d5 d6 47 |..!.. ukv.........Mf| +00000340 57 70 1a 4c 21 27 7f c8 69 f4 f4 83 5c 44 32 b4 |Wp.L!'..i...\D2.| +00000350 73 18 a3 c4 4a c1 71 92 04 7a 49 49 15 25 05 a0 |s...J.q..zII.%..| +00000360 61 69 f8 38 4b 9f 92 96 f4 6b 6b 4b 96 60 45 16 |ai.8K....kkK.`E.| 00000370 03 01 00 04 0e 00 00 00 |........| >>> Flow 3 (client to server) 00000000 16 03 01 00 25 10 00 00 21 20 2f e5 7d a3 47 cd |....%...! /.}.G.| 00000010 62 43 15 28 da ac 5f bb 29 07 30 ff f6 84 af c4 |bC.(.._.).0.....| 00000020 cf c2 ed 90 99 5f 58 cb 3b 74 14 03 01 00 01 01 |....._X.;t......| -00000030 16 03 01 00 30 43 fc 64 73 ed 5b eb ac 0e 09 cf |....0C.ds.[.....| -00000040 ae 3e 3c 8c 0a ab b5 a9 c0 32 ed 8d ea 71 ed 87 |.><......2...q..| -00000050 e5 ee d7 0c 9d a4 09 c6 9b 1d b2 86 2f a3 2e 77 |............/..w| -00000060 aa b2 5c 6f b0 |..\o.| +00000030 16 03 01 00 30 e2 8b e2 aa 5a 35 c5 e5 68 ce f4 |....0....Z5..h..| +00000040 fa 51 3f 7b 3e 99 2f 21 b2 c6 b2 70 74 af ae ca |.Q?{>./!...pt...| +00000050 36 86 78 08 ea 8f 02 29 e6 a6 71 fa ad 7f c6 97 |6.x....)..q.....| +00000060 54 6f 88 a3 4b |To..K| >>> Flow 4 (server to client) -00000000 14 03 01 00 01 01 16 03 01 00 30 c5 aa 36 4d 9a |..........0..6M.| -00000010 7a e6 ea 66 2e 63 2d 69 9b b4 91 fa fc f1 f7 a5 |z..f.c-i........| -00000020 19 17 eb da d6 95 d9 95 42 09 4c 54 30 60 c9 00 |........B.LT0`..| -00000030 d4 a1 9e 25 dd 62 f0 33 29 43 9c |...%.b.3)C.| +00000000 14 03 01 00 01 01 16 03 01 00 30 af 26 01 47 8a |..........0.&.G.| +00000010 a3 08 b2 79 1c fe fa 91 e8 4b a6 e1 ad 8e 59 b7 |...y.....K....Y.| +00000020 ea 41 ee 3e 3a aa 2f f2 07 9e 0d 90 3d 6f 92 d5 |.A.>:./.....=o..| +00000030 72 92 ad ae ee c8 5d 48 a0 25 46 |r.....]H.%F| >>> Flow 5 (client to server) -00000000 17 03 01 00 20 44 84 33 58 99 c7 71 39 e6 fa 89 |.... D.3X..q9...| -00000010 f9 a2 bd 15 9a 41 2f e7 27 1a 33 e9 89 ce 24 4c |.....A/.'.3...$L| -00000020 db cf c6 11 15 17 03 01 00 20 e5 5a 7b 6b ea 19 |......... .Z{k..| -00000030 f1 55 77 54 b6 a0 c0 c6 02 d6 ce 49 b6 93 91 d3 |.UwT.......I....| -00000040 7f 8a 93 d1 73 8d d6 f6 56 b6 15 03 01 00 20 71 |....s...V..... q| -00000050 26 23 0c 06 c6 08 13 2d f3 b2 c0 91 f3 11 c4 23 |&#.....-.......#| -00000060 c3 57 79 eb ff 8b e1 81 12 fb 13 02 26 b1 5b |.Wy.........&.[| +00000000 17 03 01 00 20 29 2b 6a 75 2b 1b 94 f4 cb 80 14 |.... )+ju+......| +00000010 16 91 ec 08 77 5a 08 45 e7 51 2e a2 ec 03 f0 ca |....wZ.E.Q......| +00000020 35 88 20 3a 2e 17 03 01 00 20 59 0c 48 6f 66 8e |5. :..... Y.Hof.| +00000030 88 62 90 cc 33 39 62 ce 96 28 d0 2f 40 6e ed 14 |.b..39b..(./@n..| +00000040 94 72 88 d8 4a cb 73 24 a9 01 15 03 01 00 20 5c |.r..J.s$...... \| +00000050 8a 91 45 ed c9 38 e7 1d 71 02 b8 30 bf 24 0e 30 |..E..8..q..0.$.0| +00000060 6d fa 0a 4a 39 9f 56 b2 04 99 3e 67 bd bc d9 |m..J9.V...>g...| diff --git a/testdata/Client-TLSv10-RSA-RC4 b/testdata/Client-TLSv10-RSA-RC4 index 219462a..8fce559 100644 --- a/testdata/Client-TLSv10-RSA-RC4 +++ b/testdata/Client-TLSv10-RSA-RC4 @@ -7,21 +7,21 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 7f 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 0a 00 08 00 1d 00 17 00 18 00 19 00 0b 00 02 01 |................| -000000a0 00 00 0d 00 1a 00 18 08 04 04 03 08 07 08 05 08 |................| -000000b0 06 04 01 05 01 06 01 05 03 06 03 02 01 02 03 ff |................| -000000c0 01 00 01 00 00 17 00 00 00 12 00 00 00 2b 00 09 |.............+..| +00000080 01 00 00 7f 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 19 00 0d |................| +000000b0 00 1a 00 18 08 04 04 03 08 07 08 05 08 06 04 01 |................| +000000c0 05 01 06 01 05 03 06 03 02 01 02 03 00 2b 00 09 |.............+..| 000000d0 08 03 04 03 03 03 02 03 01 00 33 00 26 00 24 00 |..........3.&.$.| 000000e0 1d 00 20 2f e5 7d a3 47 cd 62 43 15 28 da ac 5f |.. /.}.G.bC.(.._| 000000f0 bb 29 07 30 ff f6 84 af c4 cf c2 ed 90 99 5f 58 |.).0.........._X| 00000100 cb 3b 74 |.;t| >>> Flow 2 (server to client) -00000000 16 03 01 00 55 02 00 00 51 03 01 73 52 96 88 0a |....U...Q..sR...| -00000010 35 f9 ca 22 44 32 ec 69 08 b1 4d b3 6b 70 18 92 |5.."D2.i..M.kp..| -00000020 af 91 bf 82 00 be 1d bf b4 2f 00 20 f3 e2 c8 e0 |........./. ....| -00000030 5f 1a 7f 0c 69 f4 6b 74 44 39 b1 2a b9 33 8f 32 |_...i.ktD9.*.3.2| -00000040 50 37 63 15 69 bc 45 d3 db a7 28 09 00 05 00 00 |P7c.i.E...(.....| +00000000 16 03 01 00 55 02 00 00 51 03 01 9b 6a cd e3 08 |....U...Q...j...| +00000010 29 e7 32 d1 53 14 f5 4a cf b7 61 1a 90 d6 9a 73 |).2.S..J..a....s| +00000020 ad 48 2a 08 ce d7 d7 cb f8 25 b1 20 c1 24 61 85 |.H*......%. .$a.| +00000030 31 d2 81 5e 8e c8 31 40 56 36 79 af bb f7 90 d3 |1..^..1@V6y.....| +00000040 06 5e 4b 5a 62 50 c0 d5 89 7f 35 70 00 05 00 00 |.^KZbP....5p....| 00000050 09 ff 01 00 01 00 00 17 00 00 16 03 01 02 59 0b |..............Y.| 00000060 00 02 55 00 02 52 00 02 4f 30 82 02 4b 30 82 01 |..U..R..O0..K0..| 00000070 b4 a0 03 02 01 02 02 09 00 e8 f0 9d 3f e2 5b ea |............?.[.| @@ -72,15 +72,15 @@ 00000060 c5 70 0f 08 83 48 e9 48 ef 6e 50 8b 05 7e e5 84 |.p...H.H.nP..~..| 00000070 25 fa 55 c7 ae 31 02 27 00 ef 3f 98 86 20 12 89 |%.U..1.'..?.. ..| 00000080 91 59 28 b4 f7 d7 af d2 69 61 35 14 03 01 00 01 |.Y(.....ia5.....| -00000090 01 16 03 01 00 24 bd d6 29 83 bf 42 06 cf 06 86 |.....$..)..B....| -000000a0 09 8a 2f 4c 72 d3 98 45 6b 24 2f 58 da 45 a3 9d |../Lr..Ek$/X.E..| -000000b0 86 7b e0 5e 8f 52 6c ee 97 1a |.{.^.Rl...| +00000090 01 16 03 01 00 24 b3 7b e6 d1 8f 79 04 e2 42 0f |.....$.{...y..B.| +000000a0 61 de d2 be 1e 4d 8f d4 6f 7e 2d 59 cf 23 ff 1e |a....M..o~-Y.#..| +000000b0 74 ea 2a 9c 7e e2 5b 23 05 2e |t.*.~.[#..| >>> Flow 4 (server to client) -00000000 14 03 01 00 01 01 16 03 01 00 24 b2 c6 b8 54 c9 |..........$...T.| -00000010 8b 16 cb d4 40 54 08 a4 39 f9 88 37 2e d7 e2 f4 |....@T..9..7....| -00000020 17 26 ec 00 0b d3 36 42 2f 7b 6d 3f 10 e0 6d |.&....6B/{m?..m| +00000000 14 03 01 00 01 01 16 03 01 00 24 3c 4e 68 82 8f |..........$>> Flow 5 (client to server) -00000000 17 03 01 00 1a 75 40 46 0c 9d 5a 40 b9 b8 7c fa |.....u@F..Z@..|.| -00000010 a3 bf ff 37 2b 30 72 cc a6 5c 8d c9 8a d6 64 15 |...7+0r..\....d.| -00000020 03 01 00 16 f4 f1 6d 64 0a 21 35 dc c9 de b5 c4 |......md.!5.....| -00000030 d7 2c 0a 6e 2a e5 90 21 20 cf |.,.n*..! .| +00000000 17 03 01 00 1a e0 a4 39 3c 9c 5c 8e 60 db 8e 5c |.......9<.\.`..\| +00000010 13 aa 60 4a 1c f0 71 1b f2 4d a9 f8 52 07 bd 15 |..`J..q..M..R...| +00000020 03 01 00 16 9e f3 0a 66 42 77 5a 75 74 18 85 f1 |.......fBwZut...| +00000030 3c fb ea d4 b8 76 6d eb 48 3d |<....vm.H=| diff --git a/testdata/Client-TLSv11-ECDHE-ECDSA-AES b/testdata/Client-TLSv11-ECDHE-ECDSA-AES index cc9dd82..0ad2db0 100644 --- a/testdata/Client-TLSv11-ECDHE-ECDSA-AES +++ b/testdata/Client-TLSv11-ECDHE-ECDSA-AES @@ -7,21 +7,21 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 7f 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 0a 00 08 00 1d 00 17 00 18 00 19 00 0b 00 02 01 |................| -000000a0 00 00 0d 00 1a 00 18 08 04 04 03 08 07 08 05 08 |................| -000000b0 06 04 01 05 01 06 01 05 03 06 03 02 01 02 03 ff |................| -000000c0 01 00 01 00 00 17 00 00 00 12 00 00 00 2b 00 09 |.............+..| +00000080 01 00 00 7f 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 19 00 0d |................| +000000b0 00 1a 00 18 08 04 04 03 08 07 08 05 08 06 04 01 |................| +000000c0 05 01 06 01 05 03 06 03 02 01 02 03 00 2b 00 09 |.............+..| 000000d0 08 03 04 03 03 03 02 03 01 00 33 00 26 00 24 00 |..........3.&.$.| 000000e0 1d 00 20 2f e5 7d a3 47 cd 62 43 15 28 da ac 5f |.. /.}.G.bC.(.._| 000000f0 bb 29 07 30 ff f6 84 af c4 cf c2 ed 90 99 5f 58 |.).0.........._X| 00000100 cb 3b 74 |.;t| >>> Flow 2 (server to client) -00000000 16 03 02 00 5d 02 00 00 59 03 02 7f 08 c0 d7 77 |....]...Y......w| -00000010 20 72 4a f2 a2 2c 41 99 b0 3e 9f c8 9d ff 9b b5 | rJ..,A..>......| -00000020 ea 99 73 91 7b 81 51 e2 1a 7e 9b 20 5d 47 a5 63 |..s.{.Q..~. ]G.c| -00000030 86 cb fe bf 40 8e f9 f8 1c cf 4b cf 8b f2 af 56 |....@.....K....V| -00000040 94 a3 71 ad 53 ab 30 71 2a 07 f3 a0 c0 09 00 00 |..q.S.0q*.......| +00000000 16 03 02 00 5d 02 00 00 59 03 02 51 70 ac 24 75 |....]...Y..Qp.$u| +00000010 53 94 02 c6 20 8e 22 0d b2 79 30 3b ee a1 00 44 |S... ."..y0;...D| +00000020 f3 1c b8 a3 4c 51 c4 d9 30 95 d4 20 ca 82 67 4f |....LQ..0.. ..gO| +00000030 8c 13 5f c2 7e fc e0 0c 04 5c e2 9a c2 a3 02 a1 |.._.~....\......| +00000040 bc fa ca 16 38 83 2e 5a c1 75 19 67 c0 09 00 00 |....8..Z.u.g....| 00000050 11 ff 01 00 01 00 00 0b 00 04 03 00 01 02 00 17 |................| 00000060 00 00 16 03 02 02 0e 0b 00 02 0a 00 02 07 00 02 |................| 00000070 04 30 82 02 00 30 82 01 62 02 09 00 b8 bf 2d 47 |.0...0..b.....-G| @@ -57,38 +57,38 @@ 00000250 c9 86 2e dd d7 11 69 7f 85 7c 56 de fb 31 78 2b |......i..|V..1x+| 00000260 e4 c7 78 0d ae cb be 9e 4e 36 24 31 7b 6a 0f 39 |..x.....N6$1{j.9| 00000270 95 12 07 8f 2a 16 03 02 00 b5 0c 00 00 b1 03 00 |....*...........| -00000280 1d 20 23 be e0 2b 65 34 a4 91 3c 4e 3c 84 51 98 |. #..+e4...U..sM~uKs.M| -00000300 62 de 29 b8 0e 59 68 0a 14 a5 75 31 4f 9d db 64 |b.)..Yh...u1O..d| -00000310 d0 b4 f4 78 ae 30 99 2f fb 33 ea 1a 21 46 33 57 |...x.0./.3..!F3W| -00000320 59 00 5d 84 4b b3 fe a1 60 3d ae 71 af b9 ea 16 |Y.].K...`=.q....| +00000280 1d 20 4a 31 cd 48 ea 05 09 8a 6d 78 c5 46 5d ea |. J1.H....mx.F].| +00000290 fb aa 62 79 17 70 31 5e 5a 95 c1 ce a9 52 3e 8e |..by.p1^Z....R>.| +000002a0 a1 7b 00 8b 30 81 88 02 42 01 e1 c6 99 40 d7 9f |.{..0...B....@..| +000002b0 15 41 f4 4f 54 5f 5d 14 bd a6 cc 18 6e 67 98 ab |.A.OT_].....ng..| +000002c0 6a 33 9d 54 68 94 2a 89 22 66 2d 20 97 e7 53 c9 |j3.Th.*."f- ..S.| +000002d0 f8 ee ad 64 46 6e 53 1d d6 57 55 6a 4c bc 37 1f |...dFnS..WUjL.7.| +000002e0 e7 9c c4 bb 23 cb af 27 2a 19 94 02 42 01 35 b4 |....#..'*...B.5.| +000002f0 a1 f0 c2 6d 34 f0 05 a7 25 9a 22 6c 3e 41 e7 a0 |...m4...%."l>A..| +00000300 1e 8f 5a 28 b1 5a 88 46 48 7e 40 93 f2 38 9d 33 |..Z(.Z.FH~@..8.3| +00000310 6b b5 92 ed 6d 44 07 03 c8 77 ee 3a 80 37 1e f9 |k...mD...w.:.7..| +00000320 4d 5c 2b 6d c5 15 07 b2 7c eb c5 f5 c5 14 dd 16 |M\+m....|.......| 00000330 03 02 00 04 0e 00 00 00 |........| >>> Flow 3 (client to server) 00000000 16 03 02 00 25 10 00 00 21 20 2f e5 7d a3 47 cd |....%...! /.}.G.| 00000010 62 43 15 28 da ac 5f bb 29 07 30 ff f6 84 af c4 |bC.(.._.).0.....| 00000020 cf c2 ed 90 99 5f 58 cb 3b 74 14 03 02 00 01 01 |....._X.;t......| 00000030 16 03 02 00 40 00 00 00 00 00 00 00 00 00 00 00 |....@...........| -00000040 00 00 00 00 00 ef 00 72 e6 a4 f6 8b 7f 98 ef e0 |.......r........| -00000050 15 01 2c fc 31 7a e7 ba fa 07 ec 0e c1 4b 69 39 |..,.1z.......Ki9| -00000060 89 97 fa a8 8b bf 3b 7f 1a 00 32 26 72 64 19 1c |......;...2&rd..| -00000070 0c 2f 4b ba 78 |./K.x| +00000040 00 00 00 00 00 40 aa 15 c7 e0 2e f6 9e e8 aa 92 |.....@..........| +00000050 81 6d 83 8f 13 7e 7c d5 9f b9 bf ca 5d da fd 3c |.m...~|.....]..<| +00000060 ba c7 8e 8e 9a 93 86 21 49 15 04 9d b8 75 c1 fe |.......!I....u..| +00000070 5b a6 41 d5 46 |[.A.F| >>> Flow 4 (server to client) -00000000 14 03 02 00 01 01 16 03 02 00 40 d7 89 58 0a f0 |..........@..X..| -00000010 bd c1 a0 bb b5 f0 b4 1a 0b 08 25 e8 5a 73 04 04 |..........%.Zs..| -00000020 01 99 65 e1 9c 80 24 e5 80 a8 a8 a1 29 bd af 99 |..e...$.....)...| -00000030 06 4d 9a 48 59 95 0a 0e bc 72 7d 90 cb 62 5a 2d |.M.HY....r}..bZ-| -00000040 7b 19 53 83 10 47 55 8b c3 e0 84 |{.S..GU....| +00000000 14 03 02 00 01 01 16 03 02 00 40 ba a7 6d aa 40 |..........@..m.@| +00000010 b5 94 f8 d6 84 38 7c 19 7f b9 e9 8b 0f a8 db 4c |.....8|........L| +00000020 68 cf 1e d4 e0 b2 7c 78 80 76 18 c7 a5 cf 57 2d |h.....|x.v....W-| +00000030 1e 3d 17 b2 ce 44 93 76 38 91 4b d0 7f 09 00 2f |.=...D.v8.K..../| +00000040 c2 da c7 32 70 de fd cb a4 99 90 |...2p......| >>> Flow 5 (client to server) 00000000 17 03 02 00 30 00 00 00 00 00 00 00 00 00 00 00 |....0...........| -00000010 00 00 00 00 00 5d d8 f2 5e 83 a1 39 cb 57 a9 7f |.....]..^..9.W..| -00000020 93 35 72 a3 ce 15 f6 4c 5c 06 8f d1 f5 77 7c ca |.5r....L\....w|.| -00000030 a9 59 5f e9 ce 15 03 02 00 30 00 00 00 00 00 00 |.Y_......0......| -00000040 00 00 00 00 00 00 00 00 00 00 2b 0a 90 aa 87 8f |..........+.....| -00000050 ff 26 85 22 26 26 bd 0e a3 40 88 e1 72 21 76 69 |.&."&&...@..r!vi| -00000060 4c 69 22 2c 6c 72 a3 64 6e 61 |Li",lr.dna| +00000010 00 00 00 00 00 86 40 c2 e7 d4 56 43 6b e0 e4 96 |......@...VCk...| +00000020 41 74 2e b1 65 cd c6 93 06 71 f0 25 20 21 c5 1b |At..e....q.% !..| +00000030 d2 ea eb e4 06 15 03 02 00 30 00 00 00 00 00 00 |.........0......| +00000040 00 00 00 00 00 00 00 00 00 00 1e a9 c0 dc d8 23 |...............#| +00000050 f2 08 b0 c5 b2 2e 53 9b 23 50 8a 02 c6 41 9a 36 |......S.#P...A.6| +00000060 59 b1 23 d9 5e 91 45 cf 1b a1 |Y.#.^.E...| diff --git a/testdata/Client-TLSv11-ECDHE-RSA-AES b/testdata/Client-TLSv11-ECDHE-RSA-AES index 5bde683..83c7d77 100644 --- a/testdata/Client-TLSv11-ECDHE-RSA-AES +++ b/testdata/Client-TLSv11-ECDHE-RSA-AES @@ -7,21 +7,21 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 7f 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 0a 00 08 00 1d 00 17 00 18 00 19 00 0b 00 02 01 |................| -000000a0 00 00 0d 00 1a 00 18 08 04 04 03 08 07 08 05 08 |................| -000000b0 06 04 01 05 01 06 01 05 03 06 03 02 01 02 03 ff |................| -000000c0 01 00 01 00 00 17 00 00 00 12 00 00 00 2b 00 09 |.............+..| +00000080 01 00 00 7f 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 19 00 0d |................| +000000b0 00 1a 00 18 08 04 04 03 08 07 08 05 08 06 04 01 |................| +000000c0 05 01 06 01 05 03 06 03 02 01 02 03 00 2b 00 09 |.............+..| 000000d0 08 03 04 03 03 03 02 03 01 00 33 00 26 00 24 00 |..........3.&.$.| 000000e0 1d 00 20 2f e5 7d a3 47 cd 62 43 15 28 da ac 5f |.. /.}.G.bC.(.._| 000000f0 bb 29 07 30 ff f6 84 af c4 cf c2 ed 90 99 5f 58 |.).0.........._X| 00000100 cb 3b 74 |.;t| >>> Flow 2 (server to client) -00000000 16 03 02 00 5d 02 00 00 59 03 02 a4 97 26 eb 45 |....]...Y....&.E| -00000010 35 28 1a 9a 6b 3e b3 e6 c0 9f 4a c7 6f 57 70 9a |5(..k>....J.oWp.| -00000020 fe 3a 1a a5 c3 05 d3 50 45 43 ee 20 3e 34 5b ef |.:.....PEC. >4[.| -00000030 64 f3 f8 40 e4 69 7d 3a 46 db 4e 83 6c ff 68 2a |d..@.i}:F.N.l.h*| -00000040 f9 f4 45 5e 7c 25 5f a0 d5 89 7e 83 c0 13 00 00 |..E^|%_...~.....| +00000000 16 03 02 00 5d 02 00 00 59 03 02 79 2f de f0 f3 |....]...Y..y/...| +00000010 97 6a 5e e3 07 66 d9 f2 8b e9 be 1a 97 9f 6d c8 |.j^..f........m.| +00000020 9d b5 88 57 fc 8c 5d 7f d7 3e 34 20 e5 4c 51 33 |...W..]..>4 .LQ3| +00000030 52 23 a0 52 77 ca 41 4a 1b e4 22 fb 1c 82 f8 e4 |R#.Rw.AJ..".....| +00000040 aa 13 c2 1a ce cd d5 42 de b0 e9 10 c0 13 00 00 |.......B........| 00000050 11 ff 01 00 01 00 00 0b 00 04 03 00 01 02 00 17 |................| 00000060 00 00 16 03 02 02 59 0b 00 02 55 00 02 52 00 02 |......Y...U..R..| 00000070 4f 30 82 02 4b 30 82 01 b4 a0 03 02 01 02 02 09 |O0..K0..........| @@ -61,38 +61,38 @@ 00000290 73 bb b3 43 77 8d 0c 1c f1 0f a1 d8 40 83 61 c9 |s..Cw.......@.a.| 000002a0 4c 72 2b 9d ae db 46 06 06 4d f4 c1 b3 3e c0 d1 |Lr+...F..M...>..| 000002b0 bd 42 d4 db fe 3d 13 60 84 5c 21 d3 3b e9 fa e7 |.B...=.`.\!.;...| -000002c0 16 03 02 00 aa 0c 00 00 a6 03 00 1d 20 46 15 e3 |............ F..| -000002d0 8f f8 ab 26 88 9c 0f 28 30 d6 58 96 77 55 77 62 |...&...(0.X.wUwb| -000002e0 26 a1 64 98 df b3 cc 15 48 fc 90 2b 30 00 80 7d |&.d.....H..+0..}| -000002f0 e3 98 42 4a 27 c1 08 29 93 22 0e 7e 53 4e b7 03 |..BJ'..).".~SN..| -00000300 ca c1 67 34 0e 8d c0 94 cb dd 38 34 f4 d8 0e 10 |..g4......84....| -00000310 68 bb e7 01 3e 4b 22 27 bb 43 e2 cf da e2 6c 49 |h...>K"'.C....lI| -00000320 d7 31 2f 31 04 b2 7a 8f 86 35 5e f8 16 3f 80 b7 |.1/1..z..5^..?..| -00000330 1e 06 e1 3e 57 89 24 d7 25 65 8b 13 84 27 b6 eb |...>W.$.%e...'..| -00000340 e9 64 bd 69 22 17 bc 53 57 2c 78 b3 1d 01 97 65 |.d.i"..SW,x....e| -00000350 d9 0e b7 a7 bf d3 86 d3 a4 24 07 0f 16 0f fb 3a |.........$.....:| -00000360 e8 35 ce 80 79 93 2f 26 75 36 fa ad 99 d3 88 16 |.5..y./&u6......| +000002c0 16 03 02 00 aa 0c 00 00 a6 03 00 1d 20 ef 2a b0 |............ .*.| +000002d0 da 99 1f 17 dc 29 38 43 c2 72 18 b6 ea ad 8f e6 |.....)8C.r......| +000002e0 f2 d2 81 e5 f6 2e 6c 5a 95 89 10 14 34 00 80 11 |......lZ....4...| +000002f0 ff 56 fa 9e 9f 0c b9 a9 57 c4 2c cb a1 ce 70 ca |.V......W.,...p.| +00000300 94 bd 5e 54 0e eb da ce 1b 19 ee bc aa bb 9c 10 |..^T............| +00000310 f8 6e 59 48 82 5e fe 3c 2e 28 6d 8a 2f 08 ce df |.nYH.^.<.(m./...| +00000320 52 e2 07 a6 68 68 69 fc 2b d7 fd 28 ef 48 85 c9 |R...hhi.+..(.H..| +00000330 70 75 b4 f4 04 2f 39 69 ee 1a aa 14 c9 7b e0 f7 |pu.../9i.....{..| +00000340 bc 50 76 df 24 57 8b a4 ca 87 8a b5 ff c9 13 9e |.Pv.$W..........| +00000350 d3 9e 2b e1 d4 6f 0c ce 61 83 e9 38 51 04 2e 23 |..+..o..a..8Q..#| +00000360 b4 f8 90 f4 0f 45 93 34 14 f4 ca 4f 13 02 89 16 |.....E.4...O....| 00000370 03 02 00 04 0e 00 00 00 |........| >>> Flow 3 (client to server) 00000000 16 03 02 00 25 10 00 00 21 20 2f e5 7d a3 47 cd |....%...! /.}.G.| 00000010 62 43 15 28 da ac 5f bb 29 07 30 ff f6 84 af c4 |bC.(.._.).0.....| 00000020 cf c2 ed 90 99 5f 58 cb 3b 74 14 03 02 00 01 01 |....._X.;t......| 00000030 16 03 02 00 40 00 00 00 00 00 00 00 00 00 00 00 |....@...........| -00000040 00 00 00 00 00 89 35 3f 26 26 9c d0 87 70 65 56 |......5?&&...peV| -00000050 b4 32 f9 9e 3f 1f 20 6f 8d 71 eb 6c 45 15 a0 f4 |.2..?. o.q.lE...| -00000060 ff 02 60 8c 01 1a b7 2b 0d 1e 56 e7 be 06 ac 16 |..`....+..V.....| -00000070 74 73 be 0a 95 |ts...| +00000040 00 00 00 00 00 34 fa 43 0a 6f 38 d0 80 5d a1 d6 |.....4.C.o8..]..| +00000050 61 c9 62 a9 b2 14 88 b4 7d b9 dc 20 93 11 27 37 |a.b.....}.. ..'7| +00000060 5a 2a 5b d4 10 54 75 23 8d 39 4a 5b 51 80 48 f2 |Z*[..Tu#.9J[Q.H.| +00000070 16 64 e5 90 38 |.d..8| >>> Flow 4 (server to client) -00000000 14 03 02 00 01 01 16 03 02 00 40 04 35 19 05 8e |..........@.5...| -00000010 c6 68 3e 37 75 5f 5d bb 41 58 8b a7 b3 cf 97 28 |.h>7u_].AX.....(| -00000020 60 ad b7 be db b1 31 b9 9c f5 d2 57 49 17 7c f6 |`.....1....WI.|.| -00000030 de 60 24 87 cb c5 51 2d 7a 8d f1 4b e5 7f 2d c7 |.`$...Q-z..K..-.| -00000040 7f f4 e1 94 d9 6f 5c 2a 68 f0 24 |.....o\*h.$| +00000000 14 03 02 00 01 01 16 03 02 00 40 f8 77 bf c0 dd |..........@.w...| +00000010 11 e1 3f 90 e0 1a c0 dc a6 6a b2 81 9b 1b 63 bc |..?......j....c.| +00000020 42 b6 23 b2 1f 95 36 38 56 f8 a4 e4 c1 c9 6f d2 |B.#...68V.....o.| +00000030 64 16 13 16 b7 25 53 ec a1 c2 94 de 8d ae 38 b9 |d....%S.......8.| +00000040 07 29 42 1d 16 3d fb 29 8b 76 15 |.)B..=.).v.| >>> Flow 5 (client to server) 00000000 17 03 02 00 30 00 00 00 00 00 00 00 00 00 00 00 |....0...........| -00000010 00 00 00 00 00 a2 ba 70 25 b0 a9 b0 ea 87 7e 6b |.......p%.....~k| -00000020 ef 89 e3 10 f4 98 da 12 cf bc 20 f6 18 76 c7 ad |.......... ..v..| -00000030 b7 12 1e 7b 12 15 03 02 00 30 00 00 00 00 00 00 |...{.....0......| -00000040 00 00 00 00 00 00 00 00 00 00 91 33 9b b8 76 89 |...........3..v.| -00000050 39 ef 4b 3f d1 09 40 e4 68 6f 30 35 d9 a9 82 c1 |9.K?..@.ho05....| -00000060 9d c6 c2 a5 dc cb 1d 43 83 0a |.......C..| +00000010 00 00 00 00 00 59 ac 45 2f 3f 3b d3 5d 73 08 85 |.....Y.E/?;.]s..| +00000020 9a 0e 99 a2 ad 8d 4e de 52 e9 5b 8b 76 71 5d 5e |......N.R.[.vq]^| +00000030 6b ec 05 24 a5 15 03 02 00 30 00 00 00 00 00 00 |k..$.....0......| +00000040 00 00 00 00 00 00 00 00 00 00 92 ce 2d b7 15 d2 |............-...| +00000050 3b c5 42 ad aa 73 a8 e0 ac 26 d2 e7 ef c7 a9 72 |;.B..s...&.....r| +00000060 75 96 5c 8c 2d 60 6e 57 bd ef |u.\.-`nW..| diff --git a/testdata/Client-TLSv11-RSA-RC4 b/testdata/Client-TLSv11-RSA-RC4 index addd480..dd58620 100644 --- a/testdata/Client-TLSv11-RSA-RC4 +++ b/testdata/Client-TLSv11-RSA-RC4 @@ -7,21 +7,21 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 7f 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 0a 00 08 00 1d 00 17 00 18 00 19 00 0b 00 02 01 |................| -000000a0 00 00 0d 00 1a 00 18 08 04 04 03 08 07 08 05 08 |................| -000000b0 06 04 01 05 01 06 01 05 03 06 03 02 01 02 03 ff |................| -000000c0 01 00 01 00 00 17 00 00 00 12 00 00 00 2b 00 09 |.............+..| +00000080 01 00 00 7f 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 19 00 0d |................| +000000b0 00 1a 00 18 08 04 04 03 08 07 08 05 08 06 04 01 |................| +000000c0 05 01 06 01 05 03 06 03 02 01 02 03 00 2b 00 09 |.............+..| 000000d0 08 03 04 03 03 03 02 03 01 00 33 00 26 00 24 00 |..........3.&.$.| 000000e0 1d 00 20 2f e5 7d a3 47 cd 62 43 15 28 da ac 5f |.. /.}.G.bC.(.._| 000000f0 bb 29 07 30 ff f6 84 af c4 cf c2 ed 90 99 5f 58 |.).0.........._X| 00000100 cb 3b 74 |.;t| >>> Flow 2 (server to client) -00000000 16 03 02 00 55 02 00 00 51 03 02 66 66 1b 2f 55 |....U...Q..ff./U| -00000010 a4 db ad db 42 88 e0 12 12 36 60 41 32 ca 27 0f |....B....6`A2.'.| -00000020 36 22 d1 0b 4e 0e ba df 44 71 9f 20 7a fa f5 a7 |6"..N...Dq. z...| -00000030 ba ca 0a 9a be c5 b7 a8 98 a7 d9 0f d8 24 d4 cf |.............$..| -00000040 ab f5 13 84 03 45 57 ab 89 6d 43 42 00 05 00 00 |.....EW..mCB....| +00000000 16 03 02 00 55 02 00 00 51 03 02 42 bb c8 01 43 |....U...Q..B...C| +00000010 e4 f7 10 09 bf 35 a3 c2 d7 ca 60 a9 60 be 1d 00 |.....5....`.`...| +00000020 92 33 b6 3e 56 2b c2 f7 29 e3 f9 20 8c d7 b6 90 |.3.>V+..).. ....| +00000030 03 f5 8b 55 e9 81 47 5b 84 ec 19 bc 32 58 c6 30 |...U..G[....2X.0| +00000040 f1 79 ea 51 a2 18 cc c0 4e 8a 8e cb 00 05 00 00 |.y.Q....N.......| 00000050 09 ff 01 00 01 00 00 17 00 00 16 03 02 02 59 0b |..............Y.| 00000060 00 02 55 00 02 52 00 02 4f 30 82 02 4b 30 82 01 |..U..R..O0..K0..| 00000070 b4 a0 03 02 01 02 02 09 00 e8 f0 9d 3f e2 5b ea |............?.[.| @@ -72,15 +72,15 @@ 00000060 c5 70 0f 08 83 48 e9 48 ef 6e 50 8b 05 7e e5 84 |.p...H.H.nP..~..| 00000070 25 fa 55 c7 ae 31 02 27 00 ef 3f 98 86 20 12 89 |%.U..1.'..?.. ..| 00000080 91 59 28 b4 f7 d7 af d2 69 61 35 14 03 02 00 01 |.Y(.....ia5.....| -00000090 01 16 03 02 00 24 a9 03 2f 22 ef b7 e8 78 38 a9 |.....$../"...x8.| -000000a0 12 07 27 e3 bf 3b a9 50 5a 83 9c 6b 83 06 07 4d |..'..;.PZ..k...M| -000000b0 38 33 12 dc 21 aa 95 3c f0 cc |83..!..<..| +00000090 01 16 03 02 00 24 a8 40 50 90 31 50 fc 5e d8 f5 |.....$.@P.1P.^..| +000000a0 64 7a a5 62 8d ad ce 03 34 c9 ab 16 31 45 bc 8b |dz.b....4...1E..| +000000b0 26 8b fa 38 7a 2e 60 42 86 46 |&..8z.`B.F| >>> Flow 4 (server to client) -00000000 14 03 02 00 01 01 16 03 02 00 24 df db 82 41 b6 |..........$...A.| -00000010 3f 2d d5 0f d1 7e ca 3c 73 e0 31 58 ae f5 08 fd |?-...~.>> Flow 5 (client to server) -00000000 17 03 02 00 1a b6 12 91 b4 74 7f 92 b5 fd 7e 8c |.........t....~.| -00000010 15 1d 51 f9 e1 a3 d6 74 6e b2 07 c2 f0 a8 11 15 |..Q....tn.......| -00000020 03 02 00 16 ca 4b cb cf 88 2d 48 a7 27 29 19 ef |.....K...-H.')..| -00000030 eb 4e 58 ac 57 e2 ed af e2 a0 |.NX.W.....| +00000000 17 03 02 00 1a f9 9f c2 32 02 96 87 95 4b ba 17 |........2....K..| +00000010 1f b9 af fe 6a 87 38 d4 d8 b4 f8 1d ad 05 00 15 |....j.8.........| +00000020 03 02 00 16 54 07 15 34 f4 c3 a2 3e 01 9e 00 cb |....T..4...>....| +00000030 83 f7 58 79 e2 dc a4 b8 15 e9 |..Xy......| diff --git a/testdata/Client-TLSv12-AES128-GCM-SHA256 b/testdata/Client-TLSv12-AES128-GCM-SHA256 index 22cff45..d88acc9 100644 --- a/testdata/Client-TLSv12-AES128-GCM-SHA256 +++ b/testdata/Client-TLSv12-AES128-GCM-SHA256 @@ -7,21 +7,21 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 7f 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 0a 00 08 00 1d 00 17 00 18 00 19 00 0b 00 02 01 |................| -000000a0 00 00 0d 00 1a 00 18 08 04 04 03 08 07 08 05 08 |................| -000000b0 06 04 01 05 01 06 01 05 03 06 03 02 01 02 03 ff |................| -000000c0 01 00 01 00 00 17 00 00 00 12 00 00 00 2b 00 09 |.............+..| +00000080 01 00 00 7f 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 19 00 0d |................| +000000b0 00 1a 00 18 08 04 04 03 08 07 08 05 08 06 04 01 |................| +000000c0 05 01 06 01 05 03 06 03 02 01 02 03 00 2b 00 09 |.............+..| 000000d0 08 03 04 03 03 03 02 03 01 00 33 00 26 00 24 00 |..........3.&.$.| 000000e0 1d 00 20 2f e5 7d a3 47 cd 62 43 15 28 da ac 5f |.. /.}.G.bC.(.._| 000000f0 bb 29 07 30 ff f6 84 af c4 cf c2 ed 90 99 5f 58 |.).0.........._X| 00000100 cb 3b 74 |.;t| >>> Flow 2 (server to client) -00000000 16 03 03 00 55 02 00 00 51 03 03 9f d7 f5 00 f6 |....U...Q.......| -00000010 a1 c5 37 e8 2b 2e 66 42 54 c6 67 29 b6 ad bb 5f |..7.+.fBT.g)..._| -00000020 23 b7 bb 56 2e 8a 15 a9 7a ce a2 20 47 be 36 13 |#..V....z.. G.6.| -00000030 31 d7 51 a6 ec d1 67 e7 e3 8c fb e2 f5 d2 61 e6 |1.Q...g.......a.| -00000040 4e 11 0c 03 b0 5e b1 ae e7 8c 61 c8 00 9c 00 00 |N....^....a.....| +00000000 16 03 03 00 55 02 00 00 51 03 03 d1 5c 30 66 38 |....U...Q...\0f8| +00000010 84 89 85 fe b6 87 de 62 8e b5 86 18 16 f7 8f b0 |.......b........| +00000020 f2 00 09 e5 55 d7 10 a0 76 d8 58 20 23 7d ff 5f |....U...v.X #}._| +00000030 b4 b5 5b de b9 7a f9 d1 bc 90 ff 2c 1d d7 fe ed |..[..z.....,....| +00000040 2f 6e 29 d8 08 61 0b 9d cc 7d 64 6a 00 9c 00 00 |/n)..a...}dj....| 00000050 09 ff 01 00 01 00 00 17 00 00 16 03 03 02 59 0b |..............Y.| 00000060 00 02 55 00 02 52 00 02 4f 30 82 02 4b 30 82 01 |..U..R..O0..K0..| 00000070 b4 a0 03 02 01 02 02 09 00 e8 f0 9d 3f e2 5b ea |............?.[.| @@ -72,17 +72,17 @@ 00000060 c5 70 0f 08 83 48 e9 48 ef 6e 50 8b 05 7e e5 84 |.p...H.H.nP..~..| 00000070 25 fa 55 c7 ae 31 02 27 00 ef 3f 98 86 20 12 89 |%.U..1.'..?.. ..| 00000080 91 59 28 b4 f7 d7 af d2 69 61 35 14 03 03 00 01 |.Y(.....ia5.....| -00000090 01 16 03 03 00 28 00 00 00 00 00 00 00 00 10 d7 |.....(..........| -000000a0 17 1b 75 0d 79 ed 8d bc fb 1c c4 d6 35 44 f0 ed |..u.y.......5D..| -000000b0 ed 03 24 02 df 44 9b 70 df 4b 51 19 e6 72 |..$..D.p.KQ..r| +00000090 01 16 03 03 00 28 00 00 00 00 00 00 00 00 df b8 |.....(..........| +000000a0 35 7a 3e 44 d1 f5 6c c5 43 82 3a ac 11 c8 53 0b |5z>D..l.C.:...S.| +000000b0 a6 d3 5c f0 5b ca e8 6a c7 13 88 65 50 71 |..\.[..j...ePq| >>> Flow 4 (server to client) -00000000 14 03 03 00 01 01 16 03 03 00 28 68 9f 7c f3 ac |..........(h.|..| -00000010 31 93 86 d0 b7 0a 68 55 7a 93 00 4e c3 d6 dc 60 |1.....hUz..N...`| -00000020 d1 c5 4a 04 53 da 27 ed c1 0e 14 41 a5 27 f1 d5 |..J.S.'....A.'..| -00000030 2e 4a 43 |.JC| +00000000 14 03 03 00 01 01 16 03 03 00 28 3f 30 36 77 c6 |..........(?06w.| +00000010 6d 4f 37 2c ac f1 c2 24 9d e1 3f 0c 51 64 12 67 |mO7,...$..?.Qd.g| +00000020 83 47 ec f1 b8 02 6d 11 11 b7 ec ab 09 26 41 ff |.G....m......&A.| +00000030 e8 32 05 |.2.| >>> Flow 5 (client to server) -00000000 17 03 03 00 1e 00 00 00 00 00 00 00 01 e7 e6 3e |...............>| -00000010 e9 04 96 38 0c d4 e1 46 c6 d2 2a 1b b0 b3 11 9b |...8...F..*.....| -00000020 6d f4 81 15 03 03 00 1a 00 00 00 00 00 00 00 02 |m...............| -00000030 a3 60 58 f2 f6 60 95 f3 c4 e1 95 23 22 52 55 63 |.`X..`.....#"RUc| -00000040 b9 75 |.u| +00000000 17 03 03 00 1e 00 00 00 00 00 00 00 01 af 3a 1e |..............:.| +00000010 98 3e 74 5f 66 64 eb 6c 88 36 33 f0 98 e8 46 e9 |.>t_fd.l.63...F.| +00000020 f1 2f 32 15 03 03 00 1a 00 00 00 00 00 00 00 02 |./2.............| +00000030 76 2b 83 08 46 7d 34 58 db e8 e8 e1 e2 cb ad 1e |v+..F}4X........| +00000040 e4 a5 |..| diff --git a/testdata/Client-TLSv12-AES128-SHA256 b/testdata/Client-TLSv12-AES128-SHA256 index ee6ab62..030cbc6 100644 --- a/testdata/Client-TLSv12-AES128-SHA256 +++ b/testdata/Client-TLSv12-AES128-SHA256 @@ -7,21 +7,21 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 7f 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 0a 00 08 00 1d 00 17 00 18 00 19 00 0b 00 02 01 |................| -000000a0 00 00 0d 00 1a 00 18 08 04 04 03 08 07 08 05 08 |................| -000000b0 06 04 01 05 01 06 01 05 03 06 03 02 01 02 03 ff |................| -000000c0 01 00 01 00 00 17 00 00 00 12 00 00 00 2b 00 09 |.............+..| +00000080 01 00 00 7f 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 19 00 0d |................| +000000b0 00 1a 00 18 08 04 04 03 08 07 08 05 08 06 04 01 |................| +000000c0 05 01 06 01 05 03 06 03 02 01 02 03 00 2b 00 09 |.............+..| 000000d0 08 03 04 03 03 03 02 03 01 00 33 00 26 00 24 00 |..........3.&.$.| 000000e0 1d 00 20 2f e5 7d a3 47 cd 62 43 15 28 da ac 5f |.. /.}.G.bC.(.._| 000000f0 bb 29 07 30 ff f6 84 af c4 cf c2 ed 90 99 5f 58 |.).0.........._X| 00000100 cb 3b 74 |.;t| >>> Flow 2 (server to client) -00000000 16 03 03 00 55 02 00 00 51 03 03 b3 4d 83 66 45 |....U...Q...M.fE| -00000010 e7 32 1f e5 99 ea a0 90 c7 12 91 2b 25 82 ba ca |.2.........+%...| -00000020 01 c1 a9 22 1f 1d 06 62 e1 37 6a 20 a4 87 9b c0 |..."...b.7j ....| -00000030 7f 86 ff c1 0f 49 56 fe c4 49 f7 fb e5 97 23 dc |.....IV..I....#.| -00000040 fc 51 80 75 f7 03 52 5e 86 80 97 0f 00 3c 00 00 |.Q.u..R^.....<..| +00000000 16 03 03 00 55 02 00 00 51 03 03 bd e7 e2 ea 28 |....U...Q......(| +00000010 09 0b 7f 30 b5 91 fd b4 91 d1 c3 b8 8f 25 38 88 |...0.........%8.| +00000020 62 28 5c 1d 14 1a 6a 50 7d 30 e8 20 c3 91 2d ea |b(\...jP}0. ..-.| +00000030 59 8d 1d 56 98 c9 02 c0 f1 98 94 a6 8c 2b f2 63 |Y..V.........+.c| +00000040 ed b9 97 36 c6 c6 32 97 9e 61 6c 3b 00 3c 00 00 |...6..2..al;.<..| 00000050 09 ff 01 00 01 00 00 17 00 00 16 03 03 02 59 0b |..............Y.| 00000060 00 02 55 00 02 52 00 02 4f 30 82 02 4b 30 82 01 |..U..R..O0..K0..| 00000070 b4 a0 03 02 01 02 02 09 00 e8 f0 9d 3f e2 5b ea |............?.[.| @@ -73,25 +73,25 @@ 00000070 25 fa 55 c7 ae 31 02 27 00 ef 3f 98 86 20 12 89 |%.U..1.'..?.. ..| 00000080 91 59 28 b4 f7 d7 af d2 69 61 35 14 03 03 00 01 |.Y(.....ia5.....| 00000090 01 16 03 03 00 50 00 00 00 00 00 00 00 00 00 00 |.....P..........| -000000a0 00 00 00 00 00 00 ad 28 77 9e 77 a8 54 2d df fe |.......(w.w.T-..| -000000b0 b3 d1 3a 88 49 e8 ee 86 a1 46 d8 46 26 98 88 f3 |..:.I....F.F&...| -000000c0 eb e1 bd 26 38 26 78 53 90 47 bf 76 4b 29 a6 db |...&8&xS.G.vK)..| -000000d0 e5 c5 5d aa e7 cc d1 ad ee 3f 27 72 a3 a7 06 8b |..]......?'r....| -000000e0 1a da 35 1a 57 4a |..5.WJ| +000000a0 00 00 00 00 00 00 f3 6e c5 65 29 75 22 fe 23 6f |.......n.e)u".#o| +000000b0 96 fa b3 8d 98 ac df bf 3a 23 ca 4f d9 52 95 3f |........:#.O.R.?| +000000c0 89 8b 61 cf d2 2d f3 14 31 9d 3a 6f a9 b5 7b 69 |..a..-..1.:o..{i| +000000d0 27 a6 2b 2d 43 6e 77 f1 cd 73 fa 80 7b bf 8a 1d |'.+-Cnw..s..{...| +000000e0 83 c5 9b 8c 0a 03 |......| >>> Flow 4 (server to client) -00000000 14 03 03 00 01 01 16 03 03 00 50 b6 40 f7 ea 59 |..........P.@..Y| -00000010 29 60 1f b0 00 78 db 1b 29 4e 4f 7d 02 12 a9 f9 |)`...x..)NO}....| -00000020 98 fb 89 9e 08 8d 55 91 f3 d1 b3 58 73 ba 58 12 |......U....Xs.X.| -00000030 2e b3 3a da 3a 96 76 63 5c 89 7b d5 64 9a 41 3f |..:.:.vc\.{.d.A?| -00000040 f9 55 4c 19 d7 08 a1 b2 c4 cc f0 6a e3 7d ab 6b |.UL........j.}.k| -00000050 26 cf 80 10 a9 c6 1a d6 2d 0e 77 |&.......-.w| +00000000 14 03 03 00 01 01 16 03 03 00 50 f6 93 f3 85 25 |..........P....%| +00000010 06 5c 47 ea d5 6e 90 05 21 91 9a 86 06 42 f6 54 |.\G..n..!....B.T| +00000020 25 4a 61 65 7e 19 c8 1a 58 52 06 81 df dd 19 fc |%Jae~...XR......| +00000030 bd 5a 82 ff ae 80 92 b3 3b 7d 89 c0 64 b1 36 e3 |.Z......;}..d.6.| +00000040 5c bb 2a 5b e8 6d 18 02 43 27 b5 57 bc 3f ab b1 |\.*[.m..C'.W.?..| +00000050 27 59 0e 6a d5 07 6a 66 ad 51 82 |'Y.j..jf.Q.| >>> Flow 5 (client to server) 00000000 17 03 03 00 40 00 00 00 00 00 00 00 00 00 00 00 |....@...........| -00000010 00 00 00 00 00 04 1d bb 53 4a 08 73 26 c2 33 d5 |........SJ.s&.3.| -00000020 95 2c cf aa 74 1b 58 27 11 99 f9 67 e7 93 56 72 |.,..t.X'...g..Vr| -00000030 a5 0b 96 9e ea 32 b2 c8 c3 2e 47 b4 91 81 47 86 |.....2....G...G.| -00000040 f2 31 fd 7a f8 15 03 03 00 40 00 00 00 00 00 00 |.1.z.....@......| -00000050 00 00 00 00 00 00 00 00 00 00 55 3a e3 6d aa 75 |..........U:.m.u| -00000060 31 f5 92 6c ae f8 8d fc f4 6e 20 de a6 66 7c 97 |1..l.....n ..f|.| -00000070 51 e5 c7 8b 4a 1d 0e e8 38 f5 9f 0a 6b b6 63 c1 |Q...J...8...k.c.| -00000080 85 97 c6 3c d2 79 b5 a3 42 1d |...<.y..B.| +00000010 00 00 00 00 00 2a 8b 84 55 57 20 b8 4f 11 d2 cc |.....*..UW .O...| +00000020 5e a0 ef 1a f1 62 fc 59 38 14 30 0f e0 76 04 ca |^....b.Y8.0..v..| +00000030 eb c2 45 a4 75 12 e6 1a 16 fc d8 bd d4 f7 fd 6f |..E.u..........o| +00000040 f3 99 ca d6 41 15 03 03 00 40 00 00 00 00 00 00 |....A....@......| +00000050 00 00 00 00 00 00 00 00 00 00 8c 80 a8 e9 95 4c |...............L| +00000060 c9 fa 4d 9d 06 e5 d8 70 5f fa a9 44 24 15 f4 47 |..M....p_..D$..G| +00000070 5a 0a 24 55 a7 6a 04 1c 2a 39 80 fd 08 47 d7 08 |Z.$U.j..*9...G..| +00000080 41 8b 9d 46 74 cb 61 c6 84 84 |A..Ft.a...| diff --git a/testdata/Client-TLSv12-AES256-GCM-SHA384 b/testdata/Client-TLSv12-AES256-GCM-SHA384 index 0166f1a..42454d5 100644 --- a/testdata/Client-TLSv12-AES256-GCM-SHA384 +++ b/testdata/Client-TLSv12-AES256-GCM-SHA384 @@ -7,21 +7,21 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 7f 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 0a 00 08 00 1d 00 17 00 18 00 19 00 0b 00 02 01 |................| -000000a0 00 00 0d 00 1a 00 18 08 04 04 03 08 07 08 05 08 |................| -000000b0 06 04 01 05 01 06 01 05 03 06 03 02 01 02 03 ff |................| -000000c0 01 00 01 00 00 17 00 00 00 12 00 00 00 2b 00 09 |.............+..| +00000080 01 00 00 7f 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 19 00 0d |................| +000000b0 00 1a 00 18 08 04 04 03 08 07 08 05 08 06 04 01 |................| +000000c0 05 01 06 01 05 03 06 03 02 01 02 03 00 2b 00 09 |.............+..| 000000d0 08 03 04 03 03 03 02 03 01 00 33 00 26 00 24 00 |..........3.&.$.| 000000e0 1d 00 20 2f e5 7d a3 47 cd 62 43 15 28 da ac 5f |.. /.}.G.bC.(.._| 000000f0 bb 29 07 30 ff f6 84 af c4 cf c2 ed 90 99 5f 58 |.).0.........._X| 00000100 cb 3b 74 |.;t| >>> Flow 2 (server to client) -00000000 16 03 03 00 55 02 00 00 51 03 03 38 33 33 fb 62 |....U...Q..833.b| -00000010 ff ce 69 f1 cd 8c fe 50 05 bd 1e ce f9 ad a5 e6 |..i....P........| -00000020 ee d7 71 82 97 25 04 2a cd aa c5 20 13 68 7a d0 |..q..%.*... .hz.| -00000030 0f cc 61 05 63 31 cc 47 24 1c 52 81 8d cc d3 d1 |..a.c1.G$.R.....| -00000040 d1 53 97 70 e9 f1 98 3b 00 2d df ab 00 9d 00 00 |.S.p...;.-......| +00000000 16 03 03 00 55 02 00 00 51 03 03 a3 a8 ef 9d b3 |....U...Q.......| +00000010 36 14 00 fe 5b e4 07 77 e7 78 c8 b4 d8 96 8d 72 |6...[..w.x.....r| +00000020 c5 79 99 10 8f 6e ac e3 fd 99 ee 20 53 99 57 36 |.y...n..... S.W6| +00000030 7e 9b 89 a3 79 c7 57 c6 f6 c7 2c 66 0a 6b 48 a2 |~...y.W...,f.kH.| +00000040 06 87 54 2c 20 3d 65 b9 1c 93 fd a3 00 9d 00 00 |..T, =e.........| 00000050 09 ff 01 00 01 00 00 17 00 00 16 03 03 02 59 0b |..............Y.| 00000060 00 02 55 00 02 52 00 02 4f 30 82 02 4b 30 82 01 |..U..R..O0..K0..| 00000070 b4 a0 03 02 01 02 02 09 00 e8 f0 9d 3f e2 5b ea |............?.[.| @@ -72,17 +72,17 @@ 00000060 c5 70 0f 08 83 48 e9 48 ef 6e 50 8b 05 7e e5 84 |.p...H.H.nP..~..| 00000070 25 fa 55 c7 ae 31 02 27 00 ef 3f 98 86 20 12 89 |%.U..1.'..?.. ..| 00000080 91 59 28 b4 f7 d7 af d2 69 61 35 14 03 03 00 01 |.Y(.....ia5.....| -00000090 01 16 03 03 00 28 00 00 00 00 00 00 00 00 2b 4c |.....(........+L| -000000a0 62 77 65 ac 19 53 aa 52 8e 3d 92 5b e1 45 c6 90 |bwe..S.R.=.[.E..| -000000b0 bf 01 bb e3 9c d2 6a ed bf e6 8c 53 3d 58 |......j....S=X| +00000090 01 16 03 03 00 28 00 00 00 00 00 00 00 00 76 c9 |.....(........v.| +000000a0 1e 50 43 51 5e 4a b6 c8 98 33 8f 18 ac f3 fe 20 |.PCQ^J...3..... | +000000b0 09 76 7c 48 f7 e8 00 2c 3b e1 7e 2f 71 d5 |.v|H...,;.~/q.| >>> Flow 4 (server to client) -00000000 14 03 03 00 01 01 16 03 03 00 28 77 7f 9b a4 ea |..........(w....| -00000010 30 03 8f fd 22 37 60 78 db b1 1a 37 bc 2d 50 ad |0..."7`x...7.-P.| -00000020 40 b4 a6 8f f8 0c e8 ab 24 54 82 12 75 be 0b 8c |@.......$T..u...| -00000030 9f 35 e2 |.5.| +00000000 14 03 03 00 01 01 16 03 03 00 28 55 b2 34 a3 b7 |..........(U.4..| +00000010 18 a8 36 55 c4 ef 81 82 e4 41 9f 1a 42 2c 42 7e |..6U.....A..B,B~| +00000020 9b 59 c8 9d 3a 0b 59 a6 78 d0 ab 2f c4 e1 f7 2b |.Y..:.Y.x../...+| +00000030 9b ee 9f |...| >>> Flow 5 (client to server) -00000000 17 03 03 00 1e 00 00 00 00 00 00 00 01 01 66 69 |..............fi| -00000010 ac a4 9d 4f d2 59 01 4e d6 04 98 e5 c8 83 b3 cb |...O.Y.N........| -00000020 36 4d cf 15 03 03 00 1a 00 00 00 00 00 00 00 02 |6M..............| -00000030 17 80 89 ac 0b d6 00 8c 1d ae b2 c2 46 42 69 82 |............FBi.| -00000040 da ac |..| +00000000 17 03 03 00 1e 00 00 00 00 00 00 00 01 ec ad 42 |...............B| +00000010 8a cf 39 ed 82 b7 70 9b 1a 29 4c 3e b7 f6 92 35 |..9...p..)L>...5| +00000020 12 e2 df 15 03 03 00 1a 00 00 00 00 00 00 00 02 |................| +00000030 81 d4 de 3c 03 a9 01 0e e7 64 ae 18 84 dd d3 6c |...<.....d.....l| +00000040 57 6a |Wj| diff --git a/testdata/Client-TLSv12-ALPN b/testdata/Client-TLSv12-ALPN index 4ae1fe9..9f3f4dc 100644 --- a/testdata/Client-TLSv12-ALPN +++ b/testdata/Client-TLSv12-ALPN @@ -7,22 +7,22 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 93 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 0a 00 08 00 1d 00 17 00 18 00 19 00 0b 00 02 01 |................| -000000a0 00 00 0d 00 1a 00 18 08 04 04 03 08 07 08 05 08 |................| -000000b0 06 04 01 05 01 06 01 05 03 06 03 02 01 02 03 ff |................| -000000c0 01 00 01 00 00 17 00 00 00 10 00 10 00 0e 06 70 |...............p| -000000d0 72 6f 74 6f 32 06 70 72 6f 74 6f 31 00 12 00 00 |roto2.proto1....| +00000080 01 00 00 93 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 19 00 0d |................| +000000b0 00 1a 00 18 08 04 04 03 08 07 08 05 08 06 04 01 |................| +000000c0 05 01 06 01 05 03 06 03 02 01 02 03 00 10 00 10 |................| +000000d0 00 0e 06 70 72 6f 74 6f 32 06 70 72 6f 74 6f 31 |...proto2.proto1| 000000e0 00 2b 00 09 08 03 04 03 03 03 02 03 01 00 33 00 |.+............3.| 000000f0 26 00 24 00 1d 00 20 2f e5 7d a3 47 cd 62 43 15 |&.$... /.}.G.bC.| 00000100 28 da ac 5f bb 29 07 30 ff f6 84 af c4 cf c2 ed |(.._.).0........| 00000110 90 99 5f 58 cb 3b 74 |.._X.;t| >>> Flow 2 (server to client) -00000000 16 03 03 00 6a 02 00 00 66 03 03 a8 8a 7d 2c f6 |....j...f....},.| -00000010 d0 44 0a 7b 16 26 e5 aa 6e 4b 78 7c ff 7f 07 86 |.D.{.&..nKx|....| -00000020 48 cc 3a dd 73 95 94 d2 75 d8 87 20 6d 0b 3a a3 |H.:.s...u.. m.:.| -00000030 71 b9 50 4e c7 ad 33 04 8a 9c d8 71 48 93 ec ae |q.PN..3....qH...| -00000040 db ad 5f 79 d5 7c 65 33 37 06 73 0e cc a8 00 00 |.._y.|e37.s.....| +00000000 16 03 03 00 6a 02 00 00 66 03 03 71 ba 32 f4 08 |....j...f..q.2..| +00000010 31 23 ea 71 46 b6 f0 24 f9 80 c2 94 b8 13 f5 cc |1#.qF..$........| +00000020 6b 77 e5 46 f1 76 df a5 0c 56 6a 20 98 53 12 a3 |kw.F.v...Vj .S..| +00000030 d2 a6 97 45 36 11 e6 b6 b6 6e 0b b9 30 2d 65 c8 |...E6....n..0-e.| +00000040 47 c7 af 4c c5 a6 51 90 2f 77 db 8c cc a8 00 00 |G..L..Q./w......| 00000050 1e ff 01 00 01 00 00 0b 00 04 03 00 01 02 00 10 |................| 00000060 00 09 00 07 06 70 72 6f 74 6f 31 00 17 00 00 16 |.....proto1.....| 00000070 03 03 02 59 0b 00 02 55 00 02 52 00 02 4f 30 82 |...Y...U..R..O0.| @@ -63,31 +63,31 @@ 000002a0 43 77 8d 0c 1c f1 0f a1 d8 40 83 61 c9 4c 72 2b |Cw.......@.a.Lr+| 000002b0 9d ae db 46 06 06 4d f4 c1 b3 3e c0 d1 bd 42 d4 |...F..M...>...B.| 000002c0 db fe 3d 13 60 84 5c 21 d3 3b e9 fa e7 16 03 03 |..=.`.\!.;......| -000002d0 00 ac 0c 00 00 a8 03 00 1d 20 fe 7c 30 da b3 7e |......... .|0..~| -000002e0 b9 f5 74 9f c2 5a 3b 2e a4 c4 fe 98 50 1d 14 ea |..t..Z;.....P...| -000002f0 31 f0 ff d9 90 88 42 77 f6 18 08 04 00 80 70 97 |1.....Bw......p.| -00000300 1d e4 fb 40 de b5 9a cc 6a 63 63 86 b4 91 55 c4 |...@....jcc...U.| -00000310 ad b7 2f a2 8f 4f 28 22 86 df ec 2f 7c d2 83 b7 |../..O(".../|...| -00000320 28 9c 22 e7 73 74 51 f0 1e 20 50 d5 f1 3c 15 65 |(.".stQ.. P..<.e| -00000330 d9 cb 7f 4e 82 11 41 f8 c6 2a 23 ed b5 b4 cf 2d |...N..A..*#....-| -00000340 02 e2 8e 8b e8 88 bb 8c 63 1e 9c 37 44 c3 89 cf |........c..7D...| -00000350 ea 68 4b 81 73 0e 57 82 c9 dc ab f3 0c 63 ce f6 |.hK.s.W......c..| -00000360 c3 3a a3 da df be a7 10 4a 27 e1 bd b3 88 47 a2 |.:......J'....G.| -00000370 0d 02 03 17 3c 6c 7f 6e 04 26 75 1c a0 3e 16 03 |......| +000002d0 00 ac 0c 00 00 a8 03 00 1d 20 76 16 ff 2a 83 9a |......... v..*..| +000002e0 07 b0 01 f6 1e 3e 4b c1 69 62 9b 00 38 35 c5 4f |.....>K.ib..85.O| +000002f0 d3 2c db 50 16 9d 26 b1 cc 28 08 04 00 80 56 73 |.,.P..&..(....Vs| +00000300 39 4d ab f4 68 92 14 6d d5 75 db 10 4b 0c a4 19 |9M..h..m.u..K...| +00000310 9e 67 42 d3 f8 3f 91 26 06 4d f9 34 9b ad 7c 85 |.gB..?.&.M.4..|.| +00000320 ec 11 34 43 dd 7d a8 5b 0f 59 54 ff a3 92 dc 7c |..4C.}.[.YT....|| +00000330 26 ee 07 0e cf bc e4 6a 1a da b9 d2 9a 62 bf de |&......j.....b..| +00000340 37 a6 68 e2 cd 21 8e 4e a3 66 ee e1 74 45 7d 64 |7.h..!.N.f..tE}d| +00000350 b2 d8 1d dc 6a cd 2a 86 9e 0d 76 a3 7b f2 49 11 |....j.*...v.{.I.| +00000360 ae ad a1 d4 f2 a9 e5 56 0e 2a 96 a5 f7 8b 74 d4 |.......V.*....t.| +00000370 78 e0 bc cc 95 a1 f1 76 0b 4b 37 ed 77 1b 16 03 |x......v.K7.w...| 00000380 03 00 04 0e 00 00 00 |.......| >>> Flow 3 (client to server) 00000000 16 03 03 00 25 10 00 00 21 20 2f e5 7d a3 47 cd |....%...! /.}.G.| 00000010 62 43 15 28 da ac 5f bb 29 07 30 ff f6 84 af c4 |bC.(.._.).0.....| 00000020 cf c2 ed 90 99 5f 58 cb 3b 74 14 03 03 00 01 01 |....._X.;t......| -00000030 16 03 03 00 20 a0 68 d5 5a 22 13 42 16 b2 13 f4 |.... .h.Z".B....| -00000040 99 a1 5c f7 38 22 a1 8b e0 6b c2 7e f9 e5 a0 ef |..\.8"...k.~....| -00000050 79 ce 5a 74 d1 |y.Zt.| +00000030 16 03 03 00 20 aa 8c 9c ab fb ab ed 5b 2e 3e 4b |.... .......[.>K| +00000040 92 cd 18 dd ac ce af 1a b9 f2 df aa 7f a1 d2 ad |................| +00000050 0e 8a 67 03 3f |..g.?| >>> Flow 4 (server to client) -00000000 14 03 03 00 01 01 16 03 03 00 20 dd a3 ff 04 65 |.......... ....e| -00000010 4b 49 77 b6 88 ab f3 31 07 3d 2e 30 ec b3 e1 1f |KIw....1.=.0....| -00000020 18 0f ef a9 2d 32 1f e6 b9 71 3f |....-2...q?| +00000000 14 03 03 00 01 01 16 03 03 00 20 db cb 3a 73 0c |.......... ..:s.| +00000010 ab 16 44 41 5a 25 df f7 45 bf f0 70 c6 a8 4f bd |..DAZ%..E..p..O.| +00000020 50 99 fb 18 26 e7 cf 71 16 1a 96 |P...&..q...| >>> Flow 5 (client to server) -00000000 17 03 03 00 16 54 7a 06 57 6b 66 e0 93 f8 f5 7a |.....Tz.Wkf....z| -00000010 ab 1a d1 f4 53 91 47 e8 5c 11 15 15 03 03 00 12 |....S.G.\.......| -00000020 42 b6 c5 6f 63 b6 72 8b 85 c3 ba c5 e3 38 8f e2 |B..oc.r......8..| -00000030 42 dd |B.| +00000000 17 03 03 00 16 34 82 27 01 99 27 08 58 c4 aa 76 |.....4.'..'.X..v| +00000010 fe 34 9c 1f 99 ea 4c f8 a0 ef 96 15 03 03 00 12 |.4....L.........| +00000020 68 b8 da ac 77 d5 f7 95 9f 68 e0 d6 26 88 cd ef |h...w....h..&...| +00000030 31 d4 |1.| diff --git a/testdata/Client-TLSv12-ClientCert-ECDSA-ECDSA b/testdata/Client-TLSv12-ClientCert-ECDSA-ECDSA index 4b40e44..b56ac9f 100644 --- a/testdata/Client-TLSv12-ClientCert-ECDSA-ECDSA +++ b/testdata/Client-TLSv12-ClientCert-ECDSA-ECDSA @@ -7,21 +7,21 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 7f 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 0a 00 08 00 1d 00 17 00 18 00 19 00 0b 00 02 01 |................| -000000a0 00 00 0d 00 1a 00 18 08 04 04 03 08 07 08 05 08 |................| -000000b0 06 04 01 05 01 06 01 05 03 06 03 02 01 02 03 ff |................| -000000c0 01 00 01 00 00 17 00 00 00 12 00 00 00 2b 00 09 |.............+..| +00000080 01 00 00 7f 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 19 00 0d |................| +000000b0 00 1a 00 18 08 04 04 03 08 07 08 05 08 06 04 01 |................| +000000c0 05 01 06 01 05 03 06 03 02 01 02 03 00 2b 00 09 |.............+..| 000000d0 08 03 04 03 03 03 02 03 01 00 33 00 26 00 24 00 |..........3.&.$.| 000000e0 1d 00 20 2f e5 7d a3 47 cd 62 43 15 28 da ac 5f |.. /.}.G.bC.(.._| 000000f0 bb 29 07 30 ff f6 84 af c4 cf c2 ed 90 99 5f 58 |.).0.........._X| 00000100 cb 3b 74 |.;t| >>> Flow 2 (server to client) -00000000 16 03 03 00 5d 02 00 00 59 03 03 7c 3c 83 43 cf |....]...Y..|<.C.| -00000010 60 91 0b 04 73 55 30 be 25 6b 41 c9 4c 67 5b 91 |`...sU0.%kA.Lg[.| -00000020 af 04 b5 34 c7 61 c7 d3 62 2e ca 20 88 47 3a 15 |...4.a..b.. .G:.| -00000030 b4 8d 3f eb a6 b3 fd ae a4 e9 d9 db 5b 59 3b 1c |..?.........[Y;.| -00000040 e6 47 e3 98 74 da 32 04 32 b0 57 81 c0 09 00 00 |.G..t.2.2.W.....| +00000000 16 03 03 00 5d 02 00 00 59 03 03 d4 19 2c 08 c6 |....]...Y....,..| +00000010 ef 32 88 79 a1 84 fc 79 38 62 b2 dd 4b a7 0b b3 |.2.y...y8b..K...| +00000020 d3 13 3d d4 f7 c7 4d d9 8b c6 8e 20 56 8e 90 3d |..=...M.... V..=| +00000030 2b 6e 2d cf 7e c1 c6 b0 e5 d8 d2 af 3a 06 88 c6 |+n-.~.......:...| +00000040 ed e7 18 76 ab 45 c5 76 47 67 95 ad c0 09 00 00 |...v.E.vGg......| 00000050 11 ff 01 00 01 00 00 0b 00 04 03 00 01 02 00 17 |................| 00000060 00 00 16 03 03 02 0e 0b 00 02 0a 00 02 07 00 02 |................| 00000070 04 30 82 02 00 30 82 01 62 02 09 00 b8 bf 2d 47 |.0...0..b.....-G| @@ -56,23 +56,23 @@ 00000240 8c 25 c1 33 13 83 0d 94 06 bb d4 37 7a f6 ec 7a |.%.3.......7z..z| 00000250 c9 86 2e dd d7 11 69 7f 85 7c 56 de fb 31 78 2b |......i..|V..1x+| 00000260 e4 c7 78 0d ae cb be 9e 4e 36 24 31 7b 6a 0f 39 |..x.....N6$1{j.9| -00000270 95 12 07 8f 2a 16 03 03 00 b6 0c 00 00 b2 03 00 |....*...........| -00000280 1d 20 b5 f3 76 c4 a9 33 34 2a 38 16 b1 38 f5 a1 |. ..v..34*8..8..| -00000290 dc f7 60 67 32 cf 6b aa 82 0c b5 db 31 c4 b4 36 |..`g2.k.....1..6| -000002a0 3e 16 04 03 00 8a 30 81 87 02 41 34 fc 19 0c 94 |>.....0...A4....| -000002b0 d7 c3 9d ed ae 75 7a 20 b5 b0 93 69 85 8e 4b 20 |.....uz ...i..K | -000002c0 27 03 83 12 12 8d d5 e4 cc 06 95 a7 dc 7c b2 dc |'............|..| -000002d0 71 6e 8c 18 89 4b fe 14 41 59 f7 af c8 1f d4 b8 |qn...K..AY......| -000002e0 7b c4 1f cb 75 53 04 29 87 df 92 37 02 42 01 e7 |{...uS.)...7.B..| -000002f0 c3 86 70 fa 8e 5e 21 16 52 0e 87 65 4a 69 aa ae |..p..^!.R..eJi..| -00000300 4c 4f 1e b5 91 17 24 b9 7d 18 7e 0f d0 db a5 33 |LO....$.}.~....3| -00000310 19 7d 98 7b 5e 15 23 d2 8c 52 8d 17 56 08 60 d6 |.}.{^.#..R..V.`.| -00000320 7c 2c 19 11 e1 d7 37 a7 b0 68 7b df 8c ae 3d 3e ||,....7..h{...=>| -00000330 16 03 03 00 3a 0d 00 00 36 03 01 02 40 00 2e 04 |....:...6...@...| -00000340 03 05 03 06 03 08 07 08 08 08 09 08 0a 08 0b 08 |................| -00000350 04 08 05 08 06 04 01 05 01 06 01 03 03 02 03 03 |................| -00000360 01 02 01 03 02 02 02 04 02 05 02 06 02 00 00 16 |................| -00000370 03 03 00 04 0e 00 00 00 |........| +00000270 95 12 07 8f 2a 16 03 03 00 b7 0c 00 00 b3 03 00 |....*...........| +00000280 1d 20 e9 3c ed d4 07 43 c1 20 f5 41 35 e1 49 4a |. .<...C. .A5.IJ| +00000290 1c 52 5d 77 f2 07 59 18 55 e0 66 d1 49 ab 95 74 |.R]w..Y.U.f.I..t| +000002a0 81 1c 04 03 00 8b 30 81 88 02 42 01 f1 52 e7 13 |......0...B..R..| +000002b0 3e 9b 3b 4f 90 0f d2 9b 50 11 fe df 1f 12 f2 d9 |>.;O....P.......| +000002c0 0d 89 bc 6c 01 93 45 ca b8 3c 09 cf b2 01 e9 99 |...l..E..<......| +000002d0 87 fb 1d ac 91 7f 77 a2 21 5e 07 5e 65 3b ec 31 |......w.!^.^e;.1| +000002e0 d7 b5 b9 1d 88 c8 82 f5 03 a9 37 e8 b9 02 42 01 |..........7...B.| +000002f0 78 c4 90 fb e3 7f 5a 7a 66 0a 44 f5 66 0e 1e ac |x.....Zzf.D.f...| +00000300 cb 53 c4 74 55 3a b8 b7 ec b3 f6 4c e1 a8 b6 cb |.S.tU:.....L....| +00000310 a1 e5 37 ac e2 17 e2 6c 8f 71 37 b0 f1 ca b8 1b |..7....l.q7.....| +00000320 df 91 16 a4 7f 31 b1 4f 3e e4 30 f0 5a 5e df 93 |.....1.O>.0.Z^..| +00000330 85 16 03 03 00 3a 0d 00 00 36 03 01 02 40 00 2e |.....:...6...@..| +00000340 04 03 05 03 06 03 08 07 08 08 08 09 08 0a 08 0b |................| +00000350 08 04 08 05 08 06 04 01 05 01 06 01 03 03 02 03 |................| +00000360 03 01 02 01 03 02 02 02 04 02 05 02 06 02 00 00 |................| +00000370 16 03 03 00 04 0e 00 00 00 |.........| >>> Flow 3 (client to server) 00000000 16 03 03 02 0a 0b 00 02 06 00 02 03 00 02 00 30 |...............0| 00000010 82 01 fc 30 82 01 5e 02 09 00 9a 30 84 6c 26 35 |...0..^....0.l&5| @@ -109,32 +109,32 @@ 00000200 e4 fa cc b1 8a ce e2 23 a0 87 f0 e1 67 51 eb 16 |.......#....gQ..| 00000210 03 03 00 25 10 00 00 21 20 2f e5 7d a3 47 cd 62 |...%...! /.}.G.b| 00000220 43 15 28 da ac 5f bb 29 07 30 ff f6 84 af c4 cf |C.(.._.).0......| -00000230 c2 ed 90 99 5f 58 cb 3b 74 16 03 03 00 92 0f 00 |...._X.;t.......| -00000240 00 8e 04 03 00 8a 30 81 87 02 42 00 92 a9 5e 4b |......0...B...^K| -00000250 9d ee cc 03 2e 34 e8 5b bd 7b 11 5a 25 00 80 a6 |.....4.[.{.Z%...| -00000260 83 44 79 07 06 0d ba 0f 76 4d e9 40 50 52 9a c3 |.Dy.....vM.@PR..| -00000270 24 43 e4 2a 2c 29 d8 da 78 af a4 ad b1 db 0f e6 |$C.*,)..x.......| -00000280 29 a8 be ec d5 c9 79 4e dc e6 6b 39 77 02 41 45 |).....yN..k9w.AE| -00000290 be 07 99 32 88 da 0b 8c 33 48 91 78 2e 23 03 9a |...2....3H.x.#..| -000002a0 6a 92 b3 4c 82 c0 fd cf 0f 08 b5 19 f6 6d 21 95 |j..L.........m!.| -000002b0 32 7a bc 6f 4b a8 01 b2 e2 a3 48 6c d0 ec 77 1c |2z.oK.....Hl..w.| -000002c0 30 83 f4 6c 12 a7 50 ea de a3 6e 47 59 cc 0d 35 |0..l..P...nGY..5| -000002d0 14 03 03 00 01 01 16 03 03 00 40 00 00 00 00 00 |..........@.....| -000002e0 00 00 00 00 00 00 00 00 00 00 00 65 d3 93 a7 5f |...........e..._| -000002f0 ff 8c 1e 8f e5 9b 61 fe df ac b6 9d e3 68 31 f8 |......a......h1.| -00000300 2b d0 70 32 2a 07 13 fe 34 5d a2 ab 35 f1 4c 81 |+.p2*...4]..5.L.| -00000310 28 34 50 0d 21 bc 4a a9 2d 90 c4 |(4P.!.J.-..| +00000230 c2 ed 90 99 5f 58 cb 3b 74 16 03 03 00 93 0f 00 |...._X.;t.......| +00000240 00 8f 04 03 00 8b 30 81 88 02 42 01 c9 2c e8 1f |......0...B..,..| +00000250 5b a0 97 0f 70 2d 46 e3 6e b4 4c 82 fc be df 05 |[...p-F.n.L.....| +00000260 09 b0 d7 e4 0a 06 71 66 d6 3b 3e b6 56 2c 22 c7 |......qf.;>.V,".| +00000270 7c 3a 63 5c 34 22 5b 3a 49 a2 97 f3 2f 58 e7 2a ||:c\4"[:I.../X.*| +00000280 cd f4 05 84 db 8b 0b 22 e3 50 1b e7 6d 02 42 01 |.......".P..m.B.| +00000290 fd 1e bc 64 8b 01 3f a0 f8 8b 41 be 4d 97 07 6c |...d..?...A.M..l| +000002a0 3b 09 74 d6 00 76 b3 a0 c0 d0 92 d0 78 24 d7 b2 |;.t..v......x$..| +000002b0 1f c0 86 90 59 3a fb a8 e1 f6 80 23 db f7 90 93 |....Y:.....#....| +000002c0 95 fd 37 14 8c 34 f3 07 10 f8 dd e3 66 28 1c b2 |..7..4......f(..| +000002d0 a0 14 03 03 00 01 01 16 03 03 00 40 00 00 00 00 |...........@....| +000002e0 00 00 00 00 00 00 00 00 00 00 00 00 6c b8 ab 0b |............l...| +000002f0 c1 2d 2f 4e d2 25 14 96 24 c6 18 97 82 93 1c 1b |.-/N.%..$.......| +00000300 b4 ca 77 8b 17 7c cf 08 ca 06 e2 ef f3 97 6a 31 |..w..|........j1| +00000310 88 aa 46 a2 d3 7b 65 56 e2 77 72 df |..F..{eV.wr.| >>> Flow 4 (server to client) -00000000 14 03 03 00 01 01 16 03 03 00 40 49 93 f4 1d 25 |..........@I...%| -00000010 62 e3 5d 46 a2 ae 3d d2 4c 35 a9 06 f0 e1 ca d7 |b.]F..=.L5......| -00000020 43 c1 96 27 96 ce d1 f6 d5 07 cc ec 6a 4a 96 c6 |C..'........jJ..| -00000030 1f 89 14 ff 15 6f 79 bc 90 3e fd 63 ed 21 69 95 |.....oy..>.c.!i.| -00000040 91 a1 08 4a 7e e6 f0 5d e6 ae b6 |...J~..]...| +00000000 14 03 03 00 01 01 16 03 03 00 40 b8 19 a7 e2 35 |..........@....5| +00000010 8a be 5f 4c 91 d2 db 3f f3 42 90 8e b5 7f ea f7 |.._L...?.B......| +00000020 52 3e 61 2f 4d ef 25 8d ce 82 77 22 05 6f 0d b6 |R>a/M.%...w".o..| +00000030 04 c1 f0 f0 a2 9d bf 80 a9 f5 e1 62 5c e2 30 ef |...........b\.0.| +00000040 83 e7 c5 78 de 8f 17 4e d3 57 dd |...x...N.W.| >>> Flow 5 (client to server) 00000000 17 03 03 00 30 00 00 00 00 00 00 00 00 00 00 00 |....0...........| -00000010 00 00 00 00 00 88 36 f6 a8 b4 e5 b6 58 ec 9b 08 |......6.....X...| -00000020 6f bf 5a 7c f1 b5 81 b2 6b 93 f2 35 40 34 89 61 |o.Z|....k..5@4.a| -00000030 a9 ef 6d fe 2c 15 03 03 00 30 00 00 00 00 00 00 |..m.,....0......| -00000040 00 00 00 00 00 00 00 00 00 00 97 6d 99 d3 e5 8b |...........m....| -00000050 54 93 b6 fd 3f ec 6e 03 03 4e 04 39 35 2c bb 10 |T...?.n..N.95,..| -00000060 02 d0 8d 48 4e 56 1a e5 98 97 |...HNV....| +00000010 00 00 00 00 00 cb 79 13 ea 9e 7a 63 8f 5a 2b 8c |......y...zc.Z+.| +00000020 3a f3 bb 7e dc ff d1 2c 4a a6 4a aa ad bf 44 b8 |:..~...,J.J...D.| +00000030 cb 67 ce 3d f0 15 03 03 00 30 00 00 00 00 00 00 |.g.=.....0......| +00000040 00 00 00 00 00 00 00 00 00 00 f4 15 a0 f0 64 d1 |..............d.| +00000050 dd 5f 14 66 6c ce 51 95 bc b5 0b f8 4f 42 48 57 |._.fl.Q.....OBHW| +00000060 cf f3 09 62 75 0d 3e 64 64 e0 |...bu.>dd.| diff --git a/testdata/Client-TLSv12-ClientCert-ECDSA-RSA b/testdata/Client-TLSv12-ClientCert-ECDSA-RSA index b7323e5..692092e 100644 --- a/testdata/Client-TLSv12-ClientCert-ECDSA-RSA +++ b/testdata/Client-TLSv12-ClientCert-ECDSA-RSA @@ -7,21 +7,21 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 7f 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 0a 00 08 00 1d 00 17 00 18 00 19 00 0b 00 02 01 |................| -000000a0 00 00 0d 00 1a 00 18 08 04 04 03 08 07 08 05 08 |................| -000000b0 06 04 01 05 01 06 01 05 03 06 03 02 01 02 03 ff |................| -000000c0 01 00 01 00 00 17 00 00 00 12 00 00 00 2b 00 09 |.............+..| +00000080 01 00 00 7f 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 19 00 0d |................| +000000b0 00 1a 00 18 08 04 04 03 08 07 08 05 08 06 04 01 |................| +000000c0 05 01 06 01 05 03 06 03 02 01 02 03 00 2b 00 09 |.............+..| 000000d0 08 03 04 03 03 03 02 03 01 00 33 00 26 00 24 00 |..........3.&.$.| 000000e0 1d 00 20 2f e5 7d a3 47 cd 62 43 15 28 da ac 5f |.. /.}.G.bC.(.._| 000000f0 bb 29 07 30 ff f6 84 af c4 cf c2 ed 90 99 5f 58 |.).0.........._X| 00000100 cb 3b 74 |.;t| >>> Flow 2 (server to client) -00000000 16 03 03 00 5d 02 00 00 59 03 03 75 bb 71 f8 35 |....]...Y..u.q.5| -00000010 6c a2 b1 c8 b1 a1 dc 40 01 bc e7 0c 8c 22 90 2c |l......@.....".,| -00000020 aa 34 d3 d2 c8 b1 96 3b bf 4a bf 20 b3 2a f7 96 |.4.....;.J. .*..| -00000030 9d 79 53 4b 64 b2 80 4d 0e ab f8 3d cd 82 2d 78 |.ySKd..M...=..-x| -00000040 47 8e cd 9b 14 8c 1e 6d 0e 52 7b db c0 2f 00 00 |G......m.R{../..| +00000000 16 03 03 00 5d 02 00 00 59 03 03 ed c3 6f 59 34 |....]...Y....oY4| +00000010 78 33 49 00 68 50 1f a5 aa 93 45 9a 87 34 c4 4e |x3I.hP....E..4.N| +00000020 71 b0 ab 5e 43 f7 a1 5c 89 e8 2f 20 f7 42 d7 2a |q..^C..\../ .B.*| +00000030 a5 fe 16 76 ac 6f cf 20 1d a6 bc d5 9d 27 9d 81 |...v.o. .....'..| +00000040 80 b4 0d 4e 12 89 de 7b 7a 5b a0 2b c0 2f 00 00 |...N...{z[.+./..| 00000050 11 ff 01 00 01 00 00 0b 00 04 03 00 01 02 00 17 |................| 00000060 00 00 16 03 03 02 59 0b 00 02 55 00 02 52 00 02 |......Y...U..R..| 00000070 4f 30 82 02 4b 30 82 01 b4 a0 03 02 01 02 02 09 |O0..K0..........| @@ -61,18 +61,18 @@ 00000290 73 bb b3 43 77 8d 0c 1c f1 0f a1 d8 40 83 61 c9 |s..Cw.......@.a.| 000002a0 4c 72 2b 9d ae db 46 06 06 4d f4 c1 b3 3e c0 d1 |Lr+...F..M...>..| 000002b0 bd 42 d4 db fe 3d 13 60 84 5c 21 d3 3b e9 fa e7 |.B...=.`.\!.;...| -000002c0 16 03 03 00 ac 0c 00 00 a8 03 00 1d 20 f1 7e d0 |............ .~.| -000002d0 74 5c 5a ab 67 9d 3e ad b5 4a 07 22 4a b7 3c e5 |t\Z.g.>..J."J.<.| -000002e0 dd 4a 1f ba 33 b5 73 91 87 2a ef 5d 2b 08 04 00 |.J..3.s..*.]+...| -000002f0 80 d7 78 82 c0 ee 54 02 e8 69 66 94 4b 92 74 0b |..x...T..if.K.t.| -00000300 be 72 05 ef 78 e2 60 c0 72 3a 09 42 4b d3 0d a0 |.r..x.`.r:.BK...| -00000310 8b 50 b2 48 33 e4 d2 9f 64 4b 81 8c 5a c4 ad 8d |.P.H3...dK..Z...| -00000320 52 7c c4 79 10 1c df a8 80 bc 91 bc a7 5e b9 87 |R|.y.........^..| -00000330 8c 68 63 41 dc 95 b0 b7 65 c4 e8 54 39 ce 2b f8 |.hcA....e..T9.+.| -00000340 36 76 7f d1 1f ec 84 2b 08 63 10 d0 3c c0 4a 61 |6v.....+.c..<.Ja| -00000350 5f 74 6a e2 94 93 82 e9 4f 81 bf 93 65 e8 09 06 |_tj.....O...e...| -00000360 b6 61 14 ed 1a e0 52 f7 4f 08 2d 93 1e 1a 83 e2 |.a....R.O.-.....| -00000370 17 16 03 03 00 3a 0d 00 00 36 03 01 02 40 00 2e |.....:...6...@..| +000002c0 16 03 03 00 ac 0c 00 00 a8 03 00 1d 20 d9 02 16 |............ ...| +000002d0 ba b6 db c0 c6 65 6d fb b8 69 dc 04 1a 8d 4a 36 |.....em..i....J6| +000002e0 27 6b f0 53 c3 72 56 1a 99 07 0f b9 79 08 04 00 |'k.S.rV.....y...| +000002f0 80 5d c6 1e a2 20 7d ae 35 e6 20 2f ff 7a 7b 8d |.]... }.5. /.z{.| +00000300 3f fd 49 d4 ce 26 f7 d0 c2 51 2a 42 03 26 b7 30 |?.I..&...Q*B.&.0| +00000310 af 5f 7d 34 1d 7d 37 ef 8a 1c e6 be 19 99 f1 30 |._}4.}7........0| +00000320 2e 26 6d 7b 83 cd 6e 26 c4 03 f5 7a 30 8f bf e3 |.&m{..n&...z0...| +00000330 c1 64 da 43 fc f0 32 c9 a2 68 e4 97 d0 34 8a c4 |.d.C..2..h...4..| +00000340 fc f8 bb 61 ec df 69 f7 d0 d7 1e 19 c0 5b 21 86 |...a..i......[!.| +00000350 eb 79 93 46 3b 7a 50 83 41 8b d3 7c 59 d5 34 8a |.y.F;zP.A..|Y.4.| +00000360 0c b5 70 e4 86 38 3a 6c 11 04 57 d6 94 c0 78 c7 |..p..8:l..W...x.| +00000370 91 16 03 03 00 3a 0d 00 00 36 03 01 02 40 00 2e |.....:...6...@..| 00000380 04 03 05 03 06 03 08 07 08 08 08 09 08 0a 08 0b |................| 00000390 08 04 08 05 08 06 04 01 05 01 06 01 03 03 02 03 |................| 000003a0 03 01 02 01 03 02 02 02 04 02 05 02 06 02 00 00 |................| @@ -114,27 +114,27 @@ 00000210 03 03 00 25 10 00 00 21 20 2f e5 7d a3 47 cd 62 |...%...! /.}.G.b| 00000220 43 15 28 da ac 5f bb 29 07 30 ff f6 84 af c4 cf |C.(.._.).0......| 00000230 c2 ed 90 99 5f 58 cb 3b 74 16 03 03 00 93 0f 00 |...._X.;t.......| -00000240 00 8f 04 03 00 8b 30 81 88 02 42 01 8a 49 56 8a |......0...B..IV.| -00000250 3d 09 db 5b ae 29 2f 93 04 b1 7a 80 95 5c 30 4b |=..[.)/...z..\0K| -00000260 9a 90 5a 64 3d 12 72 03 7a 8f 4d 40 a8 b0 fd d3 |..Zd=.r.z.M@....| -00000270 2d e5 3f a4 ce 97 34 e6 e4 23 4f 0b 00 7c 89 8e |-.?...4..#O..|..| -00000280 f2 37 14 a8 50 d3 d6 ec 99 f2 ff c6 8e 02 42 01 |.7..P.........B.| -00000290 75 ba 90 7c 16 88 9f 93 73 2a ec e8 e0 53 82 6c |u..|....s*...S.l| -000002a0 85 a9 1f 42 7e a2 db 55 e9 cd a7 b0 b2 c6 a2 38 |...B~..U.......8| -000002b0 14 75 ea 91 2f 10 c7 0a f4 98 14 c7 a4 71 72 af |.u../........qr.| -000002c0 d1 b3 2b 86 a7 25 97 5f de 5a c3 79 fe 44 42 b1 |..+..%._.Z.y.DB.| -000002d0 dd 14 03 03 00 01 01 16 03 03 00 28 00 00 00 00 |...........(....| -000002e0 00 00 00 00 a8 a3 81 5b 57 fb 9e 15 5a aa 77 1c |.......[W...Z.w.| -000002f0 39 cb 84 05 dc 58 2e 65 3c 25 b2 46 9a b3 17 a4 |9....X.e<%.F....| -00000300 2f 6c ae fb |/l..| +00000240 00 8f 04 03 00 8b 30 81 88 02 42 01 a3 80 63 a4 |......0...B...c.| +00000250 49 60 35 5c 06 87 9f 7f ae 40 37 d0 64 58 b2 60 |I`5\.....@7.dX.`| +00000260 61 59 8b 6d a6 d9 55 67 81 f6 7e 9c de 40 69 00 |aY.m..Ug..~..@i.| +00000270 42 e1 2e 67 0d 48 cf 23 a7 28 f2 e0 9e 26 61 20 |B..g.H.#.(...&a | +00000280 4f 50 b6 e3 85 0b f5 f6 96 ec 03 32 35 02 42 01 |OP.........25.B.| +00000290 bd 3b 3e d6 03 98 b5 09 9a aa a9 73 1d 98 6a a5 |.;>........s..j.| +000002a0 29 ff e5 b3 f8 1f 58 2a a1 92 ea 2d 6d e9 71 d3 |).....X*...-m.q.| +000002b0 ce 04 46 ef d6 fb e4 5e e3 70 19 01 1a 22 85 70 |..F....^.p...".p| +000002c0 06 ec 15 bd ff ef af ed 2b 6d 00 97 cb 67 1f cb |........+m...g..| +000002d0 f6 14 03 03 00 01 01 16 03 03 00 28 00 00 00 00 |...........(....| +000002e0 00 00 00 00 80 da 31 59 19 74 39 ff a4 8c 30 1b |......1Y.t9...0.| +000002f0 25 fd 6b 25 57 ef 26 57 bd a1 df 90 4e d6 6a 47 |%.k%W.&W....N.jG| +00000300 96 08 54 92 |..T.| >>> Flow 4 (server to client) -00000000 14 03 03 00 01 01 16 03 03 00 28 fd 91 33 fe 0c |..........(..3..| -00000010 f3 cf d7 9d b0 d1 e7 63 ea 06 f7 93 d3 f5 cd 33 |.......c.......3| -00000020 32 ac 94 78 8e 15 ac 57 c9 b4 44 36 97 96 8d f1 |2..x...W..D6....| -00000030 c3 20 0d |. .| +00000000 14 03 03 00 01 01 16 03 03 00 28 0e 1f ce 8a 46 |..........(....F| +00000010 77 28 6d e2 fc c4 e4 39 70 6b ab 6e 14 14 2a 34 |w(m....9pk.n..*4| +00000020 13 a0 5b c5 95 f5 fa a9 a2 f6 60 20 e3 1f c5 84 |..[.......` ....| +00000030 9c 00 5e |..^| >>> Flow 5 (client to server) -00000000 17 03 03 00 1e 00 00 00 00 00 00 00 01 99 85 0f |................| -00000010 d6 6c 5e b9 55 12 d5 b5 93 a8 b8 85 cb 0b 8f cd |.l^.U...........| -00000020 f5 fc a1 15 03 03 00 1a 00 00 00 00 00 00 00 02 |................| -00000030 e3 c0 5e 6a 72 6c 2d 5a 4c 94 0d 1e 77 85 ef 4a |..^jrl-ZL...w..J| -00000040 90 a5 |..| +00000000 17 03 03 00 1e 00 00 00 00 00 00 00 01 88 d1 a4 |................| +00000010 c9 1b a6 a5 21 4d 93 e8 04 8b 3b 69 a9 2f bd 7d |....!M....;i./.}| +00000020 97 c1 3d 15 03 03 00 1a 00 00 00 00 00 00 00 02 |..=.............| +00000030 ba 48 db 22 9e ae d8 a9 24 b7 a6 52 13 92 68 d6 |.H."....$..R..h.| +00000040 aa b5 |..| diff --git a/testdata/Client-TLSv12-ClientCert-Ed25519 b/testdata/Client-TLSv12-ClientCert-Ed25519 index c683f6d..edb433f 100644 --- a/testdata/Client-TLSv12-ClientCert-Ed25519 +++ b/testdata/Client-TLSv12-ClientCert-Ed25519 @@ -7,21 +7,21 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 7f 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 0a 00 08 00 1d 00 17 00 18 00 19 00 0b 00 02 01 |................| -000000a0 00 00 0d 00 1a 00 18 08 04 04 03 08 07 08 05 08 |................| -000000b0 06 04 01 05 01 06 01 05 03 06 03 02 01 02 03 ff |................| -000000c0 01 00 01 00 00 17 00 00 00 12 00 00 00 2b 00 09 |.............+..| +00000080 01 00 00 7f 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 19 00 0d |................| +000000b0 00 1a 00 18 08 04 04 03 08 07 08 05 08 06 04 01 |................| +000000c0 05 01 06 01 05 03 06 03 02 01 02 03 00 2b 00 09 |.............+..| 000000d0 08 03 04 03 03 03 02 03 01 00 33 00 26 00 24 00 |..........3.&.$.| 000000e0 1d 00 20 2f e5 7d a3 47 cd 62 43 15 28 da ac 5f |.. /.}.G.bC.(.._| 000000f0 bb 29 07 30 ff f6 84 af c4 cf c2 ed 90 99 5f 58 |.).0.........._X| 00000100 cb 3b 74 |.;t| >>> Flow 2 (server to client) -00000000 16 03 03 00 5d 02 00 00 59 03 03 6c b5 d2 af 6d |....]...Y..l...m| -00000010 6d 09 3b 84 5c 76 fc 25 81 84 b9 07 01 e9 54 cc |m.;.\v.%......T.| -00000020 4f 3f ab da ef 02 e7 59 8a e6 10 20 f9 72 db 0c |O?.....Y... .r..| -00000030 a4 c6 29 f6 ce 25 04 5d af 3c 0f fa 97 28 ee 43 |..)..%.].<...(.C| -00000040 b1 e5 5f 0a 42 36 2b 63 06 7d d0 de cc a8 00 00 |.._.B6+c.}......| +00000000 16 03 03 00 5d 02 00 00 59 03 03 68 ad d5 4c 88 |....]...Y..h..L.| +00000010 60 b8 3b b4 ea e4 f2 55 7d 0f 90 d8 bd 55 b5 53 |`.;....U}....U.S| +00000020 49 6e f7 50 e4 05 70 a2 6d 9e a5 20 d1 0a e5 58 |In.P..p.m.. ...X| +00000030 38 f1 82 94 a7 c3 bf 77 60 d8 51 c2 c7 e9 8e d6 |8......w`.Q.....| +00000040 94 ee 4f 23 51 d3 2c 52 06 12 4b 4a cc a8 00 00 |..O#Q.,R..KJ....| 00000050 11 ff 01 00 01 00 00 0b 00 04 03 00 01 02 00 17 |................| 00000060 00 00 16 03 03 02 59 0b 00 02 55 00 02 52 00 02 |......Y...U..R..| 00000070 4f 30 82 02 4b 30 82 01 b4 a0 03 02 01 02 02 09 |O0..K0..........| @@ -61,18 +61,18 @@ 00000290 73 bb b3 43 77 8d 0c 1c f1 0f a1 d8 40 83 61 c9 |s..Cw.......@.a.| 000002a0 4c 72 2b 9d ae db 46 06 06 4d f4 c1 b3 3e c0 d1 |Lr+...F..M...>..| 000002b0 bd 42 d4 db fe 3d 13 60 84 5c 21 d3 3b e9 fa e7 |.B...=.`.\!.;...| -000002c0 16 03 03 00 ac 0c 00 00 a8 03 00 1d 20 05 e2 67 |............ ..g| -000002d0 4b 7b e7 b3 0f 62 ff 90 4d 73 b1 c6 b7 ef 9c 33 |K{...b..Ms.....3| -000002e0 30 83 7d 09 66 b6 d8 10 51 c6 95 b3 64 08 04 00 |0.}.f...Q...d...| -000002f0 80 71 0d e7 a9 1b d7 2e 08 90 5b aa 30 cf c1 e0 |.q........[.0...| -00000300 26 df 57 2d b2 95 4a 69 51 e4 b1 26 ad 91 1a 3e |&.W-..JiQ..&...>| -00000310 38 9f 4e 9e e3 72 7a a7 a8 57 79 3d e5 94 ab c2 |8.N..rz..Wy=....| -00000320 e3 0f e9 07 aa 31 c9 d6 d8 3d 9c 00 2e c3 8b 3f |.....1...=.....?| -00000330 23 5a a9 af f0 6b f0 8f 55 b5 5d b3 67 7a cf b5 |#Z...k..U.].gz..| -00000340 b4 c7 52 29 e9 3a 05 d2 cd d9 a9 99 13 49 15 8a |..R).:.......I..| -00000350 85 92 60 9a ed 72 c7 75 34 0f b5 26 70 ba 67 0b |..`..r.u4..&p.g.| -00000360 6e fb 52 97 01 bd 32 59 5b 56 bc e5 d9 68 cd 88 |n.R...2Y[V...h..| -00000370 7c 16 03 03 00 3a 0d 00 00 36 03 01 02 40 00 2e ||....:...6...@..| +000002c0 16 03 03 00 ac 0c 00 00 a8 03 00 1d 20 4e 55 f3 |............ NU.| +000002d0 5f 83 c8 88 d4 f2 5c 75 6a ab 0e 25 df 12 ef f0 |_.....\uj..%....| +000002e0 ea e9 3e b4 4f 2c cd bb 43 5b 64 21 12 08 04 00 |..>.O,..C[d!....| +000002f0 80 84 5e ca 36 b2 fa d0 29 47 1c c2 de 4e 1d 81 |..^.6...)G...N..| +00000300 14 66 0a 26 6f 21 5f d5 b5 54 2e 37 f1 7e b1 90 |.f.&o!_..T.7.~..| +00000310 a0 57 ab 40 81 cf e5 77 29 23 54 fa 12 76 1a 4a |.W.@...w)#T..v.J| +00000320 66 c0 52 08 07 3c 3c 56 06 08 02 df 9f 75 75 5e |f.R..<>> Flow 4 (server to client) -00000000 14 03 03 00 01 01 16 03 03 00 20 97 ae 75 77 58 |.......... ..uwX| -00000010 02 f2 b3 fe ef cf 61 fe e8 d9 b3 49 02 49 64 c2 |......a....I.Id.| -00000020 4b 94 fe 05 8d c1 46 ef 5b 53 8c |K.....F.[S.| +00000000 14 03 03 00 01 01 16 03 03 00 20 10 cb 1b e5 55 |.......... ....U| +00000010 64 49 55 0a bf 25 e4 b0 d0 45 e1 47 b0 05 d0 f2 |dIU..%...E.G....| +00000020 41 b7 f4 6a 84 4e 6a 66 8d 0e 43 |A..j.Njf..C| >>> Flow 5 (client to server) -00000000 17 03 03 00 16 16 ea 3f e3 7d 1f 53 af a2 74 82 |.......?.}.S..t.| -00000010 6e 8a 01 6a ea 75 8b a8 4e 76 74 15 03 03 00 12 |n..j.u..Nvt.....| -00000020 e3 d8 78 82 9f db 28 60 01 c6 03 f0 e7 86 52 ba |..x...(`......R.| -00000030 2c 45 |,E| +00000000 17 03 03 00 16 4a f3 ed 07 22 0d 7d 9b a6 a8 3c |.....J...".}...<| +00000010 88 58 f3 48 c2 f1 aa ea c7 cd 14 15 03 03 00 12 |.X.H............| +00000020 0b 1d 53 98 b3 69 99 e1 cd 4f 37 3c dc 63 17 9f |..S..i...O7<.c..| +00000030 00 7f |..| diff --git a/testdata/Client-TLSv12-ClientCert-RSA-AES256-GCM-SHA384 b/testdata/Client-TLSv12-ClientCert-RSA-AES256-GCM-SHA384 index 9631c0c..c6673f6 100644 --- a/testdata/Client-TLSv12-ClientCert-RSA-AES256-GCM-SHA384 +++ b/testdata/Client-TLSv12-ClientCert-RSA-AES256-GCM-SHA384 @@ -7,21 +7,21 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 7f 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 0a 00 08 00 1d 00 17 00 18 00 19 00 0b 00 02 01 |................| -000000a0 00 00 0d 00 1a 00 18 08 04 04 03 08 07 08 05 08 |................| -000000b0 06 04 01 05 01 06 01 05 03 06 03 02 01 02 03 ff |................| -000000c0 01 00 01 00 00 17 00 00 00 12 00 00 00 2b 00 09 |.............+..| +00000080 01 00 00 7f 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 19 00 0d |................| +000000b0 00 1a 00 18 08 04 04 03 08 07 08 05 08 06 04 01 |................| +000000c0 05 01 06 01 05 03 06 03 02 01 02 03 00 2b 00 09 |.............+..| 000000d0 08 03 04 03 03 03 02 03 01 00 33 00 26 00 24 00 |..........3.&.$.| 000000e0 1d 00 20 2f e5 7d a3 47 cd 62 43 15 28 da ac 5f |.. /.}.G.bC.(.._| 000000f0 bb 29 07 30 ff f6 84 af c4 cf c2 ed 90 99 5f 58 |.).0.........._X| 00000100 cb 3b 74 |.;t| >>> Flow 2 (server to client) -00000000 16 03 03 00 5d 02 00 00 59 03 03 b7 f3 10 78 e0 |....]...Y.....x.| -00000010 58 51 c7 7c 5c 88 27 e1 ce e4 df 24 45 36 7c fe |XQ.|\.'....$E6|.| -00000020 9b 5c a1 89 0a 6e af 2a 73 b9 93 20 40 64 4c 4d |.\...n.*s.. @dLM| -00000030 9d 10 58 ef 28 30 5d 81 2b 91 3b 5d 2b 67 b4 61 |..X.(0].+.;]+g.a| -00000040 ef 24 f1 23 e2 32 46 4c 3e 96 7a a2 c0 30 00 00 |.$.#.2FL>.z..0..| +00000000 16 03 03 00 5d 02 00 00 59 03 03 60 13 bb 4b ce |....]...Y..`..K.| +00000010 d6 49 3b b2 3a 0c d4 5a e8 25 26 67 41 fd dd 0f |.I;.:..Z.%&gA...| +00000020 62 ec c1 ab bc 58 92 67 9d 71 fd 20 20 4c ab 4d |b....X.g.q. L.M| +00000030 85 ce 87 49 68 8c cf 9c 2f 7b f9 2b 96 62 8a 75 |...Ih.../{.+.b.u| +00000040 c3 21 05 c6 ab b6 98 5e e7 e5 d8 4a c0 30 00 00 |.!.....^...J.0..| 00000050 11 ff 01 00 01 00 00 0b 00 04 03 00 01 02 00 17 |................| 00000060 00 00 16 03 03 02 59 0b 00 02 55 00 02 52 00 02 |......Y...U..R..| 00000070 4f 30 82 02 4b 30 82 01 b4 a0 03 02 01 02 02 09 |O0..K0..........| @@ -61,18 +61,18 @@ 00000290 73 bb b3 43 77 8d 0c 1c f1 0f a1 d8 40 83 61 c9 |s..Cw.......@.a.| 000002a0 4c 72 2b 9d ae db 46 06 06 4d f4 c1 b3 3e c0 d1 |Lr+...F..M...>..| 000002b0 bd 42 d4 db fe 3d 13 60 84 5c 21 d3 3b e9 fa e7 |.B...=.`.\!.;...| -000002c0 16 03 03 00 ac 0c 00 00 a8 03 00 1d 20 e4 a0 4d |............ ..M| -000002d0 a8 b2 65 c0 a7 f8 46 a3 79 1c c6 32 7d 1e c4 7b |..e...F.y..2}..{| -000002e0 09 4a cd 92 5d a6 64 20 b7 c2 0e 5e 50 08 04 00 |.J..].d ...^P...| -000002f0 80 32 80 e3 3b 30 c3 d9 67 9a ef ea 95 f1 c3 50 |.2..;0..g......P| -00000300 cb 98 82 3e 92 fd 4c 1b 76 53 4e 31 41 f4 30 9a |...>..L.vSN1A.0.| -00000310 0a c0 8b 50 5c d6 5c ce 9f ee d9 c6 02 79 48 58 |...P\.\......yHX| -00000320 97 04 9f 7f 86 f2 7b 61 87 f8 5a d1 92 c3 57 d4 |......{a..Z...W.| -00000330 c8 86 a2 be 75 3c 13 75 71 13 e2 20 e7 03 b6 6e |....u<.uq.. ...n| -00000340 97 d5 32 f5 af ce d5 4f e6 7d a6 b3 36 11 f5 ae |..2....O.}..6...| -00000350 4a 0a fb 43 fa 2c c5 29 e6 fa 59 5f 20 e4 41 f1 |J..C.,.)..Y_ .A.| -00000360 3b be e1 1e 80 92 74 1c 8e fe 3a f8 c3 ef ed 93 |;.....t...:.....| -00000370 02 16 03 03 00 3a 0d 00 00 36 03 01 02 40 00 2e |.....:...6...@..| +000002c0 16 03 03 00 ac 0c 00 00 a8 03 00 1d 20 85 c8 0e |............ ...| +000002d0 fb 1e b3 4a ec c1 b2 3a b8 4e bb a1 ca 80 8e 13 |...J...:.N......| +000002e0 f5 08 b5 9a b8 3e c4 6c 23 cf 17 a0 31 08 04 00 |.....>.l#...1...| +000002f0 80 28 db ec 9d f9 f4 9a 06 12 8a 32 89 11 4a e5 |.(.........2..J.| +00000300 b6 68 98 21 ec f1 75 9c f9 28 bc b1 99 5b ec 77 |.h.!..u..(...[.w| +00000310 37 8b 6b 05 ad b3 10 de 24 05 84 a4 16 fe 1d 84 |7.k.....$.......| +00000320 af 5d 28 7d d7 bc de 2f 81 da a3 79 fb c0 a5 43 |.](}.../...y...C| +00000330 b6 3b 8d 90 30 00 80 98 16 83 ac 50 43 c7 3e 76 |.;..0......PC.>v| +00000340 c5 dc 85 c2 19 75 a6 90 f8 2f 71 40 d9 a0 73 7e |.....u.../q@..s~| +00000350 fe 3b 1c d7 66 73 0f f0 42 c5 00 b1 2b be 41 2b |.;..fs..B...+.A+| +00000360 40 da 8f b0 f1 9e b0 0a 83 23 04 80 fb 4c fe 7e |@........#...L.~| +00000370 b4 16 03 03 00 3a 0d 00 00 36 03 01 02 40 00 2e |.....:...6...@..| 00000380 04 03 05 03 06 03 08 07 08 08 08 09 08 0a 08 0b |................| 00000390 08 04 08 05 08 06 04 01 05 01 06 01 03 03 02 03 |................| 000003a0 03 01 02 01 03 02 02 02 04 02 05 02 06 02 00 00 |................| @@ -113,26 +113,26 @@ 00000200 e5 35 16 03 03 00 25 10 00 00 21 20 2f e5 7d a3 |.5....%...! /.}.| 00000210 47 cd 62 43 15 28 da ac 5f bb 29 07 30 ff f6 84 |G.bC.(.._.).0...| 00000220 af c4 cf c2 ed 90 99 5f 58 cb 3b 74 16 03 03 00 |......._X.;t....| -00000230 88 0f 00 00 84 08 04 00 80 57 04 14 cf f4 73 9e |.........W....s.| -00000240 5d 94 16 54 3a 06 6b 37 03 b2 15 52 f1 27 86 2e |]..T:.k7...R.'..| -00000250 66 e3 0b 4c da f9 71 1b 6a 5b 65 d8 7c 43 80 6a |f..L..q.j[e.|C.j| -00000260 d1 5c 5c 3b ff 44 dc c7 a9 74 01 51 76 69 79 24 |.\\;.D...t.Qviy$| -00000270 c5 91 79 65 73 7e b7 1b 15 80 34 b4 31 89 c4 e9 |..yes~....4.1...| -00000280 f8 e3 18 fd 68 65 b9 65 d7 31 cc d0 8d 00 4e 55 |....he.e.1....NU| -00000290 3f dc 17 58 b3 b8 aa 98 4e 73 c5 05 bb 54 81 e3 |?..X....Ns...T..| -000002a0 42 5d b3 1b 6e b0 f8 a0 2c 00 52 e0 e1 16 18 d3 |B]..n...,.R.....| -000002b0 d1 df 2b b9 15 20 69 d6 1a 14 03 03 00 01 01 16 |..+.. i.........| -000002c0 03 03 00 28 00 00 00 00 00 00 00 00 b7 cd 13 34 |...(...........4| -000002d0 56 65 49 f9 1c 23 7f 7d 45 18 91 0f 23 27 c8 78 |VeI..#.}E...#'.x| -000002e0 cb 34 f8 7c 90 58 5f 29 ff ac f8 1c |.4.|.X_)....| +00000230 88 0f 00 00 84 08 04 00 80 41 83 55 9b 3c 8d 29 |.........A.U.<.)| +00000240 ed 6c 58 91 85 cb 9b 19 df 61 09 d0 d3 73 fb 2b |.lX......a...s.+| +00000250 3b 4b 4b bd 64 7e e6 53 87 cb 6d 2f 78 1c 67 cf |;KK.d~.S..m/x.g.| +00000260 13 21 e0 ec 1b d7 d8 aa 06 a0 0e d5 86 6f ba 1e |.!...........o..| +00000270 97 e2 8c 9b 86 e2 8a 4d 62 1a bd 35 0e 2d 63 18 |.......Mb..5.-c.| +00000280 a1 1f 7c ed fc 3b 89 c2 00 6d da 01 42 0a 47 95 |..|..;...m..B.G.| +00000290 12 8e 01 82 62 58 f9 96 eb a9 aa c3 f8 96 ec 20 |....bX......... | +000002a0 e1 65 a9 46 a8 af 4b 7c aa 29 ee 9c 48 18 b3 4a |.e.F..K|.)..H..J| +000002b0 00 7f 79 97 87 27 92 ca 45 14 03 03 00 01 01 16 |..y..'..E.......| +000002c0 03 03 00 28 00 00 00 00 00 00 00 00 da f3 01 f2 |...(............| +000002d0 76 e2 df 95 82 0d cc 0c 7e b0 cc 15 69 ba 8c 64 |v.......~...i..d| +000002e0 ac dc f3 45 58 a3 8f ed f0 2a 43 ce |...EX....*C.| >>> Flow 4 (server to client) -00000000 14 03 03 00 01 01 16 03 03 00 28 c0 cc d9 54 39 |..........(...T9| -00000010 73 0a 5f d9 33 a2 00 cc 18 f6 73 c9 b1 c6 35 b7 |s._.3.....s...5.| -00000020 49 85 5c 0d 46 21 84 4e 3d b8 ca b8 66 04 e7 96 |I.\.F!.N=...f...| -00000030 e6 55 26 |.U&| +00000000 14 03 03 00 01 01 16 03 03 00 28 e4 27 5e 80 00 |..........(.'^..| +00000010 ee db 03 4c 17 d1 9c bf f5 68 5f eb a6 fb 0c 3f |...L.....h_....?| +00000020 4f c4 38 84 3e c2 e9 f4 9b 06 39 5f 89 06 3a bd |O.8.>.....9_..:.| +00000030 77 db 25 |w.%| >>> Flow 5 (client to server) -00000000 17 03 03 00 1e 00 00 00 00 00 00 00 01 61 6d a3 |.............am.| -00000010 bd c6 12 0d b3 42 56 a3 e3 c9 e6 4d 38 bf 1d 4c |.....BV....M8..L| -00000020 59 82 c8 15 03 03 00 1a 00 00 00 00 00 00 00 02 |Y...............| -00000030 ea 55 21 35 64 fd c6 7c 0e f3 2d 67 d6 53 03 20 |.U!5d..|..-g.S. | -00000040 64 06 |d.| +00000000 17 03 03 00 1e 00 00 00 00 00 00 00 01 2b 98 2b |.............+.+| +00000010 d6 dc d2 69 03 c9 0e 44 46 d1 5e d2 5a 14 89 7b |...i...DF.^.Z..{| +00000020 60 ab 62 15 03 03 00 1a 00 00 00 00 00 00 00 02 |`.b.............| +00000030 b9 7a 17 4b 10 5f 25 90 14 75 bb aa 42 de 7b 63 |.z.K._%..u..B.{c| +00000040 69 e8 |i.| diff --git a/testdata/Client-TLSv12-ClientCert-RSA-ECDSA b/testdata/Client-TLSv12-ClientCert-RSA-ECDSA index ccb5998..7b2a363 100644 --- a/testdata/Client-TLSv12-ClientCert-RSA-ECDSA +++ b/testdata/Client-TLSv12-ClientCert-RSA-ECDSA @@ -7,21 +7,21 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 7f 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 0a 00 08 00 1d 00 17 00 18 00 19 00 0b 00 02 01 |................| -000000a0 00 00 0d 00 1a 00 18 08 04 04 03 08 07 08 05 08 |................| -000000b0 06 04 01 05 01 06 01 05 03 06 03 02 01 02 03 ff |................| -000000c0 01 00 01 00 00 17 00 00 00 12 00 00 00 2b 00 09 |.............+..| +00000080 01 00 00 7f 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 19 00 0d |................| +000000b0 00 1a 00 18 08 04 04 03 08 07 08 05 08 06 04 01 |................| +000000c0 05 01 06 01 05 03 06 03 02 01 02 03 00 2b 00 09 |.............+..| 000000d0 08 03 04 03 03 03 02 03 01 00 33 00 26 00 24 00 |..........3.&.$.| 000000e0 1d 00 20 2f e5 7d a3 47 cd 62 43 15 28 da ac 5f |.. /.}.G.bC.(.._| 000000f0 bb 29 07 30 ff f6 84 af c4 cf c2 ed 90 99 5f 58 |.).0.........._X| 00000100 cb 3b 74 |.;t| >>> Flow 2 (server to client) -00000000 16 03 03 00 5d 02 00 00 59 03 03 62 ba 01 96 bd |....]...Y..b....| -00000010 12 c5 9d 43 86 5e fe 8d 9e 77 a2 17 dc f3 a2 d6 |...C.^...w......| -00000020 ca 8f d4 49 ff 9b cb a5 bc 86 29 20 58 57 f3 d7 |...I......) XW..| -00000030 5e d8 b9 d7 95 54 f9 50 5c b6 78 44 29 bb 83 21 |^....T.P\.xD)..!| -00000040 77 b2 95 23 5d 4f bb 6a 15 60 e6 86 c0 09 00 00 |w..#]O.j.`......| +00000000 16 03 03 00 5d 02 00 00 59 03 03 6d b7 f7 cf 1d |....]...Y..m....| +00000010 f9 c0 02 cb ee 90 23 93 41 8e 26 24 3e 74 31 ce |......#.A.&$>t1.| +00000020 4f 53 f8 9d 0f 94 02 b2 66 c9 87 20 d6 5c 35 52 |OS......f.. .\5R| +00000030 4b b1 f2 bb 2e 1d 95 ff 7d 83 f0 58 a8 0a ed b1 |K.......}..X....| +00000040 54 25 03 ca ea 7b 8d 1a 8f 9f 43 51 c0 09 00 00 |T%...{....CQ....| 00000050 11 ff 01 00 01 00 00 0b 00 04 03 00 01 02 00 17 |................| 00000060 00 00 16 03 03 02 0e 0b 00 02 0a 00 02 07 00 02 |................| 00000070 04 30 82 02 00 30 82 01 62 02 09 00 b8 bf 2d 47 |.0...0..b.....-G| @@ -56,23 +56,23 @@ 00000240 8c 25 c1 33 13 83 0d 94 06 bb d4 37 7a f6 ec 7a |.%.3.......7z..z| 00000250 c9 86 2e dd d7 11 69 7f 85 7c 56 de fb 31 78 2b |......i..|V..1x+| 00000260 e4 c7 78 0d ae cb be 9e 4e 36 24 31 7b 6a 0f 39 |..x.....N6$1{j.9| -00000270 95 12 07 8f 2a 16 03 03 00 b7 0c 00 00 b3 03 00 |....*...........| -00000280 1d 20 e7 43 a8 15 b3 d3 ea fd b4 dd 02 83 09 c8 |. .C............| -00000290 76 8f 9b 0e d8 f1 9c e7 99 d5 80 0e fb b8 a1 5c |v..............\| -000002a0 f2 1e 04 03 00 8b 30 81 88 02 42 01 22 7d 76 28 |......0...B."}v(| -000002b0 67 0b 8c 78 65 0b d8 11 3e 29 70 02 49 d1 d7 c4 |g..xe...>)p.I...| -000002c0 50 7b fb 07 2e 8d 91 f6 c4 f8 56 be 75 c6 61 05 |P{........V.u.a.| -000002d0 43 42 2f f9 46 25 09 a6 a8 29 1d 95 6a 5c 65 fd |CB/.F%...)..j\e.| -000002e0 07 c1 88 1b f3 fd 52 7a e4 17 01 fe ad 02 42 01 |......Rz......B.| -000002f0 4f 77 cd d5 34 45 7d 3f 8f 70 ad 80 70 b9 77 9a |Ow..4E}?.p..p.w.| -00000300 08 c6 96 1c 95 14 76 17 90 05 fd 9a 38 be aa ff |......v.....8...| -00000310 64 76 35 ae 91 85 14 e5 e8 37 f7 0a b1 50 16 69 |dv5......7...P.i| -00000320 ab 80 14 77 ee c0 56 77 e5 17 ea d4 57 3c 04 23 |...w..Vw....W<.#| -00000330 d7 16 03 03 00 3a 0d 00 00 36 03 01 02 40 00 2e |.....:...6...@..| -00000340 04 03 05 03 06 03 08 07 08 08 08 09 08 0a 08 0b |................| -00000350 08 04 08 05 08 06 04 01 05 01 06 01 03 03 02 03 |................| -00000360 03 01 02 01 03 02 02 02 04 02 05 02 06 02 00 00 |................| -00000370 16 03 03 00 04 0e 00 00 00 |.........| +00000270 95 12 07 8f 2a 16 03 03 00 b6 0c 00 00 b2 03 00 |....*...........| +00000280 1d 20 04 b4 79 b4 2c 1d 0f b3 4b ff 67 e7 24 88 |. ..y.,...K.g.$.| +00000290 d6 db 4f 1e 66 da 0e f2 89 5a 53 ed 4e ba ad 4c |..O.f....ZS.N..L| +000002a0 81 0a 04 03 00 8a 30 81 87 02 42 01 fb 16 53 43 |......0...B...SC| +000002b0 2b 86 61 0a 58 a0 68 c1 cd 2c ff ec 79 7f 83 fa |+.a.X.h..,..y...| +000002c0 cc 0b 24 9d 98 54 d0 dc 90 55 e1 b3 e6 48 69 1a |..$..T...U...Hi.| +000002d0 55 62 f4 da 8f 60 db f7 76 80 d5 4d 37 f6 43 49 |Ub...`..v..M7.CI| +000002e0 95 3d 96 f6 e2 fd a4 07 ae 24 8c fa bd 02 41 20 |.=.......$....A | +000002f0 a1 50 78 a3 dd 99 c0 cf 74 f1 c0 79 b1 13 9d bc |.Px.....t..y....| +00000300 0b 37 cf 7c 09 11 b8 a4 71 65 e8 be ff 3a b9 85 |.7.|....qe...:..| +00000310 cd b4 30 f8 1f d6 2e 83 96 6c 01 3e d2 00 a7 5b |..0......l.>...[| +00000320 23 c6 d0 69 eb 90 49 e3 46 ed 45 96 3b 07 d4 a8 |#..i..I.F.E.;...| +00000330 16 03 03 00 3a 0d 00 00 36 03 01 02 40 00 2e 04 |....:...6...@...| +00000340 03 05 03 06 03 08 07 08 08 08 09 08 0a 08 0b 08 |................| +00000350 04 08 05 08 06 04 01 05 01 06 01 03 03 02 03 03 |................| +00000360 01 02 01 03 02 02 02 04 02 05 02 06 02 00 00 16 |................| +00000370 03 03 00 04 0e 00 00 00 |........| >>> Flow 3 (client to server) 00000000 16 03 03 01 fd 0b 00 01 f9 00 01 f6 00 01 f3 30 |...............0| 00000010 82 01 ef 30 82 01 58 a0 03 02 01 02 02 10 5c 19 |...0..X.......\.| @@ -109,31 +109,31 @@ 00000200 e5 35 16 03 03 00 25 10 00 00 21 20 2f e5 7d a3 |.5....%...! /.}.| 00000210 47 cd 62 43 15 28 da ac 5f bb 29 07 30 ff f6 84 |G.bC.(.._.).0...| 00000220 af c4 cf c2 ed 90 99 5f 58 cb 3b 74 16 03 03 00 |......._X.;t....| -00000230 88 0f 00 00 84 08 04 00 80 47 44 b3 b1 39 6e 07 |.........GD..9n.| -00000240 14 9c 0d 2f bd 5e 39 06 7a af b2 d0 52 9c 6b b8 |.../.^9.z...R.k.| -00000250 6e 07 59 e7 a2 c2 33 83 31 d6 42 79 25 ed 37 b0 |n.Y...3.1.By%.7.| -00000260 97 25 d5 cc a7 7b 54 36 a3 a2 7c 67 38 c2 92 e9 |.%...{T6..|g8...| -00000270 ab 58 59 4f 22 89 57 2b 27 2c d4 e8 7b 1d 5f 0b |.XYO".W+',..{._.| -00000280 1f 94 15 b0 38 67 0d a7 ff 66 2d fd 02 65 d6 8b |....8g...f-..e..| -00000290 ce e2 2a 3c 83 70 56 26 00 e6 1b 47 69 9e 9d 3b |..*<.pV&...Gi..;| -000002a0 81 88 49 58 a6 3a a1 5f 27 dc 7e 79 86 40 af 8c |..IX.:._'.~y.@..| -000002b0 35 17 83 92 da 81 7c 41 0d 14 03 03 00 01 01 16 |5.....|A........| +00000230 88 0f 00 00 84 08 04 00 80 3f 4a c2 4f 36 85 f0 |.........?J.O6..| +00000240 d0 c6 b6 8f f1 cc 45 c1 2f f2 c7 24 1e 0f 04 dc |......E./..$....| +00000250 f5 af 6e 38 eb aa a6 6f 36 f4 80 dd 78 78 a7 d4 |..n8...o6...xx..| +00000260 50 3a df e1 23 c4 3f 58 df 1a c0 1d 57 a5 46 3b |P:..#.?X....W.F;| +00000270 5d 09 ac 62 63 28 8a a2 b5 d4 9b 88 7c b9 4d b4 |]..bc(......|.M.| +00000280 66 b2 9d 53 6e 15 9c f2 9b c7 14 ca 19 7f 00 38 |f..Sn..........8| +00000290 81 a3 7b 44 e8 3d 6d 54 0f b3 81 fd 82 07 4d a1 |..{D.=mT......M.| +000002a0 3e 8c 30 34 cd 6e 55 96 58 bf 86 8b 9c f6 be 94 |>.04.nU.X.......| +000002b0 f4 a8 7e 4d 7f 03 07 7e 98 14 03 03 00 01 01 16 |..~M...~........| 000002c0 03 03 00 40 00 00 00 00 00 00 00 00 00 00 00 00 |...@............| -000002d0 00 00 00 00 09 20 b3 66 7d 40 5d 62 f0 21 0c 02 |..... .f}@]b.!..| -000002e0 66 75 9e 32 f7 28 e4 8e ad 90 18 7d 6a 2b f0 1c |fu.2.(.....}j+..| -000002f0 3e d4 6d 55 c7 a6 74 88 58 25 c3 69 df 0f 86 10 |>.mU..t.X%.i....| -00000300 3c 51 88 26 |>> Flow 4 (server to client) -00000000 14 03 03 00 01 01 16 03 03 00 40 80 4c 52 cc b6 |..........@.LR..| -00000010 b3 e1 4d 8c a7 26 70 f3 47 21 ed ff 01 45 41 91 |..M..&p.G!...EA.| -00000020 b7 ce 09 87 4d 5b d8 48 c5 9e b1 5d 42 e4 43 1c |....M[.H...]B.C.| -00000030 e0 90 c6 e2 20 64 80 30 6a e7 25 0f 7b 40 fe 8c |.... d.0j.%.{@..| -00000040 5f 80 b3 92 25 96 2b e9 38 f2 e3 |_...%.+.8..| +00000000 14 03 03 00 01 01 16 03 03 00 40 9e 65 27 5b 92 |..........@.e'[.| +00000010 1e 2b 1a bc 81 ab 85 29 51 c1 38 04 b6 97 e5 4b |.+.....)Q.8....K| +00000020 b1 7d a5 e2 6d e7 b1 1a 33 6c f1 3d a4 9c de 2d |.}..m...3l.=...-| +00000030 b3 8a 01 da cc f1 d7 83 b1 1e 84 cb b7 e7 fe e6 |................| +00000040 26 83 b0 2d 6f a9 77 46 55 44 7a |&..-o.wFUDz| >>> Flow 5 (client to server) 00000000 17 03 03 00 30 00 00 00 00 00 00 00 00 00 00 00 |....0...........| -00000010 00 00 00 00 00 6c d5 26 50 49 6f 1a 46 3a d2 3a |.....l.&PIo.F:.:| -00000020 ff b2 0b 17 65 ed 7f a4 b8 e8 82 f6 89 af 07 04 |....e...........| -00000030 bc 77 d6 74 34 15 03 03 00 30 00 00 00 00 00 00 |.w.t4....0......| -00000040 00 00 00 00 00 00 00 00 00 00 ca b6 5b 91 20 9d |............[. .| -00000050 91 42 33 eb f4 49 b6 38 24 fc 3c 8b f7 6c 6b fd |.B3..I.8$.<..lk.| -00000060 df e8 aa 07 18 29 cd 04 85 70 |.....)...p| +00000010 00 00 00 00 00 e2 55 06 b8 6f 63 c4 63 78 76 4b |......U..oc.cxvK| +00000020 c8 63 8b 4b c6 11 2c ff dc fc 20 f7 52 fe fa 5f |.c.K..,... .R.._| +00000030 e3 45 3a f2 a1 15 03 03 00 30 00 00 00 00 00 00 |.E:......0......| +00000040 00 00 00 00 00 00 00 00 00 00 0e cb 88 2f 1f be |............./..| +00000050 9c 76 4d db 75 7f eb 01 ae bd 76 28 07 41 49 6c |.vM.u.....v(.AIl| +00000060 4c 82 84 d5 fc d3 75 f4 4b 81 |L.....u.K.| diff --git a/testdata/Client-TLSv12-ClientCert-RSA-RSA b/testdata/Client-TLSv12-ClientCert-RSA-RSA index c36f282..25fc245 100644 --- a/testdata/Client-TLSv12-ClientCert-RSA-RSA +++ b/testdata/Client-TLSv12-ClientCert-RSA-RSA @@ -7,21 +7,21 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 7f 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 0a 00 08 00 1d 00 17 00 18 00 19 00 0b 00 02 01 |................| -000000a0 00 00 0d 00 1a 00 18 08 04 04 03 08 07 08 05 08 |................| -000000b0 06 04 01 05 01 06 01 05 03 06 03 02 01 02 03 ff |................| -000000c0 01 00 01 00 00 17 00 00 00 12 00 00 00 2b 00 09 |.............+..| +00000080 01 00 00 7f 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 19 00 0d |................| +000000b0 00 1a 00 18 08 04 04 03 08 07 08 05 08 06 04 01 |................| +000000c0 05 01 06 01 05 03 06 03 02 01 02 03 00 2b 00 09 |.............+..| 000000d0 08 03 04 03 03 03 02 03 01 00 33 00 26 00 24 00 |..........3.&.$.| 000000e0 1d 00 20 2f e5 7d a3 47 cd 62 43 15 28 da ac 5f |.. /.}.G.bC.(.._| 000000f0 bb 29 07 30 ff f6 84 af c4 cf c2 ed 90 99 5f 58 |.).0.........._X| 00000100 cb 3b 74 |.;t| >>> Flow 2 (server to client) -00000000 16 03 03 00 5d 02 00 00 59 03 03 04 e5 45 68 3b |....]...Y....Eh;| -00000010 73 6e 96 92 17 2a e1 5e f8 6a 16 a1 5e a9 55 d0 |sn...*.^.j..^.U.| -00000020 f5 2a 30 1d 94 96 5b 76 d4 c3 d5 20 2b 8a eb 6d |.*0...[v... +..m| -00000030 9c 5a 72 4e a9 df e0 5b 91 7e eb c7 e4 12 6d 1d |.ZrN...[.~....m.| -00000040 a5 3f 54 e2 27 dd 07 4f df be b2 e7 c0 2f 00 00 |.?T.'..O...../..| +00000000 16 03 03 00 5d 02 00 00 59 03 03 5f da ab 10 86 |....]...Y.._....| +00000010 4c 91 60 4c ec 28 20 d4 37 84 c4 d0 87 bb 9d a9 |L.`L.( .7.......| +00000020 5a c0 86 81 d9 91 38 5a ef 3f ae 20 ec 14 b6 de |Z.....8Z.?. ....| +00000030 b7 cf 59 09 43 dc 59 3f 74 89 10 f2 82 ea 60 46 |..Y.C.Y?t.....`F| +00000040 8f a3 6a 0f 61 0f 2d 66 24 c3 fb 7f c0 2f 00 00 |..j.a.-f$..../..| 00000050 11 ff 01 00 01 00 00 0b 00 04 03 00 01 02 00 17 |................| 00000060 00 00 16 03 03 02 59 0b 00 02 55 00 02 52 00 02 |......Y...U..R..| 00000070 4f 30 82 02 4b 30 82 01 b4 a0 03 02 01 02 02 09 |O0..K0..........| @@ -61,18 +61,18 @@ 00000290 73 bb b3 43 77 8d 0c 1c f1 0f a1 d8 40 83 61 c9 |s..Cw.......@.a.| 000002a0 4c 72 2b 9d ae db 46 06 06 4d f4 c1 b3 3e c0 d1 |Lr+...F..M...>..| 000002b0 bd 42 d4 db fe 3d 13 60 84 5c 21 d3 3b e9 fa e7 |.B...=.`.\!.;...| -000002c0 16 03 03 00 ac 0c 00 00 a8 03 00 1d 20 77 dc b7 |............ w..| -000002d0 44 64 c9 3b e9 e2 bf b5 01 47 c9 64 f8 ef ee 33 |Dd.;.....G.d...3| -000002e0 e2 81 a1 af 05 c0 31 37 1f 8d 3c 55 45 08 04 00 |......17......k2..D...| -00000320 54 7e 57 74 92 a3 4e f9 cf 70 52 b1 50 9a 60 4f |T~Wt..N..pR.P.`O| -00000330 79 72 5d c4 53 ba 19 ff 05 56 1d 41 be 18 77 71 |yr].S....V.A..wq| -00000340 5c 00 84 5e 70 fa cf 9e 8e d2 62 7d 48 6a fe 75 |\..^p.....b}Hj.u| -00000350 6a 67 5b 82 52 76 d4 fc 96 a4 ad fa a9 ea fc e5 |jg[.Rv..........| -00000360 97 dd 53 a0 ef 53 00 27 72 ae 5b c9 06 f6 43 c8 |..S..S.'r.[...C.| -00000370 d5 16 03 03 00 3a 0d 00 00 36 03 01 02 40 00 2e |.....:...6...@..| +000002c0 16 03 03 00 ac 0c 00 00 a8 03 00 1d 20 2c c4 b9 |............ ,..| +000002d0 13 19 85 99 cb 09 f3 5c 3a a1 b2 16 ee 77 6a cd |.......\:....wj.| +000002e0 23 6c 08 00 7e 6b c0 67 a8 cd 8b 62 64 08 04 00 |#l..~k.g...bd...| +000002f0 80 90 74 bf ce f7 94 f1 94 b1 95 04 4a ab d6 08 |..t.........J...| +00000300 23 11 8d ce 4e 7b 36 ee 67 d2 26 af 11 0e 33 58 |#...N{6.g.&...3X| +00000310 12 cb e5 3b 5b 5c f3 d1 82 19 2e 55 6b 98 05 6e |...;[\.....Uk..n| +00000320 3c 5e 04 f5 3e df 76 c3 e5 46 e7 a6 bb f7 d4 d5 |<^..>.v..F......| +00000330 e8 fd 20 d3 ce 3e 9d a0 90 9a 10 52 a7 04 c9 e9 |.. ..>.....R....| +00000340 28 6f 3f ff e1 0a 10 d0 25 04 ea e4 84 4c b7 80 |(o?.....%....L..| +00000350 e4 fe a7 a6 da db cc b0 e0 62 80 10 fc 03 16 94 |.........b......| +00000360 f2 dd 0d 3f aa 11 45 af e3 e4 7b e6 bc d6 75 91 |...?..E...{...u.| +00000370 99 16 03 03 00 3a 0d 00 00 36 03 01 02 40 00 2e |.....:...6...@..| 00000380 04 03 05 03 06 03 08 07 08 08 08 09 08 0a 08 0b |................| 00000390 08 04 08 05 08 06 04 01 05 01 06 01 03 03 02 03 |................| 000003a0 03 01 02 01 03 02 02 02 04 02 05 02 06 02 00 00 |................| @@ -113,26 +113,26 @@ 00000200 e5 35 16 03 03 00 25 10 00 00 21 20 2f e5 7d a3 |.5....%...! /.}.| 00000210 47 cd 62 43 15 28 da ac 5f bb 29 07 30 ff f6 84 |G.bC.(.._.).0...| 00000220 af c4 cf c2 ed 90 99 5f 58 cb 3b 74 16 03 03 00 |......._X.;t....| -00000230 88 0f 00 00 84 08 04 00 80 56 b9 1d 6a ed f4 b2 |.........V..j...| -00000240 e9 2b 9c 6b a3 18 78 1c 76 18 57 7d a3 05 6f 7e |.+.k..x.v.W}..o~| -00000250 36 52 e2 d7 35 f9 c2 2d 81 db ca ee 85 f9 45 d8 |6R..5..-......E.| -00000260 d7 ec 76 9c 1d 85 b7 38 9d 12 f6 64 dc fe ca 16 |..v....8...d....| -00000270 2f ad 91 ae b5 a1 18 bf 85 df 07 bc 7b 42 5b 6d |/...........{B[m| -00000280 ad 54 c7 ae 42 b0 3b e7 b7 70 b9 80 ef a1 65 e7 |.T..B.;..p....e.| -00000290 46 aa e4 9a 22 d9 ce 1f 7d 33 b9 62 4d 3d 77 8a |F..."...}3.bM=w.| -000002a0 b8 ac 38 64 f0 aa 95 be be 78 bc ad 94 b8 90 29 |..8d.....x.....)| -000002b0 72 7f d1 ed f0 bf 79 13 00 14 03 03 00 01 01 16 |r.....y.........| -000002c0 03 03 00 28 00 00 00 00 00 00 00 00 b6 3d 7b 87 |...(.........={.| -000002d0 c8 a0 18 96 ec f8 36 f4 4c 18 7e 13 6b 56 1e de |......6.L.~.kV..| -000002e0 80 8a 37 1b 4e 84 85 3f 60 e8 50 55 |..7.N..?`.PU| +00000230 88 0f 00 00 84 08 04 00 80 4d c1 8a 3d 2b 1f a0 |.........M..=+..| +00000240 ad 6f 1c b6 44 7c cc 0d 21 6f e8 31 51 58 51 fe |.o..D|..!o.1QXQ.| +00000250 84 f3 41 40 12 48 29 0d 20 16 d1 6a 4b 38 0b c8 |..A@.H). ..jK8..| +00000260 b3 70 3f 4a ca 17 da 05 30 ec 6c 4f 55 e2 ee e5 |.p?J....0.lOU...| +00000270 9a 8c a7 9f c1 96 79 cf 53 b6 67 c8 cb 67 d3 23 |......y.S.g..g.#| +00000280 07 8a 3f ef df e5 e6 84 f6 5f 5e 23 57 89 cc 77 |..?......_^#W..w| +00000290 99 ed 3d 58 8a ec eb bb 64 62 d1 44 7f b6 45 85 |..=X....db.D..E.| +000002a0 89 06 90 56 48 98 8a 43 93 64 53 df 3a 8c b3 93 |...VH..C.dS.:...| +000002b0 91 81 7b 60 95 8f 99 99 eb 14 03 03 00 01 01 16 |..{`............| +000002c0 03 03 00 28 00 00 00 00 00 00 00 00 dd 93 96 02 |...(............| +000002d0 47 0e 1d 2f 6a 76 12 e5 56 53 8f 7f c1 cd f3 5e |G../jv..VS.....^| +000002e0 3c 94 35 1b fe d5 33 97 b2 5b a3 29 |<.5...3..[.)| >>> Flow 4 (server to client) -00000000 14 03 03 00 01 01 16 03 03 00 28 38 5d b5 b3 a8 |..........(8]...| -00000010 94 65 de ee 2e e9 4f f3 13 9e ff 0a f4 d2 b0 9e |.e....O.........| -00000020 e7 ec 8c 7c 03 8f c3 fc c6 97 75 5b 96 1d 64 ad |...|......u[..d.| -00000030 4f ee dd |O..| +00000000 14 03 03 00 01 01 16 03 03 00 28 de 60 8a ea b5 |..........(.`...| +00000010 74 66 35 35 39 bb 62 ab 17 7d 91 c3 1a 5a e5 6c |tf559.b..}...Z.l| +00000020 49 14 c8 bc bd d6 b6 7e 2f 8e d4 40 5a ae ee 89 |I......~/..@Z...| +00000030 89 ae af |...| >>> Flow 5 (client to server) -00000000 17 03 03 00 1e 00 00 00 00 00 00 00 01 a5 03 23 |...............#| -00000010 3a 39 6b b5 e5 71 c8 87 07 b4 c9 79 2b 84 d9 9d |:9k..q.....y+...| -00000020 1b 21 26 15 03 03 00 1a 00 00 00 00 00 00 00 02 |.!&.............| -00000030 f5 e9 fb d2 c8 57 34 45 e1 27 8e 35 6d 36 95 10 |.....W4E.'.5m6..| -00000040 76 0d |v.| +00000000 17 03 03 00 1e 00 00 00 00 00 00 00 01 3c 92 2d |.............<.-| +00000010 44 23 5b eb 34 dc 9a 4d c2 fe a7 88 cb 6f 8d 62 |D#[.4..M.....o.b| +00000020 4b 2a bf 15 03 03 00 1a 00 00 00 00 00 00 00 02 |K*..............| +00000030 90 82 82 54 5d 63 6e 8b 50 71 6e e8 fd 75 96 9e |...T]cn.Pqn..u..| +00000040 d0 0d |..| diff --git a/testdata/Client-TLSv12-ClientCert-RSA-RSAPKCS1v15 b/testdata/Client-TLSv12-ClientCert-RSA-RSAPKCS1v15 index bf2f5c4..6500aec 100644 --- a/testdata/Client-TLSv12-ClientCert-RSA-RSAPKCS1v15 +++ b/testdata/Client-TLSv12-ClientCert-RSA-RSAPKCS1v15 @@ -7,21 +7,21 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 7f 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 0a 00 08 00 1d 00 17 00 18 00 19 00 0b 00 02 01 |................| -000000a0 00 00 0d 00 1a 00 18 08 04 04 03 08 07 08 05 08 |................| -000000b0 06 04 01 05 01 06 01 05 03 06 03 02 01 02 03 ff |................| -000000c0 01 00 01 00 00 17 00 00 00 12 00 00 00 2b 00 09 |.............+..| +00000080 01 00 00 7f 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 19 00 0d |................| +000000b0 00 1a 00 18 08 04 04 03 08 07 08 05 08 06 04 01 |................| +000000c0 05 01 06 01 05 03 06 03 02 01 02 03 00 2b 00 09 |.............+..| 000000d0 08 03 04 03 03 03 02 03 01 00 33 00 26 00 24 00 |..........3.&.$.| 000000e0 1d 00 20 2f e5 7d a3 47 cd 62 43 15 28 da ac 5f |.. /.}.G.bC.(.._| 000000f0 bb 29 07 30 ff f6 84 af c4 cf c2 ed 90 99 5f 58 |.).0.........._X| 00000100 cb 3b 74 |.;t| >>> Flow 2 (server to client) -00000000 16 03 03 00 5d 02 00 00 59 03 03 0d ab 4e 27 0a |....]...Y....N'.| -00000010 9c 1b 91 00 41 33 eb a7 d6 84 45 e0 dd f7 8a a1 |....A3....E.....| -00000020 62 c4 e0 2d 2f 51 4f 33 21 2a 6d 20 24 2d d0 3f |b..-/QO3!*m $-.?| -00000030 cc 5a 9c 5f b7 53 54 fc c7 bf a9 2c 8e 39 16 e4 |.Z._.ST....,.9..| -00000040 7d 80 72 6b 95 93 51 41 8a da 67 29 c0 2f 00 00 |}.rk..QA..g)./..| +00000000 16 03 03 00 5d 02 00 00 59 03 03 7b 21 bd ee 4b |....]...Y..{!..K| +00000010 af e3 88 cb 18 15 e5 f3 ef a5 a7 b3 a1 66 06 b2 |.............f..| +00000020 f1 cc d7 36 7e 18 d1 f6 2e 3e cd 20 34 09 01 9f |...6~....>. 4...| +00000030 c6 80 10 43 c1 ed e6 c1 29 1c ed ac 61 36 37 4f |...C....)...a67O| +00000040 8e 00 44 9d b9 cb 51 0b a2 9c 64 be c0 2f 00 00 |..D...Q...d../..| 00000050 11 ff 01 00 01 00 00 0b 00 04 03 00 01 02 00 17 |................| 00000060 00 00 16 03 03 02 59 0b 00 02 55 00 02 52 00 02 |......Y...U..R..| 00000070 4f 30 82 02 4b 30 82 01 b4 a0 03 02 01 02 02 09 |O0..K0..........| @@ -61,18 +61,18 @@ 00000290 73 bb b3 43 77 8d 0c 1c f1 0f a1 d8 40 83 61 c9 |s..Cw.......@.a.| 000002a0 4c 72 2b 9d ae db 46 06 06 4d f4 c1 b3 3e c0 d1 |Lr+...F..M...>..| 000002b0 bd 42 d4 db fe 3d 13 60 84 5c 21 d3 3b e9 fa e7 |.B...=.`.\!.;...| -000002c0 16 03 03 00 ac 0c 00 00 a8 03 00 1d 20 94 9e e3 |............ ...| -000002d0 41 3b c6 0c cc 05 92 ac ea 8c 9e 2d e5 bc 42 30 |A;.........-..B0| -000002e0 47 87 d6 b3 6e d5 73 9f ca 2a 48 9a 04 04 01 00 |G...n.s..*H.....| -000002f0 80 d6 f2 ef 4a 3f ca 47 9a 13 e4 38 3b d8 23 77 |....J?.G...8;.#w| -00000300 b4 84 fa 89 c4 e6 e2 84 e2 a7 50 81 e4 b2 b8 1f |..........P.....| -00000310 04 15 0d 50 5f 4a 95 e3 0d 27 c3 2f 96 9b 92 c0 |...P_J...'./....| -00000320 fb 6a 52 c1 a4 39 39 7e 8f da 53 5e 34 db 62 01 |.jR..99~..S^4.b.| -00000330 6d 0a 14 bd b5 0a 24 b5 df b2 99 56 cd 68 a6 75 |m.....$....V.h.u| -00000340 9f 70 1a f6 d3 6b f6 68 ef bc 75 09 69 c4 18 4a |.p...k.h..u.i..J| -00000350 dc 51 c2 65 01 36 f1 c0 d9 34 66 d1 c2 dc d9 0d |.Q.e.6...4f.....| -00000360 f5 74 4f 84 df b0 c2 d2 0a d6 51 fc 6e 3c d8 74 |.tO.......Q.n<.t| -00000370 35 16 03 03 00 0c 0d 00 00 08 01 01 00 02 04 01 |5...............| +000002c0 16 03 03 00 ac 0c 00 00 a8 03 00 1d 20 d3 22 bb |............ .".| +000002d0 c4 42 90 54 0a 43 f6 26 06 c1 ad 71 c8 82 ba 03 |.B.T.C.&...q....| +000002e0 9b cd be a4 a8 04 5a 30 69 ec b5 c9 79 04 01 00 |......Z0i...y...| +000002f0 80 ab c7 ca 24 9b db 7d 8c 81 c4 c4 46 49 2a 45 |....$..}....FI*E| +00000300 69 31 1b dc ef 01 ce 9f e4 da cf 6c 04 4c e3 4e |i1.........l.L.N| +00000310 16 84 05 fe 48 f4 21 60 fc d4 e1 6c 48 8c 87 2d |....H.!`...lH..-| +00000320 1f 56 2c ad 88 2b 5c 8d 4f 36 93 d6 a3 b1 32 4a |.V,..+\.O6....2J| +00000330 ef 0f e6 db 82 1c f2 ea 38 08 2a 62 8b a3 bd 4e |........8.*b...N| +00000340 8b 2a ae eb 0e e5 f1 88 ff 3c de f8 ed d7 c3 07 |.*.......<......| +00000350 05 92 bb e5 6d 15 23 c8 54 19 a6 cf d1 4f e2 b1 |....m.#.T....O..| +00000360 a3 4d ff 6f 22 32 5b 58 f7 58 c1 9f 58 59 b5 e2 |.M.o"2[X.X..XY..| +00000370 7b 16 03 03 00 0c 0d 00 00 08 01 01 00 02 04 01 |{...............| 00000380 00 00 16 03 03 00 04 0e 00 00 00 |...........| >>> Flow 3 (client to server) 00000000 16 03 03 01 fd 0b 00 01 f9 00 01 f6 00 01 f3 30 |...............0| @@ -110,26 +110,26 @@ 00000200 e5 35 16 03 03 00 25 10 00 00 21 20 2f e5 7d a3 |.5....%...! /.}.| 00000210 47 cd 62 43 15 28 da ac 5f bb 29 07 30 ff f6 84 |G.bC.(.._.).0...| 00000220 af c4 cf c2 ed 90 99 5f 58 cb 3b 74 16 03 03 00 |......._X.;t....| -00000230 88 0f 00 00 84 04 01 00 80 81 fe 69 7d 68 10 74 |...........i}h.t| -00000240 e4 9a d0 11 7a c4 e4 11 4c 7c 8a 13 f1 cf 0e 33 |....z...L|.....3| -00000250 a5 3d d2 1f a2 73 c4 8e 2d 9e 87 45 b6 d2 dc 98 |.=...s..-..E....| -00000260 fe 4d 86 8d ad 87 a8 2c e3 9f 08 a0 4f 78 4d 9c |.M.....,....OxM.| -00000270 de c2 92 7e dc 48 6b a9 e7 cc 58 a9 45 41 04 fb |...~.Hk...X.EA..| -00000280 48 fa d1 e4 5c 71 92 d5 bf e4 92 a1 66 07 b8 73 |H...\q......f..s| -00000290 b0 45 98 12 8e d8 2d e8 3e 85 05 e5 d3 38 ea 3a |.E....-.>....8.:| -000002a0 5d 33 4a 32 f9 ff 8b 18 ae 55 b7 f3 d2 0e e7 b8 |]3J2.....U......| -000002b0 4e e8 bc 4f c6 a3 65 c1 a1 14 03 03 00 01 01 16 |N..O..e.........| -000002c0 03 03 00 28 00 00 00 00 00 00 00 00 da 49 06 a7 |...(.........I..| -000002d0 0e a4 7a df 94 f1 57 43 21 ef 85 ee 9f 52 f2 03 |..z...WC!....R..| -000002e0 5a 79 58 7a a0 b2 1f 9e 1d f9 5a d3 |ZyXz......Z.| +00000230 88 0f 00 00 84 04 01 00 80 8f 22 b5 46 ab 82 02 |..........".F...| +00000240 f8 a8 f8 63 d9 0f eb d4 2b 8d 02 de ce 79 d5 a1 |...c....+....y..| +00000250 20 bb 70 7a b2 36 6a b5 52 81 f5 ea f7 23 b5 41 | .pz.6j.R....#.A| +00000260 86 35 90 cc 64 4a 68 7e e3 ae c1 97 32 3b c2 a9 |.5..dJh~....2;..| +00000270 e0 f0 07 14 63 d5 08 15 59 46 f5 ea a6 39 5c 98 |....c...YF...9\.| +00000280 39 7e 17 d8 74 ae 05 a3 f5 3a 71 74 e8 b4 c9 a4 |9~..t....:qt....| +00000290 1c 82 04 ca fe 5f 97 23 8a c1 f9 ce d1 5d 0e 81 |....._.#.....]..| +000002a0 da 5f e1 b6 76 80 3c cf 9f 19 79 cf 33 d0 0a fe |._..v.<...y.3...| +000002b0 19 fc 2d 9a bb 24 cd d4 79 14 03 03 00 01 01 16 |..-..$..y.......| +000002c0 03 03 00 28 00 00 00 00 00 00 00 00 28 78 b8 0b |...(........(x..| +000002d0 59 d8 a8 11 21 ed 45 74 02 00 50 33 42 b9 0a d2 |Y...!.Et..P3B...| +000002e0 8c 9c a3 45 6e b5 9d 3e 5b 30 a9 2e |...En..>[0..| >>> Flow 4 (server to client) -00000000 14 03 03 00 01 01 16 03 03 00 28 22 7a 58 97 ef |..........("zX..| -00000010 f2 e6 4a c1 10 ca 63 52 e0 82 87 b4 9d d5 2f c4 |..J...cR....../.| -00000020 68 f1 4a d5 e8 ae 3a 22 9e f7 b3 07 8f a4 8c 18 |h.J...:"........| -00000030 2c 44 65 |,De| +00000000 14 03 03 00 01 01 16 03 03 00 28 f8 f5 85 19 36 |..........(....6| +00000010 be 6e 58 45 66 04 c4 f9 e7 fd 50 55 3b 07 6c 50 |.nXEf.....PU;.lP| +00000020 16 8c 2e 72 cf be 78 0a 8a 82 91 ed c1 72 10 d3 |...r..x......r..| +00000030 cf 42 b5 |.B.| >>> Flow 5 (client to server) -00000000 17 03 03 00 1e 00 00 00 00 00 00 00 01 2c ee 44 |.............,.D| -00000010 2d 89 8f 1f bd c2 de ac 8b 3c f2 35 d1 bd 17 4e |-........<.5...N| -00000020 65 3c 47 15 03 03 00 1a 00 00 00 00 00 00 00 02 |e>> Flow 2 (server to client) -00000000 16 03 03 00 5d 02 00 00 59 03 03 87 97 ae 0d d7 |....]...Y.......| -00000010 e4 be cd c5 ca 90 a8 85 23 c8 e3 32 15 f4 29 d8 |........#..2..).| -00000020 47 d7 ae e7 d8 7b 71 f5 c4 ea 07 20 e4 fd d6 48 |G....{q.... ...H| -00000030 10 13 e0 9b 06 e1 d7 b1 93 94 38 16 b7 a0 ef 80 |..........8.....| -00000040 2e b7 67 d6 ff 73 99 bf 67 cc 62 a1 c0 2f 00 00 |..g..s..g.b../..| +00000000 16 03 03 00 5d 02 00 00 59 03 03 0d 73 c5 43 a1 |....]...Y...s.C.| +00000010 71 b6 21 da 7a f6 76 44 60 8a 84 ec 6b 1d 70 01 |q.!.z.vD`...k.p.| +00000020 d8 b2 29 48 db 5d ea da ea 79 bb 20 3f b9 66 fe |..)H.]...y. ?.f.| +00000030 73 db fc 90 18 3f ac e5 1f 5d 86 24 80 75 ec a3 |s....?...].$.u..| +00000040 c6 aa e9 05 c1 47 21 bd 30 f6 41 43 c0 2f 00 00 |.....G!.0.AC./..| 00000050 11 ff 01 00 01 00 00 0b 00 04 03 00 01 02 00 17 |................| 00000060 00 00 16 03 03 02 66 0b 00 02 62 00 02 5f 00 02 |......f...b.._..| 00000070 5c 30 82 02 58 30 82 01 8d a0 03 02 01 02 02 11 |\0..X0..........| @@ -62,17 +62,17 @@ 000002a0 fa b1 3f 14 11 89 66 79 d1 8e 88 0e 0b a0 9e 30 |..?...fy.......0| 000002b0 2a c0 67 ef ca 46 02 88 e9 53 81 22 69 22 97 ad |*.g..F...S."i"..| 000002c0 80 93 d4 f7 dd 70 14 24 d7 70 0a 46 a1 16 03 03 |.....p.$.p.F....| -000002d0 00 ac 0c 00 00 a8 03 00 1d 20 19 11 2f cc 8b d4 |......... ../...| -000002e0 74 7c 77 34 b0 c7 4f 49 85 d1 f3 b0 2c 0e 83 26 |t|w4..OI....,..&| -000002f0 ee c1 2c 32 c1 82 43 3c cd 1b 08 04 00 80 68 33 |..,2..C<......h3| -00000300 a3 71 38 a8 70 34 04 91 e0 7b b3 44 46 45 54 a9 |.q8.p4...{.DFET.| -00000310 af ad 50 0d b6 91 7c 87 c7 4c 99 2d 02 9d 57 57 |..P...|..L.-..WW| -00000320 ae 2a 25 63 82 32 f0 4a 14 cd d3 b4 ca b8 bc d9 |.*%c.2.J........| -00000330 ff 1e 01 93 20 6e 27 97 04 31 c4 d8 e9 a6 84 1e |.... n'..1......| -00000340 96 6c a6 25 cc 93 e7 2d 15 32 e1 ad 01 7d fb 2c |.l.%...-.2...}.,| -00000350 12 04 5d 59 f6 bc 90 e8 cc d7 48 6d 46 c4 ed 64 |..]Y......HmF..d| -00000360 6b 41 5b 9d 9a 3b c8 11 57 bb b8 b1 cb c6 54 d6 |kA[..;..W.....T.| -00000370 08 34 7e ad e3 59 7b f7 90 77 e6 50 95 aa 16 03 |.4~..Y{..w.P....| +000002d0 00 ac 0c 00 00 a8 03 00 1d 20 03 05 56 dd 40 c0 |......... ..V.@.| +000002e0 b6 4d 5a df 26 e7 4a f1 a8 47 ef af 12 6e 5f 01 |.MZ.&.J..G...n_.| +000002f0 2a 7a 19 1a 45 52 8c 47 d2 53 08 04 00 80 8a 6a |*z..ER.G.S.....j| +00000300 9d 8b 38 73 da 92 bc f6 05 79 90 af 7a 43 59 62 |..8s.....y..zCYb| +00000310 bc 97 b6 af ef ce 5f 59 07 81 93 bc c5 3c 5f f9 |......_Y.....<_.| +00000320 4e 04 45 74 5e cc 7a 6f 82 7a cf 86 0d 68 c9 35 |N.Et^.zo.z...h.5| +00000330 1d 62 f0 3c ee 77 b5 4c 3a 40 ec 89 fc 97 ff a6 |.b.<.w.L:@......| +00000340 34 13 8b bc 6b 83 92 e8 52 c5 c6 42 c9 25 ad 37 |4...k...R..B.%.7| +00000350 41 e7 5a 52 d8 0f 7d fd a8 9e 86 c6 1b b2 8b 50 |A.ZR..}........P| +00000360 2a 1c 15 56 00 d8 a8 85 86 05 28 7f a1 3e ba f2 |*..V......(..>..| +00000370 fe 92 07 c8 a4 4a 2a 5f d1 53 82 09 9c 65 16 03 |.....J*_.S...e..| 00000380 03 00 0c 0d 00 00 08 01 01 00 02 08 04 00 00 16 |................| 00000390 03 03 00 04 0e 00 00 00 |........| >>> Flow 3 (client to server) @@ -118,26 +118,26 @@ 00000270 10 00 00 21 20 2f e5 7d a3 47 cd 62 43 15 28 da |...! /.}.G.bC.(.| 00000280 ac 5f bb 29 07 30 ff f6 84 af c4 cf c2 ed 90 99 |._.).0..........| 00000290 5f 58 cb 3b 74 16 03 03 00 88 0f 00 00 84 08 04 |_X.;t...........| -000002a0 00 80 a2 37 90 1d d9 05 16 91 e6 5d 93 ec d0 4c |...7.......]...L| -000002b0 c9 eb ed d3 66 fc 36 55 ee cb e0 bc aa 41 11 fb |....f.6U.....A..| -000002c0 91 d5 2c 81 d4 08 ee ce f8 96 cd 73 20 73 5b 8c |..,........s s[.| -000002d0 85 45 17 fa 6d 06 db a6 68 49 5e a8 2b 86 83 0f |.E..m...hI^.+...| -000002e0 e2 52 04 96 8c c9 a0 f8 ed 64 51 e3 6e b4 b1 48 |.R.......dQ.n..H| -000002f0 c7 f6 21 c9 aa c0 8d 01 00 43 14 d3 16 ed 9a 3c |..!......C.....<| -00000300 d2 14 57 90 22 f6 52 bc 44 64 88 40 03 93 56 8a |..W.".R.Dd.@..V.| -00000310 4f 50 ad 73 ff bc b4 72 cd e2 01 01 50 88 f9 1c |OP.s...r....P...| -00000320 4f 4d 14 03 03 00 01 01 16 03 03 00 28 00 00 00 |OM..........(...| -00000330 00 00 00 00 00 07 15 02 d9 a8 bd 4b c4 61 57 e0 |...........K.aW.| -00000340 a6 c0 11 05 bc 25 0b 4d fb 36 c4 19 80 e2 59 3e |.....%.M.6....Y>| -00000350 00 a0 7b 87 42 |..{.B| +000002a0 00 80 2e 4c af b1 f2 9c de 14 92 81 c4 7d d1 2f |...L.........}./| +000002b0 a3 ba ba df 6f 26 da 2d 86 b4 1f 60 cd fe e7 c1 |....o&.-...`....| +000002c0 77 02 a5 58 3f 6a fc 1d ef 93 23 0a 9c c9 70 93 |w..X?j....#...p.| +000002d0 f8 0c 67 fd 58 83 96 85 62 da 31 e7 a6 78 9f 1c |..g.X...b.1..x..| +000002e0 dc 02 b3 b8 bc 05 26 92 e8 6a e7 3c db 5f 80 ee |......&..j.<._..| +000002f0 12 75 ff e6 36 36 e6 75 c2 77 d9 63 ef 60 89 db |.u..66.u.w.c.`..| +00000300 21 aa 27 85 11 9b 8c eb be a3 e3 34 0e 01 93 ca |!.'........4....| +00000310 a6 65 e3 cd 0f b8 b5 c6 f0 d7 15 69 db 4b 57 d2 |.e.........i.KW.| +00000320 05 0d 14 03 03 00 01 01 16 03 03 00 28 00 00 00 |............(...| +00000330 00 00 00 00 00 b5 09 a0 c4 55 89 df 8a 60 83 f3 |.........U...`..| +00000340 82 12 55 1d d5 50 11 81 74 0f cd b5 ed 9a 00 e7 |..U..P..t.......| +00000350 58 f7 65 0e 8d |X.e..| >>> Flow 4 (server to client) -00000000 14 03 03 00 01 01 16 03 03 00 28 8b ae 36 31 a0 |..........(..61.| -00000010 0a ba f4 e8 45 6d e2 55 8d 9d 61 e4 80 b6 4e bb |....Em.U..a...N.| -00000020 8c 7f e0 2b ea fc 4d e7 4c 60 c1 c6 91 92 ef 46 |...+..M.L`.....F| -00000030 00 19 b9 |...| +00000000 14 03 03 00 01 01 16 03 03 00 28 3f eb 87 50 b0 |..........(?..P.| +00000010 ae c2 fd 68 30 95 94 61 1c 78 1e 60 3e 38 17 ef |...h0..a.x.`>8..| +00000020 ed 9b f1 10 26 5e 53 a3 8c 46 2e 6c 24 b2 ab a7 |....&^S..F.l$...| +00000030 6c f0 ea |l..| >>> Flow 5 (client to server) -00000000 17 03 03 00 1e 00 00 00 00 00 00 00 01 61 0d 4c |.............a.L| -00000010 bf 57 34 f8 b3 f7 33 d6 49 46 66 14 e8 b2 e4 e0 |.W4...3.IFf.....| -00000020 de 82 d1 15 03 03 00 1a 00 00 00 00 00 00 00 02 |................| -00000030 76 2e 52 63 53 26 93 e3 32 59 de d9 62 e8 f4 93 |v.RcS&..2Y..b...| -00000040 65 bc |e.| +00000000 17 03 03 00 1e 00 00 00 00 00 00 00 01 fe de 40 |...............@| +00000010 52 50 79 da 5f 31 52 52 d8 96 04 35 86 92 03 0b |RPy._1RR...5....| +00000020 6f 5f 04 15 03 03 00 1a 00 00 00 00 00 00 00 02 |o_..............| +00000030 9c 85 24 b0 a9 17 24 cf 18 f6 ef f5 0d c6 77 6d |..$...$.......wm| +00000040 e0 b2 |..| diff --git a/testdata/Client-TLSv12-ECDHE-ECDSA-AES b/testdata/Client-TLSv12-ECDHE-ECDSA-AES index dd7dfab..774cb40 100644 --- a/testdata/Client-TLSv12-ECDHE-ECDSA-AES +++ b/testdata/Client-TLSv12-ECDHE-ECDSA-AES @@ -7,21 +7,21 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 7f 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 0a 00 08 00 1d 00 17 00 18 00 19 00 0b 00 02 01 |................| -000000a0 00 00 0d 00 1a 00 18 08 04 04 03 08 07 08 05 08 |................| -000000b0 06 04 01 05 01 06 01 05 03 06 03 02 01 02 03 ff |................| -000000c0 01 00 01 00 00 17 00 00 00 12 00 00 00 2b 00 09 |.............+..| +00000080 01 00 00 7f 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 19 00 0d |................| +000000b0 00 1a 00 18 08 04 04 03 08 07 08 05 08 06 04 01 |................| +000000c0 05 01 06 01 05 03 06 03 02 01 02 03 00 2b 00 09 |.............+..| 000000d0 08 03 04 03 03 03 02 03 01 00 33 00 26 00 24 00 |..........3.&.$.| 000000e0 1d 00 20 2f e5 7d a3 47 cd 62 43 15 28 da ac 5f |.. /.}.G.bC.(.._| 000000f0 bb 29 07 30 ff f6 84 af c4 cf c2 ed 90 99 5f 58 |.).0.........._X| 00000100 cb 3b 74 |.;t| >>> Flow 2 (server to client) -00000000 16 03 03 00 5d 02 00 00 59 03 03 53 0a a8 7d 57 |....]...Y..S..}W| -00000010 28 ed 64 43 b5 dd b2 15 a8 6f 88 09 6a 90 4c 23 |(.dC.....o..j.L#| -00000020 06 49 b6 1a 56 b5 a0 a2 68 af 7d 20 5a 4a d6 c3 |.I..V...h.} ZJ..| -00000030 ed 18 12 98 b4 4e f8 f2 df d7 ee 6f e9 c6 c7 82 |.....N.....o....| -00000040 5c bb 79 70 a5 59 51 c7 7f 41 7e 8e c0 09 00 00 |\.yp.YQ..A~.....| +00000000 16 03 03 00 5d 02 00 00 59 03 03 15 ed ca 52 59 |....]...Y.....RY| +00000010 e2 56 80 e2 f3 20 5b 7d 52 f3 67 1f 01 0d ad 30 |.V... [}R.g....0| +00000020 36 a6 43 c2 ed 5e 34 c5 24 89 e1 20 c7 4c 5d 06 |6.C..^4.$.. .L].| +00000030 01 7a 80 aa 84 0c 46 48 63 36 49 4a 9b 3f 8d ba |.z....FHc6IJ.?..| +00000040 78 1b cd f9 ef 03 df cd ee 2c b1 79 c0 09 00 00 |x........,.y....| 00000050 11 ff 01 00 01 00 00 0b 00 04 03 00 01 02 00 17 |................| 00000060 00 00 16 03 03 02 0e 0b 00 02 0a 00 02 07 00 02 |................| 00000070 04 30 82 02 00 30 82 01 62 02 09 00 b8 bf 2d 47 |.0...0..b.....-G| @@ -56,39 +56,39 @@ 00000240 8c 25 c1 33 13 83 0d 94 06 bb d4 37 7a f6 ec 7a |.%.3.......7z..z| 00000250 c9 86 2e dd d7 11 69 7f 85 7c 56 de fb 31 78 2b |......i..|V..1x+| 00000260 e4 c7 78 0d ae cb be 9e 4e 36 24 31 7b 6a 0f 39 |..x.....N6$1{j.9| -00000270 95 12 07 8f 2a 16 03 03 00 b7 0c 00 00 b3 03 00 |....*...........| -00000280 1d 20 f5 a1 40 c1 31 8d 23 ee 2a 95 de 6f 22 a4 |. ..@.1.#.*..o".| -00000290 98 03 77 82 92 67 0e cd 75 5a ac 95 90 07 70 77 |..w..g..uZ....pw| -000002a0 c0 5b 04 03 00 8b 30 81 88 02 42 00 92 88 e3 97 |.[....0...B.....| -000002b0 42 e5 0a ca b7 48 db 4a f0 a2 1d c7 b8 1b bb 4b |B....H.J.......K| -000002c0 ea 5e 6c 40 b7 f7 de e1 b7 e5 b0 5e 8f fd 99 5b |.^l@.......^...[| -000002d0 14 e4 4d 55 4b cb cd f7 9a 3a 77 a7 41 cf 15 26 |..MUK....:w.A..&| -000002e0 79 a5 75 d8 c5 29 64 17 b7 16 7e e4 38 02 42 01 |y.u..)d...~.8.B.| -000002f0 b2 74 0c 2f 4d 18 e3 88 6e fe 90 59 12 5d 2e ef |.t./M...n..Y.]..| -00000300 36 c6 12 04 d5 aa 60 06 83 00 72 93 8c 5c f5 08 |6.....`...r..\..| -00000310 26 38 f7 f6 64 b1 66 2f e4 35 cb 56 0c 67 61 1a |&8..d.f/.5.V.ga.| -00000320 4d 16 8a ba 28 ba b5 ec 0b 61 38 79 db a3 65 c7 |M...(....a8y..e.| -00000330 3e 16 03 03 00 04 0e 00 00 00 |>.........| +00000270 95 12 07 8f 2a 16 03 03 00 b6 0c 00 00 b2 03 00 |....*...........| +00000280 1d 20 b7 f5 92 bc 9b 4a f9 62 3f 46 b8 b0 33 56 |. .....J.b?F..3V| +00000290 1e 8d fc e9 68 af bf 67 9b a5 d0 9e a9 cc d9 65 |....h..g.......e| +000002a0 7e 41 04 03 00 8a 30 81 87 02 41 08 b2 fe 6e 40 |~A....0...A...n@| +000002b0 b7 5f 04 db eb 39 18 d5 e0 46 81 07 33 3a 29 fb |._...9...F..3:).| +000002c0 0b 19 76 ac 95 0d cd 4d a4 f0 99 df 6d d6 73 79 |..v....M....m.sy| +000002d0 ed 48 52 78 ea 7a 1d 4b b1 67 d6 fd 21 3b c9 9d |.HRx.z.K.g..!;..| +000002e0 89 67 b7 b9 8e cf 35 28 62 28 3f 0b 02 42 01 7e |.g....5(b(?..B.~| +000002f0 4c a5 af 5b ba 3b d6 38 3b 34 b7 0c 69 27 92 ce |L..[.;.8;4..i'..| +00000300 34 ba bb 0d f6 32 65 fe 3c c0 9c 9d 92 88 b4 11 |4....2e.<.......| +00000310 04 88 f5 b3 21 79 6c ed 6e f6 51 f5 e7 b1 3d 0d |....!yl.n.Q...=.| +00000320 bd d6 92 67 c8 90 71 7a db cc cc 21 64 44 22 d4 |...g..qz...!dD".| +00000330 16 03 03 00 04 0e 00 00 00 |.........| >>> Flow 3 (client to server) 00000000 16 03 03 00 25 10 00 00 21 20 2f e5 7d a3 47 cd |....%...! /.}.G.| 00000010 62 43 15 28 da ac 5f bb 29 07 30 ff f6 84 af c4 |bC.(.._.).0.....| 00000020 cf c2 ed 90 99 5f 58 cb 3b 74 14 03 03 00 01 01 |....._X.;t......| 00000030 16 03 03 00 40 00 00 00 00 00 00 00 00 00 00 00 |....@...........| -00000040 00 00 00 00 00 7a 74 f0 c3 20 b7 87 3b 1b a6 86 |.....zt.. ..;...| -00000050 0a cf c3 b9 0f 3e 40 39 ed 4e e0 db c0 77 69 b6 |.....>@9.N...wi.| -00000060 79 cb 28 84 1f 88 72 5d 85 df 92 d2 05 ad bd 1b |y.(...r]........| -00000070 34 ba 21 ee 46 |4.!.F| +00000040 00 00 00 00 00 07 03 9e fa a4 84 27 17 b8 dd 53 |...........'...S| +00000050 12 4b 89 a1 47 98 22 e3 7b c8 d4 5c 18 bb 89 09 |.K..G.".{..\....| +00000060 29 3a b9 af d3 38 4a 40 76 d6 15 37 80 19 9c ce |):...8J@v..7....| +00000070 32 5b 94 89 2e |2[...| >>> Flow 4 (server to client) -00000000 14 03 03 00 01 01 16 03 03 00 40 f3 23 7b 1c 0b |..........@.#{..| -00000010 b3 07 a9 28 3f 33 84 7b 91 9c 7a b2 c2 df 89 6e |...(?3.{..z....n| -00000020 aa 54 35 d7 09 ae 61 cf 90 3a 86 cd 7a 00 6b b1 |.T5...a..:..z.k.| -00000030 1e 7f 55 4c f2 9e e5 4e 69 87 4f a1 eb bb d5 16 |..UL...Ni.O.....| -00000040 03 11 08 24 1d bc 83 29 4d 48 41 |...$...)MHA| +00000000 14 03 03 00 01 01 16 03 03 00 40 2d 53 b0 b0 c1 |..........@-S...| +00000010 05 78 e3 3c 5d 57 a5 04 9a 4b b9 f7 56 ce 5a 76 |.x.<]W...K..V.Zv| +00000020 84 4d f2 46 2e fc c2 9c ec 37 2b 4d 99 88 ab 30 |.M.F.....7+M...0| +00000030 1b 83 7d d8 72 bf e7 c7 f7 cf b8 13 54 d5 a2 a2 |..}.r.......T...| +00000040 dc 76 b3 01 a4 d0 a5 cc eb 66 29 |.v.......f)| >>> Flow 5 (client to server) 00000000 17 03 03 00 30 00 00 00 00 00 00 00 00 00 00 00 |....0...........| -00000010 00 00 00 00 00 f7 2c 65 61 5d 89 5d de 8d 42 92 |......,ea].]..B.| -00000020 91 1e f4 71 39 42 a3 92 91 98 96 9f 95 04 86 99 |...q9B..........| -00000030 c6 f3 e8 e1 e7 15 03 03 00 30 00 00 00 00 00 00 |.........0......| -00000040 00 00 00 00 00 00 00 00 00 00 81 23 13 80 00 d8 |...........#....| -00000050 1a 93 58 38 4d f0 6f 87 43 05 6d 63 6c e8 b9 80 |..X8M.o.C.mcl...| -00000060 1c 52 12 59 ae ca a6 c8 3c e3 |.R.Y....<.| +00000010 00 00 00 00 00 11 31 80 89 b8 32 e7 66 a6 eb c5 |......1...2.f...| +00000020 ca 4b f7 2b 47 73 e9 cd 9f 4e 9a 5e 3f 99 5a 29 |.K.+Gs...N.^?.Z)| +00000030 00 0d 4f 4e 93 15 03 03 00 30 00 00 00 00 00 00 |..ON.....0......| +00000040 00 00 00 00 00 00 00 00 00 00 d9 18 f4 dd 64 64 |..............dd| +00000050 38 27 a7 96 d5 14 d1 b2 26 9c 14 96 54 2a cf d7 |8'......&...T*..| +00000060 4c d0 b6 c3 20 fe 33 73 78 e5 |L... .3sx.| diff --git a/testdata/Client-TLSv12-ECDHE-ECDSA-AES-GCM b/testdata/Client-TLSv12-ECDHE-ECDSA-AES-GCM index 1b3e1e5..8609534 100644 --- a/testdata/Client-TLSv12-ECDHE-ECDSA-AES-GCM +++ b/testdata/Client-TLSv12-ECDHE-ECDSA-AES-GCM @@ -7,21 +7,21 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 7f 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 0a 00 08 00 1d 00 17 00 18 00 19 00 0b 00 02 01 |................| -000000a0 00 00 0d 00 1a 00 18 08 04 04 03 08 07 08 05 08 |................| -000000b0 06 04 01 05 01 06 01 05 03 06 03 02 01 02 03 ff |................| -000000c0 01 00 01 00 00 17 00 00 00 12 00 00 00 2b 00 09 |.............+..| +00000080 01 00 00 7f 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 19 00 0d |................| +000000b0 00 1a 00 18 08 04 04 03 08 07 08 05 08 06 04 01 |................| +000000c0 05 01 06 01 05 03 06 03 02 01 02 03 00 2b 00 09 |.............+..| 000000d0 08 03 04 03 03 03 02 03 01 00 33 00 26 00 24 00 |..........3.&.$.| 000000e0 1d 00 20 2f e5 7d a3 47 cd 62 43 15 28 da ac 5f |.. /.}.G.bC.(.._| 000000f0 bb 29 07 30 ff f6 84 af c4 cf c2 ed 90 99 5f 58 |.).0.........._X| 00000100 cb 3b 74 |.;t| >>> Flow 2 (server to client) -00000000 16 03 03 00 5d 02 00 00 59 03 03 d8 ac 8a ae 13 |....]...Y.......| -00000010 8a e4 2d ac c0 a1 a3 d5 32 5b ca 18 5a 73 22 83 |..-.....2[..Zs".| -00000020 d0 76 39 5c 48 40 b0 3a 75 87 5d 20 fd a3 fd b4 |.v9\H@.:u.] ....| -00000030 32 cc 05 54 aa 59 cc 76 81 7b 29 c3 bc c6 32 c0 |2..T.Y.v.{)...2.| -00000040 a9 52 fc ea 08 51 20 13 e3 e4 8e 68 c0 2b 00 00 |.R...Q ....h.+..| +00000000 16 03 03 00 5d 02 00 00 59 03 03 e1 ed 2c 5d 15 |....]...Y....,].| +00000010 15 24 d2 e3 a0 58 fb 2f 89 a3 26 b1 c8 06 0f dc |.$...X./..&.....| +00000020 ef e1 a7 a4 81 4a 71 2c 1d a2 35 20 be ff 22 db |.....Jq,..5 ..".| +00000030 2d 33 1b 11 24 55 96 96 54 5f 62 c7 7f b5 ba 32 |-3..$U..T_b....2| +00000040 e7 e6 7c 11 68 f8 97 d1 17 f7 8f 4f c0 2b 00 00 |..|.h......O.+..| 00000050 11 ff 01 00 01 00 00 0b 00 04 03 00 01 02 00 17 |................| 00000060 00 00 16 03 03 02 0e 0b 00 02 0a 00 02 07 00 02 |................| 00000070 04 30 82 02 00 30 82 01 62 02 09 00 b8 bf 2d 47 |.0...0..b.....-G| @@ -56,34 +56,34 @@ 00000240 8c 25 c1 33 13 83 0d 94 06 bb d4 37 7a f6 ec 7a |.%.3.......7z..z| 00000250 c9 86 2e dd d7 11 69 7f 85 7c 56 de fb 31 78 2b |......i..|V..1x+| 00000260 e4 c7 78 0d ae cb be 9e 4e 36 24 31 7b 6a 0f 39 |..x.....N6$1{j.9| -00000270 95 12 07 8f 2a 16 03 03 00 b7 0c 00 00 b3 03 00 |....*...........| -00000280 1d 20 1b e5 74 f7 2a 8e 86 7d 32 5b 99 f7 e0 2d |. ..t.*..}2[...-| -00000290 0d 96 a7 38 59 6c d9 50 7c 8a a2 2a 06 76 85 1f |...8Yl.P|..*.v..| -000002a0 77 7b 04 03 00 8b 30 81 88 02 42 01 9e 35 d1 fc |w{....0...B..5..| -000002b0 b8 16 97 b6 7b c4 6e 16 a9 de 5c 90 78 a6 d8 78 |....{.n...\.x..x| -000002c0 be 38 98 ba 50 bc 88 bb f0 15 30 62 29 96 43 15 |.8..P.....0b).C.| -000002d0 a7 7e 93 d4 3a 8c 2c 24 a5 7b e3 51 eb ef d4 16 |.~..:.,$.{.Q....| -000002e0 9b d7 c2 c3 b1 10 54 fe 26 55 05 a7 79 02 42 01 |......T.&U..y.B.| -000002f0 ca 62 10 6d b0 be 85 cf 3d ef a1 2f 9a 04 b9 6b |.b.m....=../...k| -00000300 1d ec bf fc 4e 77 81 b2 70 50 98 26 b4 89 5f a9 |....Nw..pP.&.._.| -00000310 d8 63 1a 54 79 f2 39 83 88 57 a0 25 cc a6 36 fa |.c.Ty.9..W.%..6.| -00000320 31 c1 45 c5 8d 04 83 42 89 a4 15 c3 3e 61 71 1c |1.E....B....>aq.| -00000330 53 16 03 03 00 04 0e 00 00 00 |S.........| +00000270 95 12 07 8f 2a 16 03 03 00 b6 0c 00 00 b2 03 00 |....*...........| +00000280 1d 20 74 55 23 1a ff ed d3 e7 95 30 ee ed 6d 77 |. tU#......0..mw| +00000290 57 83 fb 09 fc 81 70 69 d8 ae 38 1b e7 da 7f c6 |W.....pi..8.....| +000002a0 e4 01 04 03 00 8a 30 81 87 02 41 36 52 ca 91 b7 |......0...A6R...| +000002b0 a2 b2 31 91 98 96 65 92 67 a6 9c f2 75 8a 00 91 |..1...e.g...u...| +000002c0 8e 17 bd 22 d2 6c cb 16 0a fb 6b 27 08 3b f9 e4 |...".l....k'.;..| +000002d0 7c b5 21 45 60 4c c0 71 0b 28 46 d2 a8 a2 ad ad ||.!E`L.q.(F.....| +000002e0 51 fd bc 2e 40 7d 06 89 e7 b8 07 df 02 42 00 86 |Q...@}.......B..| +000002f0 83 4f 1d c1 c0 6d 3c f3 ed 24 47 70 65 e9 7c 5e |.O...m<..$Gpe.|^| +00000300 27 43 f0 05 b8 cd a4 34 ba 69 bc 81 7c fb b1 c3 |'C.....4.i..|...| +00000310 f8 bc 99 d6 90 15 8f db 21 fe 9f 18 10 23 75 6d |........!....#um| +00000320 22 b2 c6 f4 a5 60 80 31 06 a3 ad 33 88 c4 52 5d |"....`.1...3..R]| +00000330 16 03 03 00 04 0e 00 00 00 |.........| >>> Flow 3 (client to server) 00000000 16 03 03 00 25 10 00 00 21 20 2f e5 7d a3 47 cd |....%...! /.}.G.| 00000010 62 43 15 28 da ac 5f bb 29 07 30 ff f6 84 af c4 |bC.(.._.).0.....| 00000020 cf c2 ed 90 99 5f 58 cb 3b 74 14 03 03 00 01 01 |....._X.;t......| -00000030 16 03 03 00 28 00 00 00 00 00 00 00 00 4f 28 16 |....(........O(.| -00000040 51 9e e7 01 d2 5c 25 d7 bb 42 4c fc d9 dc d7 7f |Q....\%..BL.....| -00000050 2b 6c 5e 03 63 ce 19 ae 92 b8 c1 46 20 |+l^.c......F | +00000030 16 03 03 00 28 00 00 00 00 00 00 00 00 6b 3d 83 |....(........k=.| +00000040 88 db aa b0 62 30 8d 4a 6c b2 f1 14 d3 99 43 65 |....b0.Jl.....Ce| +00000050 4c ef 26 a4 ba 46 2f 75 9a 05 0c f2 91 |L.&..F/u.....| >>> Flow 4 (server to client) -00000000 14 03 03 00 01 01 16 03 03 00 28 31 c5 7a e8 49 |..........(1.z.I| -00000010 52 3d 85 b0 c4 7d 82 fa 08 a3 84 a9 58 8a 05 8c |R=...}......X...| -00000020 9a 7c 6c 4e 29 fd 46 53 06 27 09 d2 38 f5 7c 5c |.|lN).FS.'..8.|\| -00000030 fb ba 6b |..k| +00000000 14 03 03 00 01 01 16 03 03 00 28 d5 c2 de 26 c1 |..........(...&.| +00000010 ed 28 f1 d8 81 b3 9a 4f 3d 82 ad 22 d0 2c 41 61 |.(.....O=..".,Aa| +00000020 8b 15 a3 72 01 94 44 ff 8f 01 c1 05 e6 84 56 0a |...r..D.......V.| +00000030 8b 1d c4 |...| >>> Flow 5 (client to server) -00000000 17 03 03 00 1e 00 00 00 00 00 00 00 01 df 67 c1 |..............g.| -00000010 b4 dd 34 b2 32 ea b4 00 1b b9 67 60 03 91 bf 17 |..4.2.....g`....| -00000020 0d dd dc 15 03 03 00 1a 00 00 00 00 00 00 00 02 |................| -00000030 7c a9 51 36 43 33 ab e4 35 15 cf 6f ef c5 ed c7 ||.Q6C3..5..o....| -00000040 2f 4d |/M| +00000000 17 03 03 00 1e 00 00 00 00 00 00 00 01 c7 7d a7 |..............}.| +00000010 c4 a5 a1 21 94 7a 23 bc 05 44 7d 4a 2f 16 dc 95 |...!.z#..D}J/...| +00000020 25 6e 17 15 03 03 00 1a 00 00 00 00 00 00 00 02 |%n..............| +00000030 77 fa b6 34 7e 60 77 f9 a5 09 d1 39 b0 1e 66 86 |w..4~`w....9..f.| +00000040 50 41 |PA| diff --git a/testdata/Client-TLSv12-ECDHE-ECDSA-AES128-SHA256 b/testdata/Client-TLSv12-ECDHE-ECDSA-AES128-SHA256 index 1e871a4..ac5d07e 100644 --- a/testdata/Client-TLSv12-ECDHE-ECDSA-AES128-SHA256 +++ b/testdata/Client-TLSv12-ECDHE-ECDSA-AES128-SHA256 @@ -7,21 +7,21 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 7f 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 0a 00 08 00 1d 00 17 00 18 00 19 00 0b 00 02 01 |................| -000000a0 00 00 0d 00 1a 00 18 08 04 04 03 08 07 08 05 08 |................| -000000b0 06 04 01 05 01 06 01 05 03 06 03 02 01 02 03 ff |................| -000000c0 01 00 01 00 00 17 00 00 00 12 00 00 00 2b 00 09 |.............+..| +00000080 01 00 00 7f 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 19 00 0d |................| +000000b0 00 1a 00 18 08 04 04 03 08 07 08 05 08 06 04 01 |................| +000000c0 05 01 06 01 05 03 06 03 02 01 02 03 00 2b 00 09 |.............+..| 000000d0 08 03 04 03 03 03 02 03 01 00 33 00 26 00 24 00 |..........3.&.$.| 000000e0 1d 00 20 2f e5 7d a3 47 cd 62 43 15 28 da ac 5f |.. /.}.G.bC.(.._| 000000f0 bb 29 07 30 ff f6 84 af c4 cf c2 ed 90 99 5f 58 |.).0.........._X| 00000100 cb 3b 74 |.;t| >>> Flow 2 (server to client) -00000000 16 03 03 00 5d 02 00 00 59 03 03 32 b8 00 e5 21 |....]...Y..2...!| -00000010 98 b0 8b 40 56 f2 af 06 fa 7d 1c 23 6a 01 c6 95 |...@V....}.#j...| -00000020 41 9d 08 ac 5d de 0e 7e 39 57 07 20 b5 df a0 9a |A...]..~9W. ....| -00000030 13 3f b4 ae 1f 54 eb 47 6a 5a d5 f1 07 22 8f 29 |.?...T.GjZ...".)| -00000040 00 e8 9e e9 f6 76 80 ab 7d a8 23 4a c0 23 00 00 |.....v..}.#J.#..| +00000000 16 03 03 00 5d 02 00 00 59 03 03 36 c3 50 72 b9 |....]...Y..6.Pr.| +00000010 0d e9 d9 76 1d 31 72 e6 61 ec 3e 13 93 d7 f1 52 |...v.1r.a.>....R| +00000020 a7 36 5c 16 9a cc c5 c0 da 7e f3 20 31 79 7a ec |.6\......~. 1yz.| +00000030 1d db f7 cd 0a fe b3 86 6f 43 12 f4 9d 19 16 51 |........oC.....Q| +00000040 e2 42 1b 94 43 13 71 67 2d 52 7a 86 c0 23 00 00 |.B..C.qg-Rz..#..| 00000050 11 ff 01 00 01 00 00 0b 00 04 03 00 01 02 00 17 |................| 00000060 00 00 16 03 03 02 0e 0b 00 02 0a 00 02 07 00 02 |................| 00000070 04 30 82 02 00 30 82 01 62 02 09 00 b8 bf 2d 47 |.0...0..b.....-G| @@ -56,43 +56,43 @@ 00000240 8c 25 c1 33 13 83 0d 94 06 bb d4 37 7a f6 ec 7a |.%.3.......7z..z| 00000250 c9 86 2e dd d7 11 69 7f 85 7c 56 de fb 31 78 2b |......i..|V..1x+| 00000260 e4 c7 78 0d ae cb be 9e 4e 36 24 31 7b 6a 0f 39 |..x.....N6$1{j.9| -00000270 95 12 07 8f 2a 16 03 03 00 b6 0c 00 00 b2 03 00 |....*...........| -00000280 1d 20 f1 d6 ed a5 69 28 d2 bd 97 e3 00 e0 81 74 |. ....i(.......t| -00000290 8d 36 6e 77 73 40 10 a1 73 b3 4d 8e 04 41 b1 0e |.6nws@..s.M..A..| -000002a0 08 28 04 03 00 8a 30 81 87 02 42 01 4b b4 14 32 |.(....0...B.K..2| -000002b0 13 88 f1 8d 3a 66 e2 a2 d6 d4 de 26 50 7d 74 22 |....:f.....&P}t"| -000002c0 f9 56 83 00 0a b7 34 b3 96 99 0e c4 1d 8d 86 df |.V....4.........| -000002d0 22 2b 1c d7 75 f5 c9 45 2a c7 8a 74 40 ae 04 ac |"+..u..E*..t@...| -000002e0 b3 b4 5e c1 c5 e6 9c c3 01 ad 10 37 2b 02 41 4f |..^........7+.AO| -000002f0 74 33 31 aa c0 f8 8e ac cf 5a 90 a5 b8 d1 52 76 |t31......Z....Rv| -00000300 c3 a3 4f 0d 7d d7 8a 50 d3 bb 49 ce 22 ec d0 d3 |..O.}..P..I."...| -00000310 b5 e3 5c c2 a9 54 2e 6f 9c d1 24 3d 70 7f 2b a3 |..\..T.o..$=p.+.| -00000320 fe 24 fc 48 14 d3 8a f0 70 f3 1f af fe ae e3 fe |.$.H....p.......| -00000330 16 03 03 00 04 0e 00 00 00 |.........| +00000270 95 12 07 8f 2a 16 03 03 00 b7 0c 00 00 b3 03 00 |....*...........| +00000280 1d 20 d2 2d 0f 11 29 eb b4 23 67 1c 40 84 7f 7e |. .-..)..#g.@..~| +00000290 cd 8c 3d c2 62 ed 9b 0f 08 01 5b a5 fd 86 31 c5 |..=.b.....[...1.| +000002a0 d2 76 04 03 00 8b 30 81 88 02 42 01 a4 ea c8 67 |.v....0...B....g| +000002b0 c0 0a 93 23 7c d9 41 17 ba 91 02 78 c7 16 28 85 |...#|.A....x..(.| +000002c0 b8 d6 5c ed ed 20 1e 8b 90 e0 19 db 67 72 7e d3 |..\.. ......gr~.| +000002d0 2c 2e 84 6a d7 bc b7 53 74 8b 1b ef a8 bc 39 d8 |,..j...St.....9.| +000002e0 e0 75 29 6b 1d 89 c3 12 c2 3c 51 25 84 02 42 01 |.u)k.....>> Flow 3 (client to server) 00000000 16 03 03 00 25 10 00 00 21 20 2f e5 7d a3 47 cd |....%...! /.}.G.| 00000010 62 43 15 28 da ac 5f bb 29 07 30 ff f6 84 af c4 |bC.(.._.).0.....| 00000020 cf c2 ed 90 99 5f 58 cb 3b 74 14 03 03 00 01 01 |....._X.;t......| 00000030 16 03 03 00 50 00 00 00 00 00 00 00 00 00 00 00 |....P...........| -00000040 00 00 00 00 00 ea c6 10 80 cf 85 ad 7c 5f 6b 98 |............|_k.| -00000050 7b 5a d6 47 84 dc 95 c9 ed 6e e6 c3 56 d5 91 93 |{Z.G.....n..V...| -00000060 0e 3f b5 6c 2f 73 d9 72 9b f7 64 47 29 9e 75 4f |.?.l/s.r..dG).uO| -00000070 97 2e 6d 94 52 f7 8f c9 24 5b d0 fe 05 aa e6 93 |..m.R...$[......| -00000080 79 ea 37 0f 9e |y.7..| +00000040 00 00 00 00 00 98 8d 15 68 8c 12 3e 4a 88 64 7c |........h..>J.d|| +00000050 69 46 25 16 66 20 d7 f5 7e 08 d8 9d c4 89 c1 cf |iF%.f ..~.......| +00000060 ac 86 b7 ce 3a 9c 95 0c 5d d1 a2 c2 bf fd 7c e1 |....:...].....|.| +00000070 b5 f4 04 7e 71 ae 3c fc d2 c1 2a ec 81 e4 62 a6 |...~q.<...*...b.| +00000080 e6 05 72 d8 9e |..r..| >>> Flow 4 (server to client) -00000000 14 03 03 00 01 01 16 03 03 00 50 ed 02 93 7e 89 |..........P...~.| -00000010 d5 d7 e9 0b 21 71 a9 cd b6 ac 65 6f 83 b2 0f 35 |....!q....eo...5| -00000020 d6 1c bb df c5 c2 d6 6c b6 32 37 14 a0 0c fd ae |.......l.27.....| -00000030 18 75 9e 82 df 00 ec 6c 99 e2 31 a3 35 e0 82 6d |.u.....l..1.5..m| -00000040 57 5b 60 82 ec 69 8a 79 30 96 4f 96 bb 99 66 75 |W[`..i.y0.O...fu| -00000050 5d 41 f9 04 fc f2 c6 bb 92 1c cb |]A.........| +00000000 14 03 03 00 01 01 16 03 03 00 50 27 94 9b d3 f1 |..........P'....| +00000010 6c 59 bb fa b7 73 8b d6 fa b2 ca c1 0c d3 60 cf |lY...s........`.| +00000020 50 18 a6 6f 3d b3 46 a1 06 a2 b1 62 4c ea 88 2f |P..o=.F....bL../| +00000030 95 bc 35 6f 55 a6 8a 52 69 6c 5b a5 fc 94 2a b6 |..5oU..Ril[...*.| +00000040 27 7c d7 95 27 72 d4 c1 f2 f9 9c a5 b3 2a 85 52 |'|..'r.......*.R| +00000050 ae bf 14 52 54 51 6a fe a1 99 05 |...RTQj....| >>> Flow 5 (client to server) 00000000 17 03 03 00 40 00 00 00 00 00 00 00 00 00 00 00 |....@...........| -00000010 00 00 00 00 00 23 62 3f ed a2 99 3b ac 03 f5 8c |.....#b?...;....| -00000020 3c 9f 71 25 b5 5c ec 2c 79 d5 70 ae 23 cf 2f 65 |<.q%.\.,y.p.#./e| -00000030 3d 28 5f dd fb d6 6a 12 b5 5f eb 9f 2a 8e 79 80 |=(_...j.._..*.y.| -00000040 eb 77 6e 7e b0 15 03 03 00 40 00 00 00 00 00 00 |.wn~.....@......| -00000050 00 00 00 00 00 00 00 00 00 00 13 e1 0c 7b 01 90 |.............{..| -00000060 e8 0d 2d 41 b5 c3 67 0a 37 c4 28 fa b6 88 cc 99 |..-A..g.7.(.....| -00000070 f7 0a d9 25 09 24 88 f7 38 78 c4 1c 37 b4 3c a8 |...%.$..8x..7.<.| -00000080 3d 2d ac a7 0d 45 62 9c 61 53 |=-...Eb.aS| +00000010 00 00 00 00 00 9b b4 f6 7e 49 48 09 cd 4f ed 22 |........~IH..O."| +00000020 68 db 19 94 ad af de d1 9b b6 bc f5 d6 7f c6 b2 |h...............| +00000030 ff b1 0e b4 0e dd 77 19 e8 9e ff 68 1a 04 fc e5 |......w....h....| +00000040 f2 3b 5b 34 aa 15 03 03 00 40 00 00 00 00 00 00 |.;[4.....@......| +00000050 00 00 00 00 00 00 00 00 00 00 f7 95 04 54 94 ff |.............T..| +00000060 f7 86 df 0a 2e 5b e9 54 fe 13 30 2a 97 f9 21 8e |.....[.T..0*..!.| +00000070 83 8b ba 86 77 67 92 33 5e a8 ea b7 64 65 63 59 |....wg.3^...decY| +00000080 44 2e 65 60 9a 0a 7c 78 97 a4 |D.e`..|x..| diff --git a/testdata/Client-TLSv12-ECDHE-ECDSA-AES256-GCM-SHA384 b/testdata/Client-TLSv12-ECDHE-ECDSA-AES256-GCM-SHA384 index 6477993..ad5fa50 100644 --- a/testdata/Client-TLSv12-ECDHE-ECDSA-AES256-GCM-SHA384 +++ b/testdata/Client-TLSv12-ECDHE-ECDSA-AES256-GCM-SHA384 @@ -7,21 +7,21 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 7f 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 0a 00 08 00 1d 00 17 00 18 00 19 00 0b 00 02 01 |................| -000000a0 00 00 0d 00 1a 00 18 08 04 04 03 08 07 08 05 08 |................| -000000b0 06 04 01 05 01 06 01 05 03 06 03 02 01 02 03 ff |................| -000000c0 01 00 01 00 00 17 00 00 00 12 00 00 00 2b 00 09 |.............+..| +00000080 01 00 00 7f 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 19 00 0d |................| +000000b0 00 1a 00 18 08 04 04 03 08 07 08 05 08 06 04 01 |................| +000000c0 05 01 06 01 05 03 06 03 02 01 02 03 00 2b 00 09 |.............+..| 000000d0 08 03 04 03 03 03 02 03 01 00 33 00 26 00 24 00 |..........3.&.$.| 000000e0 1d 00 20 2f e5 7d a3 47 cd 62 43 15 28 da ac 5f |.. /.}.G.bC.(.._| 000000f0 bb 29 07 30 ff f6 84 af c4 cf c2 ed 90 99 5f 58 |.).0.........._X| 00000100 cb 3b 74 |.;t| >>> Flow 2 (server to client) -00000000 16 03 03 00 5d 02 00 00 59 03 03 99 43 3d 42 93 |....]...Y...C=B.| -00000010 5a 7a 04 30 74 51 61 36 15 df ef a7 26 ef b8 76 |Zz.0tQa6....&..v| -00000020 87 35 7a 88 75 83 9e 0d 2c d4 3d 20 1f 29 99 ea |.5z.u...,.= .)..| -00000030 71 f7 c3 c4 68 3e 7f 58 7a 07 c7 2d a3 38 47 8d |q...h>.Xz..-.8G.| -00000040 c9 ed 05 b4 8e e7 b6 85 5d a1 62 6b c0 2c 00 00 |........].bk.,..| +00000000 16 03 03 00 5d 02 00 00 59 03 03 54 28 b4 3e d3 |....]...Y..T(.>.| +00000010 f8 21 2a 34 c9 6b 54 76 aa d2 cf 5e 07 7a aa e2 |.!*4.kTv...^.z..| +00000020 10 cb 3e ed 87 f4 3e 70 44 d0 35 20 6e b4 f0 71 |..>...>pD.5 n..q| +00000030 76 96 1e 2a 57 74 4b db 9a 11 0a af 06 ea 3b 20 |v..*WtK.......; | +00000040 a8 81 51 9d 41 ef f1 f9 23 87 18 cb c0 2c 00 00 |..Q.A...#....,..| 00000050 11 ff 01 00 01 00 00 0b 00 04 03 00 01 02 00 17 |................| 00000060 00 00 16 03 03 02 0e 0b 00 02 0a 00 02 07 00 02 |................| 00000070 04 30 82 02 00 30 82 01 62 02 09 00 b8 bf 2d 47 |.0...0..b.....-G| @@ -56,34 +56,34 @@ 00000240 8c 25 c1 33 13 83 0d 94 06 bb d4 37 7a f6 ec 7a |.%.3.......7z..z| 00000250 c9 86 2e dd d7 11 69 7f 85 7c 56 de fb 31 78 2b |......i..|V..1x+| 00000260 e4 c7 78 0d ae cb be 9e 4e 36 24 31 7b 6a 0f 39 |..x.....N6$1{j.9| -00000270 95 12 07 8f 2a 16 03 03 00 b5 0c 00 00 b1 03 00 |....*...........| -00000280 1d 20 fb 11 a5 85 16 55 f9 09 56 4a 4c f7 c8 a1 |. .....U..VJL...| -00000290 fd 57 e3 4d 1e b5 78 df 7a b1 02 0c 42 60 80 f9 |.W.M..x.z...B`..| -000002a0 4b 6e 04 03 00 89 30 81 86 02 41 4d 4a 3c 11 e1 |Kn....0...AMJ<..| -000002b0 72 33 71 38 77 52 4d d8 78 ee 23 f9 f3 00 20 76 |r3q8wRM.x.#... v| -000002c0 04 19 b2 4c 28 34 9d 22 b7 3e 1d 35 8f 93 ab 66 |...L(4.".>.5...f| -000002d0 09 c4 7a 8e 8c 5a fc ae 1d c7 ba 2e 36 ea e7 0b |..z..Z......6...| -000002e0 43 ae 03 e3 ec 6b f7 81 2e 22 e5 f0 02 41 39 95 |C....k..."...A9.| -000002f0 22 5f b0 1a 5c 13 a0 c5 08 47 a7 51 9c fa 15 32 |"_..\....G.Q...2| -00000300 95 84 95 8f 2f ed 38 19 bb b5 2b ac 39 90 a1 4c |..../.8...+.9..L| -00000310 b5 20 49 cd 87 17 9d ef b4 c3 22 05 56 23 7d bc |. I.......".V#}.| -00000320 6a d6 ae d9 e5 50 65 6c 8b df 4b 2e 6d e9 e3 16 |j....Pel..K.m...| -00000330 03 03 00 04 0e 00 00 00 |........| +00000270 95 12 07 8f 2a 16 03 03 00 b7 0c 00 00 b3 03 00 |....*...........| +00000280 1d 20 de df 32 23 35 b3 79 a9 49 c2 b3 ad 0c d6 |. ..2#5.y.I.....| +00000290 23 a6 6a 9b 0f e3 52 51 7b bc f2 79 00 c9 a4 a0 |#.j...RQ{..y....| +000002a0 94 02 04 03 00 8b 30 81 88 02 42 01 8c 12 91 28 |......0...B....(| +000002b0 d4 6d cd 39 62 75 9a e0 e5 dd ea 31 45 f5 cd 8b |.m.9bu.....1E...| +000002c0 28 82 14 f5 e9 61 0e 9d af 42 06 17 42 e9 24 1c |(....a...B..B.$.| +000002d0 2b 1a c8 77 e4 7a 82 2b b0 dd 28 3f 76 5d dd fd |+..w.z.+..(?v]..| +000002e0 20 53 87 e6 77 26 be 45 e4 6d 31 e3 bf 02 42 01 | S..w&.E.m1...B.| +000002f0 70 c5 97 3a e4 7b 80 2b 1b eb c9 b2 0a 79 92 2e |p..:.{.+.....y..| +00000300 3d b1 4d 13 69 d2 60 a9 fd e9 66 56 83 e4 f5 6a |=.M.i.`...fV...j| +00000310 ae cd 8b 94 9f 0b 70 81 b1 ed c6 0d 5f 33 42 04 |......p....._3B.| +00000320 3d f7 b6 d3 e9 09 b8 bf 43 8c 19 d5 7d 60 d6 a9 |=.......C...}`..| +00000330 f7 16 03 03 00 04 0e 00 00 00 |..........| >>> Flow 3 (client to server) 00000000 16 03 03 00 25 10 00 00 21 20 2f e5 7d a3 47 cd |....%...! /.}.G.| 00000010 62 43 15 28 da ac 5f bb 29 07 30 ff f6 84 af c4 |bC.(.._.).0.....| 00000020 cf c2 ed 90 99 5f 58 cb 3b 74 14 03 03 00 01 01 |....._X.;t......| -00000030 16 03 03 00 28 00 00 00 00 00 00 00 00 ef cc 31 |....(..........1| -00000040 f9 de 58 68 c9 6a c7 c4 3e 60 1f 4e f9 bf 27 87 |..Xh.j..>`.N..'.| -00000050 b0 17 ed 83 17 a0 45 b7 a9 d8 95 b6 51 |......E.....Q| +00000030 16 03 03 00 28 00 00 00 00 00 00 00 00 a7 5d c9 |....(.........].| +00000040 e7 6b 78 13 ae 11 64 d0 e7 77 48 03 d4 cf b9 65 |.kx...d..wH....e| +00000050 7f 07 75 78 7f 3d ae a1 9a 0f fb cb 74 |..ux.=......t| >>> Flow 4 (server to client) -00000000 14 03 03 00 01 01 16 03 03 00 28 61 eb 42 a7 10 |..........(a.B..| -00000010 6f 1a ef 4d e5 4d df 75 cb 8e 59 f8 06 e0 f9 ee |o..M.M.u..Y.....| -00000020 d1 a9 11 7b 89 97 62 b9 76 d1 8e eb ee 30 dd 0f |...{..b.v....0..| -00000030 60 b1 e1 |`..| +00000000 14 03 03 00 01 01 16 03 03 00 28 07 4e 69 71 66 |..........(.Niqf| +00000010 75 a0 bb b4 fd 86 8d 74 40 7e 0d e9 a5 95 d0 2d |u......t@~.....-| +00000020 ca eb 12 2f 7b 09 22 7c 8e bf da 97 18 d9 bd 74 |.../{."|.......t| +00000030 cd 08 6b |..k| >>> Flow 5 (client to server) -00000000 17 03 03 00 1e 00 00 00 00 00 00 00 01 fb 32 66 |..............2f| -00000010 d6 d5 e1 52 31 8d 63 4f 5c a0 ac b5 f3 64 dc 40 |...R1.cO\....d.@| -00000020 f5 93 5a 15 03 03 00 1a 00 00 00 00 00 00 00 02 |..Z.............| -00000030 6b 66 c3 db e8 33 66 14 9b 4b 1c 59 bf 9e 6c 7e |kf...3f..K.Y..l~| -00000040 2d 1e |-.| +00000000 17 03 03 00 1e 00 00 00 00 00 00 00 01 44 26 54 |.............D&T| +00000010 a3 37 94 7a 3d 93 6a 06 35 fe 9a d4 7b 54 ab d4 |.7.z=.j.5...{T..| +00000020 33 fd 93 15 03 03 00 1a 00 00 00 00 00 00 00 02 |3...............| +00000030 bf ff c7 9e 4b db ee a4 a2 b9 a5 91 cd 09 97 a2 |....K...........| +00000040 55 a5 |U.| diff --git a/testdata/Client-TLSv12-ECDHE-ECDSA-CHACHA20-POLY1305 b/testdata/Client-TLSv12-ECDHE-ECDSA-CHACHA20-POLY1305 index e1b45cb..9982121 100644 --- a/testdata/Client-TLSv12-ECDHE-ECDSA-CHACHA20-POLY1305 +++ b/testdata/Client-TLSv12-ECDHE-ECDSA-CHACHA20-POLY1305 @@ -4,21 +4,21 @@ 00000020 00 00 00 00 00 00 00 00 00 00 00 20 00 00 00 00 |........... ....| 00000030 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |................| 00000040 00 00 00 00 00 00 00 00 00 00 00 00 00 08 cc a9 |................| -00000050 13 03 13 01 13 02 01 00 00 7f 00 05 00 05 01 00 |................| -00000060 00 00 00 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 |................| -00000070 19 00 0b 00 02 01 00 00 0d 00 1a 00 18 08 04 04 |................| -00000080 03 08 07 08 05 08 06 04 01 05 01 06 01 05 03 06 |................| -00000090 03 02 01 02 03 ff 01 00 01 00 00 17 00 00 00 12 |................| -000000a0 00 00 00 2b 00 09 08 03 04 03 03 03 02 03 01 00 |...+............| +00000050 13 03 13 01 13 02 01 00 00 7f 00 0b 00 02 01 00 |................| +00000060 ff 01 00 01 00 00 17 00 00 00 12 00 00 00 05 00 |................| +00000070 05 01 00 00 00 00 00 0a 00 0a 00 08 00 1d 00 17 |................| +00000080 00 18 00 19 00 0d 00 1a 00 18 08 04 04 03 08 07 |................| +00000090 08 05 08 06 04 01 05 01 06 01 05 03 06 03 02 01 |................| +000000a0 02 03 00 2b 00 09 08 03 04 03 03 03 02 03 01 00 |...+............| 000000b0 33 00 26 00 24 00 1d 00 20 2f e5 7d a3 47 cd 62 |3.&.$... /.}.G.b| 000000c0 43 15 28 da ac 5f bb 29 07 30 ff f6 84 af c4 cf |C.(.._.).0......| 000000d0 c2 ed 90 99 5f 58 cb 3b 74 |...._X.;t| >>> Flow 2 (server to client) -00000000 16 03 03 00 5d 02 00 00 59 03 03 f0 39 6d 08 4c |....]...Y...9m.L| -00000010 1e c8 06 4d 9e 1e 2a 27 d9 17 6f 39 19 38 ba 49 |...M..*'..o9.8.I| -00000020 a5 fa b2 6d a2 70 e8 9d b2 03 92 20 09 ef 68 cb |...m.p..... ..h.| -00000030 58 2a fd 4b 60 9a 1e af f4 02 c0 cb 10 b2 dd 73 |X*.K`..........s| -00000040 0c e0 6a da 3f cd 3a a3 a3 55 58 00 cc a9 00 00 |..j.?.:..UX.....| +00000000 16 03 03 00 5d 02 00 00 59 03 03 4f ed 35 28 41 |....]...Y..O.5(A| +00000010 4a 0f a2 da 57 ef 60 69 32 00 a5 82 22 3d d9 ea |J...W.`i2..."=..| +00000020 36 28 20 31 e3 4a b6 d1 b6 b4 49 20 97 f3 45 59 |6( 1.J....I ..EY| +00000030 e7 9c f5 40 57 51 b8 f8 5a 8d f2 eb ce 83 18 2d |...@WQ..Z......-| +00000040 e3 28 55 6f 17 08 23 88 57 b1 a0 e4 cc a9 00 00 |.(Uo..#.W.......| 00000050 11 ff 01 00 01 00 00 0b 00 04 03 00 01 02 00 17 |................| 00000060 00 00 16 03 03 02 0e 0b 00 02 0a 00 02 07 00 02 |................| 00000070 04 30 82 02 00 30 82 01 62 02 09 00 b8 bf 2d 47 |.0...0..b.....-G| @@ -54,31 +54,31 @@ 00000250 c9 86 2e dd d7 11 69 7f 85 7c 56 de fb 31 78 2b |......i..|V..1x+| 00000260 e4 c7 78 0d ae cb be 9e 4e 36 24 31 7b 6a 0f 39 |..x.....N6$1{j.9| 00000270 95 12 07 8f 2a 16 03 03 00 b7 0c 00 00 b3 03 00 |....*...........| -00000280 1d 20 f0 e0 d6 3e 40 a0 97 de 26 8a 52 25 2c a7 |. ...>@...&.R%,.| -00000290 78 c5 ed 73 5c 59 ca 02 a8 9e 0d 69 bd cc bb 4b |x..s\Y.....i...K| -000002a0 11 3d 04 03 00 8b 30 81 88 02 42 00 ed 4d bc dc |.=....0...B..M..| -000002b0 d7 5e 95 b4 13 b3 fb 40 38 1a 53 09 71 a4 14 2a |.^.....@8.S.q..*| -000002c0 45 6f e3 fe db 0a c8 32 05 e6 98 17 bb f8 e9 72 |Eo.....2.......r| -000002d0 db 5d e8 f5 b2 ad df 1b 62 dd b2 98 f8 6b 38 13 |.]......b....k8.| -000002e0 a9 2f 13 1b ea db 58 24 4b e2 3a b9 5a 02 42 00 |./....X$K.:.Z.B.| -000002f0 ea cd 03 cb b9 67 5c f3 99 35 cc 57 2a 58 12 45 |.....g\..5.W*X.E| -00000300 c9 f1 e4 27 1a 42 2c ce 9c ba 10 f8 6f 15 41 67 |...'.B,.....o.Ag| -00000310 07 33 38 94 dd 34 57 90 41 cf 16 04 b7 fc af ae |.38..4W.A.......| -00000320 6b ac 16 87 75 6d 60 52 e7 b9 1e 85 a3 45 92 a4 |k...um`R.....E..| -00000330 cf 16 03 03 00 04 0e 00 00 00 |..........| +00000280 1d 20 64 49 59 eb a9 80 c3 0a 9e 13 f4 09 04 6b |. dIY..........k| +00000290 1f e5 3b 0b 77 84 fe 2e 1f ea 7e d4 64 2a 7f 3f |..;.w.....~.d*.?| +000002a0 dc 0f 04 03 00 8b 30 81 88 02 42 00 a4 62 9b d1 |......0...B..b..| +000002b0 ed 60 b7 2d 05 48 64 b6 94 3b a1 75 cb 41 78 e5 |.`.-.Hd..;.u.Ax.| +000002c0 e0 12 70 d9 90 4d c0 34 39 f3 52 13 75 4b fa 10 |..p..M.49.R.uK..| +000002d0 19 6f a6 2d b4 c3 8f 45 0c 7f 34 fb 82 01 e6 a1 |.o.-...E..4.....| +000002e0 be 73 72 3b e5 04 80 70 7d bd 4a f9 e5 02 42 01 |.sr;...p}.J...B.| +000002f0 69 3d 53 e9 8d 70 6d 07 84 7e 56 3f ce 53 b9 6c |i=S..pm..~V?.S.l| +00000300 43 0f 70 74 f1 52 ce d4 95 55 13 8c 07 e7 20 d7 |C.pt.R...U.... .| +00000310 61 2e b7 f4 5b 34 6e 5d 9c d8 73 66 89 a1 f6 7e |a...[4n]..sf...~| +00000320 01 bb 9a 5e 52 59 3f fc 3e 24 fc e7 49 10 83 9d |...^RY?.>$..I...| +00000330 fb 16 03 03 00 04 0e 00 00 00 |..........| >>> Flow 3 (client to server) 00000000 16 03 03 00 25 10 00 00 21 20 2f e5 7d a3 47 cd |....%...! /.}.G.| 00000010 62 43 15 28 da ac 5f bb 29 07 30 ff f6 84 af c4 |bC.(.._.).0.....| 00000020 cf c2 ed 90 99 5f 58 cb 3b 74 14 03 03 00 01 01 |....._X.;t......| -00000030 16 03 03 00 20 24 01 e0 f7 26 b8 69 62 f7 98 45 |.... $...&.ib..E| -00000040 6f 6d fc eb 37 c9 69 f1 21 eb 13 70 57 a9 5b de |om..7.i.!..pW.[.| -00000050 37 30 64 cc c1 |70d..| +00000030 16 03 03 00 20 cf f9 90 26 e8 2c 00 99 ae 0e e6 |.... ...&.,.....| +00000040 a8 d9 66 6b 23 e7 c9 73 1c f7 e9 af e1 71 1d f3 |..fk#..s.....q..| +00000050 34 60 ee 16 9d |4`...| >>> Flow 4 (server to client) -00000000 14 03 03 00 01 01 16 03 03 00 20 8d fd f9 fd 18 |.......... .....| -00000010 08 fa c1 5b 1c d1 03 bc ba 36 6b 69 30 72 9c 92 |...[.....6ki0r..| -00000020 f9 56 0c 5e ed 7b 91 e8 42 6c 26 |.V.^.{..Bl&| +00000000 14 03 03 00 01 01 16 03 03 00 20 39 9f 39 3a 22 |.......... 9.9:"| +00000010 0b 27 cb 75 0d 43 98 11 06 dd 7e 73 17 e0 8a 19 |.'.u.C....~s....| +00000020 6d eb a8 33 c6 42 b4 e9 cb dd b1 |m..3.B.....| >>> Flow 5 (client to server) -00000000 17 03 03 00 16 94 1f 97 8b 5b 66 15 63 a5 1e 78 |.........[f.c..x| -00000010 c2 e3 4e 96 ae 08 16 d6 33 b8 60 15 03 03 00 12 |..N.....3.`.....| -00000020 f9 71 c8 e5 93 b4 0d 17 97 0f 6d cb 58 0f 59 64 |.q........m.X.Yd| -00000030 12 0f |..| +00000000 17 03 03 00 16 24 1f 08 49 ef 32 16 8d 76 c7 34 |.....$..I.2..v.4| +00000010 e0 08 cb d9 e7 72 aa 0f fb c4 94 15 03 03 00 12 |.....r..........| +00000020 38 0b 8c e0 0b 61 20 e8 a6 7c 77 69 fb 00 96 39 |8....a ..|wi...9| +00000030 b9 a7 |..| diff --git a/testdata/Client-TLSv12-ECDHE-RSA-AES b/testdata/Client-TLSv12-ECDHE-RSA-AES index d5665da..e2e935c 100644 --- a/testdata/Client-TLSv12-ECDHE-RSA-AES +++ b/testdata/Client-TLSv12-ECDHE-RSA-AES @@ -7,21 +7,21 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 7f 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 0a 00 08 00 1d 00 17 00 18 00 19 00 0b 00 02 01 |................| -000000a0 00 00 0d 00 1a 00 18 08 04 04 03 08 07 08 05 08 |................| -000000b0 06 04 01 05 01 06 01 05 03 06 03 02 01 02 03 ff |................| -000000c0 01 00 01 00 00 17 00 00 00 12 00 00 00 2b 00 09 |.............+..| +00000080 01 00 00 7f 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 19 00 0d |................| +000000b0 00 1a 00 18 08 04 04 03 08 07 08 05 08 06 04 01 |................| +000000c0 05 01 06 01 05 03 06 03 02 01 02 03 00 2b 00 09 |.............+..| 000000d0 08 03 04 03 03 03 02 03 01 00 33 00 26 00 24 00 |..........3.&.$.| 000000e0 1d 00 20 2f e5 7d a3 47 cd 62 43 15 28 da ac 5f |.. /.}.G.bC.(.._| 000000f0 bb 29 07 30 ff f6 84 af c4 cf c2 ed 90 99 5f 58 |.).0.........._X| 00000100 cb 3b 74 |.;t| >>> Flow 2 (server to client) -00000000 16 03 03 00 5d 02 00 00 59 03 03 1e 8b e8 b6 ab |....]...Y.......| -00000010 28 56 58 92 6d 03 e6 46 aa 94 dc 6d a0 7b 6f db |(VX.m..F...m.{o.| -00000020 09 22 9f 48 14 de 37 bf 54 68 42 20 f8 0f 31 09 |.".H..7.ThB ..1.| -00000030 56 de 8f ad db d7 ab 38 66 8b cf 86 1c 84 0d 9c |V......8f.......| -00000040 ad 24 c8 35 a8 28 8d 06 10 23 5e 34 c0 13 00 00 |.$.5.(...#^4....| +00000000 16 03 03 00 5d 02 00 00 59 03 03 8d 69 e3 6e 69 |....]...Y...i.ni| +00000010 45 96 8b 0d c8 7d 9c dc b6 75 24 ee 61 44 95 99 |E....}...u$.aD..| +00000020 cb a8 da df 35 ac c3 36 02 3f b9 20 2d c2 47 c9 |....5..6.?. -.G.| +00000030 f0 47 80 9a c6 bd e4 1b ca d6 62 17 59 ec c9 83 |.G........b.Y...| +00000040 d5 ed 3f 2c 13 b0 30 0a 5e 1f 0e db c0 13 00 00 |..?,..0.^.......| 00000050 11 ff 01 00 01 00 00 0b 00 04 03 00 01 02 00 17 |................| 00000060 00 00 16 03 03 02 59 0b 00 02 55 00 02 52 00 02 |......Y...U..R..| 00000070 4f 30 82 02 4b 30 82 01 b4 a0 03 02 01 02 02 09 |O0..K0..........| @@ -61,38 +61,38 @@ 00000290 73 bb b3 43 77 8d 0c 1c f1 0f a1 d8 40 83 61 c9 |s..Cw.......@.a.| 000002a0 4c 72 2b 9d ae db 46 06 06 4d f4 c1 b3 3e c0 d1 |Lr+...F..M...>..| 000002b0 bd 42 d4 db fe 3d 13 60 84 5c 21 d3 3b e9 fa e7 |.B...=.`.\!.;...| -000002c0 16 03 03 00 ac 0c 00 00 a8 03 00 1d 20 e6 56 06 |............ .V.| -000002d0 58 6f 5d 7a 59 32 f5 3e 7b 07 17 de 27 62 9e e8 |Xo]zY2.>{...'b..| -000002e0 d0 42 f1 97 56 66 d0 d5 c1 06 b9 48 2f 08 04 00 |.B..Vf.....H/...| -000002f0 80 1d 63 88 8e ed 58 f2 0e d3 b3 17 46 f3 9c 49 |..c...X.....F..I| -00000300 bb 22 22 eb e2 77 13 6c a5 aa 77 fe ad 16 06 23 |.""..w.l..w....#| -00000310 c3 2a ec b9 76 43 4a 7f 41 72 5f 53 ae de 70 3a |.*..vCJ.Ar_S..p:| -00000320 f2 e9 60 92 30 2e f3 df a1 3d 4a c1 1f 26 fa 42 |..`.0....=J..&.B| -00000330 c8 31 cb 97 c0 5c 6b 8e d9 18 28 be 99 7c d1 75 |.1...\k...(..|.u| -00000340 05 ad 22 91 4f 55 ae 50 2c fa 37 ee 28 e9 64 1c |..".OU.P,.7.(.d.| -00000350 2b 2a c5 95 f5 90 ae ae d4 a3 50 f3 fe 26 71 4f |+*........P..&qO| -00000360 55 db 32 03 1f 5c 3f 91 20 85 d5 e1 73 45 43 59 |U.2..\?. ...sECY| -00000370 e5 16 03 03 00 04 0e 00 00 00 |..........| +000002c0 16 03 03 00 ac 0c 00 00 a8 03 00 1d 20 0f 4e 12 |............ .N.| +000002d0 ab ce 7e 62 68 64 e0 1d 7e 33 a2 ee 5d e7 2d d5 |..~bhd..~3..].-.| +000002e0 d2 dc d0 ce b2 7e 9b be 33 8d 9c 56 7a 08 04 00 |.....~..3..Vz...| +000002f0 80 44 b8 9b 87 5f 84 f6 8a 99 af e9 f7 f8 88 fd |.D..._..........| +00000300 f7 12 02 48 a1 fa 66 9c 89 a2 dc bf fd 41 08 fa |...H..f......A..| +00000310 6f e4 44 09 8e c1 45 bb 2a e9 e3 45 19 a3 81 50 |o.D...E.*..E...P| +00000320 99 46 5f 86 5b 6b c0 29 d1 e5 21 4b 56 af f4 d0 |.F_.[k.)..!KV...| +00000330 63 c4 75 ac f6 75 61 ca fe 1a b9 70 4d 14 50 b1 |c.u..ua....pM.P.| +00000340 12 7f 29 2d c5 d7 78 da 06 3e 4c 47 75 8a a6 01 |..)-..x..>LGu...| +00000350 37 17 1c e8 ef 94 85 d0 e2 ee d5 25 ae 8d f8 e6 |7..........%....| +00000360 90 10 12 37 b4 0f f5 c7 a2 85 1a 83 8a 38 e6 32 |...7.........8.2| +00000370 98 16 03 03 00 04 0e 00 00 00 |..........| >>> Flow 3 (client to server) 00000000 16 03 03 00 25 10 00 00 21 20 2f e5 7d a3 47 cd |....%...! /.}.G.| 00000010 62 43 15 28 da ac 5f bb 29 07 30 ff f6 84 af c4 |bC.(.._.).0.....| 00000020 cf c2 ed 90 99 5f 58 cb 3b 74 14 03 03 00 01 01 |....._X.;t......| 00000030 16 03 03 00 40 00 00 00 00 00 00 00 00 00 00 00 |....@...........| -00000040 00 00 00 00 00 f9 b1 38 55 39 80 ba c1 07 e1 40 |.......8U9.....@| -00000050 b9 ac 39 da bc 66 ad c3 6d dc 1b f0 bd 2a 92 ce |..9..f..m....*..| -00000060 4b b5 97 33 5b 3b 21 6d 91 f4 dd 09 07 73 5d a2 |K..3[;!m.....s].| -00000070 b4 a3 a0 6d 43 |...mC| +00000040 00 00 00 00 00 6c 72 1c 47 f9 89 fa 2b 0e cf 69 |.....lr.G...+..i| +00000050 bf 95 e4 ea b8 74 e7 99 d4 c4 53 f5 97 f5 08 f9 |.....t....S.....| +00000060 ef 03 e7 76 b8 2c 31 f6 9b 2c cd 27 c8 42 6a a8 |...v.,1..,.'.Bj.| +00000070 c0 e0 b9 5e cd |...^.| >>> Flow 4 (server to client) -00000000 14 03 03 00 01 01 16 03 03 00 40 82 12 f1 e0 35 |..........@....5| -00000010 74 0c e5 68 7c 6b b6 fb e9 36 b3 5e 95 13 6b 04 |t..h|k...6.^..k.| -00000020 00 59 18 f0 51 50 93 2e e9 1b c6 e9 11 62 7c 01 |.Y..QP.......b|.| -00000030 43 e8 68 7b 87 a9 d5 17 3f 73 de f2 06 12 9f c7 |C.h{....?s......| -00000040 a4 81 45 52 dd 9f 6f fa ab 82 86 |..ER..o....| +00000000 14 03 03 00 01 01 16 03 03 00 40 89 35 48 2e 99 |..........@.5H..| +00000010 7c 13 76 5e 7f 07 a6 44 d9 95 1c 9f 25 59 3d f5 ||.v^...D....%Y=.| +00000020 df d6 5e cb 85 3e 0c f7 48 69 95 77 29 95 88 1c |..^..>..Hi.w)...| +00000030 1e 76 8a c3 ea 69 07 75 46 68 09 50 fa 30 0a 57 |.v...i.uFh.P.0.W| +00000040 84 e3 c7 d9 34 c4 40 32 7b f4 95 |....4.@2{..| >>> Flow 5 (client to server) 00000000 17 03 03 00 30 00 00 00 00 00 00 00 00 00 00 00 |....0...........| -00000010 00 00 00 00 00 21 96 5b 74 b3 c1 96 e9 4f 6d 97 |.....!.[t....Om.| -00000020 70 1c 5d c2 60 32 a1 98 12 2b 0d 4c 11 03 fe 17 |p.].`2...+.L....| -00000030 28 92 06 2f 84 15 03 03 00 30 00 00 00 00 00 00 |(../.....0......| -00000040 00 00 00 00 00 00 00 00 00 00 78 bf 75 9e 08 8d |..........x.u...| -00000050 57 5a 22 17 e9 d3 bd 3c e4 ac e6 58 7a e8 5e 45 |WZ"....<...Xz.^E| -00000060 63 10 b6 b8 df 78 c5 10 48 c0 |c....x..H.| +00000010 00 00 00 00 00 24 6d d9 23 68 ad 8d 64 2e 3a d5 |.....$m.#h..d.:.| +00000020 ed eb 4c e9 cb 9d 13 49 4c 44 b9 00 af af 2c e7 |..L....ILD....,.| +00000030 22 c0 bb 31 4e 15 03 03 00 30 00 00 00 00 00 00 |"..1N....0......| +00000040 00 00 00 00 00 00 00 00 00 00 c8 60 b8 c1 66 9b |...........`..f.| +00000050 52 44 3c 26 7f ff 96 a6 21 c7 eb 33 71 f8 40 23 |RD<&....!..3q.@#| +00000060 7c 5b ef b2 e1 b4 3f 84 82 48 ||[....?..H| diff --git a/testdata/Client-TLSv12-ECDHE-RSA-AES128-SHA256 b/testdata/Client-TLSv12-ECDHE-RSA-AES128-SHA256 index 03679a4..f8f04ac 100644 --- a/testdata/Client-TLSv12-ECDHE-RSA-AES128-SHA256 +++ b/testdata/Client-TLSv12-ECDHE-RSA-AES128-SHA256 @@ -7,21 +7,21 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 7f 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 0a 00 08 00 1d 00 17 00 18 00 19 00 0b 00 02 01 |................| -000000a0 00 00 0d 00 1a 00 18 08 04 04 03 08 07 08 05 08 |................| -000000b0 06 04 01 05 01 06 01 05 03 06 03 02 01 02 03 ff |................| -000000c0 01 00 01 00 00 17 00 00 00 12 00 00 00 2b 00 09 |.............+..| +00000080 01 00 00 7f 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 19 00 0d |................| +000000b0 00 1a 00 18 08 04 04 03 08 07 08 05 08 06 04 01 |................| +000000c0 05 01 06 01 05 03 06 03 02 01 02 03 00 2b 00 09 |.............+..| 000000d0 08 03 04 03 03 03 02 03 01 00 33 00 26 00 24 00 |..........3.&.$.| 000000e0 1d 00 20 2f e5 7d a3 47 cd 62 43 15 28 da ac 5f |.. /.}.G.bC.(.._| 000000f0 bb 29 07 30 ff f6 84 af c4 cf c2 ed 90 99 5f 58 |.).0.........._X| 00000100 cb 3b 74 |.;t| >>> Flow 2 (server to client) -00000000 16 03 03 00 5d 02 00 00 59 03 03 3d 4c 61 a3 1e |....]...Y..=La..| -00000010 dd 9a c3 52 42 9d ee 2b 7b f6 24 a4 38 d7 93 e9 |...RB..+{.$.8...| -00000020 f5 f4 09 a2 0f 2b 45 ae 7d fd 97 20 3b b6 27 a6 |.....+E.}.. ;.'.| -00000030 88 dd af 75 8d 27 1c c6 ef 8f 4b 33 c6 30 be 08 |...u.'....K3.0..| -00000040 7d bd 8d cd 2e d8 37 0b 67 e3 39 30 c0 27 00 00 |}.....7.g.90.'..| +00000000 16 03 03 00 5d 02 00 00 59 03 03 8f cc 68 50 60 |....]...Y....hP`| +00000010 11 c8 c3 ce e7 e9 e1 3c fb 29 d7 4f df 44 16 65 |.......<.).O.D.e| +00000020 1d 3b 25 5b 32 59 f1 8e be d8 49 20 c2 89 a7 d5 |.;%[2Y....I ....| +00000030 cb 2c a2 05 19 6b 65 64 9b 71 2b d3 d2 19 cb 66 |.,...ked.q+....f| +00000040 61 c1 6f 19 b4 7a 15 41 76 14 85 fc c0 27 00 00 |a.o..z.Av....'..| 00000050 11 ff 01 00 01 00 00 0b 00 04 03 00 01 02 00 17 |................| 00000060 00 00 16 03 03 02 59 0b 00 02 55 00 02 52 00 02 |......Y...U..R..| 00000070 4f 30 82 02 4b 30 82 01 b4 a0 03 02 01 02 02 09 |O0..K0..........| @@ -61,42 +61,42 @@ 00000290 73 bb b3 43 77 8d 0c 1c f1 0f a1 d8 40 83 61 c9 |s..Cw.......@.a.| 000002a0 4c 72 2b 9d ae db 46 06 06 4d f4 c1 b3 3e c0 d1 |Lr+...F..M...>..| 000002b0 bd 42 d4 db fe 3d 13 60 84 5c 21 d3 3b e9 fa e7 |.B...=.`.\!.;...| -000002c0 16 03 03 00 ac 0c 00 00 a8 03 00 1d 20 a4 26 51 |............ .&Q| -000002d0 47 58 cf 92 87 27 f0 c1 c0 39 55 dd 20 16 39 de |GX...'...9U. .9.| -000002e0 ed 79 66 3a 97 54 75 35 27 20 7b 99 76 08 04 00 |.yf:.Tu5' {.v...| -000002f0 80 34 32 55 55 c1 56 69 b8 4a f7 a6 d1 9d ae f6 |.42UU.Vi.J......| -00000300 0d de 13 e2 bd b8 9a 5c 42 f2 b5 42 d9 25 69 fe |.......\B..B.%i.| -00000310 ef b3 c3 0f 1b b7 a0 61 1d 1d 59 31 1c 4c 61 17 |.......a..Y1.La.| -00000320 6e 2d bc b4 08 76 ee d2 46 d4 81 c1 cc e9 96 22 |n-...v..F......"| -00000330 10 07 a5 c0 c6 26 42 c6 37 42 56 e5 47 f2 44 d1 |.....&B.7BV.G.D.| -00000340 57 1d c8 8d c1 2c 28 be e9 7a 82 2e f1 8e 1a bf |W....,(..z......| -00000350 4a f0 f2 22 de 78 00 c2 d3 f4 99 ba e9 d3 7e fc |J..".x........~.| -00000360 83 bf ef 7c 64 c6 c4 dd fb 30 e2 f9 43 43 91 60 |...|d....0..CC.`| -00000370 83 16 03 03 00 04 0e 00 00 00 |..........| +000002c0 16 03 03 00 ac 0c 00 00 a8 03 00 1d 20 88 db 33 |............ ..3| +000002d0 96 fb ae 63 de f8 2b 4b 94 fa da c2 8e 75 fa 63 |...c..+K.....u.c| +000002e0 0a 54 2b 68 01 76 2a 76 4f e7 91 e9 2a 08 04 00 |.T+h.v*vO...*...| +000002f0 80 d9 47 dd dd b9 94 b8 1c 1b dc 1f 79 bd f1 26 |..G.........y..&| +00000300 66 19 52 0b 0a 2e ea 0d 69 bf 93 a0 29 0f 6a 30 |f.R.....i...).j0| +00000310 2c 1b 44 25 13 e3 b7 03 db b3 fc 37 9c 3f bb e7 |,.D%.......7.?..| +00000320 c7 4d 65 8f af bb 39 fa 6e 77 09 bb 08 09 7e d1 |.Me...9.nw....~.| +00000330 0f ad 57 78 a6 cb a8 3f 2e 70 fc 38 75 2f a0 23 |..Wx...?.p.8u/.#| +00000340 0b 0c 6c 28 0a 71 51 dc 10 8f 85 fd 97 0f c4 84 |..l(.qQ.........| +00000350 80 cf 70 0a a9 56 9a af 2f ab 12 c7 8b d1 82 1c |..p..V../.......| +00000360 f0 6c 08 00 73 18 dd 6e 5a 66 ed a5 f7 7a 3d 73 |.l..s..nZf...z=s| +00000370 88 16 03 03 00 04 0e 00 00 00 |..........| >>> Flow 3 (client to server) 00000000 16 03 03 00 25 10 00 00 21 20 2f e5 7d a3 47 cd |....%...! /.}.G.| 00000010 62 43 15 28 da ac 5f bb 29 07 30 ff f6 84 af c4 |bC.(.._.).0.....| 00000020 cf c2 ed 90 99 5f 58 cb 3b 74 14 03 03 00 01 01 |....._X.;t......| 00000030 16 03 03 00 50 00 00 00 00 00 00 00 00 00 00 00 |....P...........| -00000040 00 00 00 00 00 06 06 f1 9b b7 1f f1 0d 24 fe 76 |.............$.v| -00000050 8a 72 84 58 8c 56 bd c3 73 4e c8 99 3c 5b 21 79 |.r.X.V..sN..<[!y| -00000060 17 23 21 bd 72 0d fb f7 22 36 99 78 1f 88 d1 87 |.#!.r..."6.x....| -00000070 73 c3 62 aa a5 22 a6 63 68 41 bb 61 34 50 b9 e7 |s.b..".chA.a4P..| -00000080 ce 6d 0b 18 f0 |.m...| +00000040 00 00 00 00 00 93 01 19 de 19 e6 58 a9 b2 bb e6 |...........X....| +00000050 83 08 03 78 72 d8 25 fc 31 70 55 fa cd ec e4 0a |...xr.%.1pU.....| +00000060 a2 7b 00 5c fe 7f 08 26 a5 ca 9f d6 28 95 69 f5 |.{.\...&....(.i.| +00000070 b9 17 23 34 83 fe 36 24 60 17 4c 90 18 30 f9 44 |..#4..6$`.L..0.D| +00000080 af 74 ea 65 4b |.t.eK| >>> Flow 4 (server to client) -00000000 14 03 03 00 01 01 16 03 03 00 50 f4 00 f2 81 78 |..........P....x| -00000010 0f 4b d9 3a 2d 62 34 77 74 6e b6 d5 e8 62 55 88 |.K.:-b4wtn...bU.| -00000020 7e 60 e4 e7 b7 35 9d dc 50 02 d2 10 ae 36 7a 5d |~`...5..P....6z]| -00000030 36 c5 89 2c 4e db 9c 83 9e d0 ec de 6e 63 1c 94 |6..,N.......nc..| -00000040 4c ed 12 ca ef 62 a1 26 a7 f9 fd 52 ad b9 1a 2b |L....b.&...R...+| -00000050 cc bc 01 bb cc 86 b5 1b 74 60 80 |........t`.| +00000000 14 03 03 00 01 01 16 03 03 00 50 b6 cf 83 c7 0d |..........P.....| +00000010 dc 8f 9a 96 0d 0b 4f 58 ed c9 46 fa 95 0b f1 ab |......OX..F.....| +00000020 9a 50 2a cc af 26 73 03 0b 93 e7 4e 96 a0 e2 44 |.P*..&s....N...D| +00000030 01 99 9e 06 a3 81 3f 0b e4 7c 03 53 e4 65 36 69 |......?..|.S.e6i| +00000040 65 96 79 a2 4e 79 e8 fc b1 6a 50 3e dd 22 1f e3 |e.y.Ny...jP>."..| +00000050 fe e3 77 9f 8c 05 f8 cc 08 4b 6b |..w......Kk| >>> Flow 5 (client to server) 00000000 17 03 03 00 40 00 00 00 00 00 00 00 00 00 00 00 |....@...........| -00000010 00 00 00 00 00 67 6b 64 7b 02 ce ad 5c df 4d 26 |.....gkd{...\.M&| -00000020 f9 ef d5 94 ec 34 28 de 52 1a d9 1b e3 af 89 11 |.....4(.R.......| -00000030 7b aa f6 46 8a 27 e7 15 c0 81 89 78 20 09 ca 37 |{..F.'.....x ..7| -00000040 dc a3 c2 5c 4f 15 03 03 00 40 00 00 00 00 00 00 |...\O....@......| -00000050 00 00 00 00 00 00 00 00 00 00 61 45 e8 a0 f8 70 |..........aE...p| -00000060 7b a3 75 09 42 b2 41 54 79 b3 75 48 47 f1 36 1b |{.u.B.ATy.uHG.6.| -00000070 4c cd 29 57 fe 9f 41 a7 7f 5c a9 12 7a ec c6 1d |L.)W..A..\..z...| -00000080 9c fb ff 1e e5 58 04 ae 16 50 |.....X...P| +00000010 00 00 00 00 00 f8 39 8e 57 60 18 1c ef 19 c8 da |......9.W`......| +00000020 f4 3b dc 42 85 44 e3 59 28 ea 29 11 60 ba 2b 2b |.;.B.D.Y(.).`.++| +00000030 dc 6a 5d 3a ed ce f2 10 34 17 6e 10 67 00 f0 43 |.j]:....4.n.g..C| +00000040 3e 0f e1 a1 c8 15 03 03 00 40 00 00 00 00 00 00 |>........@......| +00000050 00 00 00 00 00 00 00 00 00 00 13 0d fa 71 e4 df |.............q..| +00000060 76 f3 c9 01 d5 60 b4 34 d4 6f 68 f5 cd af d6 0b |v....`.4.oh.....| +00000070 e6 af ab ec 64 75 38 d6 17 d4 27 81 96 e5 71 74 |....du8...'...qt| +00000080 d5 cd 39 30 35 4a ef 92 56 6e |..905J..Vn| diff --git a/testdata/Client-TLSv12-ECDHE-RSA-CHACHA20-POLY1305 b/testdata/Client-TLSv12-ECDHE-RSA-CHACHA20-POLY1305 index 3c5779c..2ea5deb 100644 --- a/testdata/Client-TLSv12-ECDHE-RSA-CHACHA20-POLY1305 +++ b/testdata/Client-TLSv12-ECDHE-RSA-CHACHA20-POLY1305 @@ -4,21 +4,21 @@ 00000020 00 00 00 00 00 00 00 00 00 00 00 20 00 00 00 00 |........... ....| 00000030 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |................| 00000040 00 00 00 00 00 00 00 00 00 00 00 00 00 08 cc a8 |................| -00000050 13 03 13 01 13 02 01 00 00 7f 00 05 00 05 01 00 |................| -00000060 00 00 00 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 |................| -00000070 19 00 0b 00 02 01 00 00 0d 00 1a 00 18 08 04 04 |................| -00000080 03 08 07 08 05 08 06 04 01 05 01 06 01 05 03 06 |................| -00000090 03 02 01 02 03 ff 01 00 01 00 00 17 00 00 00 12 |................| -000000a0 00 00 00 2b 00 09 08 03 04 03 03 03 02 03 01 00 |...+............| +00000050 13 03 13 01 13 02 01 00 00 7f 00 0b 00 02 01 00 |................| +00000060 ff 01 00 01 00 00 17 00 00 00 12 00 00 00 05 00 |................| +00000070 05 01 00 00 00 00 00 0a 00 0a 00 08 00 1d 00 17 |................| +00000080 00 18 00 19 00 0d 00 1a 00 18 08 04 04 03 08 07 |................| +00000090 08 05 08 06 04 01 05 01 06 01 05 03 06 03 02 01 |................| +000000a0 02 03 00 2b 00 09 08 03 04 03 03 03 02 03 01 00 |...+............| 000000b0 33 00 26 00 24 00 1d 00 20 2f e5 7d a3 47 cd 62 |3.&.$... /.}.G.b| 000000c0 43 15 28 da ac 5f bb 29 07 30 ff f6 84 af c4 cf |C.(.._.).0......| 000000d0 c2 ed 90 99 5f 58 cb 3b 74 |...._X.;t| >>> Flow 2 (server to client) -00000000 16 03 03 00 5d 02 00 00 59 03 03 fa 07 a1 2e 81 |....]...Y.......| -00000010 44 c8 72 44 5b 86 21 61 2f 3e 37 92 0f d5 7f d3 |D.rD[.!a/>7.....| -00000020 0b 11 9a 5f d9 40 db 25 e4 2d da 20 11 0f ba 98 |..._.@.%.-. ....| -00000030 8b fd 6f 93 c7 05 08 69 d6 c5 bc ef 3e 2b b8 98 |..o....i....>+..| -00000040 10 f6 bc 57 72 81 a9 c0 96 1e a4 d2 cc a8 00 00 |...Wr...........| +00000000 16 03 03 00 5d 02 00 00 59 03 03 01 ce 8f f1 84 |....]...Y.......| +00000010 65 dc 47 4e 43 f2 cd 85 6c 98 40 a7 5c 7f ed 53 |e.GNC...l.@.\..S| +00000020 78 63 03 dd 50 3e a4 27 20 21 bf 20 d9 93 9d f6 |xc..P>.' !. ....| +00000030 1f e8 0e 72 fc 64 e0 dd 8e ef b3 ea ff 5b ad 60 |...r.d.......[.`| +00000040 a5 f0 68 ff 7e 35 46 a4 28 71 31 fd cc a8 00 00 |..h.~5F.(q1.....| 00000050 11 ff 01 00 01 00 00 0b 00 04 03 00 01 02 00 17 |................| 00000060 00 00 16 03 03 02 59 0b 00 02 55 00 02 52 00 02 |......Y...U..R..| 00000070 4f 30 82 02 4b 30 82 01 b4 a0 03 02 01 02 02 09 |O0..K0..........| @@ -58,31 +58,31 @@ 00000290 73 bb b3 43 77 8d 0c 1c f1 0f a1 d8 40 83 61 c9 |s..Cw.......@.a.| 000002a0 4c 72 2b 9d ae db 46 06 06 4d f4 c1 b3 3e c0 d1 |Lr+...F..M...>..| 000002b0 bd 42 d4 db fe 3d 13 60 84 5c 21 d3 3b e9 fa e7 |.B...=.`.\!.;...| -000002c0 16 03 03 00 ac 0c 00 00 a8 03 00 1d 20 c7 4c 84 |............ .L.| -000002d0 aa 9d be 0a bb 72 d2 bc 76 73 59 9b 07 e1 6f 94 |.....r..vsY...o.| -000002e0 25 e7 13 7a 4c a5 8d f9 ab 9d 30 d0 4c 08 04 00 |%..zL.....0.L...| -000002f0 80 88 4d ea e2 83 d7 b6 50 fb 22 e0 a9 32 87 8e |..M.....P."..2..| -00000300 cf e3 3d 94 bc 07 99 c3 b7 53 9d f6 0c 80 77 f7 |..=......S....w.| -00000310 96 50 39 eb 85 33 9e 17 72 14 f7 3f e6 c2 9b 94 |.P9..3..r..?....| -00000320 bb bc 26 b9 c6 68 1f 2a 19 d6 40 f5 8b 85 a4 8d |..&..h.*..@.....| -00000330 c8 29 96 bf d1 e1 15 f7 f8 75 66 42 00 45 d3 ff |.).......ufB.E..| -00000340 4d ef f7 ad 7b b5 00 3e 9f 08 b8 ce 87 df d9 fa |M...{..>........| -00000350 79 b9 d1 a4 a3 a7 ad 0b 2b fc 65 c2 51 dc 8c 29 |y.......+.e.Q..)| -00000360 85 31 92 f9 b3 dd 1a a1 f1 f0 9c 21 9d a0 6e 49 |.1.........!..nI| -00000370 ff 16 03 03 00 04 0e 00 00 00 |..........| +000002c0 16 03 03 00 ac 0c 00 00 a8 03 00 1d 20 ea 03 c7 |............ ...| +000002d0 b0 eb 76 ba 86 25 18 e5 0d b3 70 2a 41 72 4d 88 |..v..%....p*ArM.| +000002e0 55 6d 91 2b 65 fe e0 64 12 69 42 eb 27 08 04 00 |Um.+e..d.iB.'...| +000002f0 80 0f 00 0a b0 35 db 39 fa ba a1 27 44 e0 9b d4 |.....5.9...'D...| +00000300 b8 aa b3 4f 93 46 ed 09 f8 3e 1b c8 47 6e 52 8a |...O.F...>..GnR.| +00000310 8f fd b1 67 f6 05 87 68 de 7b 25 1b 40 df 1e f2 |...g...h.{%.@...| +00000320 04 2b 4f 39 3d 6f a8 f7 25 37 26 34 87 84 06 c4 |.+O9=o..%7&4....| +00000330 0e 31 bc 46 8a d2 99 14 6d 5d 14 32 a2 32 fc 10 |.1.F....m].2.2..| +00000340 5e fb d9 f8 06 d4 05 17 5d 59 f4 38 c5 13 1c 91 |^.......]Y.8....| +00000350 5a 5f cb dd 3e 27 78 10 2c 0c 9b 7f 1a ec 4c da |Z_..>'x.,.....L.| +00000360 fb d7 52 eb 76 83 75 87 d2 a3 7f e9 25 a5 8a 22 |..R.v.u.....%.."| +00000370 dd 16 03 03 00 04 0e 00 00 00 |..........| >>> Flow 3 (client to server) 00000000 16 03 03 00 25 10 00 00 21 20 2f e5 7d a3 47 cd |....%...! /.}.G.| 00000010 62 43 15 28 da ac 5f bb 29 07 30 ff f6 84 af c4 |bC.(.._.).0.....| 00000020 cf c2 ed 90 99 5f 58 cb 3b 74 14 03 03 00 01 01 |....._X.;t......| -00000030 16 03 03 00 20 61 fc dc e1 f7 bf 7b 90 e4 af 71 |.... a.....{...q| -00000040 03 22 10 79 6d d9 e9 aa 1d 60 8e 40 d1 1e 3a 94 |.".ym....`.@..:.| -00000050 ca 78 86 ad e6 |.x...| +00000030 16 03 03 00 20 28 48 18 85 9d 35 c7 5a 46 2c a7 |.... (H...5.ZF,.| +00000040 5b 8b c0 71 73 66 d0 a7 53 a0 e3 ed c8 57 f3 70 |[..qsf..S....W.p| +00000050 9a 01 58 61 84 |..Xa.| >>> Flow 4 (server to client) -00000000 14 03 03 00 01 01 16 03 03 00 20 39 ee c6 1c d9 |.......... 9....| -00000010 83 3e d3 bf 8a c3 3d bb 0a 27 7a 95 84 ef 82 e1 |.>....=..'z.....| -00000020 80 6b 25 bf 68 dc 58 63 21 80 7d |.k%.h.Xc!.}| +00000000 14 03 03 00 01 01 16 03 03 00 20 b9 72 f6 07 40 |.......... .r..@| +00000010 0b 2f 67 8a 97 fa 17 24 81 e5 6f 5b 09 90 72 8d |./g....$..o[..r.| +00000020 48 59 14 00 34 e8 3c 82 b8 2f 87 |HY..4.<../.| >>> Flow 5 (client to server) -00000000 17 03 03 00 16 e6 75 bb fe 46 1a 4c 75 41 36 eb |......u..F.LuA6.| -00000010 a9 31 d9 59 74 9d 75 76 db 00 94 15 03 03 00 12 |.1.Yt.uv........| -00000020 f0 a9 56 8e bd a5 bb c8 2d ea be d7 7f 9e 39 7a |..V.....-.....9z| -00000030 4f de |O.| +00000000 17 03 03 00 16 f6 cf b1 93 64 54 56 f3 35 3d 8f |.........dTV.5=.| +00000010 31 5e 66 62 56 aa e9 81 47 4c 8b 15 03 03 00 12 |1^fbV...GL......| +00000020 de 0b 32 2b 58 2c b5 4e 80 2a 66 e7 a0 a9 28 d9 |..2+X,.N.*f...(.| +00000030 db 11 |..| diff --git a/testdata/Client-TLSv12-Ed25519 b/testdata/Client-TLSv12-Ed25519 index b2380ed..d43ee07 100644 --- a/testdata/Client-TLSv12-Ed25519 +++ b/testdata/Client-TLSv12-Ed25519 @@ -7,21 +7,21 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 7f 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 0a 00 08 00 1d 00 17 00 18 00 19 00 0b 00 02 01 |................| -000000a0 00 00 0d 00 1a 00 18 08 04 04 03 08 07 08 05 08 |................| -000000b0 06 04 01 05 01 06 01 05 03 06 03 02 01 02 03 ff |................| -000000c0 01 00 01 00 00 17 00 00 00 12 00 00 00 2b 00 09 |.............+..| +00000080 01 00 00 7f 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 19 00 0d |................| +000000b0 00 1a 00 18 08 04 04 03 08 07 08 05 08 06 04 01 |................| +000000c0 05 01 06 01 05 03 06 03 02 01 02 03 00 2b 00 09 |.............+..| 000000d0 08 03 04 03 03 03 02 03 01 00 33 00 26 00 24 00 |..........3.&.$.| 000000e0 1d 00 20 2f e5 7d a3 47 cd 62 43 15 28 da ac 5f |.. /.}.G.bC.(.._| 000000f0 bb 29 07 30 ff f6 84 af c4 cf c2 ed 90 99 5f 58 |.).0.........._X| 00000100 cb 3b 74 |.;t| >>> Flow 2 (server to client) -00000000 16 03 03 00 5d 02 00 00 59 03 03 17 80 d3 0b 73 |....]...Y......s| -00000010 6d e4 3e 2d 7a 35 ab ab 65 ad a0 03 14 cb e8 98 |m.>-z5..e.......| -00000020 3a d3 c6 41 39 b2 78 c2 1b 06 da 20 ec 80 a9 c4 |:..A9.x.... ....| -00000030 7c b8 9b cc b3 98 7a cd 97 40 41 39 b7 75 13 7a ||.....z..@A9.u.z| -00000040 40 33 ec 9d 69 97 32 5b f5 6e 4f bc cc a9 00 00 |@3..i.2[.nO.....| +00000000 16 03 03 00 5d 02 00 00 59 03 03 93 8a a3 77 84 |....]...Y.....w.| +00000010 fd 41 3d a5 ad b5 eb 91 63 a6 b5 3a 5f 21 08 df |.A=.....c..:_!..| +00000020 72 07 be 1f df d7 4e 6f f3 f8 cb 20 ae d3 e5 fe |r.....No... ....| +00000030 53 a3 c7 84 6c 3e c6 1d d5 65 5d a6 a5 7d f7 5c |S...l>...e]..}.\| +00000040 34 65 a7 df 1e 28 3f 7d 20 08 81 2c cc a9 00 00 |4e...(?} ..,....| 00000050 11 ff 01 00 01 00 00 0b 00 04 03 00 01 02 00 17 |................| 00000060 00 00 16 03 03 01 3c 0b 00 01 38 00 01 35 00 01 |......<...8..5..| 00000070 32 30 82 01 2e 30 81 e1 a0 03 02 01 02 02 10 0f |20...0..........| @@ -44,26 +44,26 @@ 00000180 fc ab 7d 4d d4 e0 93 13 d0 a9 42 e0 b6 6b fe 5d |..}M......B..k.]| 00000190 67 48 d7 9f 50 bc 6c cd 4b 03 83 7c f2 08 58 cd |gH..P.l.K..|..X.| 000001a0 ac cf 0c 16 03 03 00 6c 0c 00 00 68 03 00 1d 20 |.......l...h... | -000001b0 6b 23 39 84 eb 4d db d0 0c f4 5a 9f ce bf 3a a8 |k#9..M....Z...:.| -000001c0 52 df 00 9b 14 10 31 95 21 35 07 f1 7f 22 bf 14 |R.....1.!5..."..| -000001d0 08 07 00 40 f6 b8 53 ed 97 7f 5a 28 88 84 f4 aa |...@..S...Z(....| -000001e0 64 30 dc 4c 80 1f 8f 62 9d 52 aa bb e7 98 e1 7f |d0.L...b.R......| -000001f0 12 19 b5 84 d2 4b 92 b1 38 a9 4e c2 09 1a 91 bf |.....K..8.N.....| -00000200 4a 83 5e a4 82 a0 36 84 85 0d bd b5 a9 4f 2f 60 |J.^...6......O/`| -00000210 a4 2f 33 0d 16 03 03 00 04 0e 00 00 00 |./3..........| +000001b0 e9 e7 75 b4 4c 42 14 7a e0 50 0a 95 f1 d7 35 aa |..u.LB.z.P....5.| +000001c0 39 05 9e 59 73 5e cd d2 ec 56 18 f0 ee 1f 81 3c |9..Ys^...V.....<| +000001d0 08 07 00 40 44 e9 19 b6 00 49 f7 c8 06 62 cb c1 |...@D....I...b..| +000001e0 b5 7c b6 cd 32 47 c9 05 82 3b f0 af d1 cd 75 8b |.|..2G...;....u.| +000001f0 82 8b 47 dd 85 13 78 69 5d 40 7e 9b 91 24 2e ce |..G...xi]@~..$..| +00000200 3e be e0 12 1e ec 56 0b ff 25 21 92 6f 24 12 10 |>.....V..%!.o$..| +00000210 30 33 cf 04 16 03 03 00 04 0e 00 00 00 |03...........| >>> Flow 3 (client to server) 00000000 16 03 03 00 25 10 00 00 21 20 2f e5 7d a3 47 cd |....%...! /.}.G.| 00000010 62 43 15 28 da ac 5f bb 29 07 30 ff f6 84 af c4 |bC.(.._.).0.....| 00000020 cf c2 ed 90 99 5f 58 cb 3b 74 14 03 03 00 01 01 |....._X.;t......| -00000030 16 03 03 00 20 a2 a9 10 50 bb d9 12 ee 74 a1 79 |.... ...P....t.y| -00000040 cb fa 36 73 26 89 4e a4 2d 14 c0 ac f3 7b 82 c6 |..6s&.N.-....{..| -00000050 cf fb 00 88 9e |.....| +00000030 16 03 03 00 20 69 ac be cf f1 3d 8a 4e f3 3a 54 |.... i....=.N.:T| +00000040 05 d8 20 3a f0 67 40 3f 5b 94 cf a4 3e ec 8e 4e |.. :.g@?[...>..N| +00000050 75 c9 92 2c af |u..,.| >>> Flow 4 (server to client) -00000000 14 03 03 00 01 01 16 03 03 00 20 22 85 b9 b0 e7 |.......... "....| -00000010 14 c0 a6 a9 91 4e 08 80 83 75 92 b5 45 9d 13 e9 |.....N...u..E...| -00000020 0f 45 e7 55 ac b7 68 93 b4 bb 00 |.E.U..h....| +00000000 14 03 03 00 01 01 16 03 03 00 20 70 c5 f8 c7 7c |.......... p...|| +00000010 4a 34 6f b0 eb 1b 13 c7 e0 21 32 cf ce 89 aa 53 |J4o......!2....S| +00000020 5f 67 b8 a7 3e 10 bb a3 5f fa 2f |_g..>..._./| >>> Flow 5 (client to server) -00000000 17 03 03 00 16 0a c8 36 60 97 80 1c d5 d5 3c 3d |.......6`.....<=| -00000010 07 4f 9b 2c 75 6c a0 b1 9a 2c b8 15 03 03 00 12 |.O.,ul...,......| -00000020 fc a4 95 ae ee fe e2 4f ad b2 13 e0 c9 a7 2a 5a |.......O......*Z| -00000030 54 2c |T,| +00000000 17 03 03 00 16 54 ae 8d 1c 04 40 47 8a 7e ac c3 |.....T....@G.~..| +00000010 21 a2 8a f0 5d 3d 12 9d b0 b5 8d 15 03 03 00 12 |!...]=..........| +00000020 71 3b 30 89 d4 c3 ef 34 66 92 29 1b e1 af d4 d2 |q;0....4f.).....| +00000030 7e cd |~.| diff --git a/testdata/Client-TLSv12-ExportKeyingMaterial b/testdata/Client-TLSv12-ExportKeyingMaterial index cbd1fbd..3d06b4c 100644 --- a/testdata/Client-TLSv12-ExportKeyingMaterial +++ b/testdata/Client-TLSv12-ExportKeyingMaterial @@ -7,21 +7,21 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 7f 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 0a 00 08 00 1d 00 17 00 18 00 19 00 0b 00 02 01 |................| -000000a0 00 00 0d 00 1a 00 18 08 04 04 03 08 07 08 05 08 |................| -000000b0 06 04 01 05 01 06 01 05 03 06 03 02 01 02 03 ff |................| -000000c0 01 00 01 00 00 17 00 00 00 12 00 00 00 2b 00 09 |.............+..| +00000080 01 00 00 7f 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 19 00 0d |................| +000000b0 00 1a 00 18 08 04 04 03 08 07 08 05 08 06 04 01 |................| +000000c0 05 01 06 01 05 03 06 03 02 01 02 03 00 2b 00 09 |.............+..| 000000d0 08 03 04 03 03 03 02 03 01 00 33 00 26 00 24 00 |..........3.&.$.| 000000e0 1d 00 20 2f e5 7d a3 47 cd 62 43 15 28 da ac 5f |.. /.}.G.bC.(.._| 000000f0 bb 29 07 30 ff f6 84 af c4 cf c2 ed 90 99 5f 58 |.).0.........._X| 00000100 cb 3b 74 |.;t| >>> Flow 2 (server to client) -00000000 16 03 03 00 5d 02 00 00 59 03 03 86 45 94 b6 f3 |....]...Y...E...| -00000010 30 74 36 25 50 09 38 f6 3e 4a 5a b6 bf 06 fd 01 |0t6%P.8.>JZ.....| -00000020 4b 35 b0 bc ef 77 bf f6 e9 a2 84 20 97 96 9b ba |K5...w..... ....| -00000030 24 5f 28 cd 16 3f d3 f4 2b 92 da 09 a5 18 2f 21 |$_(..?..+...../!| -00000040 d8 23 85 9a c9 4a 69 36 93 ab c2 5a cc a8 00 00 |.#...Ji6...Z....| +00000000 16 03 03 00 5d 02 00 00 59 03 03 18 47 80 ab 8d |....]...Y...G...| +00000010 42 c7 73 06 75 ef 28 ff 87 46 49 af 3a 3b cb bb |B.s.u.(..FI.:;..| +00000020 ff 6e e3 60 11 40 2c b8 40 87 5c 20 86 3d de c2 |.n.`.@,.@.\ .=..| +00000030 18 41 ff 1a dc 00 77 4e 17 0b 36 f3 69 92 d7 04 |.A....wN..6.i...| +00000040 c4 c6 39 ad ed f7 06 23 8c 52 50 da cc a8 00 00 |..9....#.RP.....| 00000050 11 ff 01 00 01 00 00 0b 00 04 03 00 01 02 00 17 |................| 00000060 00 00 16 03 03 02 59 0b 00 02 55 00 02 52 00 02 |......Y...U..R..| 00000070 4f 30 82 02 4b 30 82 01 b4 a0 03 02 01 02 02 09 |O0..K0..........| @@ -61,31 +61,31 @@ 00000290 73 bb b3 43 77 8d 0c 1c f1 0f a1 d8 40 83 61 c9 |s..Cw.......@.a.| 000002a0 4c 72 2b 9d ae db 46 06 06 4d f4 c1 b3 3e c0 d1 |Lr+...F..M...>..| 000002b0 bd 42 d4 db fe 3d 13 60 84 5c 21 d3 3b e9 fa e7 |.B...=.`.\!.;...| -000002c0 16 03 03 00 ac 0c 00 00 a8 03 00 1d 20 34 09 94 |............ 4..| -000002d0 56 6a c3 3b 88 60 42 3d 1d f2 99 a1 8e 56 72 e3 |Vj.;.`B=.....Vr.| -000002e0 09 83 17 04 60 08 ad db 70 c6 f6 77 2a 08 04 00 |....`...p..w*...| -000002f0 80 80 1c d5 53 c0 5b 1f 86 e9 d7 16 18 0d 50 3c |....S.[.......P<| -00000300 b6 40 1f 58 ea 79 e6 af cf a1 cf 55 3f e1 fe 04 |.@.X.y.....U?...| -00000310 bc e5 1c 4a ae 36 e9 7b 64 a1 76 ea 43 bc 8f a7 |...J.6.{d.v.C...| -00000320 0a 8a 8b d1 af 54 57 21 9b 55 10 90 91 07 f7 96 |.....TW!.U......| -00000330 68 68 33 ec 4b c4 70 08 88 92 59 2d 4d 86 47 d9 |hh3.K.p...Y-M.G.| -00000340 8a a7 d2 22 b4 ab 83 0e 3b 29 79 fd 1b f7 5b c8 |..."....;)y...[.| -00000350 b2 d5 3a be 74 e7 b5 c8 6e 4e c4 8d c5 70 6c 98 |..:.t...nN...pl.| -00000360 fe 57 f9 2e c0 8c d3 38 39 e9 0e c1 17 c9 8d 36 |.W.....89......6| -00000370 47 16 03 03 00 04 0e 00 00 00 |G.........| +000002c0 16 03 03 00 ac 0c 00 00 a8 03 00 1d 20 c5 28 44 |............ .(D| +000002d0 4a 31 d9 b6 53 90 8e 41 3c 67 2c 6f 9d b0 a6 d3 |J1..S..A>> Flow 3 (client to server) 00000000 16 03 03 00 25 10 00 00 21 20 2f e5 7d a3 47 cd |....%...! /.}.G.| 00000010 62 43 15 28 da ac 5f bb 29 07 30 ff f6 84 af c4 |bC.(.._.).0.....| 00000020 cf c2 ed 90 99 5f 58 cb 3b 74 14 03 03 00 01 01 |....._X.;t......| -00000030 16 03 03 00 20 35 b3 34 ef 69 93 b1 31 f1 da 9c |.... 5.4.i..1...| -00000040 3f 49 e5 99 8f af 4f 3b 48 52 b9 a3 fa 42 e7 3e |?I....O;HR...B.>| -00000050 29 4c 22 b7 0a |)L"..| +00000030 16 03 03 00 20 9f 16 49 2a d8 cc 0a 45 92 8d c2 |.... ..I*...E...| +00000040 25 3c b1 5c a8 f2 c4 9b c4 2a 66 fe 7f 87 df 35 |%<.\.....*f....5| +00000050 77 a4 b0 05 f5 |w....| >>> Flow 4 (server to client) -00000000 14 03 03 00 01 01 16 03 03 00 20 cd 8f ee d3 57 |.......... ....W| -00000010 a5 e4 c0 4c 83 91 37 e2 5b 30 aa a1 52 ed 6c 42 |...L..7.[0..R.lB| -00000020 5b d6 59 1c 9f f7 c6 69 c9 2a 5d |[.Y....i.*]| +00000000 14 03 03 00 01 01 16 03 03 00 20 37 55 d5 05 71 |.......... 7U..q| +00000010 a0 00 44 56 32 c3 c8 e6 68 5e de d4 e7 65 56 d3 |..DV2...h^...eV.| +00000020 2d 93 07 e6 72 17 e9 49 74 4d c0 |-...r..ItM.| >>> Flow 5 (client to server) -00000000 17 03 03 00 16 c9 3b 66 6a 59 3a b6 be 39 a0 db |......;fjY:..9..| -00000010 e9 b4 d8 e1 f5 a6 15 70 4a fc e7 15 03 03 00 12 |.......pJ.......| -00000020 1b c5 fe f3 89 a3 0d d6 1e 23 2d 54 d6 01 62 3c |.........#-T..b<| -00000030 af 0c |..| +00000000 17 03 03 00 16 27 a6 31 16 5c 7e bd 05 0a 2c 05 |.....'.1.\~...,.| +00000010 ba 37 06 00 d7 8d 66 a7 8e 16 7b 15 03 03 00 12 |.7....f...{.....| +00000020 70 38 bc 7e 6b 83 83 e1 61 3b bb a5 d9 dc f7 e7 |p8.~k...a;......| +00000030 5e 12 |^.| diff --git a/testdata/Client-TLSv12-P256-ECDHE b/testdata/Client-TLSv12-P256-ECDHE index 9b6c750..7a0a53c 100644 --- a/testdata/Client-TLSv12-P256-ECDHE +++ b/testdata/Client-TLSv12-P256-ECDHE @@ -7,22 +7,22 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 9a 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 04 00 02 00 17 00 0b 00 02 01 00 00 0d 00 1a 00 |................| -000000a0 18 08 04 04 03 08 07 08 05 08 06 04 01 05 01 06 |................| -000000b0 01 05 03 06 03 02 01 02 03 ff 01 00 01 00 00 17 |................| -000000c0 00 00 00 12 00 00 00 2b 00 09 08 03 04 03 03 03 |.......+........| +00000080 01 00 00 9a 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 04 00 02 00 17 00 0d 00 1a 00 18 08 04 |................| +000000b0 04 03 08 07 08 05 08 06 04 01 05 01 06 01 05 03 |................| +000000c0 06 03 02 01 02 03 00 2b 00 09 08 03 04 03 03 03 |.......+........| 000000d0 02 03 01 00 33 00 47 00 45 00 17 00 41 04 1e 18 |....3.G.E...A...| 000000e0 37 ef 0d 19 51 88 35 75 71 b5 e5 54 5b 12 2e 8f |7...Q.5uq..T[...| 000000f0 09 67 fd a7 24 20 3e b2 56 1c ce 97 28 5e f8 2b |.g..$ >.V...(^.+| 00000100 2d 4f 9e f1 07 9f 6c 4b 5b 83 56 e2 32 42 e9 58 |-O....lK[.V.2B.X| 00000110 b6 d7 49 a6 b5 68 1a 41 03 56 6b dc 5a 89 |..I..h.A.Vk.Z.| >>> Flow 2 (server to client) -00000000 16 03 03 00 5d 02 00 00 59 03 03 a4 cd 94 7e 17 |....]...Y.....~.| -00000010 86 6e 81 dc 58 f5 86 34 fc 66 25 77 df 05 e5 85 |.n..X..4.f%w....| -00000020 98 2e b4 38 e3 54 98 93 f5 ef 9e 20 db e9 53 1a |...8.T..... ..S.| -00000030 67 e3 18 c1 64 66 4f 92 7f d6 44 42 a0 b3 04 d9 |g...dfO...DB....| -00000040 c3 5f f2 6a 89 e6 fd e9 6d bf 2c a6 c0 2f 00 00 |._.j....m.,../..| +00000000 16 03 03 00 5d 02 00 00 59 03 03 1c ad ae e9 64 |....]...Y......d| +00000010 35 80 c6 04 f5 69 05 bb 5c 38 78 d3 99 2f ad e6 |5....i..\8x../..| +00000020 56 20 d4 79 89 1a 51 54 14 ac 6d 20 06 6d 1a bd |V .y..QT..m .m..| +00000030 04 cf 4f 42 3d aa 31 3b fb dc c1 85 42 c3 6d 12 |..OB=.1;....B.m.| +00000040 27 98 be 4b 88 93 45 0e 78 ba d8 13 c0 2f 00 00 |'..K..E.x..../..| 00000050 11 ff 01 00 01 00 00 0b 00 04 03 00 01 02 00 17 |................| 00000060 00 00 16 03 03 02 59 0b 00 02 55 00 02 52 00 02 |......Y...U..R..| 00000070 4f 30 82 02 4b 30 82 01 b4 a0 03 02 01 02 02 09 |O0..K0..........| @@ -62,37 +62,37 @@ 00000290 73 bb b3 43 77 8d 0c 1c f1 0f a1 d8 40 83 61 c9 |s..Cw.......@.a.| 000002a0 4c 72 2b 9d ae db 46 06 06 4d f4 c1 b3 3e c0 d1 |Lr+...F..M...>..| 000002b0 bd 42 d4 db fe 3d 13 60 84 5c 21 d3 3b e9 fa e7 |.B...=.`.\!.;...| -000002c0 16 03 03 00 cd 0c 00 00 c9 03 00 17 41 04 28 4d |............A.(M| -000002d0 03 04 41 d2 e5 04 f6 34 90 21 2e bc da 53 95 9d |..A....4.!...S..| -000002e0 2b 10 d8 b5 e2 e1 47 06 08 b7 7a 4a d4 13 3a f9 |+.....G...zJ..:.| -000002f0 50 22 c0 fb 4e 13 b9 1f b9 43 20 71 be b8 e1 9b |P"..N....C q....| -00000300 c8 6b 48 fb 80 22 87 8a 61 54 fb c1 7a 7e 08 04 |.kH.."..aT..z~..| -00000310 00 80 86 09 16 06 8e 1c c9 02 ec 9d d9 4d c0 d1 |.............M..| -00000320 d1 d0 48 96 f6 31 4a 69 02 9e 27 26 ca ff bb 1e |..H..1Ji..'&....| -00000330 94 3b fb 41 fa 11 a5 cd ec a7 a0 6f 4c 35 dc 7a |.;.A.......oL5.z| -00000340 fb fd c4 41 ab 5b ee 21 96 16 9d 42 8f ce b6 50 |...A.[.!...B...P| -00000350 6a 48 9f 92 d2 00 70 53 30 c3 3d 5e a9 cb e3 f1 |jH....pS0.=^....| -00000360 52 19 c8 1a 58 f5 19 9a 11 a2 ea 9d a2 29 5e b2 |R...X........)^.| -00000370 ef bb c1 a6 c5 2c e4 33 2f 6d 60 ac 34 42 dc 42 |.....,.3/m`.4B.B| -00000380 85 69 e3 c6 b8 2d af c4 37 8e b8 b6 39 4e 07 ff |.i...-..7...9N..| -00000390 88 d0 16 03 03 00 04 0e 00 00 00 |...........| +000002c0 16 03 03 00 cd 0c 00 00 c9 03 00 17 41 04 3a 1c |............A.:.| +000002d0 84 6b e6 cb 7d 3f bd ea d7 7a c3 63 43 77 f7 14 |.k..}?...z.cCw..| +000002e0 a7 98 52 86 49 4d 05 b2 70 e2 d3 44 c9 05 eb 83 |..R.IM..p..D....| +000002f0 b4 11 c5 3e 9d 3b 3b cd de d0 df 78 83 0f 0c d8 |...>.;;....x....| +00000300 76 e7 19 9d 1f 5a 3d 2a 54 19 16 a0 c2 55 08 04 |v....Z=*T....U..| +00000310 00 80 09 ee 97 8a d1 82 fc 4a fc f2 89 d2 a3 c7 |.........J......| +00000320 8c 25 74 98 cf b5 67 c6 fd f6 0d 3b 62 ba 31 ca |.%t...g....;b.1.| +00000330 d1 67 aa c3 32 89 ee 83 22 d2 b7 3c f8 98 af 16 |.g..2..."..<....| +00000340 dd 05 06 2c c4 57 dd fc 22 3a 2e 80 f9 84 6a ee |...,.W..":....j.| +00000350 f2 a1 21 d1 0f db 17 50 a1 35 94 b3 0a b7 62 ca |..!....P.5....b.| +00000360 2c b3 0b 68 0c 58 d7 24 83 82 d8 34 64 3f a4 61 |,..h.X.$...4d?.a| +00000370 0e b1 ca 93 67 b3 51 11 dc 49 f2 df 26 89 8b ea |....g.Q..I..&...| +00000380 22 09 1a be 62 27 61 c8 93 4b dd 95 31 6a ba e2 |"...b'a..K..1j..| +00000390 c3 2b 16 03 03 00 04 0e 00 00 00 |.+.........| >>> Flow 3 (client to server) 00000000 16 03 03 00 46 10 00 00 42 41 04 1e 18 37 ef 0d |....F...BA...7..| 00000010 19 51 88 35 75 71 b5 e5 54 5b 12 2e 8f 09 67 fd |.Q.5uq..T[....g.| 00000020 a7 24 20 3e b2 56 1c ce 97 28 5e f8 2b 2d 4f 9e |.$ >.V...(^.+-O.| 00000030 f1 07 9f 6c 4b 5b 83 56 e2 32 42 e9 58 b6 d7 49 |...lK[.V.2B.X..I| 00000040 a6 b5 68 1a 41 03 56 6b dc 5a 89 14 03 03 00 01 |..h.A.Vk.Z......| -00000050 01 16 03 03 00 28 00 00 00 00 00 00 00 00 e3 ce |.....(..........| -00000060 26 ff 24 7b cf 1a 6e 65 68 3d 56 ca 11 6c 7c a6 |&.${..neh=V..l|.| -00000070 de 97 f1 f3 cd 04 4e 38 bd 0c 5b 08 1b dd |......N8..[...| +00000050 01 16 03 03 00 28 00 00 00 00 00 00 00 00 fa c4 |.....(..........| +00000060 4e 47 d1 de 6d 60 fc af 59 43 7f 2f 4c b3 6e aa |NG..m`..YC./L.n.| +00000070 6f c3 bc 8a 40 5e e9 9c d9 b0 87 c5 92 41 |o...@^.......A| >>> Flow 4 (server to client) -00000000 14 03 03 00 01 01 16 03 03 00 28 38 ac 96 e8 6f |..........(8...o| -00000010 bc 22 ba 46 a9 64 f6 dc 19 79 5e 01 cd 50 db 9e |.".F.d...y^..P..| -00000020 98 23 19 2a f2 25 49 b9 f1 cb 63 c5 5e 32 85 c4 |.#.*.%I...c.^2..| -00000030 e0 e5 16 |...| +00000000 14 03 03 00 01 01 16 03 03 00 28 eb 92 83 02 be |..........(.....| +00000010 89 55 4e 77 b2 45 1d 15 fd e0 6a 36 ab 0c 7b 4a |.UNw.E....j6..{J| +00000020 5d 50 e2 5a f3 c6 10 e2 ac ac a4 d3 4c 2e d8 31 |]P.Z........L..1| +00000030 84 31 17 |.1.| >>> Flow 5 (client to server) -00000000 17 03 03 00 1e 00 00 00 00 00 00 00 01 b7 b1 9c |................| -00000010 5d 9f f1 b7 21 b3 30 00 9d 39 26 5f 6e 99 67 e8 |]...!.0..9&_n.g.| -00000020 47 01 62 15 03 03 00 1a 00 00 00 00 00 00 00 02 |G.b.............| -00000030 2a 2f 3f 76 2a 10 9b ee c0 86 41 8a fe cf c5 70 |*/?v*.....A....p| -00000040 c7 ac |..| +00000000 17 03 03 00 1e 00 00 00 00 00 00 00 01 90 44 33 |..............D3| +00000010 cf be 4e 29 fc 6f 2f 30 c1 ef aa 8e cb 10 0e f9 |..N).o/0........| +00000020 8f 60 fc 15 03 03 00 1a 00 00 00 00 00 00 00 02 |.`..............| +00000030 80 cb 52 6b e7 c9 45 af 69 6b e8 ee 88 23 61 20 |..Rk..E.ik...#a | +00000040 74 33 |t3| diff --git a/testdata/Client-TLSv12-RSA-RC4 b/testdata/Client-TLSv12-RSA-RC4 index f995680..24a9b8e 100644 --- a/testdata/Client-TLSv12-RSA-RC4 +++ b/testdata/Client-TLSv12-RSA-RC4 @@ -7,21 +7,21 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 7f 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 0a 00 08 00 1d 00 17 00 18 00 19 00 0b 00 02 01 |................| -000000a0 00 00 0d 00 1a 00 18 08 04 04 03 08 07 08 05 08 |................| -000000b0 06 04 01 05 01 06 01 05 03 06 03 02 01 02 03 ff |................| -000000c0 01 00 01 00 00 17 00 00 00 12 00 00 00 2b 00 09 |.............+..| +00000080 01 00 00 7f 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 19 00 0d |................| +000000b0 00 1a 00 18 08 04 04 03 08 07 08 05 08 06 04 01 |................| +000000c0 05 01 06 01 05 03 06 03 02 01 02 03 00 2b 00 09 |.............+..| 000000d0 08 03 04 03 03 03 02 03 01 00 33 00 26 00 24 00 |..........3.&.$.| 000000e0 1d 00 20 2f e5 7d a3 47 cd 62 43 15 28 da ac 5f |.. /.}.G.bC.(.._| 000000f0 bb 29 07 30 ff f6 84 af c4 cf c2 ed 90 99 5f 58 |.).0.........._X| 00000100 cb 3b 74 |.;t| >>> Flow 2 (server to client) -00000000 16 03 03 00 55 02 00 00 51 03 03 d4 a4 5a fb c9 |....U...Q....Z..| -00000010 93 ee 7e 5a c4 04 8e bb 72 da ad a4 0f 9c 0f 6e |..~Z....r......n| -00000020 2b 28 9a ef 28 be d4 49 9b 50 56 20 f8 5a e3 7b |+(..(..I.PV .Z.{| -00000030 c7 96 74 ff 52 4f 68 32 08 15 2b 46 ad 47 3e 49 |..t.ROh2..+F.G>I| -00000040 f9 a7 f8 65 78 fe 01 c0 8f ab 8e 14 00 05 00 00 |...ex...........| +00000000 16 03 03 00 55 02 00 00 51 03 03 7c f1 44 f1 2a |....U...Q..|.D.*| +00000010 6f 7f 62 66 08 15 dd c8 bd 4a 30 b5 a3 73 53 82 |o.bf.....J0..sS.| +00000020 93 78 6b f2 c6 70 70 1e 4d 8f 48 20 24 b3 17 46 |.xk..pp.M.H $..F| +00000030 37 c0 0f 79 af f4 48 43 17 6b ea df 6b 73 07 cf |7..y..HC.k..ks..| +00000040 5f 95 c5 5c 8d b2 99 5c fd 30 e5 1b 00 05 00 00 |_..\...\.0......| 00000050 09 ff 01 00 01 00 00 17 00 00 16 03 03 02 59 0b |..............Y.| 00000060 00 02 55 00 02 52 00 02 4f 30 82 02 4b 30 82 01 |..U..R..O0..K0..| 00000070 b4 a0 03 02 01 02 02 09 00 e8 f0 9d 3f e2 5b ea |............?.[.| @@ -72,15 +72,15 @@ 00000060 c5 70 0f 08 83 48 e9 48 ef 6e 50 8b 05 7e e5 84 |.p...H.H.nP..~..| 00000070 25 fa 55 c7 ae 31 02 27 00 ef 3f 98 86 20 12 89 |%.U..1.'..?.. ..| 00000080 91 59 28 b4 f7 d7 af d2 69 61 35 14 03 03 00 01 |.Y(.....ia5.....| -00000090 01 16 03 03 00 24 f7 3b 92 e7 9f 80 de 5b d4 9e |.....$.;.....[..| -000000a0 d3 02 d3 d9 2c e1 74 2e 98 90 fe d9 ee 08 57 28 |....,.t.......W(| -000000b0 47 99 86 84 f5 95 c5 a6 7f 82 |G.........| +00000090 01 16 03 03 00 24 fd 67 40 11 7e 4d 8f bb 87 e8 |.....$.g@.~M....| +000000a0 c3 1f e8 b0 15 17 3a f4 6f 5f 87 b2 50 c5 92 e4 |......:.o_..P...| +000000b0 ac c0 c0 98 aa 6f be bc fc 77 |.....o...w| >>> Flow 4 (server to client) -00000000 14 03 03 00 01 01 16 03 03 00 24 c9 09 6c e8 0b |..........$..l..| -00000010 44 56 62 ed 1f f1 ef 9d a9 cd a4 49 01 0d 2b e3 |DVb........I..+.| -00000020 8f 3d 31 6d bf c5 63 af d4 59 30 47 c6 cd 20 |.=1m..c..Y0G.. | +00000000 14 03 03 00 01 01 16 03 03 00 24 e8 ea 6f 8a 0c |..........$..o..| +00000010 79 70 73 a9 7b 2c a8 0a e5 f8 26 f3 eb 05 20 65 |yps.{,....&... e| +00000020 58 9b 0c 8e 28 3d c7 ee cf 57 85 06 a5 d7 46 |X...(=...W....F| >>> Flow 5 (client to server) -00000000 17 03 03 00 1a 65 05 a9 14 f7 fd 4e e1 68 20 7e |.....e.....N.h ~| -00000010 32 79 ca e6 e7 79 a3 d6 ce fd 28 37 c7 e2 c5 15 |2y...y....(7....| -00000020 03 03 00 16 87 82 bc 62 e3 c0 4d 2e 75 86 21 05 |.......b..M.u.!.| -00000030 c0 3d 40 d4 1d fc 1b 42 ef 55 |.=@....B.U| +00000000 17 03 03 00 1a 2d 7a c5 d0 12 79 e8 a2 05 d3 a4 |.....-z...y.....| +00000010 51 80 8f 28 37 b9 75 64 f3 11 4c 78 de 0c f3 15 |Q..(7.ud..Lx....| +00000020 03 03 00 16 43 89 2c 8b 9e dc c5 5d 4c ca 7b 4e |....C.,....]L.{N| +00000030 15 e4 e5 62 01 02 b4 d4 6f 1c |...b....o.| diff --git a/testdata/Client-TLSv12-RenegotiateOnce b/testdata/Client-TLSv12-RenegotiateOnce index 30db289..0510d5e 100644 --- a/testdata/Client-TLSv12-RenegotiateOnce +++ b/testdata/Client-TLSv12-RenegotiateOnce @@ -7,21 +7,21 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 7f 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 0a 00 08 00 1d 00 17 00 18 00 19 00 0b 00 02 01 |................| -000000a0 00 00 0d 00 1a 00 18 08 04 04 03 08 07 08 05 08 |................| -000000b0 06 04 01 05 01 06 01 05 03 06 03 02 01 02 03 ff |................| -000000c0 01 00 01 00 00 17 00 00 00 12 00 00 00 2b 00 09 |.............+..| +00000080 01 00 00 7f 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 19 00 0d |................| +000000b0 00 1a 00 18 08 04 04 03 08 07 08 05 08 06 04 01 |................| +000000c0 05 01 06 01 05 03 06 03 02 01 02 03 00 2b 00 09 |.............+..| 000000d0 08 03 04 03 03 03 02 03 01 00 33 00 26 00 24 00 |..........3.&.$.| 000000e0 1d 00 20 2f e5 7d a3 47 cd 62 43 15 28 da ac 5f |.. /.}.G.bC.(.._| 000000f0 bb 29 07 30 ff f6 84 af c4 cf c2 ed 90 99 5f 58 |.).0.........._X| 00000100 cb 3b 74 |.;t| >>> Flow 2 (server to client) -00000000 16 03 03 00 5d 02 00 00 59 03 03 6d a7 e6 c4 60 |....]...Y..m...`| -00000010 8e dd 95 85 14 dc 69 2b d5 16 35 dd 4f a1 43 d4 |......i+..5.O.C.| -00000020 3c 8f 0f 55 4b f1 86 68 51 5b 17 20 d8 44 06 84 |<..UK..hQ[. .D..| -00000030 d5 1d 9b ed 45 25 d0 e8 a2 73 fd 44 01 fa 38 63 |....E%...s.D..8c| -00000040 c3 18 35 1c b8 54 ec 78 ab 5f 3d f3 cc a8 00 00 |..5..T.x._=.....| +00000000 16 03 03 00 5d 02 00 00 59 03 03 55 71 df 37 76 |....]...Y..Uq.7v| +00000010 48 bb 86 62 66 f1 58 0d 92 f4 c8 bd 17 6c 00 43 |H..bf.X......l.C| +00000020 a9 da f1 6f 19 2c 76 81 6d aa eb 20 4f c7 eb 3f |...o.,v.m.. O..?| +00000030 b8 48 89 7f d8 61 bc e8 3c e6 a0 3d 6c 29 fd 60 |.H...a..<..=l).`| +00000040 7c 0a 09 1c 71 41 07 04 24 dc e7 27 cc a8 00 00 ||...qA..$..'....| 00000050 11 ff 01 00 01 00 00 0b 00 04 03 00 01 02 00 17 |................| 00000060 00 00 16 03 03 02 59 0b 00 02 55 00 02 52 00 02 |......Y...U..R..| 00000070 4f 30 82 02 4b 30 82 01 b4 a0 03 02 01 02 02 09 |O0..K0..........| @@ -61,186 +61,186 @@ 00000290 73 bb b3 43 77 8d 0c 1c f1 0f a1 d8 40 83 61 c9 |s..Cw.......@.a.| 000002a0 4c 72 2b 9d ae db 46 06 06 4d f4 c1 b3 3e c0 d1 |Lr+...F..M...>..| 000002b0 bd 42 d4 db fe 3d 13 60 84 5c 21 d3 3b e9 fa e7 |.B...=.`.\!.;...| -000002c0 16 03 03 00 ac 0c 00 00 a8 03 00 1d 20 f1 ac a3 |............ ...| -000002d0 08 ba 9d 89 8e 71 c3 db b1 46 f0 ac 2f 32 13 ad |.....q...F../2..| -000002e0 f7 42 ee b5 9f e5 5c 52 46 0a 9a 53 75 08 04 00 |.B....\RF..Su...| -000002f0 80 89 8c 5b cd e9 fe 7f 6b 15 36 bc d7 43 ed f3 |...[....k.6..C..| -00000300 96 df 69 7c 65 26 f8 68 4f 5b fb 53 75 2c 5a 65 |..i|e&.hO[.Su,Ze| -00000310 4d b4 7b c5 bd 36 71 ea 43 bb 84 ec f3 8f 6b 49 |M.{..6q.C.....kI| -00000320 26 cb fa c1 4c 8b 92 e1 91 ed 09 61 7d 85 44 ea |&...L......a}.D.| -00000330 a7 1c a4 47 02 d2 b4 c0 bf 44 14 e8 03 64 8d 86 |...G.....D...d..| -00000340 80 5c 63 eb ab a0 66 ca 30 2e d7 04 54 d8 91 94 |.\c...f.0...T...| -00000350 37 e8 6c b8 00 a0 06 98 5c 67 c2 46 a2 e9 5c b8 |7.l.....\g.F..\.| -00000360 66 46 b8 82 65 22 29 80 b8 af 50 37 5c 00 96 a5 |fF..e")...P7\...| -00000370 85 16 03 03 00 04 0e 00 00 00 |..........| +000002c0 16 03 03 00 ac 0c 00 00 a8 03 00 1d 20 7a 15 23 |............ z.#| +000002d0 f5 78 c2 16 21 72 bb e5 d3 2e c9 67 55 a8 2c 1f |.x..!r.....gU.,.| +000002e0 00 50 a2 04 4f 71 9a 94 4a 90 55 69 33 08 04 00 |.P..Oq..J.Ui3...| +000002f0 80 53 b3 16 f5 08 3a 5a 84 3c 02 5d c3 b6 0e c2 |.S....:Z.<.]....| +00000300 93 f6 27 74 24 b4 e2 3d 22 04 30 a0 d6 5b c8 da |..'t$..=".0..[..| +00000310 6e 56 30 d4 fb 86 fd 76 8f 1b 47 c0 55 95 cd 15 |nV0....v..G.U...| +00000320 bf a7 27 ce 2d c3 43 6b ed 2d 09 bb eb 55 73 c9 |..'.-.Ck.-...Us.| +00000330 2c ee cd 23 af d9 1c 51 1d 0c 00 14 01 61 8a fd |,..#...Q.....a..| +00000340 8f 95 d1 ce 32 57 ae 2b 09 15 b4 86 41 1e 74 f5 |....2W.+....A.t.| +00000350 d5 96 d7 e1 03 03 09 f4 3c 53 fe 6b 9a c1 52 ab |........>> Flow 3 (client to server) 00000000 16 03 03 00 25 10 00 00 21 20 2f e5 7d a3 47 cd |....%...! /.}.G.| 00000010 62 43 15 28 da ac 5f bb 29 07 30 ff f6 84 af c4 |bC.(.._.).0.....| 00000020 cf c2 ed 90 99 5f 58 cb 3b 74 14 03 03 00 01 01 |....._X.;t......| -00000030 16 03 03 00 20 ca 08 57 0f 80 64 62 ad 11 01 27 |.... ..W..db...'| -00000040 39 d8 80 6c a6 05 f6 75 a1 b6 0d 72 c0 25 f7 bc |9..l...u...r.%..| -00000050 f0 de 76 ee 29 |..v.)| +00000030 16 03 03 00 20 bf 35 ae 8c b4 63 82 40 e8 5d d4 |.... .5...c.@.].| +00000040 bb 3d 0a 0f 07 28 3a 74 2c 5b a8 d0 a6 ab 88 ba |.=...(:t,[......| +00000050 7d 5c 1c 42 c7 |}\.B.| >>> Flow 4 (server to client) -00000000 14 03 03 00 01 01 16 03 03 00 20 27 45 9d b0 c3 |.......... 'E...| -00000010 18 c6 34 cb 1a 38 33 ac 91 4f f1 e5 d5 02 ed 62 |..4..83..O.....b| -00000020 c0 46 1e a0 4a b3 46 35 2e e1 a2 |.F..J.F5...| +00000000 14 03 03 00 01 01 16 03 03 00 20 e7 86 48 6c 00 |.......... ..Hl.| +00000010 0a 1e f5 5f b8 ff ad 1c 9d 74 24 c5 6e d4 c6 6e |..._.....t$.n..n| +00000020 25 27 7d 6e 18 44 96 29 eb db b0 |%'}n.D.)...| >>> Flow 5 (client to server) -00000000 17 03 03 00 16 50 48 06 41 d8 9d 1b e9 8b 55 9b |.....PH.A.....U.| -00000010 3c ba ea 58 93 5b 56 17 6e 94 18 |<..X.[V.n..| +00000000 17 03 03 00 16 64 9d 31 09 a1 ce 5a 6d ec 6f c4 |.....d.1...Zm.o.| +00000010 e5 09 df 92 5f d2 1c 7d 62 c4 e7 |...._..}b..| >>> Flow 6 (server to client) -00000000 16 03 03 00 14 4c 65 ba 49 aa 53 4c 73 0a 51 ac |.....Le.I.SLs.Q.| -00000010 43 0d 4c 1f 83 6b d9 b1 06 |C.L..k...| +00000000 16 03 03 00 14 9b cb 75 61 99 76 30 9c 14 a5 12 |.......ua.v0....| +00000010 92 de b7 95 cc 8f fe ad f1 |.........| >>> Flow 7 (client to server) -00000000 16 03 03 01 1a fd 7a 4e 2b 7b 8a 07 cc cb 5b 82 |......zN+{....[.| -00000010 df d1 00 69 f8 6f 89 28 4b 91 87 c8 18 20 ec 41 |...i.o.(K.... .A| -00000020 ec c7 bd 04 3d 02 a5 42 fe e1 23 cc 20 aa 22 e8 |....=..B..#. .".| -00000030 31 2e 09 a3 ac c1 3d 04 29 2e 82 1c 31 27 8e e2 |1.....=.)...1'..| -00000040 50 de ca 3d 4d ad 7e 01 74 94 40 3d 7c 2d 08 56 |P..=M.~.t.@=|-.V| -00000050 d2 89 7b 3a b8 2a b1 34 22 65 25 48 bb 24 1b 4b |..{:.*.4"e%H.$.K| -00000060 a2 96 a8 7f ac f2 46 84 4f e2 c8 1c 25 41 eb df |......F.O...%A..| -00000070 52 ec 9b bd 89 b8 a8 c3 62 f2 75 16 de 61 63 b0 |R.......b.u..ac.| -00000080 70 9c d2 c5 b0 86 6b 2a 17 64 9a d1 6d 5c e9 48 |p.....k*.d..m\.H| -00000090 f5 02 e3 0f 16 df f9 6e 99 56 93 85 2b 10 bc da |.......n.V..+...| -000000a0 6e 02 8b 94 ac d2 dc 56 93 ad 8b 1d d6 ff e3 d9 |n......V........| -000000b0 f8 ee 11 15 c7 e4 ae 4d fe 88 0c c9 7f 30 1a 2a |.......M.....0.*| -000000c0 99 ab f8 0d a2 a9 57 87 35 a4 a9 87 b0 4f 46 8a |......W.5....OF.| -000000d0 ec 47 39 32 a7 94 3a 15 08 80 e5 1e 81 4b cd 2e |.G92..:......K..| -000000e0 76 9d 99 5b 86 89 37 09 a0 08 86 6e bb 67 ad 3f |v..[..7....n.g.?| -000000f0 a2 e9 1f 37 75 4b 0f 07 8c f3 e7 34 05 74 33 a9 |...7uK.....4.t3.| -00000100 5a e3 5b 0e 68 d0 54 e4 24 c9 6c 42 2d 81 8f 29 |Z.[.h.T.$.lB-..)| -00000110 17 97 3d a8 00 00 27 50 ae 5d 97 6d fa 7e c0 |..=...'P.].m.~.| +00000000 16 03 03 01 1a c7 9a be e1 2a 62 9f 01 59 e9 6a |.........*b..Y.j| +00000010 5f d6 32 88 bd 39 76 1b 34 fd 39 8d c7 31 cb 97 |_.2..9v.4.9..1..| +00000020 c6 09 8b 00 c9 f3 f9 00 c5 b6 48 e1 28 ae b8 8b |..........H.(...| +00000030 b2 f0 eb 8b cb e8 68 30 50 b5 23 ba cf f3 8d f3 |......h0P.#.....| +00000040 47 5f 94 ac fb 5e 56 9e 5a f8 e7 12 60 13 83 9c |G_...^V.Z...`...| +00000050 34 ca 45 a7 63 5f 2c 6e 46 c8 5a a0 d3 5b 9a a6 |4.E.c_,nF.Z..[..| +00000060 70 be da df 9e 79 21 98 bd fb 94 01 6d 14 f4 5c |p....y!.....m..\| +00000070 2a 13 56 26 47 33 7d 4f ab 5a fc 9c 9e 8d f4 75 |*.V&G3}O.Z.....u| +00000080 d0 64 16 ba f2 0d 04 ca 5d 94 6b da a8 09 b1 29 |.d......].k....)| +00000090 70 a9 37 1e ac 94 e3 81 60 c3 19 f3 a9 99 6a 11 |p.7.....`.....j.| +000000a0 b1 e7 23 45 8a f5 42 f5 50 76 9f 1e 9e a8 e7 75 |..#E..B.Pv.....u| +000000b0 4a 18 84 80 da 10 ed 83 9a 14 a9 a1 90 54 8e 8b |J............T..| +000000c0 d1 32 83 6d e7 7e be 59 f4 66 59 53 75 37 c6 82 |.2.m.~.Y.fYSu7..| +000000d0 15 aa 56 0a 01 e1 11 ba 64 0c 8e 44 93 60 29 a4 |..V.....d..D.`).| +000000e0 cc 9f b0 b9 d5 df 9c aa 64 2c ef 0c 9a 18 2a 97 |........d,....*.| +000000f0 e1 20 07 37 35 28 97 9d 00 53 61 11 81 22 45 9e |. .75(...Sa.."E.| +00000100 c3 d7 b2 b3 4c f2 05 5b e6 a4 de 11 7f a7 a2 82 |....L..[........| +00000110 88 1c cb d9 24 80 3d 34 0c fc 22 58 32 28 1b |....$.=4.."X2(.| >>> Flow 8 (server to client) -00000000 16 03 03 00 85 74 29 5c 40 48 b9 9c 76 e4 eb a1 |.....t)\@H..v...| -00000010 44 7e f1 72 cd 7b fe 11 47 4d 48 fe bc 75 4e e1 |D~.r.{..GMH..uN.| -00000020 b4 8d cb d1 0e d7 16 cc 4b d4 61 f9 47 69 cd aa |........K.a.Gi..| -00000030 c4 ad bf fd 01 6b 5c a6 63 d4 73 a4 21 f8 fe 72 |.....k\.c.s.!..r| -00000040 00 48 55 4e 40 6b 85 e5 1c f2 36 c1 91 2e e2 70 |.HUN@k....6....p| -00000050 38 95 5a aa 0c c7 32 c9 a5 ac 94 dc 6c 50 f5 e9 |8.Z...2.....lP..| -00000060 9f 14 48 f0 b3 d1 45 99 d3 aa 68 28 22 4a ae 66 |..H...E...h("J.f| -00000070 3a 2f 06 c1 86 fb 0c f2 b0 ca 6f e2 93 fe 47 e6 |:/........o...G.| -00000080 2f 33 2d 60 38 42 2f 56 f7 52 16 03 03 02 69 46 |/3-`8B/V.R....iF| -00000090 86 2d bb 38 d9 57 1c 29 bd 28 17 a8 ef 4e 26 68 |.-.8.W.).(...N&h| -000000a0 16 73 f7 2c 52 fb 54 f8 4d 6d 1e c2 57 0d 44 16 |.s.,R.T.Mm..W.D.| -000000b0 24 3d 5d b5 22 8c 13 b0 09 10 45 65 48 ec 5c 3f |$=].".....EeH.\?| -000000c0 c4 9f c1 ee ff 2b 6e 36 76 bc 01 5d f4 96 44 43 |.....+n6v..]..DC| -000000d0 bb 90 04 ec 18 d6 0b 29 2d 1f 08 0b 02 0d cf 43 |.......)-......C| -000000e0 7c a0 76 40 6d f0 eb 14 42 5a 9d df 29 35 1c 4f ||.v@m...BZ..)5.O| -000000f0 35 ef ad 60 18 16 51 97 2c 73 40 e5 74 1c 48 a7 |5..`..Q.,s@.t.H.| -00000100 e5 4d 35 2c 1a 4c 35 f6 9a eb 0d d7 49 5f 04 06 |.M5,.L5.....I_..| -00000110 da 56 8d f4 3b 3f 20 09 91 fd d3 51 31 65 05 f5 |.V..;? ....Q1e..| -00000120 fa 85 4b 1b 3a 00 33 b0 96 28 d7 3b d7 92 d0 5c |..K.:.3..(.;...\| -00000130 04 13 4d d9 a5 02 19 19 13 1d 8a 9d f4 68 c0 98 |..M..........h..| -00000140 2f f0 86 b2 6b 05 af af 65 a5 0d ab 8e af 74 dc |/...k...e.....t.| -00000150 a6 fa 41 0a 23 4b e6 1a 13 8d 96 01 9a 40 5b 09 |..A.#K.......@[.| -00000160 3b 8f 70 ab 1f d6 8c 27 f6 3d bf 85 b0 f5 66 f7 |;.p....'.=....f.| -00000170 ae 94 df ee 5f 75 47 19 e4 a1 a6 58 bf f2 8b 0e |...._uG....X....| -00000180 05 8a 3a 40 13 35 05 f1 7d 89 f6 6d 14 1c 5f 1c |..:@.5..}..m.._.| -00000190 e7 86 cc b5 83 52 55 9f 28 bf 56 54 96 91 92 7e |.....RU.(.VT...~| -000001a0 18 a6 21 8f e0 98 ee 6d 6b 19 53 0e f1 25 86 ec |..!....mk.S..%..| -000001b0 0e 5d 97 34 36 55 e3 a7 a8 5a 9f 43 8a ed ad c6 |.].46U...Z.C....| -000001c0 cb 81 96 6f 9f 3b 2c db 24 4c 32 05 c0 8e d8 5a |...o.;,.$L2....Z| -000001d0 b3 87 33 b8 5c d8 57 6b d0 94 7f 22 62 7c 15 d8 |..3.\.Wk..."b|..| -000001e0 0f 05 b0 e7 04 85 94 5f 7b b2 25 e2 a2 46 c1 43 |......._{.%..F.C| -000001f0 ac ef f7 c3 89 06 11 d6 c5 a9 0f 3d e0 7a fa 66 |...........=.z.f| -00000200 31 44 1b a8 ff 2c 11 a7 1e 43 73 1d dd c4 a8 36 |1D...,...Cs....6| -00000210 85 45 9e 34 46 78 ba 9a 9c 6a da 58 82 9a b0 2b |.E.4Fx...j.X...+| -00000220 6b 74 98 bb 6a 9d 2d 54 1b 80 09 01 13 85 60 8a |kt..j.-T......`.| -00000230 75 96 df 35 33 72 a4 d6 d3 6e 1a 0a 11 0a 0b b3 |u..53r...n......| -00000240 5c 87 82 69 09 9d 22 a9 8b e4 b2 fb af 5c fd 82 |\..i.."......\..| -00000250 32 30 f4 a8 ca a1 83 3e 8b 4d 3b 00 a6 63 7f c2 |20.....>.M;..c..| -00000260 36 60 80 f2 b5 40 76 98 a6 f9 e8 49 04 62 c0 31 |6`...@v....I.b.1| -00000270 06 da 4c a7 ff 6b 52 e2 7e af 22 b2 2c 84 df 8c |..L..kR.~.".,...| -00000280 d1 5e 7d 19 7b c7 9e da 14 e0 7e 9f 78 4a 0c bb |.^}.{.....~.xJ..| -00000290 77 28 3e 12 03 c3 59 91 2a b1 6c 7e 78 ce d6 ac |w(>...Y.*.l~x...| -000002a0 a0 57 06 20 d1 2b 74 59 20 e0 7f 4d 35 31 1a 3d |.W. .+tY ..M51.=| -000002b0 67 e9 1b 84 92 17 81 04 10 a4 5e 4d c2 00 ea 64 |g.........^M...d| -000002c0 b9 fb 82 41 2e c0 66 68 2a 9e 1d 86 ee df f4 f9 |...A..fh*.......| -000002d0 c5 6b d0 f6 07 61 93 22 31 a7 31 ee bc f3 c8 a7 |.k...a."1.1.....| -000002e0 dc 21 ea eb 61 94 aa 6f 9a a2 0a 74 d9 db 39 48 |.!..a..o...t..9H| -000002f0 21 8a f4 0a 6d f0 e7 07 16 03 03 00 bc 03 03 f8 |!...m...........| -00000300 01 78 b0 ea 48 3d 57 b3 c7 69 62 74 ee 0e 92 a4 |.x..H=W..ibt....| -00000310 d0 96 ed fe 94 2b 11 cd d1 13 f7 e8 cc 61 0c 6e |.....+.......a.n| -00000320 8a 28 70 e1 c2 01 fe 19 66 eb 47 b3 e8 7b ff fc |.(p.....f.G..{..| -00000330 e6 c0 4e 5e 15 ae b6 14 04 64 33 d3 77 bc ce ea |..N^.....d3.w...| -00000340 47 4a 85 ef ff 16 79 33 1b 2e db 42 ab ee 7c 7f |GJ....y3...B..|.| -00000350 37 65 b5 ee 70 71 f1 7b 99 9b 63 c5 23 dd 7b 0c |7e..pq.{..c.#.{.| -00000360 ed 48 07 a4 d5 a2 63 5b fd 99 01 f4 df b6 a7 95 |.H....c[........| -00000370 23 a5 c0 00 e9 b4 2b f4 f8 3e 9b ca b3 34 ff e6 |#.....+..>...4..| -00000380 5a 2f 0a 7a 55 81 77 3b 7a c5 66 e8 2c 4a 01 50 |Z/.zU.w;z.f.,J.P| -00000390 13 13 79 8a b3 9f 9b 49 e9 e7 0a a7 d4 c9 7f 10 |..y....I........| -000003a0 29 89 70 d9 83 5d 21 a9 40 7a 17 1f 6e 3d 4e 2a |).p..]!.@z..n=N*| -000003b0 48 e7 1c fa 07 2f 3f 5d 32 16 03 03 00 4a f9 74 |H..../?]2....J.t| -000003c0 d5 eb 38 ef d8 bf 7a 69 2f b0 d3 e0 e1 57 d7 fc |..8...zi/....W..| -000003d0 01 57 2e e6 99 ba 0c 23 07 59 f3 75 28 1d 77 26 |.W.....#.Y.u(.w&| -000003e0 2f 4d f4 f3 16 0a d6 2e 38 50 48 e3 a2 90 e1 0b |/M......8PH.....| -000003f0 78 99 35 81 d1 d9 4a 7b 47 a2 e1 95 39 f6 02 87 |x.5...J{G...9...| -00000400 1f fe 4f 7e 2e ee 9a 17 16 03 03 00 14 98 8e a2 |..O~............| -00000410 b6 b6 79 35 d1 fe b2 cb 90 ea 7c 91 5a 37 53 e4 |..y5......|.Z7S.| -00000420 73 |s| +00000000 16 03 03 00 85 ba 55 5d 15 b8 6d 8a b6 82 a8 e1 |......U]..m.....| +00000010 88 ea fe c0 a6 a8 fe 78 ed 8b ae 44 eb 7b 6c cc |.......x...D.{l.| +00000020 0f ad a1 da da 86 fb 60 07 4a 0e 5c ba 36 09 8b |.......`.J.\.6..| +00000030 95 3f f0 87 26 0f 7a e7 7c 1f af c7 67 42 c9 39 |.?..&.z.|...gB.9| +00000040 39 6a 4d 8d 87 00 3b 14 76 4a 86 87 46 1e d4 04 |9jM...;.vJ..F...| +00000050 2d ea c1 44 1f e8 87 71 da 1e 26 72 a2 e9 40 0c |-..D...q..&r..@.| +00000060 33 6e 6f 06 43 ed 7f fc 8f 4c d4 f4 0f 83 19 cb |3no.C....L......| +00000070 52 a9 94 f3 6a 64 db dd 20 d1 a7 d4 c7 6e 86 ed |R...jd.. ....n..| +00000080 6e ea 5c 66 d1 34 a6 92 7e b1 16 03 03 02 69 48 |n.\f.4..~.....iH| +00000090 13 97 82 60 46 e1 c9 02 d2 e1 f3 62 da d6 3a c1 |...`F......b..:.| +000000a0 2a a7 47 bd c2 ee 09 d5 2d 7e 5e 35 09 79 88 35 |*.G.....-~^5.y.5| +000000b0 96 50 09 68 79 e9 de e1 71 97 11 60 c5 4e 84 54 |.P.hy...q..`.N.T| +000000c0 03 78 69 84 e3 7f 02 1a 58 04 ed 53 47 01 b6 9e |.xi.....X..SG...| +000000d0 bd 5f 77 34 e7 52 3b 73 45 e1 10 3f c8 6e 4c 09 |._w4.R;sE..?.nL.| +000000e0 d0 4b 79 f8 de 0f 15 e7 2d 42 5d 7a 89 80 1f fb |.Ky.....-B]z....| +000000f0 f9 02 6f a1 72 d4 8d 65 8e d0 a8 43 41 4c 48 57 |..o.r..e...CALHW| +00000100 71 21 b3 14 45 e5 b1 f5 55 7a dd 89 c3 0f af 27 |q!..E...Uz.....'| +00000110 03 d6 5c 2d bc 24 5b 51 fa ae 34 7b f9 56 e8 41 |..\-.$[Q..4{.V.A| +00000120 cd 77 1c 3d c8 45 f5 a5 4a 97 92 ff bb cd 5b ff |.w.=.E..J.....[.| +00000130 d5 33 d6 02 9b 2a 5a 3a e4 1b fb 48 34 b3 0b ce |.3...*Z:...H4...| +00000140 d7 34 5c 4a b4 4b bd 87 b6 72 40 ab 29 b0 65 25 |.4\J.K...r@.).e%| +00000150 c7 1d 71 b6 e2 d7 b1 23 b1 96 a6 bd 74 eb ad 69 |..q....#....t..i| +00000160 59 0c 0f af 8a 64 be e4 a7 27 c2 95 11 05 55 a1 |Y....d...'....U.| +00000170 d6 44 df ad 1d 9c 3a 88 24 52 52 9d 42 f2 74 98 |.D....:.$RR.B.t.| +00000180 08 9f 55 1b 2f 79 ca b4 63 38 e4 f2 fa 99 ce 66 |..U./y..c8.....f| +00000190 77 ac 8d 31 91 05 1c bc 51 0a 31 df 5d 3e f8 69 |w..1....Q.1.]>.i| +000001a0 b7 fa f2 35 af 57 6d 7b c3 bf 1d 98 21 40 dd 02 |...5.Wm{....!@..| +000001b0 1c de ac 02 40 c8 d6 04 23 30 71 16 d0 0a 26 29 |....@...#0q...&)| +000001c0 66 e9 f1 a8 76 f8 52 18 3e 3f c5 66 c9 11 04 6c |f...v.R.>?.f...l| +000001d0 32 1b 35 cc 9a 34 70 07 da db 12 51 78 77 dc bc |2.5..4p....Qxw..| +000001e0 7a bb b8 b9 06 79 bb 04 dd d4 46 8e b5 69 d5 39 |z....y....F..i.9| +000001f0 5e 34 8e 37 dd a2 3e 31 be 28 19 45 21 76 5b dc |^4.7..>1.(.E!v[.| +00000200 7d 25 a2 41 98 16 1b 5b 69 f0 90 f9 28 a8 e9 b5 |}%.A...[i...(...| +00000210 6f 00 e3 3e eb f6 f3 e4 c9 0f bb 74 ce 40 23 df |o..>.......t.@#.| +00000220 12 c6 78 b0 2e bb 68 96 04 a3 e3 43 6b 4b c3 37 |..x...h....CkK.7| +00000230 6d 97 c6 79 1a ff 4f 00 c7 76 64 5c b8 b3 17 20 |m..y..O..vd\... | +00000240 3c 3e 6b d5 2b 72 88 11 73 1e 63 a7 6f 1e ae 83 |<>k.+r..s.c.o...| +00000250 10 77 6f d1 96 86 84 63 fd 27 8e b9 54 da 4b b5 |.wo....c.'..T.K.| +00000260 56 f0 50 8a aa c7 e1 b3 cb 9c 36 9e ec 38 31 39 |V.P.......6..819| +00000270 78 ec ea 34 8a 87 cf 6b 34 fd 5e 81 92 81 61 f1 |x..4...k4.^...a.| +00000280 88 e7 50 62 2e 58 0b d9 b9 ca f3 ed 79 a9 9a 01 |..Pb.X......y...| +00000290 80 9d 7f 84 ae de fb 51 ac 0f 6b b9 76 fd 68 d4 |.......Q..k.v.h.| +000002a0 f4 8d c3 92 6b 5e 9e 99 ff 7a f4 b7 0e ec 0d e7 |....k^...z......| +000002b0 6b 24 75 fb 21 49 6f 5b 31 12 f2 88 8e 3b b4 34 |k$u.!Io[1....;.4| +000002c0 f2 f7 c6 e7 48 0e d6 1d 81 11 32 16 01 cb b7 7f |....H.....2.....| +000002d0 a6 bd 9c 87 8c 0f 12 b2 dc 73 5d a0 46 fd f3 e8 |.........s].F...| +000002e0 b8 6f e4 38 ab 94 96 a8 bd ed 90 0e 31 1f fc 2f |.o.8........1../| +000002f0 8f 50 e2 97 6a f5 5c b4 16 03 03 00 bc 65 bb 7c |.P..j.\......e.|| +00000300 42 03 0d 42 46 e3 ac 9f 8a 96 b6 a3 f4 cf a5 30 |B..BF..........0| +00000310 5b 02 17 dc 20 7d 18 19 21 a4 70 f4 4b 99 bf b5 |[... }..!.p.K...| +00000320 cd d7 07 59 a5 82 ed 85 03 06 5c 34 3f c8 c3 4d |...Y......\4?..M| +00000330 c3 fb 96 05 bf b5 bd bf e2 28 07 7e 51 a6 84 90 |.........(.~Q...| +00000340 bf 9e 2e f6 b5 04 8e 06 7a 63 c8 00 84 a1 a3 2c |........zc.....,| +00000350 f3 6f 52 52 c4 ce 4a 59 31 1f d4 ab 2e f4 75 90 |.oRR..JY1.....u.| +00000360 a5 3b ff ab 20 be 51 92 c5 f4 4d 8b f2 2a a7 ff |.;.. .Q...M..*..| +00000370 90 07 40 3e d6 9c cf 23 54 d1 65 d3 74 79 af 51 |..@>...#T.e.ty.Q| +00000380 31 35 40 aa 29 42 32 7e 42 2d af 79 e8 59 6a 10 |15@.)B2~B-.y.Yj.| +00000390 c5 55 6b 70 53 53 ab 02 48 ba 1f df 07 59 f8 34 |.UkpSS..H....Y.4| +000003a0 ee 1d d3 e9 12 86 8b 37 2b cc 27 78 fe e1 65 2b |.......7+.'x..e+| +000003b0 c3 1e f2 25 a4 6d 3c b1 d4 16 03 03 00 4a 50 98 |...%.m<......JP.| +000003c0 cd ee ab 2c 94 95 d6 46 06 ef 63 65 5c aa 6d 6e |...,...F..ce\.mn| +000003d0 fb a0 99 62 23 af 7a 7d 17 dc a3 c6 2b 9a 56 2e |...b#.z}....+.V.| +000003e0 b8 60 87 1e 88 5d 58 27 3f 02 b4 f5 2f 3b 17 8c |.`...]X'?.../;..| +000003f0 f9 93 0c a9 58 af 11 ed 27 9d af a5 0a 2b d6 55 |....X...'....+.U| +00000400 7e c4 54 4a 36 51 b7 7b 16 03 03 00 14 c1 c4 d7 |~.TJ6Q.{........| +00000410 ea 2d f0 8c 54 0e 19 33 e1 7e a8 ae 49 7c 5e 05 |.-..T..3.~..I|^.| +00000420 23 |#| >>> Flow 9 (client to server) -00000000 16 03 03 02 69 ad fd 5e 51 7c 1a 62 01 a3 c7 84 |....i..^Q|.b....| -00000010 d6 d8 2d 47 2b 00 d5 d4 7c e6 16 94 7e 32 74 85 |..-G+...|...~2t.| -00000020 ce 13 d9 af d7 27 77 86 43 77 1b ca 68 f5 1f da |.....'w.Cw..h...| -00000030 20 d8 61 29 b0 11 3d 40 66 62 a0 82 ff 38 85 07 | .a)..=@fb...8..| -00000040 52 fc 59 92 44 c4 ea 12 70 62 cd 05 66 0a b4 cb |R.Y.D...pb..f...| -00000050 38 23 f4 35 58 a0 4c 1e bc 1a 5a 6a be ad 81 c9 |8#.5X.L...Zj....| -00000060 22 97 dc 7d 77 76 da e8 b5 30 be d3 28 be b2 30 |"..}wv...0..(..0| -00000070 05 52 8f 41 d3 a1 78 68 9b 76 ad 29 42 ec 90 c5 |.R.A..xh.v.)B...| -00000080 61 f2 aa f2 f0 fb dd 08 42 f3 5a a8 3c 8d f9 98 |a.......B.Z.<...| -00000090 90 00 2e e1 aa 7c ac 3f cf 34 9d ed 56 09 30 d3 |.....|.?.4..V.0.| -000000a0 1b 03 9e fb 0c 16 4c 99 0f 86 a9 03 44 ce 8b 66 |......L.....D..f| -000000b0 a6 42 bb 0b dc a4 82 47 7d fc 09 48 1d 47 85 da |.B.....G}..H.G..| -000000c0 3f 30 d1 94 36 a0 ac 44 72 2f a4 cc 5a fd 6c 96 |?0..6..Dr/..Z.l.| -000000d0 05 14 0c 25 5c 19 44 1e c2 40 12 57 be 30 1d bb |...%\.D..@.W.0..| -000000e0 62 f4 2c c2 f1 46 83 1b ad bd f4 e0 ff b2 de 62 |b.,..F.........b| -000000f0 85 04 61 3d 61 67 aa d1 f7 ba db 6f 80 75 1e 9c |..a=ag.....o.u..| -00000100 70 42 ff 6f 35 83 32 34 fc 12 08 e5 44 92 cb 99 |pB.o5.24....D...| -00000110 a5 d0 ef c3 f2 9e b2 86 ff c1 e5 87 01 bf d1 7a |...............z| -00000120 d9 57 ef 21 cf c9 fd 5f 30 6c 54 7c ac 95 54 72 |.W.!..._0lT|..Tr| -00000130 3d 46 88 4d 9f 8e a8 75 81 a0 81 50 11 1e f7 92 |=F.M...u...P....| -00000140 f5 a2 5d 49 5a f8 c1 b8 06 f3 6f 99 64 77 ee fe |..]IZ.....o.dw..| -00000150 40 fe 94 51 67 db e1 a0 d7 a4 09 cc 52 9c 1b 27 |@..Qg.......R..'| -00000160 5b 45 4a 71 ff 60 aa 52 56 07 f6 4e ad 23 b8 2c |[EJq.`.RV..N.#.,| -00000170 87 d3 2b 04 56 21 ed 51 ce 81 59 ae 3d a7 1b f5 |..+.V!.Q..Y.=...| -00000180 75 3f 8a 83 c3 ee e9 76 94 dd 48 c4 d1 69 2f af |u?.....v..H..i/.| -00000190 b1 f9 2f db 72 ef da 33 6b 87 78 64 24 3a 42 46 |../.r..3k.xd$:BF| -000001a0 e0 ed 91 60 89 dd 5a 9e 9b 93 4a 0e a3 30 32 4d |...`..Z...J..02M| -000001b0 0e 5f c6 49 26 49 18 73 8d 2d 73 d5 4c 49 3f df |._.I&I.s.-s.LI?.| -000001c0 d9 55 b7 11 7e 24 1b d6 cb 71 68 ba 6c c7 72 b2 |.U..~$...qh.l.r.| -000001d0 2e aa 39 89 ac 1b 96 a3 78 11 4d 37 ba 25 88 43 |..9.....x.M7.%.C| -000001e0 d2 8a 55 28 99 b3 f0 59 d5 92 cc 94 51 e2 f2 18 |..U(...Y....Q...| -000001f0 3b d1 1a 9b a6 ee f1 b1 91 62 6b a0 da 75 f6 69 |;........bk..u.i| -00000200 23 56 22 29 dd d0 63 05 be a9 f7 38 fc 0d a2 64 |#V")..c....8...d| -00000210 e4 09 2c d5 5f ca ee 91 81 91 d1 ee 62 04 e9 ce |..,._.......b...| -00000220 5f 49 8e 70 cf fd 5a b5 cf c1 e5 ae 53 3e 16 d0 |_I.p..Z.....S>..| -00000230 f0 49 9b 61 32 14 38 27 b5 c9 93 13 be e4 5a f0 |.I.a2.8'......Z.| -00000240 10 5f 7c 14 11 68 70 4d 6d 02 9f 51 51 94 e0 0e |._|..hpMm..QQ...| -00000250 04 a2 ae 6c 3c f0 94 11 9c 66 58 b3 a2 e8 04 f1 |...l<....fX.....| -00000260 01 b7 88 0d 74 cf 8a 63 f8 e6 c4 bb 10 bb 16 03 |....t..c........| -00000270 03 00 35 7b 36 f4 cf b3 8a 4a 7c 7e fc 7a 6d ae |..5{6....J|~.zm.| -00000280 5e fe 3b c5 e1 16 44 ab 72 0a 07 10 69 e1 11 db |^.;...D.r...i...| -00000290 6d 86 f9 43 d0 87 82 3a 28 83 b4 15 76 76 2a f9 |m..C...:(...vv*.| -000002a0 52 80 7f 2f c2 52 e1 2c 16 03 03 00 98 e8 a2 d5 |R../.R.,........| -000002b0 d6 57 15 7c 33 27 e2 29 d4 82 7b fd 2d c3 00 db |.W.|3'.)..{.-...| -000002c0 83 90 44 4b 3a be 01 4d d7 76 a5 03 cf ec 60 b5 |..DK:..M.v....`.| -000002d0 93 ba 4d 4d 74 30 a3 bb 47 3b a2 94 98 1e e9 b8 |..MMt0..G;......| -000002e0 d2 99 55 05 c7 59 cb e4 55 3e c0 c9 8c 90 40 91 |..U..Y..U>....@.| -000002f0 2e c0 64 f2 6e 09 96 7c b6 0a e0 ad fd a2 7a c4 |..d.n..|......z.| -00000300 b0 e6 0f 40 2a e5 37 fa 72 f3 89 1c 78 47 ca c7 |...@*.7.r...xG..| -00000310 e5 83 7b 1f a6 e5 39 32 c6 94 1e e4 7a 51 d9 36 |..{...92....zQ.6| -00000320 67 d9 b3 78 58 f9 ae 65 60 ee 41 c8 81 8a 04 49 |g..xX..e`.A....I| -00000330 35 2a d8 22 b3 8b 64 49 13 a0 36 e0 37 68 ea b7 |5*."..dI..6.7h..| -00000340 99 9e 1f e1 ea 14 03 03 00 11 b9 18 a2 5e 19 5f |.............^._| -00000350 77 58 6c a3 e9 97 4b 34 5e ff ff 16 03 03 00 20 |wXl...K4^...... | -00000360 71 d4 9f 5a 6f fa e4 28 bb f1 9d e5 0b c3 da 4b |q..Zo..(.......K| -00000370 ef a3 78 28 c5 e3 43 ff f7 5c a1 94 57 0d ee 41 |..x(..C..\..W..A| +00000000 16 03 03 02 69 83 ef 87 6b aa f1 2a cc c1 b8 5d |....i...k..*...]| +00000010 47 e4 2d da c5 91 62 e4 7d 49 da 54 a3 79 fb 1d |G.-...b.}I.T.y..| +00000020 59 49 e8 a6 ab 79 c0 9f 51 f9 d2 63 0d 8c 6b 7f |YI...y..Q..c..k.| +00000030 b6 77 2d f3 b3 3e 78 86 3a 14 1a ab 3b 5e 23 b2 |.w-..>x.:...;^#.| +00000040 d3 5c b1 2b 5c f4 f0 9d e2 87 08 d0 2f 24 30 d3 |.\.+\......./$0.| +00000050 05 eb f8 a6 b2 d1 52 00 c3 9e 0b 82 34 3e fd 5a |......R.....4>.Z| +00000060 46 d5 b6 b2 f0 a0 96 11 e1 35 c2 32 57 d6 dd b2 |F........5.2W...| +00000070 a8 ad b2 71 a2 6f 83 05 d6 f1 83 38 a0 3c 13 ff |...q.o.....8.<..| +00000080 c1 c1 b0 1e b5 40 5b b5 05 31 65 0b 81 a6 b0 37 |.....@[..1e....7| +00000090 7d 16 3b 7b cb e7 58 7f 81 25 e3 39 37 98 87 b0 |}.;{..X..%.97...| +000000a0 e1 8f c0 d5 de 33 fe de 15 37 41 25 d8 97 5d 84 |.....3...7A%..].| +000000b0 28 12 b4 a5 b0 15 f1 f4 cf 41 28 e9 26 5d ba 36 |(........A(.&].6| +000000c0 da b6 a6 cb 21 92 21 30 4b 21 4d 44 28 4d 76 d1 |....!.!0K!MD(Mv.| +000000d0 61 65 fa 02 05 67 50 ec 7d 98 78 21 46 5d fe 75 |ae...gP.}.x!F].u| +000000e0 78 8e 9d 41 6a 0a d7 0e 27 22 d0 a1 21 57 3d 23 |x..Aj...'"..!W=#| +000000f0 d1 7d 08 f4 0b 1b 90 ec 63 74 4c e7 df c8 8f 8b |.}......ctL.....| +00000100 b8 cd 2b 06 a5 35 f5 c1 62 d5 46 f3 d5 19 5b ce |..+..5..b.F...[.| +00000110 c8 d2 f4 c1 51 5f cd b2 51 23 61 bf 93 7f 5d bd |....Q_..Q#a...].| +00000120 61 f2 b2 e0 ad be ab d7 c9 77 26 c2 61 fb 25 8d |a........w&.a.%.| +00000130 46 38 7a 30 48 9f b5 5c 47 6b ce 10 1d 03 d0 68 |F8z0H..\Gk.....h| +00000140 7f 00 c0 94 f4 35 eb 41 e8 91 f6 d9 5c 44 d6 79 |.....5.A....\D.y| +00000150 72 9f 22 a4 08 fd 74 1b 42 dc 49 06 34 8f b6 f5 |r."...t.B.I.4...| +00000160 12 1c 09 f0 d4 eb e4 6e d5 9a 31 f9 1a 88 c1 bf |.......n..1.....| +00000170 37 42 90 5f c8 e1 38 2b 8b 4b c1 cd 66 72 e6 49 |7B._..8+.K..fr.I| +00000180 d3 19 0e 01 19 60 f7 7d d3 66 b2 bf bd 94 30 c9 |.....`.}.f....0.| +00000190 3a 01 aa b6 dc 2a d6 1a 68 cf a6 31 5e 9a 1d 5b |:....*..h..1^..[| +000001a0 90 bb 77 33 31 f2 28 5a 70 a5 c5 ef 91 91 27 22 |..w31.(Zp.....'"| +000001b0 59 33 d5 22 78 8e 8f 07 91 3c 69 ec b9 81 be e8 |Y3."x.........G...NWQ.Y| +00000250 05 84 dc 4d fd fb d1 11 33 b6 e5 5e df 65 d4 ed |...M....3..^.e..| +00000260 04 af 89 b3 f0 90 9b 7c 5e 83 b1 66 71 b1 16 03 |.......|^..fq...| +00000270 03 00 35 5b 37 fa e1 97 11 25 7c fd da 7e e8 2a |..5[7....%|..~.*| +00000280 9b 28 fa 20 a6 9b 9b ca 99 ed a2 eb 5b 84 df a0 |.(. ........[...| +00000290 b9 14 c2 fe 38 a8 54 06 e4 54 38 87 2a 24 8b 1e |....8.T..T8.*$..| +000002a0 3e ba 0a bb c2 1d a4 74 16 03 03 00 98 8b 39 c7 |>......t......9.| +000002b0 ac e5 80 bf 49 95 ad f4 c0 cf c9 7c 86 bf 11 65 |....I......|...e| +000002c0 53 40 f3 64 3e 04 ad c9 8d 33 8a 10 4a f5 2e c5 |S@.d>....3..J...| +000002d0 22 18 59 1c 81 65 8a 51 47 b4 8d b1 94 57 3c f8 |".Y..e.QG....W<.| +000002e0 d0 06 60 ce 04 f9 50 8f 6c 43 d8 6e b0 9e d9 da |..`...P.lC.n....| +000002f0 4b e5 b5 05 b7 1b 4b 46 59 d6 ad 20 bb 4c fc aa |K.....KFY.. .L..| +00000300 9a 9b ef fd 59 4b 2a 63 01 b0 1b 2d ed b1 f4 5b |....YK*c...-...[| +00000310 bb ca cd fa 13 06 06 7e 1d a5 cd c3 ca 4e bf 7b |.......~.....N.{| +00000320 7e 92 92 09 61 35 68 a2 38 f9 13 41 f4 a9 a5 0f |~...a5h.8..A....| +00000330 42 63 e4 15 e8 86 00 48 90 2b 43 30 da 05 b6 fc |Bc.....H.+C0....| +00000340 8e 7f 52 d3 b8 14 03 03 00 11 82 73 be a9 08 9d |..R........s....| +00000350 5b 2f fe bd 1f 2c fb e2 f3 94 f3 16 03 03 00 20 |[/...,......... | +00000360 d0 47 0f 2d 7e ce 8f 01 e2 7d 01 3c 32 79 a0 26 |.G.-~....}.<2y.&| +00000370 fe 00 ce d3 37 46 20 b4 f8 af 21 81 0f 1e ba 2d |....7F ...!....-| >>> Flow 10 (server to client) -00000000 14 03 03 00 11 ed 11 8d d8 09 71 3a d8 53 25 f9 |..........q:.S%.| -00000010 a9 2f 70 b9 21 fb 16 03 03 00 20 14 a7 ba 54 0e |./p.!..... ...T.| -00000020 5c a9 53 ab d4 d6 c0 3f 10 6b 2d 84 8d 66 e5 04 |\.S....?.k-..f..| -00000030 96 f9 a9 18 1d f8 c1 76 49 18 35 17 03 03 00 19 |.......vI.5.....| -00000040 5e b0 d2 83 83 7d 35 ac e5 74 9a 68 b5 d8 4d 32 |^....}5..t.h..M2| -00000050 a1 d0 bf 8d 8f 1a 2f f7 33 |....../.3| +00000000 14 03 03 00 11 53 7f 72 ce 10 f4 0e a3 ed ed 8d |.....S.r........| +00000010 3a ad 2d 57 c8 e1 16 03 03 00 20 11 e9 69 5e ff |:.-W...... ..i^.| +00000020 22 0d f6 a3 e1 e5 3f 14 34 a0 33 d7 d5 0a 7f bc |".....?.4.3.....| +00000030 7c 69 9b 9a d2 aa 41 87 fe da de 17 03 03 00 19 ||i....A.........| +00000040 bd a1 83 5d 27 9f cc 0b 40 02 23 6e 6f 18 4c bc |...]'...@.#no.L.| +00000050 48 c4 02 7d 45 08 71 ac d7 |H..}E.q..| >>> Flow 11 (client to server) -00000000 15 03 03 00 12 3d 6c 11 84 f3 af 5e 9b ee c3 56 |.....=l....^...V| -00000010 96 c1 78 a9 12 31 ba |..x..1.| +00000000 15 03 03 00 12 80 ae fb 45 cb a1 2d 1f c8 b6 02 |........E..-....| +00000010 3a 28 62 d6 13 48 2c |:(b..H,| diff --git a/testdata/Client-TLSv12-RenegotiateTwice b/testdata/Client-TLSv12-RenegotiateTwice index ff6da0a..7ff5876 100644 --- a/testdata/Client-TLSv12-RenegotiateTwice +++ b/testdata/Client-TLSv12-RenegotiateTwice @@ -7,21 +7,21 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 7f 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 0a 00 08 00 1d 00 17 00 18 00 19 00 0b 00 02 01 |................| -000000a0 00 00 0d 00 1a 00 18 08 04 04 03 08 07 08 05 08 |................| -000000b0 06 04 01 05 01 06 01 05 03 06 03 02 01 02 03 ff |................| -000000c0 01 00 01 00 00 17 00 00 00 12 00 00 00 2b 00 09 |.............+..| +00000080 01 00 00 7f 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 19 00 0d |................| +000000b0 00 1a 00 18 08 04 04 03 08 07 08 05 08 06 04 01 |................| +000000c0 05 01 06 01 05 03 06 03 02 01 02 03 00 2b 00 09 |.............+..| 000000d0 08 03 04 03 03 03 02 03 01 00 33 00 26 00 24 00 |..........3.&.$.| 000000e0 1d 00 20 2f e5 7d a3 47 cd 62 43 15 28 da ac 5f |.. /.}.G.bC.(.._| 000000f0 bb 29 07 30 ff f6 84 af c4 cf c2 ed 90 99 5f 58 |.).0.........._X| 00000100 cb 3b 74 |.;t| >>> Flow 2 (server to client) -00000000 16 03 03 00 5d 02 00 00 59 03 03 bc 20 d6 8b 64 |....]...Y... ..d| -00000010 c1 9f de ba 8e c1 6f 37 b8 5c 82 c3 1b 5e 11 3d |......o7.\...^.=| -00000020 ac 5d 16 4b 40 96 d6 ae 29 74 91 20 65 7d d0 51 |.].K@...)t. e}.Q| -00000030 d8 a2 2d c6 db 53 f6 04 16 dd 70 4a bd 44 a4 b6 |..-..S....pJ.D..| -00000040 ef e0 f0 d3 ec 6a 31 18 91 df 09 90 cc a8 00 00 |.....j1.........| +00000000 16 03 03 00 5d 02 00 00 59 03 03 25 9f b0 d0 c5 |....]...Y..%....| +00000010 56 c8 79 6a 1a ff 0e e9 8b 41 b6 be c7 36 0b 58 |V.yj.....A...6.X| +00000020 c0 9e 9d 6c 4c b4 39 1f 95 ff 8f 20 32 27 d2 39 |...lL.9.... 2'.9| +00000030 ac f6 33 f9 48 a4 0b 0f e1 f9 5f 0a 83 7b 75 95 |..3.H....._..{u.| +00000040 23 55 14 ba 55 2f 47 42 e8 df 09 39 cc a8 00 00 |#U..U/GB...9....| 00000050 11 ff 01 00 01 00 00 0b 00 04 03 00 01 02 00 17 |................| 00000060 00 00 16 03 03 02 59 0b 00 02 55 00 02 52 00 02 |......Y...U..R..| 00000070 4f 30 82 02 4b 30 82 01 b4 a0 03 02 01 02 02 09 |O0..K0..........| @@ -61,286 +61,286 @@ 00000290 73 bb b3 43 77 8d 0c 1c f1 0f a1 d8 40 83 61 c9 |s..Cw.......@.a.| 000002a0 4c 72 2b 9d ae db 46 06 06 4d f4 c1 b3 3e c0 d1 |Lr+...F..M...>..| 000002b0 bd 42 d4 db fe 3d 13 60 84 5c 21 d3 3b e9 fa e7 |.B...=.`.\!.;...| -000002c0 16 03 03 00 ac 0c 00 00 a8 03 00 1d 20 71 9d 55 |............ q.U| -000002d0 00 99 f1 f9 90 c2 8f 82 27 d7 5c 0e 96 97 a9 f7 |........'.\.....| -000002e0 be ab c4 76 41 9b 86 86 43 d7 43 78 0c 08 04 00 |...vA...C.Cx....| -000002f0 80 96 cb 93 b2 0c 1e e3 92 b1 4e 28 30 48 85 09 |..........N(0H..| -00000300 c1 cf 73 66 7b 3b 3d 7d 83 c2 a3 2a 93 14 58 c0 |..sf{;=}...*..X.| -00000310 1c 6c 7c 92 9c 3f 8b 80 d1 c4 54 d8 2b 65 38 35 |.l|..?....T.+e85| -00000320 08 a6 d2 ec 4e 84 e7 49 78 13 3f 2a 41 60 1d ea |....N..Ix.?*A`..| -00000330 09 c8 30 37 35 88 b3 eb 5c ad 16 46 19 5f f1 62 |..075...\..F._.b| -00000340 8b 49 8a 9a 47 87 a4 14 d3 17 e1 d5 79 0e 9f c4 |.I..G.......y...| -00000350 4e db 6f 38 8e 77 ec 37 74 e8 20 01 54 75 e1 8e |N.o8.w.7t. .Tu..| -00000360 5c d1 19 51 d8 c8 89 6c 27 01 54 ca 18 dd d9 2e |\..Q...l'.T.....| -00000370 8f 16 03 03 00 04 0e 00 00 00 |..........| +000002c0 16 03 03 00 ac 0c 00 00 a8 03 00 1d 20 2b 66 1d |............ +f.| +000002d0 80 f2 60 32 0f af 6f d3 03 db 28 c1 33 18 1c 5d |..`2..o...(.3..]| +000002e0 71 fd 2a 24 f9 3c 4d 76 ca e3 93 8d 25 08 04 00 |q.*$.>> Flow 3 (client to server) 00000000 16 03 03 00 25 10 00 00 21 20 2f e5 7d a3 47 cd |....%...! /.}.G.| 00000010 62 43 15 28 da ac 5f bb 29 07 30 ff f6 84 af c4 |bC.(.._.).0.....| 00000020 cf c2 ed 90 99 5f 58 cb 3b 74 14 03 03 00 01 01 |....._X.;t......| -00000030 16 03 03 00 20 46 e6 c1 9e c0 cc 46 24 6e 0c 6c |.... F.....F$n.l| -00000040 1b c5 7d b4 dc a1 b5 d4 bf db 32 69 12 8a 89 ea |..}.......2i....| -00000050 c1 bf 26 b8 ee |..&..| +00000030 16 03 03 00 20 7b de 6f c8 b7 f1 69 89 0b 29 af |.... {.o...i..).| +00000040 62 1b 92 47 e9 44 f7 26 91 93 9c 3b e2 77 0e d0 |b..G.D.&...;.w..| +00000050 c5 af fd e5 59 |....Y| >>> Flow 4 (server to client) -00000000 14 03 03 00 01 01 16 03 03 00 20 08 9b ed a2 75 |.......... ....u| -00000010 a9 2d 92 f7 dc e1 93 7a 3d c3 75 33 a8 43 17 2b |.-.....z=.u3.C.+| -00000020 50 71 58 d7 40 2a ea 1b 0a 3b 0b |PqX.@*...;.| +00000000 14 03 03 00 01 01 16 03 03 00 20 94 da e2 2e f3 |.......... .....| +00000010 65 59 31 4f 58 42 57 b5 1f e6 c1 5a c6 07 97 12 |eY1OXBW....Z....| +00000020 f6 6c 20 cc 91 50 76 42 70 dd 2c |.l ..PvBp.,| >>> Flow 5 (client to server) -00000000 17 03 03 00 16 7e a3 48 7f 20 07 19 31 8b d2 18 |.....~.H. ..1...| -00000010 81 1d 4a a1 db 72 4a 88 2d ee 18 |..J..rJ.-..| +00000000 17 03 03 00 16 fe 0d 78 61 f9 fe 65 3c 42 c0 98 |.......xa..e>> Flow 6 (server to client) -00000000 16 03 03 00 14 b4 c3 67 a8 fc 66 ad 48 f9 3f 6b |.......g..f.H.?k| -00000010 97 4b 55 f8 4d 92 a1 2e d8 |.KU.M....| +00000000 16 03 03 00 14 e0 bb 6e cc 69 fc a7 02 46 c4 5e |.......n.i...F.^| +00000010 a5 b1 1e ce e9 c7 7a d9 76 |......z.v| >>> Flow 7 (client to server) -00000000 16 03 03 01 1a 57 92 7f 92 07 a2 88 ca ea e3 5d |.....W.........]| -00000010 38 79 fd 42 41 5b 73 e5 52 34 c3 f5 10 67 3d 0b |8y.BA[s.R4...g=.| -00000020 42 58 50 d7 f1 da 6b a6 4f 6a 89 2b f7 3c 4d a0 |BXP...k.Oj.+.......| -00000050 48 06 3b 1e df 97 26 e9 59 34 59 c8 e3 05 0b 22 |H.;...&.Y4Y...."| -00000060 d1 66 0e 42 ac e0 4a e1 89 c3 80 ae ee 32 65 93 |.f.B..J......2e.| -00000070 09 6b 1f bc 03 4d 0d 85 bc e8 46 12 09 0b 0c 44 |.k...M....F....D| -00000080 20 a0 26 12 70 80 45 9c ba c2 9d 6a 7a ec bb 92 | .&.p.E....jz...| -00000090 c5 b3 49 2e 18 99 e8 19 a8 37 9d e2 28 c8 69 19 |..I......7..(.i.| -000000a0 ed 12 a6 f2 e7 84 a3 7f 7e 49 74 34 67 66 1f fc |........~It4gf..| -000000b0 02 58 0d 8e 6c ec 1c 14 8c 2a 74 b8 f2 b1 8e 6a |.X..l....*t....j| -000000c0 5f 4d 76 13 d6 7f cf c3 2d 85 18 9b 04 87 d9 9a |_Mv.....-.......| -000000d0 db 8f 09 ce 3f 47 55 fc e9 bf 6c cb 42 bf d4 c4 |....?GU...l.B...| -000000e0 76 91 3e d6 d8 32 4e fe 24 39 1b 66 38 83 32 7f |v.>..2N.$9.f8.2.| -000000f0 ee 84 d3 13 39 73 bb 41 a2 d4 ef a7 1c aa cb e3 |....9s.A........| -00000100 c2 25 6a a3 f2 fb 6f 94 eb 9d 08 1b 4e 6b 09 8a |.%j...o.....Nk..| -00000110 00 0a e3 1b e1 57 7b 58 14 d1 0a 1d 11 7a e0 |.....W{X.....z.| +00000000 16 03 03 01 1a a7 03 1c ef 27 0a 04 9b 31 b0 c6 |.........'...1..| +00000010 17 00 1f 6c d5 91 ae 7c 77 87 98 05 67 9a ea ea |...l...|w...g...| +00000020 6c 79 28 da 2c 91 6d a0 c6 9a e9 f3 85 a0 7f 7d |ly(.,.m........}| +00000030 ae 89 ac 0d 01 7f d8 34 dd fb ba c3 d8 ba ff 9b |.......4........| +00000040 75 dc d6 5e 8a fa ad 9c ea fa 15 63 55 85 98 26 |u..^.......cU..&| +00000050 65 7a 19 17 c4 99 98 85 83 c4 06 39 30 d5 63 51 |ez.........90.cQ| +00000060 ff 22 e8 cd 55 6e fc 88 5e d5 54 24 79 52 7e b0 |."..Un..^.T$yR~.| +00000070 71 e4 e6 cb a6 06 24 14 1a c2 a8 52 85 e9 fc e4 |q.....$....R....| +00000080 66 47 9c 9c d1 f3 56 11 47 16 4b 7c a5 f1 81 1e |fG....V.G.K|....| +00000090 00 78 98 8f 70 ae 47 6d 45 3b c4 af fc 88 bd 88 |.x..p.GmE;......| +000000a0 7b cc 8a 78 86 ff 86 25 2d 21 28 f2 c5 d7 4b 61 |{..x...%-!(...Ka| +000000b0 c0 ea 67 38 4c d0 d6 6f fc a0 69 62 98 6f ac 29 |..g8L..o..ib.o.)| +000000c0 29 13 34 7a f0 2d 1b 7e 52 42 6f f1 64 ed 7f 47 |).4z.-.~RBo.d..G| +000000d0 69 82 9b 9d 19 7b 3a c5 54 51 c8 8f 4c 9e 42 a7 |i....{:.TQ..L.B.| +000000e0 0f 9e 05 1d 4f 85 11 05 97 42 fa 24 37 1c 4e ec |....O....B.$7.N.| +000000f0 55 dc e1 4e f6 e2 dd c6 63 b0 dd 60 11 93 23 8a |U..N....c..`..#.| +00000100 eb 68 76 21 ec 19 cf 59 c8 78 80 f0 fa 39 6a 09 |.hv!...Y.x...9j.| +00000110 f8 7f 9d c0 e7 51 3d 75 17 e3 cf a5 bf 1c 10 |.....Q=u.......| >>> Flow 8 (server to client) -00000000 16 03 03 00 85 f1 26 e0 cc 3f 3d a3 e6 57 21 a0 |......&..?=..W!.| -00000010 25 c6 fd 11 f5 92 2e 73 21 32 2b 07 76 73 2b e3 |%......s!2+.vs+.| -00000020 0a 45 1e 01 c8 28 01 1b ba 23 d8 4e 7c 9f 2b 2e |.E...(...#.N|.+.| -00000030 5a ef df 4f 0d 77 76 27 8b 1e df 94 a4 90 1e cb |Z..O.wv'........| -00000040 5a 19 6b f0 c6 85 71 7b 6b cd 59 e1 32 a5 a5 18 |Z.k...q{k.Y.2...| -00000050 01 25 13 84 09 e5 30 6a d3 f2 80 07 1d 48 9b 72 |.%....0j.....H.r| -00000060 d2 6e 76 e3 de 85 0b 9d ec 5f e3 48 02 61 6c b1 |.nv......_.H.al.| -00000070 1a 1b 89 7e 44 f8 af fd a9 42 63 3e f6 3c f6 22 |...~D....Bc>.<."| -00000080 ff 45 b4 f2 ec 31 65 58 8c 06 16 03 03 02 69 50 |.E...1eX......iP| -00000090 e3 4b 21 fd f3 73 28 b1 b2 dc f4 46 d3 37 c1 c9 |.K!..s(....F.7..| -000000a0 15 9c 83 a0 4d b5 6e c1 8c 97 26 05 20 4d cf 92 |....M.n...&. M..| -000000b0 9a e4 e6 ff c2 d1 d4 c9 28 ca 08 00 ed ba 2a e1 |........(.....*.| -000000c0 d2 71 62 4a 1a ca 7d db 19 86 81 a1 4b c4 f7 19 |.qbJ..}.....K...| -000000d0 d2 b1 99 4a 82 39 e5 d2 90 59 ca 19 a5 1c 07 1c |...J.9...Y......| -000000e0 c1 44 d5 f3 a4 e5 33 ce 98 fc 24 e9 65 04 b9 08 |.D....3...$.e...| -000000f0 2f f7 d6 87 91 33 64 8c 9e e9 50 35 28 76 3d 77 |/....3d...P5(v=w| -00000100 b2 84 16 23 a1 6f d1 92 da 37 28 88 63 51 db 55 |...#.o...7(.cQ.U| -00000110 5d d4 29 ab 64 e8 dd 1f ef 06 31 78 ab f1 11 82 |].).d.....1x....| -00000120 76 35 17 66 87 62 bc 9e 18 be 35 96 4d 5c 2d c6 |v5.f.b....5.M\-.| -00000130 84 13 08 00 ec f9 bd b8 24 88 f5 2a 2b 11 0b ec |........$..*+...| -00000140 55 a2 f3 c7 b4 7d cf 56 90 1f d9 c0 4a 0e 8c 8c |U....}.V....J...| -00000150 d4 72 60 18 f6 eb 6a ae 83 35 bf d2 4f 0e f3 06 |.r`...j..5..O...| -00000160 73 3f e1 3a 03 1f 51 02 2f dc e1 f8 87 95 8a 13 |s?.:..Q./.......| -00000170 d3 89 ac af 36 c8 1d 19 08 61 97 c9 e3 0a b9 1a |....6....a......| -00000180 12 6e f1 fd d5 e3 78 bc 34 b7 6b 1d b4 48 3e d5 |.n....x.4.k..H>.| -00000190 61 99 04 e5 74 ca 53 66 65 21 c2 2c fb e6 12 3d |a...t.Sfe!.,...=| -000001a0 5e 48 ac b9 ef d8 a3 75 32 85 eb 6f 88 84 b6 2f |^H.....u2..o.../| -000001b0 d4 67 e7 25 26 80 c0 39 73 97 fb e5 8d ed 65 7e |.g.%&..9s.....e~| -000001c0 a4 35 4e b7 e3 92 72 23 80 c2 f5 db b4 02 26 33 |.5N...r#......&3| -000001d0 ff 46 3e 0d e6 e0 02 b1 65 e0 3f 8e 7d fd 12 73 |.F>.....e.?.}..s| -000001e0 62 20 6a fc 00 2b 19 cb 17 c7 de 14 05 4b b5 f6 |b j..+.......K..| -000001f0 49 78 92 f4 84 1d 94 1b b1 23 67 5e b2 ae 75 4e |Ix.......#g^..uN| -00000200 f3 52 72 af fb 2e 12 7c cc 6b b6 f3 3a 8a e4 ae |.Rr....|.k..:...| -00000210 03 db ed 20 b1 e5 a9 7b 0d df ae 75 c9 71 42 c4 |... ...{...u.qB.| -00000220 e5 c9 a7 ac c8 f4 a5 e6 84 05 a0 be ca d8 d0 d1 |................| -00000230 30 a0 84 42 82 df ba ba d7 11 a5 f9 93 fd 8e 91 |0..B............| -00000240 89 2e 2f b2 98 05 06 dc 2c a4 2a 6f f4 0f 9d 1d |../.....,.*o....| -00000250 16 2f d8 b9 06 02 43 92 cc 96 bc 6a a4 93 86 ef |./....C....j....| -00000260 43 11 ec b7 4e 39 9f 1f 75 71 76 1a 7b 1d 2e 68 |C...N9..uqv.{..h| -00000270 ad 36 c7 ae 3a 7a 70 10 46 4e 76 9b f5 8c 1d b7 |.6..:zp.FNv.....| -00000280 5d 62 86 70 1c 27 84 ae 8a 05 65 a2 01 bf 3b 0f |]b.p.'....e...;.| -00000290 d3 43 74 9d a0 ed 7f e4 63 dc b9 e6 7b d6 c1 2d |.Ct.....c...{..-| -000002a0 96 ae 51 6e 07 47 8b f8 f7 e2 71 19 3a df 7d cb |..Qn.G....q.:.}.| -000002b0 ef 82 2a 11 fd 9c e9 24 9d b0 9e e4 1f f2 4e 8b |..*....$......N.| -000002c0 17 02 4a 27 33 85 61 d3 55 6d 82 77 ce 55 d3 be |..J'3.a.Um.w.U..| -000002d0 94 9f 6d 1d f0 16 1d 19 bd 1f ac 77 e7 13 32 94 |..m........w..2.| -000002e0 86 8c c8 c9 33 f0 b0 47 cf 9c 7c ef 97 c3 37 25 |....3..G..|...7%| -000002f0 bf a7 09 82 35 ff 9f 79 16 03 03 00 bc 8c 34 16 |....5..y......4.| -00000300 37 9c cb db aa dc 23 ba 07 28 88 be 6f f0 cc 42 |7.....#..(..o..B| -00000310 22 31 2c fc a4 ce d8 bf 58 54 a7 62 6b 54 8b b1 |"1,.....XT.bkT..| -00000320 0b 44 29 a9 64 2f af ee f1 7b 79 1c 26 02 a3 bd |.D).d/...{y.&...| -00000330 e5 dd 60 89 ef e9 31 bc 5d 17 fc a9 05 77 38 00 |..`...1.]....w8.| -00000340 e8 d9 8c b3 c6 7d fb a0 f8 d1 87 2a c6 74 d6 2c |.....}.....*.t.,| -00000350 39 c8 3c d8 0d 0d a6 e2 ea 6b 88 9d 7d ee cc 4e |9.<......k..}..N| -00000360 69 2a ac 41 7e ac b8 fe b4 8f 43 ef 2d a7 45 78 |i*.A~.....C.-.Ex| -00000370 bf 29 72 b5 4b cf bb aa 1a 64 3c dd 38 07 ab 60 |.)r.K....d<.8..`| -00000380 b3 ee e3 0b 40 a1 72 4d 61 1a ba d8 24 a7 46 3f |....@.rMa...$.F?| -00000390 77 c9 bd 11 37 d7 ae c9 92 d8 78 a5 13 f8 2c 2f |w...7.....x...,/| -000003a0 10 50 7c e5 16 2c 56 e7 a6 10 cb fc 62 a2 6f 83 |.P|..,V.....b.o.| -000003b0 30 74 d3 94 23 78 c8 6d 28 16 03 03 00 4a 76 dc |0t..#x.m(....Jv.| -000003c0 db 13 a2 52 07 65 62 35 36 56 42 95 1d 34 8f 2a |...R.eb56VB..4.*| -000003d0 cd 5e 63 aa 56 70 ac 16 76 7b 7d b6 3f a4 57 6b |.^c.Vp..v{}.?.Wk| -000003e0 f1 9e 6a a7 ca e5 cb b0 44 5e 8b 6a ea 78 45 ad |..j.....D^.j.xE.| -000003f0 0c 9d 44 8c 1f 03 27 9b 90 2e 9e fc 50 44 1f 4d |..D...'.....PD.M| -00000400 f3 ac 1f 2f 6d ed 49 29 16 03 03 00 14 ba 05 de |.../m.I)........| -00000410 4f 96 62 af d1 e0 a6 64 0d f3 ee 50 ca 1f d1 50 |O.b....d...P...P| -00000420 bb |.| +00000000 16 03 03 00 85 14 4e 8e de d0 5b 59 2d f6 a3 b0 |......N...[Y-...| +00000010 c0 ff 4a ff 8b cf af 2f 09 f1 ee 03 0f b9 70 5e |..J..../......p^| +00000020 1b e4 ef b4 3e e7 c1 43 fb ea a8 68 4c 66 0a 55 |....>..C...hLf.U| +00000030 e8 51 a6 30 bb e3 f5 0e df 11 f2 e0 51 94 14 f6 |.Q.0........Q...| +00000040 1e c6 e8 9d 10 a2 20 9f f2 f6 1e f0 3c f3 ba ff |...... .....<...| +00000050 65 d1 f4 df 9e e6 18 9f a1 a5 9c 5f 4b 4f 20 98 |e.........._KO .| +00000060 4a f6 0b 95 da 01 1f ea c0 c4 39 39 8b fd 19 40 |J.........99...@| +00000070 8d 14 da 45 fd 51 3d a7 36 23 a0 b2 bb cb 81 6b |...E.Q=.6#.....k| +00000080 79 0a 02 71 50 84 ac d6 7b ad 16 03 03 02 69 b8 |y..qP...{.....i.| +00000090 a9 6c 87 d7 23 6b c6 1a 4c 08 dd fa 58 e8 e8 d5 |.l..#k..L...X...| +000000a0 44 16 3b de 77 60 33 2a 47 a5 3c e0 cb c3 1a 38 |D.;.w`3*G.<....8| +000000b0 1d 1f 69 8e 33 a3 ba ac 55 b5 77 9b e1 fc a4 21 |..i.3...U.w....!| +000000c0 99 90 01 5e 99 36 a3 cf 74 b4 1f 96 b7 96 1e 4b |...^.6..t......K| +000000d0 cf 0b 92 5f 6b 1f 1c b0 70 80 2e 87 57 ef 52 b0 |..._k...p...W.R.| +000000e0 2b 7d 66 06 cb a1 78 a7 5a e2 af 4c fc a4 8b 99 |+}f...x.Z..L....| +000000f0 af 6c 6d 0e 07 7e da 11 5a b7 89 af 3c ce 1e 22 |.lm..~..Z...<.."| +00000100 1f 7d 97 d5 d4 78 09 c4 e7 fb 33 bf 36 ee 6e 5a |.}...x....3.6.nZ| +00000110 af f0 5b 0f 00 eb cc 3d 76 35 41 98 4c 65 81 34 |..[....=v5A.Le.4| +00000120 74 d9 d7 ba 04 fc c8 c6 c9 ca 4b b0 8e b1 7e 87 |t.........K...~.| +00000130 9d 69 2e d5 68 54 96 48 37 42 ae ff 18 d0 08 b2 |.i..hT.H7B......| +00000140 dc 26 1c c1 99 f1 c3 02 3f 48 51 a8 92 10 18 01 |.&......?HQ.....| +00000150 f3 3b 96 4b de 80 29 27 87 da f4 89 23 1b 49 b8 |.;.K..)'....#.I.| +00000160 5b f5 50 ec 99 b0 c3 48 e2 d3 fe fb a0 95 c3 c6 |[.P....H........| +00000170 83 fe d9 87 ef 0c cf 67 8f e7 52 3d 17 7d c0 ab |.......g..R=.}..| +00000180 02 1a 33 78 c8 d6 13 8b 8e 82 be 0d 5e d4 22 e8 |..3x........^.".| +00000190 63 c3 84 a9 05 12 d3 b7 e2 36 96 a2 22 0a 77 df |c........6..".w.| +000001a0 20 06 5c 0d 8b c1 d6 ac 73 b0 b2 a0 be db 59 17 | .\.....s.....Y.| +000001b0 05 60 68 b9 18 85 d5 73 9b c9 41 b9 c1 f2 02 47 |.`h....s..A....G| +000001c0 ca 95 c8 47 e2 de 04 75 08 d4 b7 a2 41 d7 e2 6b |...G...u....A..k| +000001d0 ad 8c ba c5 fc f8 b1 fe d3 23 c0 22 ec d0 2f a7 |.........#."../.| +000001e0 d9 ed 0e da 71 18 c0 d0 1f 40 8d eb 79 ea 5f aa |....q....@..y._.| +000001f0 07 4f 65 81 c1 9e ea 36 7f 0d 8b 07 8b 71 81 5a |.Oe....6.....q.Z| +00000200 0e cb d4 0f 98 c8 5c 69 d0 61 6e b5 ef 2a dd 5f |......\i.an..*._| +00000210 63 92 b4 3e 6e f4 b8 fc 45 bf 58 79 08 a4 95 6f |c..>n...E.Xy...o| +00000220 34 01 9b 8a 19 a5 e4 11 3f d4 97 47 66 e8 42 ef |4.......?..Gf.B.| +00000230 92 72 01 f4 6f 07 a4 35 81 83 ee 26 d0 96 cc de |.r..o..5...&....| +00000240 42 2a 65 64 cc a9 0c 39 31 d5 7c 2f 42 e5 ce 36 |B*ed...91.|/B..6| +00000250 0b bf b5 22 2a 4f 3c 56 27 29 cd fb 8e 9f 8f ab |..."*O>> Flow 9 (client to server) -00000000 16 03 03 02 69 54 06 eb 58 fb 0c cd 83 50 78 6d |....iT..X....Pxm| -00000010 e1 63 b0 24 eb 11 2b b3 76 77 c9 7b e4 ad c8 a9 |.c.$..+.vw.{....| -00000020 71 73 68 a2 89 ba bc fd 0d d4 cc 7b 33 0a 11 c6 |qsh........{3...| -00000030 a0 56 0f b4 86 e6 e5 31 85 2d 98 1b f0 28 67 2b |.V.....1.-...(g+| -00000040 d2 c8 9a 32 83 c1 50 10 16 08 70 72 fb 80 c7 a4 |...2..P...pr....| -00000050 fa 95 88 bc 7c 45 67 1d 43 24 7b 56 9a 09 b6 38 |....|Eg.C${V...8| -00000060 e2 4c 25 93 7a 02 f8 c4 f2 52 7e e4 8e 99 ad 9c |.L%.z....R~.....| -00000070 1d 8f 54 a5 67 d1 27 5d c7 d0 76 47 a8 7f 54 79 |..T.g.']..vG..Ty| -00000080 4c f2 98 bc 8c 3c 78 9b 6e c1 8b 2c 09 40 77 a9 |L....s| -00000100 d5 cd e8 4e 1b a2 4a 52 38 43 6a b1 fc 85 98 7e |...N..JR8Cj....~| -00000110 db 7d 0a 9c d9 bc 6e 7b 19 ce 3c 49 2f 8a d1 6d |.}....n{...| -000001d0 3a 52 24 2f 0a 33 c1 3b 34 74 ef 06 c5 5e 14 fb |:R$/.3.;4t...^..| -000001e0 b8 30 a3 80 2e c4 11 f3 a2 4c 03 65 60 c0 b0 0c |.0.......L.e`...| -000001f0 aa cd e8 2e f1 d8 f2 5a 4b 48 c0 5b 47 57 1d 9a |.......ZKH.[GW..| -00000200 a0 cc 9e dd 6f 22 7c 8b f8 e3 21 2c fc 87 6e b0 |....o"|...!,..n.| -00000210 cd bf 90 e4 05 f7 93 af 4a f0 73 73 4e af 70 ce |........J.ssN.p.| -00000220 8d 96 e3 b0 bc e8 3e e2 92 09 a4 74 52 1c 7c 55 |......>....tR.|U| -00000230 5c 5c 64 07 05 9d f5 54 0f ff 1b 02 0c c4 22 94 |\\d....T......".| -00000240 aa 7b 43 e0 9d 67 25 23 da 8b 03 26 02 1b 22 92 |.{C..g%#...&..".| -00000250 ff f8 f6 be 40 54 c2 9b 18 af 53 63 70 76 7c ce |....@T....Scpv|.| -00000260 d4 e7 b6 f6 89 43 ec 11 af b3 05 ee de ad 16 03 |.....C..........| -00000270 03 00 35 72 0c 52 b0 32 0a 1f fc 27 13 34 67 25 |..5r.R.2...'.4g%| -00000280 a8 39 89 9e 6c ea 6f 25 72 f7 40 63 b2 c9 e2 e0 |.9..l.o%r.@c....| -00000290 d4 eb 44 ad ae d0 58 1e 54 9c db 31 ba 03 44 9d |..D...X.T..1..D.| -000002a0 95 f5 f3 bb ef d6 4d f5 16 03 03 00 98 d6 86 68 |......M........h| -000002b0 3d 68 f6 6d 2d cf 30 e8 32 2d 8e 1e b9 67 a1 8d |=h.m-.0.2-...g..| -000002c0 91 ae 10 8a d6 ce 3c f0 98 01 6a 96 c1 41 cc d4 |......<...j..A..| -000002d0 b1 dc 49 25 be 0f 5b 59 6d f2 12 4d 49 92 e7 2d |..I%..[Ym..MI..-| -000002e0 3d 59 53 38 ff ca 2c 52 ea 30 1c 55 9d 7c 7c 3b |=YS8..,R.0.U.||;| -000002f0 2b 4f 53 0d d7 0f 50 1e ac f9 97 de cb 46 f9 74 |+OS...P......F.t| -00000300 78 ac 4b 82 e4 25 10 63 04 5c 64 c1 d6 e3 4b c1 |x.K..%.c.\d...K.| -00000310 5a 41 02 79 06 bd 75 6f 54 8e a4 a8 6d 7d 30 98 |ZA.y..uoT...m}0.| -00000320 3f 65 fb 6c dd 59 39 e5 8e a4 08 96 62 70 12 2f |?e.l.Y9.....bp./| -00000330 c5 94 3a 1b 2a 99 cc da fb d3 85 19 5b 10 3c d9 |..:.*.......[.<.| -00000340 b4 f9 e8 df c8 14 03 03 00 11 c3 3f 56 55 75 1b |...........?VUu.| -00000350 90 77 ff 04 f4 24 0d 0b 04 ac 2b 16 03 03 00 20 |.w...$....+.... | -00000360 63 1a 0b 3e 2b 0b f0 d7 11 11 03 b0 0d f8 0c ce |c..>+...........| -00000370 25 c6 b4 0d ee 5c 95 40 9a 86 29 1d ee 06 29 88 |%....\.@..)...).| +00000000 16 03 03 02 69 8a dc ce d1 c0 85 30 95 6c da 57 |....i......0.l.W| +00000010 23 05 39 c1 4c 20 08 25 a2 96 f1 55 a1 77 3b 42 |#.9.L .%...U.w;B| +00000020 9f 3d 69 9b 56 49 b4 94 8a 3c d5 85 43 f1 b4 4b |.=i.VI...<..C..K| +00000030 cd e0 67 95 83 34 90 89 81 f0 18 87 28 c0 42 88 |..g..4......(.B.| +00000040 b0 1c d1 cc 0a f0 bb 67 91 55 0b e4 ed 22 52 09 |.......g.U..."R.| +00000050 92 0b 56 ac d0 3f c9 41 05 8a 19 7d e7 9a d7 ff |..V..?.A...}....| +00000060 fa 85 f5 23 b0 98 a0 79 b1 8e 0f 90 0e c8 32 92 |...#...y......2.| +00000070 4b 6a 37 47 45 31 70 be 8b cd 7a 26 3a 3c 0b 63 |Kj7GE1p...z&:<.c| +00000080 a7 8c 00 2c 1d be eb 5c 1f 16 90 76 2b d7 82 5e |...,...\...v+..^| +00000090 31 93 40 7a e0 9a e0 4c 7d 2e e3 84 0f cb 06 7d |1.@z...L}......}| +000000a0 8d 76 41 ea 27 52 4a 77 e5 91 02 ab 11 cc 8c f0 |.vA.'RJw........| +000000b0 fe 8e ee b2 f1 ba 1e ab 0d 5c e2 2d da d5 8d f9 |.........\.-....| +000000c0 7c 22 32 e9 50 1d 88 db af c0 82 51 e0 31 14 71 ||"2.P......Q.1.q| +000000d0 ad c9 05 5d 8e 2b 75 4b 9e 74 b0 3a a9 e4 7c 82 |...].+uK.t.:..|.| +000000e0 ac 75 39 31 0a dc dc 0a 5c f4 ee 55 f2 09 c2 d2 |.u91....\..U....| +000000f0 81 c8 70 2e 8f 37 6b 90 79 5c 18 6e 38 21 c6 00 |..p..7k.y\.n8!..| +00000100 08 be ad 21 e9 40 b6 54 06 f0 61 f9 2c 71 25 0e |...!.@.T..a.,q%.| +00000110 13 6c 66 ef b6 a9 61 d0 d0 42 56 58 32 3c 9c 5a |.lf...a..BVX2<.Z| +00000120 ee 13 1d 42 8b 94 41 9c d1 2e c9 ac d4 ed 0f 04 |...B..A.........| +00000130 1c 6f 5c 30 80 12 37 c6 43 07 7e 03 50 86 24 84 |.o\0..7.C.~.P.$.| +00000140 34 2a 70 82 65 67 35 cd 5e 7c 0e 49 30 35 d4 ee |4*p.eg5.^|.I05..| +00000150 43 b7 7a c3 88 30 e5 ba 98 7f 8d 9e 08 a2 8c bb |C.z..0..........| +00000160 48 44 c2 1a 8d 7b 41 de b6 68 ae d2 8a 64 9b 6b |HD...{A..h...d.k| +00000170 8a 47 88 04 49 05 8a 94 66 da d3 90 78 6d 81 64 |.G..I...f...xm.d| +00000180 4e 6b a5 6f d2 9d 1d 36 6f a2 a3 83 0c f5 69 10 |Nk.o...6o.....i.| +00000190 37 c8 b8 59 c7 b1 5b 91 fc e3 26 37 da 14 80 8f |7..Y..[...&7....| +000001a0 d4 1e 63 51 1d 77 85 67 af 7a 7d e4 5a 27 f9 3f |..cQ.w.g.z}.Z'.?| +000001b0 75 b0 9e 2a 1d 42 29 ac d4 29 c6 0d 2f ee 35 38 |u..*.B)..)../.58| +000001c0 38 91 a4 f1 60 1b d6 49 b2 eb c4 df b6 01 99 69 |8...`..I.......i| +000001d0 06 7c ca 2d aa 15 e8 c5 4f 48 5f 77 87 4b fd 41 |.|.-....OH_w.K.A| +000001e0 cf aa 7d 96 b9 12 ee b7 b3 a2 86 5e 4f 79 08 a1 |..}........^Oy..| +000001f0 00 43 12 93 92 99 07 44 23 48 78 46 c8 fc 4a 96 |.C.....D#HxF..J.| +00000200 88 72 45 2a f4 ff 92 41 7b e5 a0 74 93 ff b8 f6 |.rE*...A{..t....| +00000210 3e e0 6a 3b 3b 12 68 50 89 d1 d3 22 e0 a1 3f ef |>.j;;.hP..."..?.| +00000220 da 18 15 5b c2 48 0e 78 d0 af ae d7 81 af 23 16 |...[.H.x......#.| +00000230 ab 71 07 9d 26 b2 8b 34 7e b2 1a 1e f4 fb 02 9a |.q..&..4~.......| +00000240 f4 15 78 a9 d2 19 94 bb 9f b0 ba 2a 21 20 dd 87 |..x........*! ..| +00000250 57 73 e7 01 08 bc 38 ce 2d 9e dc 3f f7 c4 75 aa |Ws....8.-..?..u.| +00000260 00 9d 28 43 e5 de aa 82 fb e5 ca 87 4e 6c 16 03 |..(C........Nl..| +00000270 03 00 35 e0 37 f9 95 cd 96 f9 ba 36 12 6b 35 c5 |..5.7......6.k5.| +00000280 02 9d 71 8a e5 07 d6 1c 77 6a 86 17 d0 01 9b 79 |..q.....wj.....y| +00000290 74 6b 14 27 33 2f 6d c2 af cb dd 47 71 b3 73 4d |tk.'3/m....Gq.sM| +000002a0 7f 42 3e 7f 86 6e 63 ed 16 03 03 00 98 7f ba 78 |.B>..nc........x| +000002b0 bf a3 d4 02 cb 19 0d 1f 48 bf 4d 9f d0 37 3a c9 |........H.M..7:.| +000002c0 c1 76 6e fb 9a 69 63 0a a1 76 13 2d ea 52 38 18 |.vn..ic..v.-.R8.| +000002d0 71 89 9a f5 02 2e 44 94 72 6d 08 e1 89 9a e1 4c |q.....D.rm.....L| +000002e0 ee 2f 15 9c 0d b6 67 1e 0c 17 b0 e9 03 7d 66 1c |./....g......}f.| +000002f0 28 6b 57 6d c8 49 5d ef ca 4c 51 59 ae 17 55 97 |(kWm.I]..LQY..U.| +00000300 54 f1 f5 64 19 ec 36 27 96 33 0e fd 65 42 ac 50 |T..d..6'.3..eB.P| +00000310 bb cf f9 da fe 98 3d 83 79 a0 24 0d 9f 91 5c b0 |......=.y.$...\.| +00000320 5c c5 04 b4 90 53 c3 8b b5 29 c5 73 7f 04 c6 55 |\....S...).s...U| +00000330 93 4a 08 67 8f f7 a8 ba a8 e2 62 09 85 d3 47 b9 |.J.g......b...G.| +00000340 27 bd 6c 81 95 14 03 03 00 11 88 9b 21 1e 06 0a |'.l.........!...| +00000350 fa 8a 9e 4e d9 7a b3 a5 45 7a 96 16 03 03 00 20 |...N.z..Ez..... | +00000360 6f a0 f0 cf 0b 2b c2 d1 36 d8 64 2b 72 86 7b ab |o....+..6.d+r.{.| +00000370 c7 86 5d c3 67 ec d6 c0 32 4d b8 1f fa d9 3a af |..].g...2M....:.| >>> Flow 10 (server to client) -00000000 14 03 03 00 11 5e 2d 5e 29 92 98 7e cd a8 00 b6 |.....^-^)..~....| -00000010 08 53 39 b6 a2 d1 16 03 03 00 20 6e 0e 3e 92 3a |.S9....... n.>.:| -00000020 b5 a6 ec 3e f2 38 3e 78 86 77 3e 50 9d 29 de bc |...>.8>x.w>P.)..| -00000030 07 e7 d3 eb 20 ee a7 e9 5e 4c f6 17 03 03 00 19 |.... ...^L......| -00000040 06 47 a1 60 72 a7 0d 81 84 86 5e 80 a7 73 7e d9 |.G.`r.....^..s~.| -00000050 db f7 d6 97 f7 9c 12 66 b3 16 03 03 00 14 2b 6d |.......f......+m| -00000060 1a cb 48 9f a3 84 45 a6 d7 c9 ed 4f 15 44 ec c8 |..H...E....O.D..| -00000070 9b a5 |..| +00000000 14 03 03 00 11 b4 79 7e 62 ea ea f7 37 1d a4 65 |......y~b...7..e| +00000010 9d 02 95 b8 4a 6c 16 03 03 00 20 6a 45 d1 d0 ff |....Jl.... jE...| +00000020 fa 9f 6a ea d5 0d 27 b6 e7 15 8b e8 5b f9 3c d0 |..j...'.....[.<.| +00000030 32 ff 81 24 9a de 1c 31 6a 48 f8 17 03 03 00 19 |2..$...1jH......| +00000040 a9 07 ab fb 37 2f 88 0c 93 4a 0c 34 08 26 39 8c |....7/...J.4.&9.| +00000050 22 00 1b 36 3c 6d 0c 49 61 16 03 03 00 14 bb 63 |"..6>> Flow 11 (client to server) -00000000 16 03 03 01 1a 57 f6 a3 85 62 29 d9 5d b5 40 f7 |.....W...b).].@.| -00000010 71 ce d5 59 fa a4 5f a7 b7 a0 37 4a 5c 6c 9c 85 |q..Y.._...7J\l..| -00000020 e5 df be 22 14 a5 75 e5 79 0f 0f f9 91 00 74 f3 |..."..u.y.....t.| -00000030 5f b9 2f a8 1b e4 4a d4 7b 7d 79 e1 81 e4 7e 6c |_./...J.{}y...~l| -00000040 7b b8 d4 c9 69 85 2a e7 4e 33 75 47 84 e6 7a 1c |{...i.*.N3uG..z.| -00000050 9f 14 76 07 2c 53 e0 ab ba 5a c6 e3 a4 08 12 9e |..v.,S...Z......| -00000060 99 15 ed ce 17 e1 6e 20 a8 f2 24 84 53 da c6 0f |......n ..$.S...| -00000070 2f d5 c7 bf 23 00 90 1f 9f af 0f f7 d6 ad f6 4a |/...#..........J| -00000080 3f 88 ec c2 a7 04 08 0f 97 e4 b5 6b a5 19 a4 98 |?..........k....| -00000090 f7 ab a3 e1 44 56 39 b0 1d 2d c4 59 a7 3c d6 b4 |....DV9..-.Y.<..| -000000a0 44 8d ae 56 0e d5 6b ab a4 33 da d1 c3 38 4b fe |D..V..k..3...8K.| -000000b0 cc 40 3b 78 67 26 50 dd 75 3e a5 23 37 05 32 cf |.@;xg&P.u>.#7.2.| -000000c0 b4 6d a3 c1 a3 83 f8 1d a4 80 7c e9 69 84 5c 55 |.m........|.i.\U| -000000d0 92 7a 99 d7 86 27 dc be 54 27 d3 1d 1e ad 01 6d |.z...'..T'.....m| -000000e0 58 27 e2 82 a1 e4 55 03 67 b9 ee 51 b1 2d f9 25 |X'....U.g..Q.-.%| -000000f0 28 a3 c7 44 08 b0 3b 60 46 23 2c 17 76 f2 78 1e |(..D..;`F#,.v.x.| -00000100 3c f2 b5 5c b0 1e 5d a7 9c e6 4f c3 ba 34 40 30 |<..\..]...O..4@0| -00000110 d6 e3 68 2a d6 d2 75 04 d5 44 2d 41 87 c8 96 |..h*..u..D-A...| +00000000 16 03 03 01 1a a4 4c dc 47 09 04 ab bb ca 49 f2 |......L.G.....I.| +00000010 63 36 35 fb e3 3f ad ae 82 2a 9b 87 cc 0c 2e ea |c65..?...*......| +00000020 18 af ad e9 ea 7a c8 45 de c6 9b 0e e0 32 26 95 |.....z.E.....2&.| +00000030 ba e3 57 9e 27 ce ff 36 43 a3 bd 79 47 6c 02 86 |..W.'..6C..yGl..| +00000040 81 44 ac b3 c6 21 d8 fa 8c 69 43 b7 66 70 ea 24 |.D...!...iC.fp.$| +00000050 12 1b ac 44 d2 49 e3 5a d1 0e 50 76 46 4f 58 51 |...D.I.Z..PvFOXQ| +00000060 21 4c f8 20 63 60 c0 20 3a 12 e5 0b 86 e3 03 2c |!L. c`. :......,| +00000070 e1 fc 63 e4 44 d4 67 95 aa af 22 3d 40 7b 4e 12 |..c.D.g..."=@{N.| +00000080 98 7d 05 00 57 50 d5 3a d7 af dd 96 0f ac 77 63 |.}..WP.:......wc| +00000090 f8 1c b0 9c d0 96 9f 20 a1 48 55 aa dc 69 fb b7 |....... .HU..i..| +000000a0 67 58 ff 27 de 22 ea 66 48 32 56 1f ef 12 3f 44 |gX.'.".fH2V...?D| +000000b0 38 af ae 4b c2 16 bb c8 f1 fe 13 d7 05 66 de 08 |8..K.........f..| +000000c0 f3 4d 5c a6 e1 2d 0d c3 ce 50 7b 01 40 49 0f 83 |.M\..-...P{.@I..| +000000d0 97 c0 37 a2 6c 2b 64 a9 40 0e e1 7b f4 6e e1 cc |..7.l+d.@..{.n..| +000000e0 1a 5f 0b c5 69 dc dc db 0e a2 22 7b cf ca 73 81 |._..i....."{..s.| +000000f0 fc 47 47 c7 76 18 8e ae 55 6c fe 5e 5e 33 84 9c |.GG.v...Ul.^^3..| +00000100 4c 1b f8 21 29 3c 47 1b c8 01 38 7d c2 50 45 1c |L..!)>> Flow 12 (server to client) -00000000 16 03 03 00 85 77 11 78 f7 3a 59 c7 f1 a4 e6 6c |.....w.x.:Y....l| -00000010 3d e2 e0 1e 96 f7 2c d6 ce ef 27 3b 7f 37 cb bc |=.....,...';.7..| -00000020 8e ca c0 57 ab 03 1e cc d1 fb 6c 49 e2 89 48 a1 |...W......lI..H.| -00000030 84 00 a2 9b cb ae 2a ec 7c 60 9c 0c bf ff 07 ae |......*.|`......| -00000040 13 16 7b 7b a2 80 35 d3 5d 17 18 5a fb d8 87 46 |..{{..5.]..Z...F| -00000050 43 6e e7 e9 35 5f bb 5c 87 03 0d 3c 93 6d f9 9b |Cn..5_.\...<.m..| -00000060 28 b9 42 c3 ea f0 11 60 a1 f4 72 c0 f9 4c e9 36 |(.B....`..r..L.6| -00000070 77 c7 d0 e4 4b 7e d8 b4 68 d9 7f 97 bc 07 c5 4b |w...K~..h......K| -00000080 5e 11 1d ab 6e a4 24 41 2c d3 16 03 03 02 69 e7 |^...n.$A,.....i.| -00000090 68 ab 42 56 cb b5 70 a0 3b 63 c4 a6 10 49 1d d5 |h.BV..p.;c...I..| -000000a0 15 33 29 54 8f 36 a8 3c b7 8e 79 5a e7 45 6d cc |.3)T.6.<..yZ.Em.| -000000b0 c0 5f da 0a c1 13 56 b5 2d 8e 56 16 b4 ca 48 1d |._....V.-.V...H.| -000000c0 30 3f 58 c6 79 06 a2 c0 3f 6f 59 4a dc f0 09 5d |0?X.y...?oYJ...]| -000000d0 45 2a 23 4f ab 72 f4 4c 4d e0 05 44 7f 4c ab 25 |E*#O.r.LM..D.L.%| -000000e0 6f 9c 6a c4 cf c0 bd 86 03 c1 b2 b2 12 4e c2 0b |o.j..........N..| -000000f0 3e 8d 06 89 bb 46 70 79 51 33 eb 0d be ed 6e 0e |>....FpyQ3....n.| -00000100 33 08 48 53 2a 2a fb da 13 61 da 21 df 8b 74 85 |3.HS**...a.!..t.| -00000110 42 25 1f cf 7f 00 4c ca 80 9a 3d 25 07 da 22 bd |B%....L...=%..".| -00000120 17 47 75 e5 da 60 88 67 65 19 55 b6 05 fc 6d fa |.Gu..`.ge.U...m.| -00000130 9c 3d 19 fd 61 87 92 87 c5 95 80 06 d0 1a 71 7f |.=..a.........q.| -00000140 05 67 f3 f6 af da 35 1f d1 49 63 49 89 28 d1 21 |.g....5..IcI.(.!| -00000150 14 e0 06 14 14 83 a9 d9 86 21 68 0f 66 86 62 4d |.........!h.f.bM| -00000160 cc 7f 9e dc 79 fd eb 14 59 e7 cc bd 5c 29 86 4a |....y...Y...\).J| -00000170 5f 64 d2 7b 37 d1 72 4b ae 5b 12 c3 0c b0 a6 8a |_d.{7.rK.[......| -00000180 99 e5 89 e7 9e 76 1e 85 fc b6 ae 4b fd 20 8b 6a |.....v.....K. .j| -00000190 7d 7d 2b ff 11 d4 82 f0 2a d7 d6 9e e7 48 6e 1c |}}+.....*....Hn.| -000001a0 1d 33 2b 31 af aa 67 a7 66 b0 47 10 b8 f7 b8 0e |.3+1..g.f.G.....| -000001b0 0c ef 09 93 0a 42 2b 68 c8 30 cf d6 d4 8c 23 71 |.....B+h.0....#q| -000001c0 ef c3 bd f6 eb 74 b5 4e 1a 94 44 43 98 c8 ec b3 |.....t.N..DC....| -000001d0 51 10 44 2c f3 ae 27 c7 f3 5c 63 74 a8 1c f8 ff |Q.D,..'..\ct....| -000001e0 a9 38 c2 7f b4 66 fd 3b 9d a7 9c 7a 93 fd a3 09 |.8...f.;...z....| -000001f0 a6 51 c5 fd 6f 82 cc fb d2 58 bf 6e be 0d f2 4e |.Q..o....X.n...N| -00000200 2c 8c 08 6f 25 ae 82 bf b6 bf b7 71 44 b6 4f 90 |,..o%......qD.O.| -00000210 2e 1d 4e 1d 62 19 ee c7 4b 47 08 af 14 e3 cd 43 |..N.b...KG.....C| -00000220 fb 37 e0 d2 58 d7 03 7e f6 81 74 e9 a8 33 a2 7f |.7..X..~..t..3..| -00000230 06 94 5a 74 63 15 e1 f9 95 d3 b5 d6 52 e4 a4 5f |..Ztc.......R.._| -00000240 7d 16 3d 6e c6 53 3c 45 f5 f3 bc 91 7d 48 55 58 |}.=n.S\-p[.:t..c.z/..| -000002b0 4b 53 31 72 3d 20 89 60 8c 6e ce c7 07 d4 a9 6d |KS1r= .`.n.....m| -000002c0 28 76 a3 78 e0 ae 11 3f 31 e5 64 fe 35 39 d8 88 |(v.x...?1.d.59..| -000002d0 40 eb d0 f2 df db 1b 16 3a 11 33 ce 7c 63 cd 34 |@.......:.3.|c.4| -000002e0 17 8c a3 d5 d1 8f 34 21 a7 fa b3 8f f1 84 b0 06 |......4!........| -000002f0 d1 83 15 ac 26 1b 68 74 16 03 03 00 bc d2 f0 3d |....&.ht.......=| -00000300 2b a9 8c 75 e9 24 7a e8 0a ec 11 d7 cf 08 8e 5d |+..u.$z........]| -00000310 00 13 51 7f 2e 7a 6c 4b e2 35 c2 e0 9d c3 cb 79 |..Q..zlK.5.....y| -00000320 8f ec 2b 21 8f 96 4d b8 b8 0c b7 d8 d1 7f dc 5b |..+!..M........[| -00000330 85 8b b9 54 ba f6 65 76 5f b4 99 20 47 52 d8 96 |...T..ev_.. GR..| -00000340 ac 12 b0 84 77 9b 42 09 fe c4 cf b4 22 e3 e8 3c |....w.B....."..<| -00000350 a0 a0 e8 8e ab 61 0b 16 98 f3 bd ae 60 36 55 5a |.....a......`6UZ| -00000360 6b 85 8b 79 03 4f 65 15 83 06 45 eb c7 d9 de 41 |k..y.Oe...E....A| -00000370 53 0f 1f 12 ef 13 33 cc a6 fc 91 e4 7e a7 a3 31 |S.....3.....~..1| -00000380 6f 40 f4 d3 0e 2c 22 de 72 64 0d cd e0 e8 ee 21 |o@...,".rd.....!| -00000390 4b bd ef 53 78 9e 41 ce 04 96 3a 2f bc e7 41 6b |K..Sx.A...:/..Ak| -000003a0 e0 a8 9e 40 02 1b 09 ab 8b 37 4c 2b b4 bc e1 72 |...@.....7L+...r| -000003b0 06 af 88 24 75 6d 10 3a d5 16 03 03 00 14 8d 09 |...$um.:........| -000003c0 7b 2e 7a 58 f8 1c 63 44 0a a9 c4 5d 9f 5c cc 73 |{.zX..cD...].\.s| -000003d0 47 1a |G.| +00000000 16 03 03 00 85 bb 34 66 c0 a3 8c 2b 2c fe fe 82 |......4f...+,...| +00000010 53 a1 07 1f 06 db 41 94 ac 21 f2 c4 23 0e b6 48 |S.....A..!..#..H| +00000020 4d 16 97 2a 79 dd 95 4c 93 7f e4 8c 94 90 d4 02 |M..*y..L........| +00000030 3c 44 b4 80 80 7b 45 84 53 3f 6b 9f f6 b6 d3 0c |.c....>TP..alX | +00000200 da a8 5a f7 46 9d a3 57 a1 60 72 59 82 dd f7 08 |..Z.F..W.`rY....| +00000210 9e 48 16 8d b1 c0 f4 d2 e0 4e 5d 3c bf 23 88 0f |.H.......N]<.#..| +00000220 99 90 b0 a9 7e df 0b f5 1a 31 9e 59 e1 05 43 4e |....~....1.Y..CN| +00000230 4f d9 a5 b1 00 2e f2 c8 10 2c 73 ec c4 62 b8 c3 |O........,s..b..| +00000240 59 53 ce 38 37 9d c3 f6 77 36 34 f2 07 a6 21 1f |YS.87...w64...!.| +00000250 62 56 08 d3 ed ae 51 05 4d ed ef 7e 77 c5 7d ae |bV....Q.M..~w.}.| +00000260 b6 aa 74 e9 9a df 5d 89 c2 9f 07 75 a0 c2 35 2d |..t...]....u..5-| +00000270 cc 13 c5 a9 17 85 79 b6 45 0c 82 56 0d 19 9e bc |......y.E..V....| +00000280 e7 1a a6 cc 20 6f f9 7c 29 54 2f 5a 92 1f c0 8b |.... o.|)T/Z....| +00000290 9c a7 a3 85 43 f2 4c e7 c5 e3 af 6e 40 f4 14 d4 |....C.L....n@...| +000002a0 b8 26 5f ac d7 44 16 6d 40 d5 80 c5 49 df 8d fe |.&_..D.m@...I...| +000002b0 06 1c 7c 19 49 94 50 6f e8 8c e0 59 80 9a a0 0e |..|.I.Po...Y....| +000002c0 50 3f 03 de c9 30 88 15 91 83 4e a8 df c3 65 75 |P?...0....N...eu| +000002d0 cd 30 3e 7d 32 4a d9 ff 72 1e 1d 90 50 f3 67 8a |.0>}2J..r...P.g.| +000002e0 6a 94 c3 92 9a d4 0b 20 7e 61 98 6e db d0 71 4a |j...... ~a.n..qJ| +000002f0 8b 43 82 7e 76 e6 93 f7 16 03 03 00 bc e6 e6 85 |.C.~v...........| +00000300 a8 2c 74 47 10 a3 27 26 f7 46 fb da fa 6a 93 2c |.,tG..'&.F...j.,| +00000310 b1 14 b2 90 d3 4e 94 42 c4 37 6d 4d 43 73 b4 a7 |.....N.B.7mMCs..| +00000320 17 c1 3c 62 5d e4 c4 04 7c f7 13 39 9f a8 3f 05 |....d....| +00000390 e5 f8 f3 75 54 65 f4 6f e9 c8 eb a2 6c 06 98 fd |...uTe.o....l...| +000003a0 e9 bb a2 93 ab ee 0b fa c7 b4 fa e1 91 34 a9 a7 |.............4..| +000003b0 b9 14 16 25 32 88 09 3e b1 16 03 03 00 14 d0 c0 |...%2..>........| +000003c0 54 b2 37 35 9b cf 51 71 28 b2 d6 86 05 16 ad a0 |T.75..Qq(.......| +000003d0 18 e7 |..| >>> Flow 13 (client to server) -00000000 16 03 03 00 35 e1 bc fd 92 30 16 7d 71 c5 fc 15 |....5....0.}q...| -00000010 6f eb 98 2b 8c bb b6 d3 0b 6d 71 12 54 7d 08 a6 |o..+.....mq.T}..| -00000020 f1 a0 5b 37 6b 8b b7 f9 d6 11 53 c9 2c a4 b2 d3 |..[7k.....S.,...| -00000030 52 db 73 f4 75 3d 45 78 68 e5 14 03 03 00 11 51 |R.s.u=Exh......Q| -00000040 52 83 7e bd 5f 63 51 a4 1e 78 06 3b f1 f9 f8 a3 |R.~._cQ..x.;....| -00000050 16 03 03 00 20 44 02 6e 8f fe 3a 25 40 e5 63 29 |.... D.n..:%@.c)| -00000060 51 ce 94 55 cb 16 5a 9e 0d ec a8 73 f9 e8 46 06 |Q..U..Z....s..F.| -00000070 b5 98 7f c2 98 |.....| +00000000 16 03 03 00 35 e8 18 a5 be 6e 3b 37 5b d3 81 d3 |....5....n;7[...| +00000010 ad 0b 90 2e e0 df 2b 7f c4 ec 54 58 ef 85 e3 13 |......+...TX....| +00000020 41 07 50 d1 06 9b 3e a3 71 30 bf 7d 0c 7a bd 1e |A.P...>.q0.}.z..| +00000030 b6 e9 1e 10 0d 18 e3 b3 1c 38 14 03 03 00 11 bf |.........8......| +00000040 b3 65 ae 3b e6 c2 ad 30 83 75 65 c0 2b 0d 4b 11 |.e.;...0.ue.+.K.| +00000050 16 03 03 00 20 c6 cb f8 69 c3 bc 36 74 ff 8a 1f |.... ...i..6t...| +00000060 02 ef 32 37 fe 4f 14 51 d2 11 6a 98 05 4c 8c f6 |..27.O.Q..j..L..| +00000070 75 05 f9 39 2c |u..9,| >>> Flow 14 (server to client) -00000000 14 03 03 00 11 da c7 c6 7f 04 1e 65 7a cb 53 02 |...........ez.S.| -00000010 57 f7 6c f5 3b ca 16 03 03 00 20 9e 0e 55 81 35 |W.l.;..... ..U.5| -00000020 15 c9 22 94 be 1e f4 5e 1e 95 99 e5 ba 4a b6 1a |.."....^.....J..| -00000030 38 b5 31 25 85 4c a9 a8 39 fc 10 17 03 03 00 19 |8.1%.L..9.......| -00000040 61 c9 ca 41 f7 9d 66 08 bd 30 42 b2 7f 56 a7 46 |a..A..f..0B..V.F| -00000050 f4 23 18 30 c3 ec 96 cf 7f |.#.0.....| +00000000 14 03 03 00 11 a0 fa 14 67 3f 54 1b 61 89 ed db |........g?T.a...| +00000010 9c 66 9f 49 77 2d 16 03 03 00 20 ca 47 f0 57 8c |.f.Iw-.... .G.W.| +00000020 3e 52 e6 e2 6c 01 cb 16 05 68 5e 19 12 ca 80 48 |>R..l....h^....H| +00000030 dc e9 ed 41 33 08 01 ef 6e b0 a3 17 03 03 00 19 |...A3...n.......| +00000040 d9 c8 68 e8 27 3d cf c0 33 71 55 a9 6a b4 6d a5 |..h.'=..3qU.j.m.| +00000050 da 8d bb 34 94 4f b1 c6 22 |...4.O.."| >>> Flow 15 (client to server) -00000000 15 03 03 00 12 3a 24 58 49 ca a4 b1 6e 58 f2 e1 |.....:$XI...nX..| -00000010 df 3c c2 63 3d 59 e4 |.<.c=Y.| +00000000 15 03 03 00 12 15 66 43 1e 60 21 d1 f6 94 34 3e |......fC.`!...4>| +00000010 ee 90 fc 87 45 2a f5 |....E*.| diff --git a/testdata/Client-TLSv12-RenegotiateTwiceRejected b/testdata/Client-TLSv12-RenegotiateTwiceRejected index 898f5f2..7698b67 100644 --- a/testdata/Client-TLSv12-RenegotiateTwiceRejected +++ b/testdata/Client-TLSv12-RenegotiateTwiceRejected @@ -7,21 +7,21 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 7f 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 0a 00 08 00 1d 00 17 00 18 00 19 00 0b 00 02 01 |................| -000000a0 00 00 0d 00 1a 00 18 08 04 04 03 08 07 08 05 08 |................| -000000b0 06 04 01 05 01 06 01 05 03 06 03 02 01 02 03 ff |................| -000000c0 01 00 01 00 00 17 00 00 00 12 00 00 00 2b 00 09 |.............+..| +00000080 01 00 00 7f 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 19 00 0d |................| +000000b0 00 1a 00 18 08 04 04 03 08 07 08 05 08 06 04 01 |................| +000000c0 05 01 06 01 05 03 06 03 02 01 02 03 00 2b 00 09 |.............+..| 000000d0 08 03 04 03 03 03 02 03 01 00 33 00 26 00 24 00 |..........3.&.$.| 000000e0 1d 00 20 2f e5 7d a3 47 cd 62 43 15 28 da ac 5f |.. /.}.G.bC.(.._| 000000f0 bb 29 07 30 ff f6 84 af c4 cf c2 ed 90 99 5f 58 |.).0.........._X| 00000100 cb 3b 74 |.;t| >>> Flow 2 (server to client) -00000000 16 03 03 00 5d 02 00 00 59 03 03 cc a3 9c c7 68 |....]...Y......h| -00000010 f8 de 98 95 45 68 9f 10 2e ba 1f cf 81 a9 51 52 |....Eh........QR| -00000020 14 b7 ed a8 36 5a 40 43 e8 e8 bb 20 9a 57 99 f3 |....6Z@C... .W..| -00000030 a8 be d3 2a 86 8d b5 9b af 91 83 13 00 33 5e 4e |...*.........3^N| -00000040 f3 1c 42 67 08 65 54 40 dc 88 fb 90 cc a8 00 00 |..Bg.eT@........| +00000000 16 03 03 00 5d 02 00 00 59 03 03 e3 fe 9a 75 3b |....]...Y.....u;| +00000010 82 ac ff 66 ee c2 e9 75 d9 29 cc 89 6d e0 27 19 |...f...u.)..m.'.| +00000020 62 07 0b 0b c0 49 df 17 26 af 63 20 2a 95 69 54 |b....I..&.c *.iT| +00000030 3c 5d d9 67 05 4c 45 77 d0 d9 46 29 ed 25 fd 7d |<].g.LEw..F).%.}| +00000040 b4 ef 39 d2 ee 3b a3 88 85 c5 78 9a cc a8 00 00 |..9..;....x.....| 00000050 11 ff 01 00 01 00 00 0b 00 04 03 00 01 02 00 17 |................| 00000060 00 00 16 03 03 02 59 0b 00 02 55 00 02 52 00 02 |......Y...U..R..| 00000070 4f 30 82 02 4b 30 82 01 b4 a0 03 02 01 02 02 09 |O0..K0..........| @@ -61,189 +61,189 @@ 00000290 73 bb b3 43 77 8d 0c 1c f1 0f a1 d8 40 83 61 c9 |s..Cw.......@.a.| 000002a0 4c 72 2b 9d ae db 46 06 06 4d f4 c1 b3 3e c0 d1 |Lr+...F..M...>..| 000002b0 bd 42 d4 db fe 3d 13 60 84 5c 21 d3 3b e9 fa e7 |.B...=.`.\!.;...| -000002c0 16 03 03 00 ac 0c 00 00 a8 03 00 1d 20 1e f7 67 |............ ..g| -000002d0 0a a6 d0 af 27 2d 0d 36 24 23 a5 97 90 ef 75 4a |....'-.6$#....uJ| -000002e0 fc 0b 12 91 5d 92 bd bf 2d 7c 0c a2 06 08 04 00 |....]...-|......| -000002f0 80 71 f3 c0 ff 7a 01 b2 15 21 06 ae a1 f8 fa b5 |.q...z...!......| -00000300 19 f2 d0 f6 25 b2 7e 9f f1 8a 1c a1 a8 5d 2a 0a |....%.~......]*.| -00000310 ec 42 5c f8 6e 8e 8d c9 38 53 d0 c2 f3 7d f3 c8 |.B\.n...8S...}..| -00000320 12 f1 30 4b 7f 9a 9e 7c f8 78 56 9c ff 11 fd 36 |..0K...|.xV....6| -00000330 60 c9 3d b5 f7 6e 0f 7a 22 aa 3d a1 30 98 93 1d |`.=..n.z".=.0...| -00000340 7c 48 1f 79 24 cd a6 c2 d2 e8 f6 90 fe 19 6f 0d ||H.y$.........o.| -00000350 3a a6 65 35 8d 19 e4 3c cb 3a 07 5e 62 57 3d 67 |:.e5...<.:.^bW=g| -00000360 37 fa 23 26 0a 92 db 30 16 a8 37 3d d2 16 9d e4 |7.#&...0..7=....| -00000370 a7 16 03 03 00 04 0e 00 00 00 |..........| +000002c0 16 03 03 00 ac 0c 00 00 a8 03 00 1d 20 ca 74 42 |............ .tB| +000002d0 03 67 f2 31 ac 68 dd 2c db 23 7d 2c 84 df e9 50 |.g.1.h.,.#},...P| +000002e0 ff ef d4 a1 fa a4 5b 0b 0b 73 20 b7 0e 08 04 00 |......[..s .....| +000002f0 80 41 60 3d b1 1c 1d 14 8a 0a 3e 5c ea ca ce 07 |.A`=......>\....| +00000300 d4 45 18 6c 16 52 40 6f b0 f4 33 38 d7 cf 11 75 |.E.l.R@o..38...u| +00000310 08 4e 7d 8b cc 64 8c 79 dd 42 fa 43 2c 9e 84 91 |.N}..d.y.B.C,...| +00000320 e9 d5 bc 9f 84 2d 10 4b db 4e a6 be 37 e9 2e 34 |.....-.K.N..7..4| +00000330 d7 3e a7 17 80 b5 cd 37 04 2a 6c 2a cc 5f 0c a1 |.>.....7.*l*._..| +00000340 ff c2 31 86 17 50 3a 47 4d 99 49 94 9c 11 12 e2 |..1..P:GM.I.....| +00000350 70 fa d1 f4 7e 3a f2 3a df 16 34 45 0a b2 7b 73 |p...~:.:..4E..{s| +00000360 fa 59 23 85 88 74 2b e6 1e cb c7 00 f5 96 c8 8a |.Y#..t+.........| +00000370 02 16 03 03 00 04 0e 00 00 00 |..........| >>> Flow 3 (client to server) 00000000 16 03 03 00 25 10 00 00 21 20 2f e5 7d a3 47 cd |....%...! /.}.G.| 00000010 62 43 15 28 da ac 5f bb 29 07 30 ff f6 84 af c4 |bC.(.._.).0.....| 00000020 cf c2 ed 90 99 5f 58 cb 3b 74 14 03 03 00 01 01 |....._X.;t......| -00000030 16 03 03 00 20 22 30 b4 cc f8 e7 83 e4 72 5a 41 |.... "0......rZA| -00000040 39 fa 92 4e ef c5 bb 6b 6e ec d5 55 9d 2f 53 99 |9..N...kn..U./S.| -00000050 72 b6 99 55 a6 |r..U.| +00000030 16 03 03 00 20 0a a7 0c 5f 47 d1 7c 5e ea 63 82 |.... ..._G.|^.c.| +00000040 83 27 6c bc 29 20 25 ec 3d 15 2d 59 94 e7 9d 2c |.'l.) %.=.-Y...,| +00000050 8b 4e 95 85 fc |.N...| >>> Flow 4 (server to client) -00000000 14 03 03 00 01 01 16 03 03 00 20 b7 be 6c 7a 7f |.......... ..lz.| -00000010 00 e7 aa 12 ca 2d 29 6f eb f0 f1 5c 97 e5 d4 a2 |.....-)o...\....| -00000020 08 ab e3 04 ba e4 4d 15 08 ef 86 |......M....| +00000000 14 03 03 00 01 01 16 03 03 00 20 03 84 99 6b f7 |.......... ...k.| +00000010 3e 44 b1 96 6a 09 75 bf 26 4b 67 30 c4 e9 86 74 |>D..j.u.&Kg0...t| +00000020 4d e1 e3 9b fa 15 8e 1e 72 f9 5a |M.......r.Z| >>> Flow 5 (client to server) -00000000 17 03 03 00 16 5f 25 54 0e dd 48 23 b4 d9 00 3f |....._%T..H#...?| -00000010 1f 43 46 8e 32 64 3b 6a 42 70 ec |.CF.2d;jBp.| +00000000 17 03 03 00 16 68 29 2f 1b 1c 9d 28 6e b6 e5 09 |.....h)/...(n...| +00000010 4a 77 96 23 20 da 67 9e 14 ec 6b |Jw.# .g...k| >>> Flow 6 (server to client) -00000000 16 03 03 00 14 f7 db b2 a3 97 fd 00 16 52 c6 bf |.............R..| -00000010 57 78 21 37 02 02 ed 25 32 |Wx!7...%2| +00000000 16 03 03 00 14 66 e8 13 d1 b5 13 cf 5c 71 7b d9 |.....f......\q{.| +00000010 63 29 3d be 68 9f f4 ad 7b |c)=.h...{| >>> Flow 7 (client to server) -00000000 16 03 03 01 1a 9e a2 a0 cc d3 e9 25 e7 3c 11 9b |...........%.<..| -00000010 ab c4 a1 eb 5a 4a 5d c1 38 74 7e dc 8b 4c 1d 41 |....ZJ].8t~..L.A| -00000020 69 18 a6 b8 4c 67 3f 5b 90 50 ed f4 ab 34 ad 77 |i...Lg?[.P...4.w| -00000030 f6 28 f3 5b c9 db 16 ca 89 19 7c 90 f3 27 9e 0b |.(.[......|..'..| -00000040 8c ca 7e 9e a4 9e 2c ba 22 9e 85 be 8e ba 58 c7 |..~...,.".....X.| -00000050 c2 a3 da a2 55 ca 64 04 53 a5 92 43 8f 52 c0 63 |....U.d.S..C.R.c| -00000060 b5 9b 6d eb 0e 09 2e 0f 42 a7 c5 72 87 34 c2 d2 |..m.....B..r.4..| -00000070 9f 32 ce 25 58 be 94 21 4b d3 3b d8 9b 42 68 e3 |.2.%X..!K.;..Bh.| -00000080 27 75 a3 15 57 8b cf e0 a8 ac 23 94 8e 4a b0 92 |'u..W.....#..J..| -00000090 96 6f e4 a1 62 7d 24 67 92 b9 8a ec 76 1e bd ed |.o..b}$g....v...| -000000a0 1e 05 d9 c1 03 6c 6a 43 f6 22 8d bb c6 c0 58 7e |.....ljC."....X~| -000000b0 8e 49 f8 ef 9a 72 7c 3f 1b ff 98 fa 88 f4 ec b5 |.I...r|?........| -000000c0 47 b1 29 19 c8 85 98 86 bd 75 9a bc ad 02 30 41 |G.)......u....0A| -000000d0 21 e8 8f c1 69 d9 e0 b9 c2 b8 d7 91 8a 13 5b b5 |!...i.........[.| -000000e0 7f 9a df 12 2e 61 4c 54 b1 ca 12 dd bf 83 0b e7 |.....aLT........| -000000f0 68 fe 90 d9 2c 9c 86 9f 0e 57 19 e1 ba e5 2e c4 |h...,....W......| -00000100 f0 c4 b4 dd e5 0f 36 98 0f 94 26 cb 92 32 03 57 |......6...&..2.W| -00000110 78 15 19 3d bc 1e dd d1 46 28 24 06 c5 3d ed |x..=....F($..=.| +00000000 16 03 03 01 1a cb 21 91 08 de 08 87 fc 63 10 93 |......!......c..| +00000010 24 a3 83 e8 99 07 d5 03 19 61 4e 8e df dd d0 f6 |$........aN.....| +00000020 50 3c fd 14 23 67 cd 74 ad 87 9b b7 8f ee a2 23 |P<..#g.t.......#| +00000030 6c 2f 90 18 f4 01 6b 31 fe ca f7 65 f9 64 5a bc |l/....k1...e.dZ.| +00000040 49 3b 25 4c 35 59 50 f2 bc 70 cb 24 2f ec 47 12 |I;%L5YP..p.$/.G.| +00000050 b6 16 22 9e ce 3b fb 17 f9 59 4e 2f 5c 03 90 47 |.."..;...YN/\..G| +00000060 d5 e8 e9 eb d9 55 bf 8f 28 e8 72 e5 15 21 42 ba |.....U..(.r..!B.| +00000070 86 65 ac b4 f5 53 7e 98 38 39 b5 7d 2a 14 d6 7b |.e...S~.89.}*..{| +00000080 3e 69 9d dc 43 33 ed 0b 8a 77 14 54 9d b0 da 88 |>i..C3...w.T....| +00000090 3b 75 50 01 07 02 99 36 39 4f 01 ee 02 cf 05 a5 |;uP....69O......| +000000a0 71 75 03 3a a5 5c c4 ce 0e 1d ba dd 9d 79 c1 84 |qu.:.\.......y..| +000000b0 81 69 7c cd 63 a4 20 a3 a2 13 8e 6e d7 01 29 8d |.i|.c. ....n..).| +000000c0 35 e2 fa 3d 74 ea 40 06 7e 0b 2d ab 3c 54 73 ef |5..=t.@.~.-....&.FU........| +00000110 43 bd e5 9f 5c 35 02 25 54 17 89 c0 be ab bc |C...\5.%T......| >>> Flow 8 (server to client) -00000000 16 03 03 00 85 90 29 5c 91 ed 28 4f 54 29 f4 e7 |......)\..(OT)..| -00000010 b2 41 c9 38 5d ec 4a 38 22 0d a9 13 e9 65 fe 8c |.A.8].J8"....e..| -00000020 a4 e8 1a a0 6e 07 d2 4d 35 55 a7 65 92 cd da 75 |....n..M5U.e...u| -00000030 ca 0e 61 e3 6a 83 a0 30 bb 03 2a 6a e8 f0 69 3f |..a.j..0..*j..i?| -00000040 95 8d 97 c3 1b ef 74 58 68 f0 88 82 16 96 62 0a |......tXh.....b.| -00000050 49 7f 5b ec ee a1 6b 14 f6 5b 17 88 80 f6 70 e2 |I.[...k..[....p.| -00000060 d9 a3 3a dc 46 65 63 ec 37 aa b6 53 a8 13 f3 44 |..:.Fec.7..S...D| -00000070 5b 16 bd 4b ce 03 da 6f ba 2c 6a 5d 71 45 db 49 |[..K...o.,j]qE.I| -00000080 1c 00 17 d5 d8 40 0a 14 bb e8 16 03 03 02 69 d3 |.....@........i.| -00000090 cf e0 f6 ea fa 19 64 e9 af c4 47 2e 0d a5 14 20 |......d...G.... | -000000a0 cd 7e 97 0d 45 16 85 34 e7 f0 ed c1 fe 3c 12 f2 |.~..E..4.....<..| -000000b0 3f 2e f5 93 b0 95 f5 2c cd b1 ab 4b 8b e7 0d af |?......,...K....| -000000c0 7d 99 41 1e 9e 9e 18 90 6c e3 35 15 0b 89 fe 0f |}.A.....l.5.....| -000000d0 2f a2 e5 5c 67 bd 07 54 af 23 f2 ab 59 de 71 a2 |/..\g..T.#..Y.q.| -000000e0 5e 04 21 2c d9 da bf 3a 41 53 18 c8 c9 d5 82 ac |^.!,...:AS......| -000000f0 ba 31 25 fe e8 0f 94 c8 41 42 a0 43 d3 3f fb ea |.1%.....AB.C.?..| -00000100 0a b5 3f 66 ff da 49 a9 1b 20 f6 26 b3 48 4a 75 |..?f..I.. .&.HJu| -00000110 3f 88 74 d9 54 71 af d1 05 e3 9d 32 41 08 b8 8f |?.t.Tq.....2A...| -00000120 a9 fb f9 dd 5a c0 10 23 0d 8c 60 33 c1 2e b5 57 |....Z..#..`3...W| -00000130 dc 4c e2 95 82 be d0 39 10 f9 8c 48 62 df 11 f5 |.L.....9...Hb...| -00000140 d8 be 5e 46 26 3b 44 3a 36 31 8c 53 4e c6 6e 65 |..^F&;D:61.SN.ne| -00000150 28 e1 db 36 07 73 38 00 64 d6 ae fb 4e 35 a1 89 |(..6.s8.d...N5..| -00000160 03 f7 f3 22 5e 7a 69 0b 6c fa c2 5a d3 b1 ba ad |..."^zi.l..Z....| -00000170 e8 af 1f 21 31 c6 9d be 24 5d 4a f4 c3 69 61 36 |...!1...$]J..ia6| -00000180 8f ce 81 10 d4 99 82 94 66 53 f7 50 dd e3 d0 5a |........fS.P...Z| -00000190 ce 79 d8 0f 43 09 2a 2b 67 da 31 b5 0c ff c6 32 |.y..C.*+g.1....2| -000001a0 13 a4 cd 26 1d 16 49 24 45 f8 24 40 12 ea 7a f1 |...&..I$E.$@..z.| -000001b0 33 47 2d b7 1f 09 b4 fc 7e 00 dc 0d 3f a8 52 11 |3G-.....~...?.R.| -000001c0 f6 03 b0 c0 87 e4 be f7 0c 2b 6a c9 e5 ef 00 62 |.........+j....b| -000001d0 6d b6 b3 93 5f 60 08 f0 4f 3f be b7 8e 02 a8 c8 |m..._`..O?......| -000001e0 5f 38 0a 6d c1 f3 4d df 49 b5 6d 31 80 d9 5b 81 |_8.m..M.I.m1..[.| -000001f0 99 45 5d 43 cb 58 4e 28 5f 4f 6f e8 49 de cf ab |.E]C.XN(_Oo.I...| -00000200 2a ab 85 7a ef 9f 10 77 00 9e 38 99 57 25 14 40 |*..z...w..8.W%.@| -00000210 47 46 4a 30 4e 6a 75 f0 51 de 37 a0 6f 9a e6 17 |GFJ0Nju.Q.7.o...| -00000220 f5 6b 48 16 62 0d 38 2d 3f 99 ff 94 b3 e7 6e 5b |.kH.b.8-?.....n[| -00000230 3d 6f 15 5a e2 df c3 45 66 d6 52 1d a3 79 eb 01 |=o.Z...Ef.R..y..| -00000240 94 3a 4f 30 2e 6b 30 82 8e 58 3b 9a fe c8 a1 a2 |.:O0.k0..X;.....| -00000250 84 8b cd 0b 71 16 9e ea 81 23 b7 78 29 ba 5a 59 |....q....#.x).ZY| -00000260 8c 89 60 8c f8 d4 a9 80 02 b9 fb 41 fc 21 3f 4a |..`........A.!?J| -00000270 0f b3 c1 13 eb 07 f9 a0 13 d1 aa 3d c3 83 1e 53 |...........=...S| -00000280 b3 b6 f9 61 51 28 60 ab 1f 5e f0 f5 e4 94 43 c2 |...aQ(`..^....C.| -00000290 fc 53 aa d7 a3 47 f0 2e a0 e2 12 ee 21 c0 f6 81 |.S...G......!...| -000002a0 cc 60 51 66 1b fc e9 f2 64 78 d3 b3 0c 96 6b b5 |.`Qf....dx....k.| -000002b0 dc 22 7f d1 90 e9 ec ae 2f 50 81 b8 16 e7 07 83 |."....../P......| -000002c0 db 75 8c b0 fd 63 a5 c9 b1 bc 01 08 e6 53 86 3c |.u...c.......S.<| -000002d0 fe 98 67 ef 7a 7a 0a 33 2c 0b d7 57 25 8f 9d d2 |..g.zz.3,..W%...| -000002e0 ce ba 62 2c 81 f9 f9 87 6c a3 64 ba 32 34 23 02 |..b,....l.d.24#.| -000002f0 97 d7 42 cf f2 04 a9 08 16 03 03 00 bc c2 93 00 |..B.............| -00000300 26 dc ce 86 67 d7 7d 15 52 0e de 5c 2c 87 da 62 |&...g.}.R..\,..b| -00000310 4a 4f f5 cf 95 b0 c0 df 09 4a 4f 59 01 04 4b 3b |JO.......JOY..K;| -00000320 db 90 f7 ec 64 5a 71 1a 34 6c 67 ff e6 88 b1 39 |....dZq.4lg....9| -00000330 67 11 84 fc 30 26 16 00 2c 8e 0e e5 bd 3f d9 24 |g...0&..,....?.$| -00000340 46 ad c9 71 bc 2a c0 09 11 32 36 38 38 91 8d 96 |F..q.*...2688...| -00000350 73 e5 8b a4 b7 6e fb 80 fc 68 d5 a8 c7 ff 04 00 |s....n...h......| -00000360 b8 31 e8 30 17 97 db 43 ba b3 d8 4e 9f 48 c6 4b |.1.0...C...N.H.K| -00000370 23 7a a0 cb 2f 68 db 02 f2 f0 df 38 8f 4c d8 a8 |#z../h.....8.L..| -00000380 f5 27 e5 fe ca 10 2c 26 51 3c 37 07 14 66 93 9b |.'....,&Q<7..f..| -00000390 15 b0 c9 e2 f2 78 74 4d c6 e4 42 79 ff f1 cf 9d |.....xtM..By....| -000003a0 a1 c6 a5 5b 7f 4d 85 b3 fb 2b 46 96 c9 49 99 b6 |...[.M...+F..I..| -000003b0 08 58 8e 6f 95 1e 2e 6d 93 16 03 03 00 4a 55 ef |.X.o...m.....JU.| -000003c0 94 9b f2 d3 38 44 2c 39 17 07 2f 2c 76 0b c0 81 |....8D,9../,v...| -000003d0 d4 0b 5c df cf c3 07 62 c8 dc 82 bb 92 04 84 76 |..\....b.......v| -000003e0 e2 74 57 21 f6 7f ee 8f 5f c8 57 bd 97 c8 35 e7 |.tW!...._.W...5.| -000003f0 25 12 00 4b 72 c0 de c4 9e 82 5a 4d bf 05 f9 ab |%..Kr.....ZM....| -00000400 b1 5c 2e 64 66 38 95 0a 16 03 03 00 14 35 f4 4d |.\.df8.......5.M| -00000410 20 b9 38 cb 40 3e 46 83 28 b0 c7 19 ba 83 6a cd | .8.@>F.(.....j.| -00000420 e4 |.| +00000000 16 03 03 00 85 10 dc 85 7d 1e 66 b2 a4 86 68 a7 |........}.f...h.| +00000010 31 f3 b1 d8 c7 c9 26 6d 74 0a c0 c0 c0 39 ad b5 |1.....&mt....9..| +00000020 1b b1 dc d3 15 9f a4 96 27 dd 65 85 ad 83 2f 97 |........'.e.../.| +00000030 42 6f 8a 9b 58 fc f8 1b 54 89 cd 9c 11 10 b9 1d |Bo..X...T.......| +00000040 c3 e1 8e 89 20 a5 2d 0b 31 b5 e0 16 54 ce 93 9b |.... .-.1...T...| +00000050 de cc b1 af 48 48 33 96 4d a6 00 78 7b 60 3f 7c |....HH3.M..x{`?|| +00000060 cd 86 64 5e 38 e8 fd 60 d4 b1 89 cd e4 fb 42 b5 |..d^8..`......B.| +00000070 82 8f e5 23 91 87 6d 54 9e 85 37 34 df ae 70 a5 |...#..mT..74..p.| +00000080 cd 4c de 95 f7 9f a9 b4 87 0b 16 03 03 02 69 d1 |.L............i.| +00000090 c2 87 4e c8 26 b3 89 88 da c0 b9 24 84 88 c0 76 |..N.&......$...v| +000000a0 94 08 eb 56 5d fc 96 81 18 f3 5b 90 f1 38 e5 ae |...V].....[..8..| +000000b0 b5 4e 9a c1 19 19 1a b3 40 55 08 cb 0e 3b 93 b3 |.N......@U...;..| +000000c0 d7 74 80 3a 7c 0d eb be 70 0e a9 50 88 d2 52 11 |.t.:|...p..P..R.| +000000d0 2d 55 cf d9 9d aa 92 bd 15 ab 1a 62 b3 26 09 3f |-U.........b.&.?| +000000e0 50 2b b8 f2 00 a2 5a 2b 98 e3 bb e2 c7 0b 07 0e |P+....Z+........| +000000f0 5a e5 2e 08 27 87 f3 0b 1b f7 f7 82 49 cf 08 d6 |Z...'.......I...| +00000100 7c 78 39 0e 92 e7 28 f4 8f 12 ac 6a c2 72 46 e8 ||x9...(....j.rF.| +00000110 92 bf 36 c7 52 46 7a 01 92 6d a9 08 19 2a 07 70 |..6.RFz..m...*.p| +00000120 8c b2 40 7d 7f 00 27 ea fb e6 24 5c d2 d8 ae 99 |..@}..'...$\....| +00000130 0b cc 2a 4b 35 12 de 85 e9 b5 e2 2d 80 39 6d 17 |..*K5......-.9m.| +00000140 7a ca ef ca bb 58 1e 13 86 10 bc 4d 8a df 32 ba |z....X.....M..2.| +00000150 3b 7e f5 40 ec af 2e 63 be f3 38 02 a9 9d 30 1f |;~.@...c..8...0.| +00000160 c4 d2 04 93 df e1 8a bb 5d f0 6a a8 d9 b9 ad bf |........].j.....| +00000170 da d6 5e bd a1 a8 b8 20 91 26 ab 50 fd 2b bf e1 |..^.... .&.P.+..| +00000180 56 33 e3 e4 4f 3f 21 ea 86 10 e9 35 84 03 70 0b |V3..O?!....5..p.| +00000190 bd dc 44 fc 58 1d bc 9e 3a 0d 3b 61 13 d6 33 1b |..D.X...:.;a..3.| +000001a0 97 a8 67 bf e6 d9 1d 34 69 70 93 4a 6c 28 88 01 |..g....4ip.Jl(..| +000001b0 01 9d 78 59 c0 58 66 c3 70 e4 ba 74 e6 0f f7 27 |..xY.Xf.p..t...'| +000001c0 8b dd 05 ac 0d 99 dc e9 c8 2f 16 ee 59 53 91 d7 |........./..YS..| +000001d0 28 27 db ad 85 e6 d0 72 28 81 31 e1 e7 bf dd 95 |('.....r(.1.....| +000001e0 75 ff d6 a9 dc 4f 30 37 52 07 87 cb 8d a7 4a 00 |u....O07R.....J.| +000001f0 22 53 3c 6d 91 94 11 5d 0a a8 21 ea 1f 18 4e 42 |"S...A...| +00000390 37 c3 62 b5 30 89 4d b6 6c 5c f2 8c ff 3c 2e 48 |7.b.0.M.l\...<.H| +000003a0 bf 0f 5f 3e e0 b2 d7 64 2b dc 42 ad 2f 83 b5 6b |.._>...d+.B./..k| +000003b0 5a 04 51 f8 c4 07 c2 61 e4 16 03 03 00 4a a9 18 |Z.Q....a.....J..| +000003c0 58 79 d8 ad 86 d7 b6 77 39 76 99 b4 0a 29 72 b1 |Xy.....w9v...)r.| +000003d0 eb c3 ec 95 4d 30 4c 21 1a 7f 52 da 56 21 78 b7 |....M0L!..R.V!x.| +000003e0 fe dd d3 0e fc a9 89 40 99 97 12 68 7e 28 6e 32 |.......@...h~(n2| +000003f0 5b c0 e8 b4 42 eb ee 83 c2 ae 0d 28 99 48 46 a9 |[...B......(.HF.| +00000400 64 38 60 59 c2 dc 5c 7b 16 03 03 00 14 78 72 cf |d8`Y..\{.....xr.| +00000410 ac 5d 53 7e 73 b1 6e e2 0a 8e 12 33 be 03 86 6a |.]S~s.n....3...j| +00000420 ce |.| >>> Flow 9 (client to server) -00000000 16 03 03 02 69 6d 51 fa 86 0f dd 19 19 7a e9 f5 |....imQ......z..| -00000010 40 f7 4f 7a 10 c0 33 01 b8 14 32 92 7b 92 e0 c0 |@.Oz..3...2.{...| -00000020 04 84 cf 1c d8 15 2a be 12 0b 65 15 f2 bc 96 cf |......*...e.....| -00000030 9e d7 eb 5a f6 06 ee b0 8e e4 fc b9 c6 d6 81 52 |...Z...........R| -00000040 c1 4c a9 d7 33 a1 f8 b6 cd 79 eb 7d 44 5a 99 c0 |.L..3....y.}DZ..| -00000050 5b 8b 9d 8c 93 53 b6 27 f2 a0 e2 7a a2 66 de 3f |[....S.'...z.f.?| -00000060 65 0d 13 14 09 8b 1c 2a 85 7d 24 26 9a 64 b2 d1 |e......*.}$&.d..| -00000070 7c 10 ce b2 1e 86 df f1 a8 2c 2a 47 ae fe fe 1c ||........,*G....| -00000080 23 14 eb 78 40 bf 88 25 db 1a 7e 60 4d 3e b8 cb |#..x@..%..~`M>..| -00000090 7d 3c 2f d1 a7 6b 22 ee 99 21 88 50 d7 2d 06 2d |}.t..N.%.....7V.| -000001b0 fc 69 fe ad 75 67 34 7b ac e4 4f d5 82 b9 36 3e |.i..ug4{..O...6>| -000001c0 74 51 a5 32 3b 77 27 15 22 d8 8b c9 ad a6 98 5b |tQ.2;w'."......[| -000001d0 c5 4e 8d 62 bf ef 2d 41 b8 6d 5b 09 13 b3 40 ea |.N.b..-A.m[...@.| -000001e0 19 c4 08 78 e3 c1 a1 5e 05 a3 79 6a 27 d5 41 3e |...x...^..yj'.A>| -000001f0 c5 a6 f4 20 4c 93 92 77 c5 4a e8 1f f5 4b 83 87 |... L..w.J...K..| -00000200 66 40 c2 c1 aa 89 69 00 5b fb 54 94 1f b7 39 cd |f@....i.[.T...9.| -00000210 cd 9b 53 ad 08 63 30 05 e4 72 33 f0 ba b9 9d d9 |..S..c0..r3.....| -00000220 d1 fe c3 fc de 07 a2 a3 b2 85 0b 33 4a bd 54 77 |...........3J.Tw| -00000230 53 7c 8e 70 ed 9f ae 9d 2f 56 19 ce d6 1b 7a 64 |S|.p..../V....zd| -00000240 80 72 bc 86 b7 1a d6 5b ac a2 0c b2 c4 fa 79 f2 |.r.....[......y.| -00000250 16 7f 06 01 47 d3 f3 9b 4b 24 e2 f7 6b 33 45 4e |....G...K$..k3EN| -00000260 b0 84 f8 f6 4d b4 4a 3f 37 20 49 77 ff 6f 16 03 |....M.J?7 Iw.o..| -00000270 03 00 35 3b d6 d8 46 3a 93 f9 f4 29 b3 b7 9c cf |..5;..F:...)....| -00000280 b9 2d 90 58 78 91 ee d5 30 bd 59 e2 5a 1f 30 8c |.-.Xx...0.Y.Z.0.| -00000290 6e f9 1e d8 64 85 aa 1c 8b 41 10 07 d5 b2 7d 55 |n...d....A....}U| -000002a0 13 73 ad 0e 2d e0 d4 ff 16 03 03 00 98 75 4a 72 |.s..-........uJr| -000002b0 0f 07 ff 07 e3 80 96 7d c6 1b ab b8 c4 fc 38 0f |.......}......8.| -000002c0 f6 f8 f9 06 95 d4 7b 93 85 0f b3 34 11 cd 70 6f |......{....4..po| -000002d0 9b 3b a3 33 e5 fe e7 6a df 4b 02 e1 91 18 f3 e2 |.;.3...j.K......| -000002e0 3e d0 7c e4 95 c2 e7 ef dc 20 c3 6b b7 9e 1d 9a |>.|...... .k....| -000002f0 8c 23 c7 22 91 e7 7d 17 e4 5e 02 39 c3 6a b3 46 |.#."..}..^.9.j.F| -00000300 31 32 4a 8b 7b 0a 4a f4 51 ba a7 01 58 a9 bc 52 |12J.{.J.Q...X..R| -00000310 64 a9 e2 93 ad 34 c8 16 ad 66 67 e3 e7 3c 2c 66 |d....4...fg..<,f| -00000320 59 e8 df f7 cf 96 00 57 85 63 f1 4b 45 c6 8a e7 |Y......W.c.KE...| -00000330 54 9f 22 0c 74 2e 0c 1a cb df d0 98 55 bc d1 fd |T.".t.......U...| -00000340 2a e2 73 eb 1b 14 03 03 00 11 02 c8 fe cd 2a 0d |*.s...........*.| -00000350 c2 35 3c ff dd 23 e7 15 bf fe a0 16 03 03 00 20 |.5<..#......... | -00000360 7b ea 15 d3 2d 51 57 39 76 4b ef 16 0d 19 5d e0 |{...-QW9vK....].| -00000370 22 5e 68 19 c9 94 7e e9 67 41 12 85 2c e2 7c b8 |"^h...~.gA..,.|.| +00000000 16 03 03 02 69 33 a1 bb 7d ff 23 ba ad dc a0 1e |....i3..}.#.....| +00000010 3c 7c 1f 53 59 81 13 04 49 f7 6e bf 8f ef 11 92 |<|.SY...I.n.....| +00000020 51 bf 8a e7 fe ef 76 e4 f8 88 27 95 f4 12 f2 ed |Q.....v...'.....| +00000030 cc ec a6 2d 10 87 19 5e c9 fe cd 12 ae 1a 38 f9 |...-...^......8.| +00000040 78 f1 42 f8 47 26 1b c2 5f 82 a5 aa 65 17 eb 06 |x.B.G&.._...e...| +00000050 03 c8 22 9c 9f 8b 87 26 4a 64 18 93 9c f4 16 82 |.."....&Jd......| +00000060 28 eb 8d 2d f8 51 60 3a f4 bb a3 77 f5 97 2b 6a |(..-.Q`:...w..+j| +00000070 19 db 2e 46 8b d8 08 d8 28 88 bb bd d8 3b c2 bb |...F....(....;..| +00000080 8c 87 1b 17 a0 34 a8 c6 e8 a5 a0 e5 cb d6 9c 9d |.....4..........| +00000090 a6 a4 6c 06 6a 85 0c 5e ef 0c 97 6f b6 11 e7 4d |..l.j..^...o...M| +000000a0 60 91 95 74 48 af 1b 0b 47 03 ed 47 e9 b9 28 36 |`..tH...G..G..(6| +000000b0 74 0d 8a b8 1e 5d 1c cb ea 7b b7 8f 18 e3 b9 b9 |t....]...{......| +000000c0 43 ed 53 f2 bf 7e 8c 8f e6 c0 2a f4 31 25 f5 e8 |C.S..~....*.1%..| +000000d0 44 48 2d 36 4f a7 11 f6 ea 7c 3f d6 2d 5d 3e 39 |DH-6O....|?.-]>9| +000000e0 fb 50 f1 c9 eb 25 be 7a c5 af 54 f5 12 07 04 22 |.P...%.z..T...."| +000000f0 ec 68 45 f1 fd d1 91 0a cf 64 0f f3 58 4e e8 ce |.hE......d..XN..| +00000100 f6 9e c0 57 ea 3a bd a0 5d 26 d4 ab ed 1a 34 12 |...W.:..]&....4.| +00000110 9f fa ec 73 d6 38 06 78 85 3c f9 cd aa fb fd 32 |...s.8.x.<.....2| +00000120 cb e0 a7 d0 bb 71 b0 a3 d2 b9 89 5e a9 57 18 7e |.....q.....^.W.~| +00000130 c0 c9 2e e3 e5 07 65 6f 4c ad 22 78 50 f2 87 0f |......eoL."xP...| +00000140 cd 93 b3 19 a9 73 e2 1d bf 38 a0 20 8d 3a 3a 4e |.....s...8. .::N| +00000150 b3 02 b7 11 1f df 12 60 dd 10 1c f8 75 4a 52 86 |.......`....uJR.| +00000160 71 61 88 37 b3 bf f7 2d 45 6d 10 4a 9f 80 b3 fc |qa.7...-Em.J....| +00000170 36 d4 d3 9f 08 f2 bb ce 9c 3a 9a 59 f6 0a 0a aa |6........:.Y....| +00000180 7f 61 29 0b df 29 92 09 55 ec 1c 84 d6 1f 7c 68 |.a)..)..U.....|h| +00000190 72 00 88 5e e3 6a ee 35 45 7a 0b 49 35 0e 2d 7c |r..^.j.5Ez.I5.-|| +000001a0 ac 8b 9f 9c 94 48 2d 1e 74 24 68 14 8e 16 b4 06 |.....H-.t$h.....| +000001b0 24 66 a3 18 f4 ff 21 31 4b 9b bb 09 8a 9d 57 e4 |$f....!1K.....W.| +000001c0 a1 5c ae f1 e1 4b 5c 2a be 64 3c 7a 61 10 3d 73 |.\...K\*.d....^O| +000002f0 f7 4b 38 70 d0 82 42 f2 5a c9 34 d2 76 7b 8d e4 |.K8p..B.Z.4.v{..| +00000300 0b c7 3d be 86 7d 21 8c f8 9f 1a 4a dc 48 07 12 |..=..}!....J.H..| +00000310 ab 4c 98 f7 8b 3e 02 49 c2 d1 b5 e9 9a e0 5a 74 |.L...>.I......Zt| +00000320 58 ce a3 33 be 0f ca 12 54 a2 0e a9 e5 22 8f 82 |X..3....T...."..| +00000330 df 1a 3e 21 bf 66 c6 13 39 77 83 95 b1 4b 1d d3 |..>!.f..9w...K..| +00000340 32 69 24 c2 89 14 03 03 00 11 1c eb 63 31 c9 c9 |2i$.........c1..| +00000350 8a e3 8b 25 7e e9 b7 7d 19 03 3c 16 03 03 00 20 |...%~..}..<.... | +00000360 c6 41 57 04 ab e8 6c 55 0b dc cd 06 f5 b3 4b 95 |.AW...lU......K.| +00000370 40 b5 04 47 da 71 d7 70 ce d6 2e 0b c7 66 16 3c |@..G.q.p.....f.<| >>> Flow 10 (server to client) -00000000 14 03 03 00 11 6b a1 f5 7f f5 64 ff 54 2a 67 95 |.....k....d.T*g.| -00000010 f5 25 5b fe 38 39 16 03 03 00 20 be 49 c4 6c 7a |.%[.89.... .I.lz| -00000020 12 cf 16 5b 1c b3 14 53 79 3e 8d 01 85 75 91 1a |...[...Sy>...u..| -00000030 3a fe bc a9 c5 11 3f d5 88 4b 3e 17 03 03 00 19 |:.....?..K>.....| -00000040 89 9c 38 5f 11 ba 1e 81 8a 09 ae 95 03 28 47 6c |..8_.........(Gl| -00000050 db 9b 38 9d e7 37 75 01 af 16 03 03 00 14 c3 86 |..8..7u.........| -00000060 cd a6 a3 dd 62 c9 4b be e5 2d 3f 31 a0 cc 87 f8 |....b.K..-?1....| -00000070 78 61 |xa| +00000000 14 03 03 00 11 c0 4e fd fa 3a 1c 4a 19 ce 08 f6 |......N..:.J....| +00000010 da 70 56 fa 39 42 16 03 03 00 20 0c bc c4 5e 24 |.pV.9B.... ...^$| +00000020 e3 0e c9 23 8c cd f6 a2 45 07 e6 93 40 7c c8 02 |...#....E...@|..| +00000030 6e 24 f7 4e 06 9a ad ba de cd 10 17 03 03 00 19 |n$.N............| +00000040 52 e0 85 b3 46 25 7d fd 8f d0 4c ca df fe 2f a6 |R...F%}...L.../.| +00000050 14 d6 08 82 70 0f 93 78 bf 16 03 03 00 14 ff 68 |....p..x.......h| +00000060 f1 6d 8d b4 5f 74 19 6b e3 1e 6e ee 9d ee c2 34 |.m.._t.k..n....4| +00000070 0f 44 |.D| >>> Flow 11 (client to server) -00000000 15 03 03 00 12 35 45 94 25 9c 40 dd df 00 a9 13 |.....5E.%.@.....| -00000010 f2 7c 47 63 98 22 c5 15 03 03 00 12 60 26 66 bb |.|Gc."......`&f.| -00000020 8b 92 9d da 32 e3 97 92 ae 89 a9 2a d0 9a |....2......*..| +00000000 15 03 03 00 12 81 0d 63 a5 11 7a 03 ab 66 f6 c8 |.......c..z..f..| +00000010 15 f3 d9 23 fa 67 6b 15 03 03 00 12 71 0e 3b 52 |...#.gk.....q.;R| +00000020 1a 05 39 4c 8c 76 c3 a9 00 35 bd 66 80 a1 |..9L.v...5.f..| diff --git a/testdata/Client-TLSv12-RenegotiationRejected b/testdata/Client-TLSv12-RenegotiationRejected index 8307ee3..0be2e72 100644 --- a/testdata/Client-TLSv12-RenegotiationRejected +++ b/testdata/Client-TLSv12-RenegotiationRejected @@ -7,21 +7,21 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 7f 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 0a 00 08 00 1d 00 17 00 18 00 19 00 0b 00 02 01 |................| -000000a0 00 00 0d 00 1a 00 18 08 04 04 03 08 07 08 05 08 |................| -000000b0 06 04 01 05 01 06 01 05 03 06 03 02 01 02 03 ff |................| -000000c0 01 00 01 00 00 17 00 00 00 12 00 00 00 2b 00 09 |.............+..| +00000080 01 00 00 7f 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 19 00 0d |................| +000000b0 00 1a 00 18 08 04 04 03 08 07 08 05 08 06 04 01 |................| +000000c0 05 01 06 01 05 03 06 03 02 01 02 03 00 2b 00 09 |.............+..| 000000d0 08 03 04 03 03 03 02 03 01 00 33 00 26 00 24 00 |..........3.&.$.| 000000e0 1d 00 20 2f e5 7d a3 47 cd 62 43 15 28 da ac 5f |.. /.}.G.bC.(.._| 000000f0 bb 29 07 30 ff f6 84 af c4 cf c2 ed 90 99 5f 58 |.).0.........._X| 00000100 cb 3b 74 |.;t| >>> Flow 2 (server to client) -00000000 16 03 03 00 5d 02 00 00 59 03 03 8a 1d c8 bd c6 |....]...Y.......| -00000010 43 4c 78 5c 99 f4 8f e3 72 4b 73 a3 20 10 5b 8b |CLx\....rKs. .[.| -00000020 3e 04 7f 4c 5c 58 fb d5 ed c6 d9 20 ff 23 98 81 |>..L\X..... .#..| -00000030 0a 7f d2 f4 ed ae 87 2e ad e7 a9 60 31 b1 36 ab |...........`1.6.| -00000040 f4 b6 cc 98 a0 8b 62 ca 57 ed 58 87 cc a8 00 00 |......b.W.X.....| +00000000 16 03 03 00 5d 02 00 00 59 03 03 21 15 e1 02 00 |....]...Y..!....| +00000010 c6 0c e5 3f c9 6f a5 59 38 7e 13 81 1b 26 50 46 |...?.o.Y8~...&PF| +00000020 bf 2b 95 0c eb a8 bc 72 97 bc 26 20 ad 6b 84 ac |.+.....r..& .k..| +00000030 8f 62 26 0b 4b d8 bf 1b 7d a5 27 3b 3e 45 a5 8f |.b&.K...}.';>E..| +00000040 37 fb b2 25 2c d3 82 69 ed d7 c9 f0 cc a8 00 00 |7..%,..i........| 00000050 11 ff 01 00 01 00 00 0b 00 04 03 00 01 02 00 17 |................| 00000060 00 00 16 03 03 02 59 0b 00 02 55 00 02 52 00 02 |......Y...U..R..| 00000070 4f 30 82 02 4b 30 82 01 b4 a0 03 02 01 02 02 09 |O0..K0..........| @@ -61,36 +61,36 @@ 00000290 73 bb b3 43 77 8d 0c 1c f1 0f a1 d8 40 83 61 c9 |s..Cw.......@.a.| 000002a0 4c 72 2b 9d ae db 46 06 06 4d f4 c1 b3 3e c0 d1 |Lr+...F..M...>..| 000002b0 bd 42 d4 db fe 3d 13 60 84 5c 21 d3 3b e9 fa e7 |.B...=.`.\!.;...| -000002c0 16 03 03 00 ac 0c 00 00 a8 03 00 1d 20 ba 3a 8d |............ .:.| -000002d0 07 bd 2e fa bd 85 70 45 e9 b6 eb 1f 2c 15 a2 15 |......pE....,...| -000002e0 d7 29 2c a9 a8 ec 46 b0 77 0a 49 c2 49 08 04 00 |.),...F.w.I.I...| -000002f0 80 5c a8 eb 85 8d 5f 01 9f 19 b8 6b 9a 66 ed 07 |.\...._....k.f..| -00000300 ad e9 2e 85 c1 b8 94 56 17 84 0d d4 14 7b e2 c1 |.......V.....{..| -00000310 89 80 f5 92 31 a0 90 6f 59 fb e7 af a9 e9 6d f3 |....1..oY.....m.| -00000320 72 aa aa e5 d9 4c d9 ac bb 05 ac 51 e2 3f 64 05 |r....L.....Q.?d.| -00000330 e8 e4 fd 80 b3 b9 6f 54 91 13 72 8d 45 ea 0f 13 |......oT..r.E...| -00000340 f7 22 19 92 ce 66 fc d0 be af d3 8e 01 ef a5 7a |."...f.........z| -00000350 08 6e f3 f7 28 55 33 bf e9 2a b6 60 d5 32 3f df |.n..(U3..*.`.2?.| -00000360 e7 df 11 21 e4 c5 6e 13 bb f7 ad c7 ca 2e 11 2e |...!..n.........| -00000370 22 16 03 03 00 04 0e 00 00 00 |".........| +000002c0 16 03 03 00 ac 0c 00 00 a8 03 00 1d 20 b2 3a 28 |............ .:(| +000002d0 2e 2c 66 f1 9b 44 58 9a 92 03 42 81 f6 1c f4 67 |.,f..DX...B....g| +000002e0 50 b5 92 f3 06 1b 1b 23 93 99 12 c5 6b 08 04 00 |P......#....k...| +000002f0 80 44 05 ae 8d ed c6 82 3a 2a 19 05 9d 70 f9 ba |.D......:*...p..| +00000300 45 66 cb 45 75 9c da 92 cc bb 4a a5 ae 41 8c f8 |Ef.Eu.....J..A..| +00000310 9b e7 06 73 88 9f f9 7d 95 ce 74 a6 05 e9 38 a5 |...s...}..t...8.| +00000320 26 4b b2 26 31 5c e9 f9 a8 f8 6e 6b 05 e4 39 b5 |&K.&1\....nk..9.| +00000330 fe b1 b1 cd 40 23 e9 68 f3 9c ed 91 71 d3 0b c5 |....@#.h....q...| +00000340 91 c5 b2 91 69 a9 4b 2c a7 0c 24 d6 a9 e7 74 89 |....i.K,..$...t.| +00000350 9e ce 8b 00 72 9a c9 86 8b ca 8d 39 01 a0 71 3e |....r......9..q>| +00000360 46 ff a6 7d c6 da 0a af f2 84 c4 01 1c 94 47 22 |F..}..........G"| +00000370 71 16 03 03 00 04 0e 00 00 00 |q.........| >>> Flow 3 (client to server) 00000000 16 03 03 00 25 10 00 00 21 20 2f e5 7d a3 47 cd |....%...! /.}.G.| 00000010 62 43 15 28 da ac 5f bb 29 07 30 ff f6 84 af c4 |bC.(.._.).0.....| 00000020 cf c2 ed 90 99 5f 58 cb 3b 74 14 03 03 00 01 01 |....._X.;t......| -00000030 16 03 03 00 20 46 20 45 1d b3 e5 62 1d 89 b7 67 |.... F E...b...g| -00000040 23 76 0b f4 fb c3 fd 57 80 09 ee 69 e3 ad bb 42 |#v.....W...i...B| -00000050 56 55 b6 6b 73 |VU.ks| +00000030 16 03 03 00 20 80 26 44 1c a7 83 b7 12 29 9a 44 |.... .&D.....).D| +00000040 7b c1 0b 96 53 c8 0e 9b dd 8d 29 4b 4b b8 75 d7 |{...S.....)KK.u.| +00000050 0a c7 86 c7 d9 |.....| >>> Flow 4 (server to client) -00000000 14 03 03 00 01 01 16 03 03 00 20 69 d6 1d dd 67 |.......... i...g| -00000010 bb 02 a5 41 a5 11 6d e2 54 9a e8 c7 e5 b5 60 b5 |...A..m.T.....`.| -00000020 77 fb e6 61 22 c7 0d 2f bb bf d4 |w..a"../...| +00000000 14 03 03 00 01 01 16 03 03 00 20 2e d7 9e b0 66 |.......... ....f| +00000010 f1 39 84 a9 d9 93 17 bd 94 5a 31 49 bb eb f0 a0 |.9.......Z1I....| +00000020 7b af d0 3b ae 1a 5d f6 46 31 36 |{..;..].F16| >>> Flow 5 (client to server) -00000000 17 03 03 00 16 bb a9 4d d8 15 fc 1f 99 96 03 80 |.......M........| -00000010 5e fc b5 f8 ac 14 10 82 f5 08 c6 |^..........| +00000000 17 03 03 00 16 cd 39 a7 64 3b 6a de 14 e0 26 ea |......9.d;j...&.| +00000010 66 b2 73 b1 8e b0 e3 a9 94 62 4f |f.s......bO| >>> Flow 6 (server to client) -00000000 16 03 03 00 14 0f 7d 98 6c 60 b3 cc cf c5 f3 0a |......}.l`......| -00000010 8f d2 40 6a 5b e5 45 1b 8b |..@j[.E..| +00000000 16 03 03 00 14 c5 d7 88 58 81 44 1f 8d e4 c2 19 |........X.D.....| +00000010 15 3b 5c 43 76 82 fe 03 e1 |.;\Cv....| >>> Flow 7 (client to server) -00000000 15 03 03 00 12 f4 9f 10 dc f2 69 4c 21 0c a0 8f |..........iL!...| -00000010 6b fd aa a1 93 9a 3a 15 03 03 00 12 be 68 f2 b8 |k.....:......h..| -00000020 8b 0d a5 1f 98 f0 c2 dd d4 0a 8c 46 b8 f5 |...........F..| +00000000 15 03 03 00 12 d4 b1 0d fa 41 25 ab d4 e1 b7 74 |.........A%....t| +00000010 27 5c 8b c6 0d 49 8e 15 03 03 00 12 65 3d 4e 30 |'\...I......e=N0| +00000020 48 43 8f f6 8b 89 45 af f4 7a e4 eb ad a1 |HC....E..z....| diff --git a/testdata/Client-TLSv12-SCT b/testdata/Client-TLSv12-SCT index 01fa299..8ea2cd4 100644 --- a/testdata/Client-TLSv12-SCT +++ b/testdata/Client-TLSv12-SCT @@ -7,21 +7,21 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 7f 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 0a 00 08 00 1d 00 17 00 18 00 19 00 0b 00 02 01 |................| -000000a0 00 00 0d 00 1a 00 18 08 04 04 03 08 07 08 05 08 |................| -000000b0 06 04 01 05 01 06 01 05 03 06 03 02 01 02 03 ff |................| -000000c0 01 00 01 00 00 17 00 00 00 12 00 00 00 2b 00 09 |.............+..| +00000080 01 00 00 7f 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 19 00 0d |................| +000000b0 00 1a 00 18 08 04 04 03 08 07 08 05 08 06 04 01 |................| +000000c0 05 01 06 01 05 03 06 03 02 01 02 03 00 2b 00 09 |.............+..| 000000d0 08 03 04 03 03 03 02 03 01 00 33 00 26 00 24 00 |..........3.&.$.| 000000e0 1d 00 20 2f e5 7d a3 47 cd 62 43 15 28 da ac 5f |.. /.}.G.bC.(.._| 000000f0 bb 29 07 30 ff f6 84 af c4 cf c2 ed 90 99 5f 58 |.).0.........._X| 00000100 cb 3b 74 |.;t| >>> Flow 2 (server to client) -00000000 16 03 03 01 ca 02 00 01 c6 03 03 37 df c1 4d 8a |...........7..M.| -00000010 eb 27 a3 6c ec 70 05 9f f0 86 80 01 6e ad 88 55 |.'.l.p......n..U| -00000020 f2 1a 44 fb 42 d6 03 5d f8 74 18 20 0a f5 d0 22 |..D.B..].t. ..."| -00000030 aa f2 9f e3 9a 0c 86 27 2e 66 be d5 3a c2 4d 77 |.......'.f..:.Mw| -00000040 f8 5e 78 2b 71 ab 5e 0a 09 bc e1 d6 cc a8 00 01 |.^x+q.^.........| +00000000 16 03 03 01 ca 02 00 01 c6 03 03 da b0 57 a0 ee |.............W..| +00000010 bf 74 92 06 39 a6 9a 9b 80 71 7e 57 63 ab 31 74 |.t..9....q~Wc.1t| +00000020 d3 22 c1 e3 a6 c6 cf 6f 47 57 49 20 86 52 fb 0a |.".....oGWI .R..| +00000030 fd aa 10 47 00 9a 5d ad 4c d8 90 f1 cf 13 10 73 |...G..].L......s| +00000040 31 f1 df 22 f3 42 58 b0 10 25 43 eb cc a8 00 01 |1..".BX..%C.....| 00000050 7e 00 12 01 69 01 67 00 75 00 a4 b9 09 90 b4 18 |~...i.g.u.......| 00000060 58 14 87 bb 13 a2 cc 67 70 0a 3c 35 98 04 f9 1b |X......gp.<5....| 00000070 df b8 e3 77 cd 0e c8 0d dc 10 00 00 01 47 97 99 |...w.........G..| @@ -84,31 +84,31 @@ 00000400 43 77 8d 0c 1c f1 0f a1 d8 40 83 61 c9 4c 72 2b |Cw.......@.a.Lr+| 00000410 9d ae db 46 06 06 4d f4 c1 b3 3e c0 d1 bd 42 d4 |...F..M...>...B.| 00000420 db fe 3d 13 60 84 5c 21 d3 3b e9 fa e7 16 03 03 |..=.`.\!.;......| -00000430 00 ac 0c 00 00 a8 03 00 1d 20 63 41 30 1c 95 79 |......... cA0..y| -00000440 1b a6 85 f4 e1 b6 d7 f5 82 e2 4f 2b ae cd 7b 4b |..........O+..{K| -00000450 20 e2 7e 43 f1 59 e5 83 92 55 08 04 00 80 5c aa | .~C.Y...U....\.| -00000460 39 6d 57 d3 b6 15 4d 9e c8 e1 dc 50 b3 89 69 99 |9mW...M....P..i.| -00000470 da 07 64 74 c4 ab d3 83 f0 9b fc 3a da 26 9f ce |..dt.......:.&..| -00000480 37 e9 7a 50 e5 70 d1 71 0b 0d 73 03 9c c1 3f 81 |7.zP.p.q..s...?.| -00000490 f9 1d 57 32 6b 48 50 1d 5d 7d 64 56 f0 c9 8c 69 |..W2kHP.]}dV...i| -000004a0 d6 91 15 85 95 9a 0c 76 f0 9c d2 fe d4 df 65 00 |.......v......e.| -000004b0 a1 cc 65 4a a2 8e 06 fc 50 77 ff 00 44 b5 cc f5 |..eJ....Pw..D...| -000004c0 9f 39 2f 95 72 4f 51 af 21 09 6a 6a 21 60 24 65 |.9/.rOQ.!.jj!`$e| -000004d0 78 20 9b 06 0e 24 1b 79 f2 8d 15 35 49 44 16 03 |x ...$.y...5ID..| +00000430 00 ac 0c 00 00 a8 03 00 1d 20 0e e6 72 88 cf d1 |......... ..r...| +00000440 05 c7 8d 03 64 b9 db d8 c3 5e 36 80 67 67 36 94 |....d....^6.gg6.| +00000450 5b b7 92 f9 77 1f 6f b2 44 7f 08 04 00 80 1d 3b |[...w.o.D......;| +00000460 70 d5 72 87 2f 58 20 da 29 e0 f8 e8 7c 8d e5 c7 |p.r./X .)...|...| +00000470 bf da 3c 10 f8 b0 3e 38 7b 06 0b 8e 8f d7 40 b6 |..<...>8{.....@.| +00000480 47 9f 1c 64 6e 80 ab 9d 51 92 8c 60 a2 88 c4 43 |G..dn...Q..`...C| +00000490 7d dc 29 64 45 83 a7 9c 2a 39 e9 bb 2a d9 f5 96 |}.)dE...*9..*...| +000004a0 4c fb fd 0d cc 0f 9b 48 f5 ee af 8f 7a 1c 39 3e |L......H....z.9>| +000004b0 cf 23 15 c6 ab c3 f2 29 fd 6c 4f 17 6b d4 be 1a |.#.....).lO.k...| +000004c0 23 6e 74 81 e5 e5 e8 c0 de 9b b0 ed d2 32 bc 2a |#nt..........2.*| +000004d0 b1 30 b2 eb ac 9e 23 f8 be ea 31 9a b4 55 16 03 |.0....#...1..U..| 000004e0 03 00 04 0e 00 00 00 |.......| >>> Flow 3 (client to server) 00000000 16 03 03 00 25 10 00 00 21 20 2f e5 7d a3 47 cd |....%...! /.}.G.| 00000010 62 43 15 28 da ac 5f bb 29 07 30 ff f6 84 af c4 |bC.(.._.).0.....| 00000020 cf c2 ed 90 99 5f 58 cb 3b 74 14 03 03 00 01 01 |....._X.;t......| -00000030 16 03 03 00 20 d0 2b f9 13 8b 71 de 1b 1d 63 2e |.... .+...q...c.| -00000040 66 05 12 ee 11 d5 9b 75 ee 51 fa 42 fa 5d 86 eb |f......u.Q.B.]..| -00000050 f0 c5 c5 cb 5b |....[| +00000030 16 03 03 00 20 a1 58 d5 1a a3 9f 85 4e b6 c8 b7 |.... .X.....N...| +00000040 cb c1 b0 cc 0a 80 59 1d 81 41 cc 4d 0b d3 bd 38 |......Y..A.M...8| +00000050 48 69 01 23 96 |Hi.#.| >>> Flow 4 (server to client) -00000000 14 03 03 00 01 01 16 03 03 00 20 71 ac 7b 2e ba |.......... q.{..| -00000010 d5 7e 70 6c 7c 94 0e 55 0f 65 8c 1d ff 5e 79 d6 |.~pl|..U.e...^y.| -00000020 21 9b 8a f4 82 35 69 b8 5a d9 1a |!....5i.Z..| +00000000 14 03 03 00 01 01 16 03 03 00 20 83 ae fc 0d dd |.......... .....| +00000010 a1 3a 55 b0 2e 5e 21 9c 57 f3 1b 94 80 6c 0e bb |.:U..^!.W....l..| +00000020 78 ae f4 6c 20 d5 7e 23 11 1e 7d |x..l .~#..}| >>> Flow 5 (client to server) -00000000 17 03 03 00 16 82 6e 37 1a 95 19 06 bf da ca 8c |......n7........| -00000010 f4 07 3a 63 69 c7 00 ce 5c b9 bf 15 03 03 00 12 |..:ci...\.......| -00000020 eb 05 f5 6f 8c 59 16 ed 26 1b f9 1f 2e 4e b8 89 |...o.Y..&....N..| -00000030 80 77 |.w| +00000000 17 03 03 00 16 d3 16 a3 f0 93 49 44 d4 82 60 35 |..........ID..`5| +00000010 e3 63 08 c0 4e 66 99 37 31 90 6c 15 03 03 00 12 |.c..Nf.71.l.....| +00000020 3c ea 2c 19 34 7b cc 6c 7a a9 15 31 6f 9c 3b b0 |<.,.4{.lz..1o.;.| +00000030 b2 1f |..| diff --git a/testdata/Client-TLSv12-X25519-ECDHE b/testdata/Client-TLSv12-X25519-ECDHE index 372abea..c851eb1 100644 --- a/testdata/Client-TLSv12-X25519-ECDHE +++ b/testdata/Client-TLSv12-X25519-ECDHE @@ -7,20 +7,20 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 79 00 05 00 05 01 00 00 00 00 00 0a 00 |...y............| -00000090 04 00 02 00 1d 00 0b 00 02 01 00 00 0d 00 1a 00 |................| -000000a0 18 08 04 04 03 08 07 08 05 08 06 04 01 05 01 06 |................| -000000b0 01 05 03 06 03 02 01 02 03 ff 01 00 01 00 00 17 |................| -000000c0 00 00 00 12 00 00 00 2b 00 09 08 03 04 03 03 03 |.......+........| +00000080 01 00 00 79 00 0b 00 02 01 00 ff 01 00 01 00 00 |...y............| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 04 00 02 00 1d 00 0d 00 1a 00 18 08 04 |................| +000000b0 04 03 08 07 08 05 08 06 04 01 05 01 06 01 05 03 |................| +000000c0 06 03 02 01 02 03 00 2b 00 09 08 03 04 03 03 03 |.......+........| 000000d0 02 03 01 00 33 00 26 00 24 00 1d 00 20 2f e5 7d |....3.&.$... /.}| 000000e0 a3 47 cd 62 43 15 28 da ac 5f bb 29 07 30 ff f6 |.G.bC.(.._.).0..| 000000f0 84 af c4 cf c2 ed 90 99 5f 58 cb 3b 74 |........_X.;t| >>> Flow 2 (server to client) -00000000 16 03 03 00 5d 02 00 00 59 03 03 19 05 85 f6 4a |....]...Y......J| -00000010 53 c9 c6 4f ac 38 b7 cc d8 5d 00 dc 3b 97 9c 0d |S..O.8...]..;...| -00000020 d0 e0 9f d8 71 28 a1 ab e8 b7 cc 20 a6 a4 8c 69 |....q(..... ...i| -00000030 6e 9c ee ae 75 14 b8 0f 93 b3 c2 82 ff 01 9b d7 |n...u...........| -00000040 25 90 d7 53 02 6d 3b ec e9 1a 21 e5 c0 2f 00 00 |%..S.m;...!../..| +00000000 16 03 03 00 5d 02 00 00 59 03 03 e0 da ea 5e 09 |....]...Y.....^.| +00000010 bb 30 4c 10 db 85 36 44 38 9e a4 83 74 5f 2f 94 |.0L...6D8...t_/.| +00000020 a1 b4 45 61 73 2f 88 b3 ac ad e4 20 45 55 20 90 |..Eas/..... EU .| +00000030 b0 b0 d4 70 e6 10 13 5c f4 49 0e 9c 2a 52 5c 84 |...p...\.I..*R\.| +00000040 b2 55 1a ea e3 4b 5a 9f ac e9 7b 37 c0 2f 00 00 |.U...KZ...{7./..| 00000050 11 ff 01 00 01 00 00 0b 00 04 03 00 01 02 00 17 |................| 00000060 00 00 16 03 03 02 59 0b 00 02 55 00 02 52 00 02 |......Y...U..R..| 00000070 4f 30 82 02 4b 30 82 01 b4 a0 03 02 01 02 02 09 |O0..K0..........| @@ -60,33 +60,33 @@ 00000290 73 bb b3 43 77 8d 0c 1c f1 0f a1 d8 40 83 61 c9 |s..Cw.......@.a.| 000002a0 4c 72 2b 9d ae db 46 06 06 4d f4 c1 b3 3e c0 d1 |Lr+...F..M...>..| 000002b0 bd 42 d4 db fe 3d 13 60 84 5c 21 d3 3b e9 fa e7 |.B...=.`.\!.;...| -000002c0 16 03 03 00 ac 0c 00 00 a8 03 00 1d 20 3d 1d f3 |............ =..| -000002d0 d4 cb 57 6a d8 c4 23 34 84 30 2a 80 02 0c 86 de |..Wj..#4.0*.....| -000002e0 94 ae c8 78 07 f5 0c eb 61 f2 2f a6 2d 08 04 00 |...x....a./.-...| -000002f0 80 08 5e b0 4b ed 7b e1 48 45 80 6a 63 5c 1e 9a |..^.K.{.HE.jc\..| -00000300 01 4e f1 c3 92 b2 a4 83 18 ee 55 01 36 55 57 59 |.N........U.6UWY| -00000310 84 46 70 60 43 32 05 25 18 de 05 76 24 57 69 a3 |.Fp`C2.%...v$Wi.| -00000320 34 a6 bd 4c b5 45 2c 6e 63 81 a3 82 a7 4a a5 5f |4..L.E,nc....J._| -00000330 27 c2 a2 58 2b 77 9f cf cb 63 e0 2b da 75 eb 9c |'..X+w...c.+.u..| -00000340 6e 6b cd d5 ae 59 8d c8 0f c6 34 30 68 42 67 d5 |nk...Y....40hBg.| -00000350 1f e7 b1 22 60 b5 ca 4b a5 bd ce a0 44 50 df 45 |..."`..K....DP.E| -00000360 8b d8 e4 04 53 8a f8 fa 91 b2 09 fb 42 92 5f dd |....S.......B._.| -00000370 05 16 03 03 00 04 0e 00 00 00 |..........| +000002c0 16 03 03 00 ac 0c 00 00 a8 03 00 1d 20 ca 07 6e |............ ..n| +000002d0 67 12 8e f7 b4 55 c0 d4 88 73 35 f0 f1 ae c4 34 |g....U...s5....4| +000002e0 59 dc 05 df 75 96 54 f1 4f 7f 79 93 25 08 04 00 |Y...u.T.O.y.%...| +000002f0 80 d2 1d 65 15 23 74 e4 57 80 58 62 b5 6d ab 06 |...e.#t.W.Xb.m..| +00000300 11 4c e0 a0 7b 7e b5 78 87 47 71 30 c3 d8 86 b2 |.L..{~.x.Gq0....| +00000310 af 34 24 95 9c 2f 74 bb 6e c8 2a 8e 81 f8 fb d7 |.4$../t.n.*.....| +00000320 06 06 dc e8 95 01 65 fe 5d cb 9e 7f 36 9b 29 40 |......e.]...6.)@| +00000330 09 81 1b df 24 66 13 94 51 2a 48 31 e3 cb 3a 06 |....$f..Q*H1..:.| +00000340 c9 9c f4 36 b8 c0 de c1 3e 5e 79 95 f8 11 4b d8 |...6....>^y...K.| +00000350 0a b1 6c ef f4 ce 89 ba df ad 24 3d 7c 48 aa 70 |..l.......$=|H.p| +00000360 d8 0e 52 a8 12 1c 6b eb 5b c9 c3 a3 fa f0 60 d4 |..R...k.[.....`.| +00000370 54 16 03 03 00 04 0e 00 00 00 |T.........| >>> Flow 3 (client to server) 00000000 16 03 03 00 25 10 00 00 21 20 2f e5 7d a3 47 cd |....%...! /.}.G.| 00000010 62 43 15 28 da ac 5f bb 29 07 30 ff f6 84 af c4 |bC.(.._.).0.....| 00000020 cf c2 ed 90 99 5f 58 cb 3b 74 14 03 03 00 01 01 |....._X.;t......| -00000030 16 03 03 00 28 00 00 00 00 00 00 00 00 bb 7a 8d |....(.........z.| -00000040 2b 4d 9e e9 b6 b7 bf 30 e3 fd 4b e6 2e 6c ba 61 |+M.....0..K..l.a| -00000050 2b 15 58 52 d0 70 36 e5 da 64 21 28 06 |+.XR.p6..d!(.| +00000030 16 03 03 00 28 00 00 00 00 00 00 00 00 21 27 7f |....(........!'.| +00000040 32 c6 19 c4 a9 13 bf 5e 4b 53 5f c3 47 64 bb f8 |2......^KS_.Gd..| +00000050 21 d5 10 12 12 60 5e d8 e8 cf 1e fe 18 |!....`^......| >>> Flow 4 (server to client) -00000000 14 03 03 00 01 01 16 03 03 00 28 11 6b 33 c7 32 |..........(.k3.2| -00000010 9b 34 14 98 1d 90 97 cc 3a fe c1 98 f7 9d e3 dc |.4......:.......| -00000020 dc f2 e2 34 c9 5d aa 5b 02 e3 9f 33 88 5b 21 65 |...4.].[...3.[!e| -00000030 b0 f1 36 |..6| +00000000 14 03 03 00 01 01 16 03 03 00 28 af e6 ee d0 75 |..........(....u| +00000010 df 97 22 b0 ff 46 8e 51 bb 23 70 8d 4a 22 01 b6 |.."..F.Q.#p.J"..| +00000020 13 34 68 fd 69 fe 0a 0f df 0e e6 41 48 49 8c e7 |.4h.i......AHI..| +00000030 d3 21 13 |.!.| >>> Flow 5 (client to server) -00000000 17 03 03 00 1e 00 00 00 00 00 00 00 01 4b 49 39 |.............KI9| -00000010 01 d1 34 c1 b9 72 f6 25 39 c9 e6 77 5c f3 7a 4f |..4..r.%9..w\.zO| -00000020 fa f7 43 15 03 03 00 1a 00 00 00 00 00 00 00 02 |..C.............| -00000030 99 cf 0c 0e 51 f8 37 22 50 2e 98 30 bc 13 e9 f5 |....Q.7"P..0....| -00000040 d3 75 |.u| +00000000 17 03 03 00 1e 00 00 00 00 00 00 00 01 10 16 77 |...............w| +00000010 99 da 71 ef 78 16 d7 cd 2c 7b 71 ba 8a 74 c1 65 |..q.x...,{q..t.e| +00000020 f2 f6 be 15 03 03 00 1a 00 00 00 00 00 00 00 02 |................| +00000030 72 d4 4a f6 6d 63 4c ad 02 46 36 18 61 47 61 7d |r.J.mcL..F6.aGa}| +00000040 50 08 |P.| diff --git a/testdata/Client-TLSv13-AES128-SHA256 b/testdata/Client-TLSv13-AES128-SHA256 index 1097116..6c7c3d4 100644 --- a/testdata/Client-TLSv13-AES128-SHA256 +++ b/testdata/Client-TLSv13-AES128-SHA256 @@ -7,85 +7,85 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 7f 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 0a 00 08 00 1d 00 17 00 18 00 19 00 0b 00 02 01 |................| -000000a0 00 00 0d 00 1a 00 18 08 04 04 03 08 07 08 05 08 |................| -000000b0 06 04 01 05 01 06 01 05 03 06 03 02 01 02 03 ff |................| -000000c0 01 00 01 00 00 17 00 00 00 12 00 00 00 2b 00 09 |.............+..| +00000080 01 00 00 7f 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 19 00 0d |................| +000000b0 00 1a 00 18 08 04 04 03 08 07 08 05 08 06 04 01 |................| +000000c0 05 01 06 01 05 03 06 03 02 01 02 03 00 2b 00 09 |.............+..| 000000d0 08 03 04 03 03 03 02 03 01 00 33 00 26 00 24 00 |..........3.&.$.| 000000e0 1d 00 20 2f e5 7d a3 47 cd 62 43 15 28 da ac 5f |.. /.}.G.bC.(.._| 000000f0 bb 29 07 30 ff f6 84 af c4 cf c2 ed 90 99 5f 58 |.).0.........._X| 00000100 cb 3b 74 |.;t| >>> Flow 2 (server to client) -00000000 16 03 03 00 7a 02 00 00 76 03 03 0e f8 bf 2d c5 |....z...v.....-.| -00000010 14 c9 b0 54 dd 64 27 22 ce 6e e1 cb 24 46 76 5c |...T.d'".n..$Fv\| -00000020 3c 6b cf 3a 1a bb ca d9 55 18 d2 20 00 00 00 00 |...^. h..u..| -00000140 5a ba 16 71 8c 97 db 6d 90 7c 64 56 0d 29 99 16 |Z..q...m.|dV.)..| -00000150 9b f2 85 4c 84 11 b0 c4 76 f2 d8 bd 7f 19 cb 80 |...L....v.......| -00000160 ec ad 18 e0 d5 c7 a7 f7 70 08 36 c6 0c 8a 88 ef |........p.6.....| -00000170 d9 20 7e e2 b8 a7 c9 18 26 d3 8e c6 d6 48 02 1c |. ~.....&....H..| -00000180 cb 02 7b 52 93 dc 4b da 82 9d 07 b9 65 0d 2a 7a |..{R..K.....e.*z| -00000190 3a 8b 3a 3d 58 79 e2 a8 14 83 25 06 64 e0 48 71 |:.:=Xy....%.d.Hq| -000001a0 ef 2f 28 74 3f 46 04 f5 60 01 fb 53 d5 ff ca 7f |./(t?F..`..S....| -000001b0 89 4c 80 e6 e7 44 cb ad 93 d0 6a 8a 14 13 cc 09 |.L...D....j.....| -000001c0 bf 54 12 56 94 17 1e f3 c5 7a 06 d3 28 3d 61 0d |.T.V.....z..(=a.| -000001d0 1e ad d3 55 28 1e e7 f6 6a e6 da 31 3d 99 61 df |...U(...j..1=.a.| -000001e0 94 d1 1a 58 f6 06 55 0a 43 20 23 dc 58 2b d4 db |...X..U.C #.X+..| -000001f0 35 91 16 e1 29 62 e7 fd aa fe 65 d7 ef b2 a6 2b |5...)b....e....+| -00000200 6b c8 29 4b c0 94 ca bc 32 c4 d8 7a 2a 66 ea 25 |k.)K....2..z*f.%| -00000210 ee 8f fc 85 28 5f b6 1a 11 0b cb dc 57 0b 70 7e |....(_......W.p~| -00000220 58 fc f5 09 41 88 0d a0 fc 03 58 a6 e3 48 29 ed |X...A.....X..H).| -00000230 4e e4 ff cc 4b 42 fd 53 e7 e5 2d 57 0e 6a 88 96 |N...KB.S..-W.j..| -00000240 12 03 54 c3 de 8f 9a 46 98 2c ef ac cd 72 bc 7f |..T....F.,...r..| -00000250 f6 1b cb 98 d4 0c 46 32 1e 18 51 39 d1 ee bf 83 |......F2..Q9....| -00000260 71 e1 df 3a 31 82 22 2f ba 0e 69 a3 93 9d 0c 5c |q..:1."/..i....\| -00000270 8f e5 ea e8 25 26 b1 40 8e 19 0c f4 55 ff 7b cb |....%&.@....U.{.| -00000280 96 d2 0f 07 a0 da 99 38 df 63 9b 9e 33 5b 87 f2 |.......8.c..3[..| -00000290 1b f7 3f 36 e4 65 ae 95 69 0f ec fc 34 fb 1e e5 |..?6.e..i...4...| -000002a0 f7 ce 78 b0 c5 d6 94 e8 e5 ee 37 56 20 ac 58 c4 |..x.......7V .X.| -000002b0 3a 5e cd e2 7f ac 23 c6 5e 2e 45 aa 8a d5 ea 0e |:^....#.^.E.....| -000002c0 0b 1d 13 19 72 0f 8d 48 6b 2f aa 8d d3 74 bb d2 |....r..Hk/...t..| -000002d0 ff fb 46 f7 7f 7d 03 50 9e 3b a8 2d 73 c4 e5 db |..F..}.P.;.-s...| -000002e0 82 8a 48 5f b4 4e 49 35 4b 04 ca 70 35 30 c4 c9 |..H_.NI5K..p50..| -000002f0 d5 94 cb 58 e3 40 e4 8f 3f 17 f5 dd c8 80 d9 41 |...X.@..?......A| -00000300 e2 2a 7b 63 e7 87 84 9a aa 54 3c 1f 4b 64 7b 32 |.*{c.....T<.Kd{2| -00000310 17 d4 f3 17 03 03 00 99 47 1a 1f d9 17 60 17 4a |........G....`.J| -00000320 7a 68 c2 69 4f 59 6e b5 72 2f e9 a8 42 db 9c 49 |zh.iOYn.r/..B..I| -00000330 62 3c db 0c fd 49 2f 0b 4f fa de db ef 7d 5e 60 |b<...I/.O....}^`| -00000340 6b 99 39 ab b3 44 ac bc 68 2b 86 fd db 91 63 6c |k.9..D..h+....cl| -00000350 da 2f 6b 32 c4 99 b4 51 84 5c a8 0d 1d 31 05 f3 |./k2...Q.\...1..| -00000360 45 e3 b4 83 3d c8 17 2e f9 4e f7 61 6c 4b e5 d4 |E...=....N.alK..| -00000370 24 04 2e 3f c9 f4 c9 8a 2d 8f 50 d0 c2 f8 35 56 |$..?....-.P...5V| -00000380 1a 59 08 99 3d 0e 47 ea 54 44 75 d1 2b 31 28 71 |.Y..=.G.TDu.+1(q| -00000390 fb 88 69 0a d2 50 30 77 41 ab ed 29 51 58 75 87 |..i..P0wA..)QXu.| -000003a0 5a 59 bc 66 6b f3 d5 5f ad c4 26 9d e6 a8 7e 70 |ZY.fk.._..&...~p| -000003b0 b3 17 03 03 00 35 fe f7 08 e7 c6 3e 00 c3 5e a3 |.....5.....>..^.| -000003c0 87 23 df 10 46 4f bb 17 ee bf 93 df b7 6d f0 45 |.#..FO.......m.E| -000003d0 77 bf 60 6d f9 bb ce 58 f2 59 4a 40 5e d6 dd 0b |w.`m...X.YJ@^...| -000003e0 19 9a 41 8e 6b 03 16 e3 ce cd b6 |..A.k......| +00000050 2e 00 2b 00 02 03 04 00 33 00 24 00 1d 00 20 36 |..+.....3.$... 6| +00000060 e2 c3 a0 14 f4 9c 50 9c 08 03 5e c2 b8 4b 66 85 |......P...^..Kf.| +00000070 71 fb bb 20 6e 97 3a f6 74 be 02 31 29 8e 18 14 |q.. n.:.t..1)...| +00000080 03 03 00 01 01 17 03 03 00 17 00 79 2a 2d 44 f4 |...........y*-D.| +00000090 12 2d 7c d6 8c 7a 27 76 a5 3a 6b c1 2d 40 8f 20 |.-|..z'v.:k.-@. | +000000a0 8b 17 03 03 02 6d 6e 16 f8 0f d2 67 3b e8 1a 95 |.....mn....g;...| +000000b0 2a ce 16 7b 95 21 7e 03 65 bf 01 ce e9 43 83 f6 |*..{.!~.e....C..| +000000c0 0e a9 d2 f2 d1 a3 2f d4 55 d2 27 83 44 3d f9 72 |....../.U.'.D=.r| +000000d0 00 8d 41 44 eb 93 ca 68 09 d1 bd f3 1a cc a0 53 |..AD...h.......S| +000000e0 a7 18 6e b7 27 d0 f5 e1 08 d8 9f 7b 37 bc 8f b9 |..n.'......{7...| +000000f0 84 6d e0 20 cf 99 bf c1 67 c8 00 74 4c 76 3e 2d |.m. ....g..tLv>-| +00000100 63 48 11 f1 75 30 ab a5 5b a2 cb 13 e9 e0 65 36 |cH..u0..[.....e6| +00000110 86 ce 8b 64 f6 dc e1 b7 0d 16 96 d1 ec 4b 93 d5 |...d.........K..| +00000120 6c 10 0d b7 d8 a2 45 b2 f0 e0 aa ab ab 11 8d d0 |l.....E.........| +00000130 2c fc 20 35 99 1b d6 3b 72 6d 88 03 80 5c 59 d4 |,. 5...;rm...\Y.| +00000140 04 18 ee 7a ed fe fb 52 c1 3c 93 95 e2 00 23 0d |...z...R.<....#.| +00000150 cc c1 4e 0a fb 55 33 93 9f c8 31 33 29 f5 12 3e |..N..U3...13)..>| +00000160 39 62 62 27 05 cf d2 be bd 7d 42 51 97 4f 71 95 |9bb'.....}BQ.Oq.| +00000170 10 f8 eb 0f d8 d1 69 aa 22 13 a8 fe 24 f6 87 a1 |......i."...$...| +00000180 9d ca cb 8f 99 39 2b fb 99 d9 18 8a fa fa 25 20 |.....9+.......% | +00000190 df 6a b3 d1 ac ce 56 8b 76 5d a9 46 1c 0b c7 57 |.j....V.v].F...W| +000001a0 90 02 10 55 85 49 48 89 d8 d6 4b 68 29 cb 28 66 |...U.IH...Kh).(f| +000001b0 1c d1 97 e6 a0 10 90 63 83 96 33 ee 5a 5a 5b 66 |.......c..3.ZZ[f| +000001c0 ca b3 0d be 6d 70 c5 de fd 78 c8 f8 e1 c5 78 ef |....mp...x....x.| +000001d0 07 2e 60 06 28 86 ed e6 bd 7b 37 33 0e 06 5e 06 |..`.(....{73..^.| +000001e0 fb 44 2b 96 16 fe 09 30 dc 03 53 bc c9 f9 6f 1e |.D+....0..S...o.| +000001f0 4b 79 a9 ac fe 20 3f 12 58 48 0c 40 a5 2f f2 6a |Ky... ?.XH.@./.j| +00000200 ea 44 69 93 54 4f 4d 6c 98 85 b1 c5 6f 50 83 b8 |.Di.TOMl....oP..| +00000210 8a 20 e3 b9 da b7 7d e4 ec 33 28 96 29 d7 dc a3 |. ....}..3(.)...| +00000220 d0 54 76 cd a6 99 17 e8 0f 14 d2 7c 4b 68 0a 80 |.Tv........|Kh..| +00000230 4f 0b 2b b5 16 68 dc 25 42 b5 0b f7 13 6a c5 81 |O.+..h.%B....j..| +00000240 c0 18 bc fb 40 86 cc 99 2e 70 2b 9a 72 eb be 57 |....@....p+.r..W| +00000250 a0 43 92 83 3b 7e c8 02 43 ab 17 7a 73 87 1a a2 |.C..;~..C..zs...| +00000260 1c 01 db b4 31 b1 d9 44 f1 c0 d9 de 27 bd 4c 8b |....1..D....'.L.| +00000270 1c f5 3d db d6 aa 98 7d 43 fe dd 64 85 8b c1 88 |..=....}C..d....| +00000280 a9 1e f1 04 0b 5d 3b c2 fd 3f b2 27 a7 28 d1 82 |.....];..?.'.(..| +00000290 13 fb 85 46 77 78 50 45 1b 4b c0 75 f2 32 8a 6d |...FwxPE.K.u.2.m| +000002a0 52 37 2e b1 80 e9 81 3b 60 c8 88 78 11 3f 0f 96 |R7.....;`..x.?..| +000002b0 d1 4b 19 49 91 b5 70 44 2d 62 a1 04 8f 98 89 ab |.K.I..pD-b......| +000002c0 75 1f 8a 97 d5 28 dc 88 20 92 7f f2 90 16 1b de |u....(.. .......| +000002d0 54 7c 5f 05 8f c9 70 a1 f5 8c 99 09 43 ab 09 73 |T|_...p.....C..s| +000002e0 dd 5e 62 c3 9f c8 e1 fa 9e 98 65 18 b5 5e 4e f9 |.^b.......e..^N.| +000002f0 85 a4 cc dc b8 12 1b eb 0a bc bc bd 1c 2f 51 0e |............./Q.| +00000300 8f 55 f1 10 22 06 ca cb f2 97 54 63 1c 98 36 9f |.U..".....Tc..6.| +00000310 1d 66 b0 17 03 03 00 99 f0 14 4d 69 84 b3 ca d4 |.f........Mi....| +00000320 96 9c e2 3c a4 55 f4 b6 01 1f 1e 1f 77 98 c4 84 |...<.U......w...| +00000330 5e ce 4c 0b bf ba 39 6b 36 a6 15 9c d1 90 87 d1 |^.L...9k6.......| +00000340 13 39 1c dd 86 0f a0 06 f7 fc f7 c9 10 4e 46 0a |.9...........NF.| +00000350 03 12 a0 bf 3e f3 7d e6 1b b7 ce ec 16 84 52 8e |....>.}.......R.| +00000360 bc 9c 9a 4f 2f a7 d9 aa f3 d6 be 0a f8 39 2d 18 |...O/........9-.| +00000370 28 9e 35 6e 25 25 46 9b 49 61 a6 ee 6a 87 d2 5f |(.5n%%F.Ia..j.._| +00000380 54 e6 fb 96 a3 e9 8a 05 c2 fb 71 0b d7 13 2e 19 |T.........q.....| +00000390 e5 5c a2 d0 f4 b3 34 95 e1 1d 24 ef 33 a2 0a d5 |.\....4...$.3...| +000003a0 65 b2 5f 46 73 45 33 69 d6 c3 f6 49 20 e2 00 bd |e._FsE3i...I ...| +000003b0 16 17 03 03 00 35 89 2f 34 08 44 35 6a 52 1a fd |.....5./4.D5jR..| +000003c0 e4 be 2b 0e 0a dd 2d c1 e7 e3 20 7a 0a 3e 87 1d |..+...-... z.>..| +000003d0 2b 64 87 c5 11 54 46 1a 5c 89 e2 97 3f 83 b2 b4 |+d...TF.\...?...| +000003e0 04 ed d2 c4 1d 3d 37 1f e1 62 f2 |.....=7..b.| >>> Flow 3 (client to server) -00000000 14 03 03 00 01 01 17 03 03 00 35 3c 85 dc 33 0a |..........5<..3.| -00000010 bd 78 f0 fc 0a 07 3a 9e a5 31 ca b8 f6 23 d5 26 |.x....:..1...#.&| -00000020 2a 60 ce d9 d2 da 37 e5 e8 27 bb 99 a3 43 ad 66 |*`....7..'...C.f| -00000030 e2 07 33 de ca dc 2f d4 73 f4 71 50 d0 99 3b 7d |..3.../.s.qP..;}| -00000040 17 03 03 00 17 de 7a 55 7a 1d e3 1e 51 10 df 9e |......zUz...Q...| -00000050 30 a6 b9 15 79 b4 20 82 01 e5 b2 34 17 03 03 00 |0...y. ....4....| -00000060 13 85 50 af bc 99 0b eb 84 58 b9 6c 46 88 22 b0 |..P......X.lF.".| -00000070 7e 42 79 01 |~By.| +00000000 14 03 03 00 01 01 17 03 03 00 35 07 8e f6 0b 41 |..........5....A| +00000010 be 74 45 99 5e 35 59 4f 2e 59 d4 37 77 ca 53 d4 |.tE.^5YO.Y.7w.S.| +00000020 fd 33 bf dc 65 85 ee ad c5 d6 94 7e 6e e8 02 cf |.3..e......~n...| +00000030 15 d2 04 cb e1 9f 5e 94 dd 5f 37 17 95 17 0c b7 |......^.._7.....| +00000040 17 03 03 00 17 1f aa e9 7d 34 dc 12 da 3b cb dd |........}4...;..| +00000050 1c d3 b0 f1 79 ad cc 66 06 64 69 21 17 03 03 00 |....y..f.di!....| +00000060 13 b7 c7 a2 01 48 27 3a 44 e6 c6 47 a9 19 5f d2 |.....H':D..G.._.| +00000070 f8 96 98 70 |...p| diff --git a/testdata/Client-TLSv13-AES256-SHA384 b/testdata/Client-TLSv13-AES256-SHA384 index 39b2e09..c5bac35 100644 --- a/testdata/Client-TLSv13-AES256-SHA384 +++ b/testdata/Client-TLSv13-AES256-SHA384 @@ -7,87 +7,87 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 7f 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 0a 00 08 00 1d 00 17 00 18 00 19 00 0b 00 02 01 |................| -000000a0 00 00 0d 00 1a 00 18 08 04 04 03 08 07 08 05 08 |................| -000000b0 06 04 01 05 01 06 01 05 03 06 03 02 01 02 03 ff |................| -000000c0 01 00 01 00 00 17 00 00 00 12 00 00 00 2b 00 09 |.............+..| +00000080 01 00 00 7f 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 19 00 0d |................| +000000b0 00 1a 00 18 08 04 04 03 08 07 08 05 08 06 04 01 |................| +000000c0 05 01 06 01 05 03 06 03 02 01 02 03 00 2b 00 09 |.............+..| 000000d0 08 03 04 03 03 03 02 03 01 00 33 00 26 00 24 00 |..........3.&.$.| 000000e0 1d 00 20 2f e5 7d a3 47 cd 62 43 15 28 da ac 5f |.. /.}.G.bC.(.._| 000000f0 bb 29 07 30 ff f6 84 af c4 cf c2 ed 90 99 5f 58 |.).0.........._X| 00000100 cb 3b 74 |.;t| >>> Flow 2 (server to client) -00000000 16 03 03 00 7a 02 00 00 76 03 03 fc b2 8e 30 c0 |....z...v.....0.| -00000010 a2 bd d8 1c 4b 68 bc e0 a1 56 5f 5b 05 54 b7 7a |....Kh...V_[.T.z| -00000020 60 9a 49 68 f5 f4 f0 b1 49 27 79 20 00 00 00 00 |`.Ih....I'y ....| +00000000 16 03 03 00 7a 02 00 00 76 03 03 3d 39 60 81 a4 |....z...v..=9`..| +00000010 cc 92 5d fd 8b 21 58 da 2e 4c e2 70 2b 12 d2 8c |..]..!X..L.p+...| +00000020 35 55 bc ba 79 c1 9e 6f 78 8c cf 20 00 00 00 00 |5U..y..ox.. ....| 00000030 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |................| 00000040 00 00 00 00 00 00 00 00 00 00 00 00 13 02 00 00 |................| -00000050 2e 00 2b 00 02 03 04 00 33 00 24 00 1d 00 20 d3 |..+.....3.$... .| -00000060 d7 9e 72 ae 5f f9 92 24 6b 76 e5 a1 00 71 78 cf |..r._..$kv...qx.| -00000070 e9 55 29 5b fe a8 71 14 e9 02 b0 65 12 e8 04 14 |.U)[..q....e....| -00000080 03 03 00 01 01 17 03 03 00 17 24 a0 73 a6 7b ab |..........$.s.{.| -00000090 9c d8 69 e7 15 68 4b 26 0a 15 0c ff c4 40 7d b8 |..i..hK&.....@}.| -000000a0 ad 17 03 03 02 6d 05 b2 f9 6e 05 48 18 92 2b 87 |.....m...n.H..+.| -000000b0 29 1c 5b 8c a8 ae 0e 4b fc 3b 1e b9 2c c2 0c 33 |).[....K.;..,..3| -000000c0 f8 5d 16 37 39 b3 b2 4e 12 a4 02 4c fb 3b 16 4e |.].79..N...L.;.N| -000000d0 63 92 72 56 49 d6 5b 63 34 20 67 c8 07 a2 b6 0d |c.rVI.[c4 g.....| -000000e0 f1 06 b4 bd 88 54 4d 33 66 1a d4 fc 42 9c 4e 00 |.....TM3f...B.N.| -000000f0 40 34 5d cf c4 5d f1 ba 14 de 34 50 f5 2f 3d b7 |@4]..]....4P./=.| -00000100 1c 17 33 6e 9a 2b 39 1b f1 a6 0d fb b7 0c c3 b3 |..3n.+9.........| -00000110 02 f8 0c 30 e8 31 d7 ee bf a1 a0 64 28 67 64 50 |...0.1.....d(gdP| -00000120 24 ce 37 fd 15 2e c7 13 1b 8b f0 22 19 e4 ec c8 |$.7........"....| -00000130 8c b0 76 b8 d0 2d 87 99 86 8b ec ca e9 9d 8f 23 |..v..-.........#| -00000140 bf 3d bf b8 ed 85 34 85 31 15 dd 7a 36 f7 3e 0e |.=....4.1..z6.>.| -00000150 df e7 4c e8 ae 5a 98 05 f8 34 76 33 c3 4c 81 fb |..L..Z...4v3.L..| -00000160 d8 29 14 b3 47 32 eb 5f 73 5a 95 4a c7 3d 89 2a |.)..G2._sZ.J.=.*| -00000170 21 22 bd 97 b2 9d 4b dd 2c eb a5 e3 37 d6 a9 84 |!"....K.,...7...| -00000180 0c b6 02 2f 1f 5c 18 1b be 92 be 58 a7 e1 a0 49 |.../.\.....X...I| -00000190 95 dc d7 07 70 b1 5b 15 86 3f 55 fc ad 32 39 5d |....p.[..?U..29]| -000001a0 95 63 fd d4 85 55 b2 e9 c2 68 d0 09 f9 53 f9 4f |.c...U...h...S.O| -000001b0 0e 89 1c a0 85 74 7f 10 97 e7 86 8a 18 28 83 e6 |.....t.......(..| -000001c0 66 3c 2a f5 8f 14 1d 90 58 ef ad 1f d3 7f 42 0a |f<*.....X.....B.| -000001d0 08 d5 b4 96 b0 9d 3f 72 49 5a 06 13 7c 4b bc 79 |......?rIZ..|K.y| -000001e0 8c db 1f 1f 5e 3d c2 fe ad 57 e6 d9 14 bb d0 72 |....^=...W.....r| -000001f0 d7 90 14 35 ec 34 31 f6 fd b1 fd 3d 46 6e 4f a7 |...5.41....=FnO.| -00000200 1e 7d 14 40 17 0c ef c0 c8 70 fe dc 6a f1 78 6a |.}.@.....p..j.xj| -00000210 c6 df 70 2e ac 07 d9 6d f7 90 0e 4a 92 08 cf 88 |..p....m...J....| -00000220 26 c0 11 4a 7d e4 34 ba 86 43 cb 94 f8 d7 61 5a |&..J}.4..C....aZ| -00000230 05 f5 f9 49 b4 04 f1 c8 43 b6 12 52 ae cf 7c b9 |...I....C..R..|.| -00000240 39 d1 90 91 6e 80 43 cf 4c 23 3d 7c c0 c8 88 46 |9...n.C.L#=|...F| -00000250 e2 91 86 e4 41 cb ed f2 3a 92 01 9f 04 7c d2 81 |....A...:....|..| -00000260 42 18 6c 04 91 25 8a 29 0e d9 23 aa 58 e5 e8 ee |B.l..%.)..#.X...| -00000270 39 79 a5 a7 3a 4d e3 cc 15 79 3f 7b f9 e4 21 76 |9y..:M...y?{..!v| -00000280 5c 9a d8 de d3 9a f3 9e 69 44 c0 2a 56 04 b4 d2 |\.......iD.*V...| -00000290 c3 c1 4c d6 ad b8 d8 ad c8 c2 0d fa ea e1 bc 11 |..L.............| -000002a0 67 15 80 ef c6 01 48 7f de f1 c2 36 a7 dd a9 38 |g.....H....6...8| -000002b0 31 8b 14 ed 5c 2a 66 55 3b 25 e3 85 cb d9 a9 82 |1...\*fU;%......| -000002c0 7a 95 99 b3 c8 aa ac 66 30 b0 c5 3d d1 2a ab b9 |z......f0..=.*..| -000002d0 56 b3 5e 9d e0 d7 81 ac 6f 2e ae 62 a2 ef ca ef |V.^.....o..b....| -000002e0 7b cf 0f af f6 0b 29 97 2d 27 33 58 ad b6 1b d2 |{.....).-'3X....| -000002f0 0a c7 11 ec 89 b0 0d 2e ff 27 64 c2 bf 8e 85 a4 |.........'d.....| -00000300 ea 14 52 71 55 1a ec ef 0d ff 14 00 ce 3d 9d 3d |..RqU........=.=| -00000310 a9 d3 17 17 03 03 00 99 5e ba 1f f3 93 71 7a 88 |........^....qz.| -00000320 bc 14 71 7e 85 15 c9 da fe ee c1 b1 3d f6 ff 67 |..q~........=..g| -00000330 fd 28 96 f3 44 44 6f 8f 32 b4 22 be 69 29 e6 dd |.(..DDo.2.".i)..| -00000340 60 07 1d 98 0b 0c 0f ec df fa 46 c0 67 66 f2 18 |`.........F.gf..| -00000350 bf 5e 36 56 b2 b2 25 ef aa 76 51 ea f7 47 1d ee |.^6V..%..vQ..G..| -00000360 7b 25 e5 97 89 4a 04 07 f8 ff 05 73 25 71 e4 28 |{%...J.....s%q.(| -00000370 9e 91 45 ff 4c df 82 dc 85 16 02 ba 15 9b 37 91 |..E.L.........7.| -00000380 eb 65 12 66 38 59 8a 85 a2 2e af 2f d7 74 75 c1 |.e.f8Y...../.tu.| -00000390 7e f6 64 87 7e 4c 86 c8 25 bb 59 8d f8 9c e3 e5 |~.d.~L..%.Y.....| -000003a0 a4 53 a5 c6 00 bd 78 d8 07 0e f5 42 92 e3 42 11 |.S....x....B..B.| -000003b0 57 17 03 03 00 45 77 98 db b2 e4 66 e3 dc 3e 4f |W....Ew....f..>O| -000003c0 49 92 b3 ac 74 cd 1c 3b e2 81 3c 64 0b a5 c9 8c |I...t..;..4.3I8..| +000002a0 d1 04 b4 13 a8 5f 0b f2 41 77 d4 c8 b2 d3 0e d6 |....._..Aw......| +000002b0 8c dc 34 ad 2a d9 4b 5f 4a e2 17 0a be 2a 55 4a |..4.*.K_J....*UJ| +000002c0 44 a7 b0 0f d1 39 b0 e5 9d 77 6b d7 44 15 99 bf |D....9...wk.D...| +000002d0 c8 02 57 90 5b 73 29 fe ab 85 93 c3 dc 1c b0 b2 |..W.[s).........| +000002e0 14 78 01 99 f5 d2 db ef ae 0e 2a d9 17 1e 70 fa |.x........*...p.| +000002f0 bb 74 fe 93 a0 aa ff 79 cd 8b 6d 3d 79 66 d2 c8 |.t.....y..m=yf..| +00000300 90 c7 2c e6 54 26 de f7 4d b8 a7 73 cd 92 fc 42 |..,.T&..M..s...B| +00000310 ad 4e ff 17 03 03 00 99 c6 07 36 ce 58 9c fe 38 |.N........6.X..8| +00000320 aa b4 5c c8 8e f5 11 19 82 4c 4b 2b 0a 08 be 3f |..\......LK+...?| +00000330 11 76 06 4b d3 1b b7 fc 66 d9 db de fb 6a ee 29 |.v.K....f....j.)| +00000340 f6 a5 4b 96 f3 3c a0 67 44 73 d4 46 c5 d4 a1 f8 |..K..<.gDs.F....| +00000350 71 36 7c a5 62 79 fc be f9 34 55 85 31 8f fc e3 |q6|.by...4U.1...| +00000360 46 be 64 1e 2d 1b 21 c3 89 8e 1c cc df 30 05 57 |F.d.-.!......0.W| +00000370 2e d5 d5 67 11 10 46 1a af 99 01 0e fd 40 53 1f |...g..F......@S.| +00000380 b0 f0 76 3e 8e c1 7a 6a fe fe ef c1 08 6e ea 9b |..v>..zj.....n..| +00000390 75 6c 62 86 07 50 ee 1f ef 3b 55 fd 68 44 47 27 |ulb..P...;U.hDG'| +000003a0 07 c1 53 b5 13 c5 e0 a4 d6 9e 8a 3c 78 a0 04 b7 |..S........>> Flow 3 (client to server) -00000000 14 03 03 00 01 01 17 03 03 00 45 75 66 f7 1c cc |..........Euf...| -00000010 a5 d2 e0 60 37 ff ab 89 16 88 c1 27 ba 57 0c 0d |...`7......'.W..| -00000020 28 c9 c3 8a 53 57 05 1c 2a 47 52 b6 98 f9 26 4f |(...SW..*GR...&O| -00000030 34 7c 7a 71 00 87 47 c3 a5 b8 0c 8c 03 87 5e de |4|zq..G.......^.| -00000040 a1 40 33 9b e1 7f ad 36 71 10 9a e7 28 45 e1 e2 |.@3....6q...(E..| -00000050 17 03 03 00 17 a3 83 88 cd fa fc f4 60 12 e7 be |............`...| -00000060 8d 11 31 74 3f 25 3e 32 6f 7f 73 57 17 03 03 00 |..1t?%>2o.sW....| -00000070 13 7f ab 29 bc f6 7e ea f7 17 ee 7a ef 38 ff bc |...)..~....z.8..| -00000080 82 68 f5 07 |.h..| +00000000 14 03 03 00 01 01 17 03 03 00 45 ee 00 18 db 1e |..........E.....| +00000010 67 aa 0f 9e 5c 20 7d 25 27 49 e8 d5 60 02 78 7b |g...\ }%'I..`.x{| +00000020 23 58 70 67 67 93 ca 4d 50 69 b1 cf d9 dc 31 d3 |#Xpgg..MPi....1.| +00000030 03 36 b0 07 39 59 52 e1 c7 36 6d 16 0b 56 03 c6 |.6..9YR..6m..V..| +00000040 a0 ec 0e 6b ed de 7b ba 51 96 83 b6 b8 77 8f 6a |...k..{.Q....w.j| +00000050 17 03 03 00 17 77 f6 6f 83 00 ad eb be 16 26 3d |.....w.o......&=| +00000060 27 e8 58 73 a2 bc 11 ff 14 54 4a 15 17 03 03 00 |'.Xs.....TJ.....| +00000070 13 bc 94 3f 6e ee 1b 40 b0 2e 03 13 47 28 38 4d |...?n..@....G(8M| +00000080 2d 26 5d 15 |-&].| diff --git a/testdata/Client-TLSv13-ALPN b/testdata/Client-TLSv13-ALPN index b291259..f40340a 100644 --- a/testdata/Client-TLSv13-ALPN +++ b/testdata/Client-TLSv13-ALPN @@ -7,87 +7,87 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 93 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 0a 00 08 00 1d 00 17 00 18 00 19 00 0b 00 02 01 |................| -000000a0 00 00 0d 00 1a 00 18 08 04 04 03 08 07 08 05 08 |................| -000000b0 06 04 01 05 01 06 01 05 03 06 03 02 01 02 03 ff |................| -000000c0 01 00 01 00 00 17 00 00 00 10 00 10 00 0e 06 70 |...............p| -000000d0 72 6f 74 6f 32 06 70 72 6f 74 6f 31 00 12 00 00 |roto2.proto1....| +00000080 01 00 00 93 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 19 00 0d |................| +000000b0 00 1a 00 18 08 04 04 03 08 07 08 05 08 06 04 01 |................| +000000c0 05 01 06 01 05 03 06 03 02 01 02 03 00 10 00 10 |................| +000000d0 00 0e 06 70 72 6f 74 6f 32 06 70 72 6f 74 6f 31 |...proto2.proto1| 000000e0 00 2b 00 09 08 03 04 03 03 03 02 03 01 00 33 00 |.+............3.| 000000f0 26 00 24 00 1d 00 20 2f e5 7d a3 47 cd 62 43 15 |&.$... /.}.G.bC.| 00000100 28 da ac 5f bb 29 07 30 ff f6 84 af c4 cf c2 ed |(.._.).0........| 00000110 90 99 5f 58 cb 3b 74 |.._X.;t| >>> Flow 2 (server to client) -00000000 16 03 03 00 7a 02 00 00 76 03 03 90 3b d5 53 eb |....z...v...;.S.| -00000010 af 38 68 af fc 8f 47 f5 3f 13 5c c5 46 9d 97 b7 |.8h...G.?.\.F...| -00000020 e2 c4 0c 93 d4 91 2b 45 77 11 1b 20 00 00 00 00 |......+Ew.. ....| +00000000 16 03 03 00 7a 02 00 00 76 03 03 c2 2e 95 0c cf |....z...v.......| +00000010 63 40 d8 a0 bd 51 27 e2 62 79 72 26 b1 d4 38 5b |c@...Q'.byr&..8[| +00000020 50 03 66 d2 2e 8e 46 b7 cf 40 0a 20 00 00 00 00 |P.f...F..@. ....| 00000030 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |................| 00000040 00 00 00 00 00 00 00 00 00 00 00 00 13 03 00 00 |................| -00000050 2e 00 2b 00 02 03 04 00 33 00 24 00 1d 00 20 a6 |..+.....3.$... .| -00000060 5a 75 77 6c 3a 65 d9 7d c4 72 ef 66 3e 15 80 e4 |Zuwl:e.}.r.f>...| -00000070 b6 c5 55 2e fb cf 3a 17 9e 28 de de b1 ce 06 14 |..U...:..(......| -00000080 03 03 00 01 01 17 03 03 00 24 45 28 86 50 9e 48 |.........$E(.P.H| -00000090 66 13 75 a6 43 19 b2 ce 79 2b 5c 06 d0 f7 ff 4c |f.u.C...y+\....L| -000000a0 d5 bb 39 67 50 aa 78 97 1b 5a 58 a7 95 44 17 03 |..9gP.x..ZX..D..| -000000b0 03 02 6d 10 9e 3c f4 7e c6 2d e4 2a 04 10 95 dd |..m..<.~.-.*....| -000000c0 47 56 02 08 91 5e 60 c5 5c eb a1 65 f0 9d a6 2a |GV...^`.\..e...*| -000000d0 55 bc fe 58 1a b0 3e f9 d6 f0 1c 7c 70 c5 bf 14 |U..X..>....|p...| -000000e0 3c c7 bf a4 ac f8 c5 77 1c 7b f2 bb 15 01 f8 c6 |<......w.{......| -000000f0 2c 19 dd 22 29 3b 32 09 33 b7 c5 be 2e 9b 43 7c |,..");2.3.....C|| -00000100 1f b7 a2 99 09 e6 42 c3 13 b0 10 2b 15 e8 8a 89 |......B....+....| -00000110 62 ac 27 b1 09 cc e3 78 67 07 8e c9 21 d4 17 df |b.'....xg...!...| -00000120 dc db 30 9b 8e a4 6f 8e fb 1b 5a d9 22 b0 5d 9b |..0...o...Z.".].| -00000130 f1 d0 c7 d6 5e 64 00 23 36 96 8e 22 39 ab 52 3a |....^d.#6.."9.R:| -00000140 10 02 c3 6b 02 c7 87 8f cd 45 40 18 26 41 ca 06 |...k.....E@.&A..| -00000150 36 09 59 fc 0c d8 fc fe 35 b6 fb 9e 2a e3 db 29 |6.Y.....5...*..)| -00000160 dc 1b 89 08 f2 e5 06 a1 2a 62 cb 89 39 be 30 47 |........*b..9.0G| -00000170 81 5d 12 5d e5 f2 38 ae f9 6a 0a bc b6 7d 1a fc |.].]..8..j...}..| -00000180 62 24 1f ab 25 1a 81 4e 29 c1 32 89 9e 75 3d e9 |b$..%..N).2..u=.| -00000190 aa a7 ab 15 0f eb f6 e6 a4 1c c2 c6 48 8b 88 a9 |............H...| -000001a0 24 34 92 49 f9 85 4e 2c b5 eb 69 d7 55 db e5 b6 |$4.I..N,..i.U...| -000001b0 ec 09 5d 08 b0 d3 8f 0c 01 47 46 3f f8 ae eb ef |..]......GF?....| -000001c0 72 37 2e 48 03 5a 03 ed 1c 5e 6e be 59 f1 16 98 |r7.H.Z...^n.Y...| -000001d0 f9 0e 3e 04 6d 9f 53 72 29 62 5b b3 f1 b9 1a 72 |..>.m.Sr)b[....r| -000001e0 61 06 ad 97 e1 e1 31 d4 ae a0 92 02 27 94 66 ca |a.....1.....'.f.| -000001f0 21 37 dd 2e a4 b4 4b 8f 7d 47 1c 3c 3d 14 ca 92 |!7....K.}G.<=...| -00000200 e3 fc 9f 73 4f 17 3e 2a 62 9b 45 bd 5d 6b d2 90 |...sO.>*b.E.]k..| -00000210 b4 77 5b 61 81 52 10 b6 d4 0e 48 f4 d1 b4 a5 eb |.w[a.R....H.....| -00000220 4c c2 29 dd e0 74 b0 2b d0 28 09 65 bc f2 f4 12 |L.)..t.+.(.e....| -00000230 6d 25 c7 7d 84 39 4a 2a 36 4e 4c 94 bb 02 66 2e |m%.}.9J*6NL...f.| -00000240 58 17 0c 3d 1f aa 6b 25 92 d5 a3 39 9c 50 28 43 |X..=..k%...9.P(C| -00000250 5c 39 17 34 4a 59 f9 6c 65 a3 4d 35 74 65 11 04 |\9.4JY.le.M5te..| -00000260 25 99 d1 42 93 70 95 28 6f 59 a0 13 95 2c bb 79 |%..B.p.(oY...,.y| -00000270 05 dd 8c 82 e1 08 57 6d c4 8e fc c4 f5 49 17 1f |......Wm.....I..| -00000280 94 4c cc ea 6f cd ab a9 33 ed 4b fa 47 02 1a f2 |.L..o...3.K.G...| -00000290 5b 64 8d 3f e4 65 ea 78 82 78 f0 0d eb 74 c1 cc |[d.?.e.x.x...t..| -000002a0 25 f7 d4 7c 74 fc 8d 53 76 f6 fb 31 62 8d d6 83 |%..|t..Sv..1b...| -000002b0 57 56 43 dc 40 51 94 b0 44 db d2 7f f3 fe 58 ff |WVC.@Q..D.....X.| -000002c0 c5 13 22 aa bf 77 ea 16 93 85 b0 89 cf b2 1d 0b |.."..w..........| -000002d0 8c 89 9f 4c 68 43 98 53 c0 97 ba aa 82 d0 e5 e4 |...LhC.S........| -000002e0 ce 8d 16 91 46 c0 ff 38 1f 2d 3d cd 9e 65 c9 7d |....F..8.-=..e.}| -000002f0 a2 b6 21 b3 55 9d 2c ff b5 c7 aa cb 5a 51 ce e6 |..!.U.,.....ZQ..| -00000300 5c 6f 72 58 fc 8d 49 68 13 b3 a9 14 03 8a 89 ff |\orX..Ih........| -00000310 1e 05 91 a3 30 64 3a 10 06 c8 1f b0 b8 b6 4d 95 |....0d:.......M.| -00000320 17 03 03 00 99 2f cd 21 80 f7 39 77 c5 ed 5f b8 |...../.!..9w.._.| -00000330 75 fb bd 82 f1 84 09 d3 bc 2f 21 f6 d3 a2 4b b1 |u......../!...K.| -00000340 e4 67 59 7d db 64 47 20 19 9b 9d 68 33 4a 9d e1 |.gY}.dG ...h3J..| -00000350 c5 ec cc ab 66 25 a2 1b 89 6c a6 03 b6 20 3d c6 |....f%...l... =.| -00000360 03 fd 12 80 70 b9 e5 2e 27 c8 25 d2 00 00 4e e9 |....p...'.%...N.| -00000370 1a 65 4a 52 31 a0 3f e6 7c fc 77 48 83 76 11 34 |.eJR1.?.|.wH.v.4| -00000380 c1 71 36 0d 56 13 7f a2 3c 4a ac 5c 73 82 b1 f5 |.q6.V...F.P.$r*d...| +000000b0 03 02 6d 40 bc da 1a 9c 8b d7 15 24 4f d4 c1 9c |..m@.......$O...| +000000c0 8b 3c 8b 51 37 41 46 a8 cb b4 9c 50 c0 be 72 ef |.<.Q7AF....P..r.| +000000d0 81 d3 7f ed ec 96 e2 c2 08 0e 7e 23 95 c3 4f 79 |..........~#..Oy| +000000e0 01 2d 26 81 c1 ba d0 58 61 d8 c5 b7 e7 79 4f 3e |.-&....Xa....yO>| +000000f0 d8 c1 07 ae de 6a 1e 78 eb 9d 8c a1 2a 57 9c 56 |.....j.x....*W.V| +00000100 1f 6c 6e bb 2d 70 6d 55 92 10 3f 39 7e 8a d2 30 |.ln.-pmU..?9~..0| +00000110 e5 1c 4b df c0 96 d0 de 16 09 c6 34 23 16 54 a8 |..K........4#.T.| +00000120 f5 0a 1a af 9a 27 60 89 19 6a 3e 69 12 de 76 4c |.....'`..j>i..vL| +00000130 88 f2 ca 6c 0b 94 b8 d2 bc 09 f0 d3 86 74 3c 3f |...l.........tq..| +00000290 5c 9a b7 6b f2 d0 1e 55 2c 1c ac 5d 21 64 a2 d2 |\..k...U,..]!d..| +000002a0 a9 dd a8 49 7c 22 26 8e ca 75 a3 ef 52 42 d0 38 |...I|"&..u..RB.8| +000002b0 f4 02 60 af ee 33 30 46 90 a5 b3 7a 66 c8 ab 10 |..`..30F...zf...| +000002c0 3f 76 d1 76 aa 5d da c4 29 ca d7 22 c4 44 b4 e8 |?v.v.]..)..".D..| +000002d0 64 b6 6d 0f 16 cd d9 e9 62 17 91 64 03 0f 99 8f |d.m.....b..d....| +000002e0 c6 97 c8 4b c9 45 c4 31 e4 1f a8 b0 aa 67 02 e7 |...K.E.1.....g..| +000002f0 20 68 2a 89 f9 b8 e8 ce 93 d0 a3 1b 0d d1 4c 45 | h*...........LE| +00000300 c2 19 ac aa 87 43 95 ae c4 56 56 fe 4b 0e af db |.....C...VV.K...| +00000310 08 6a 14 8e 8b 7e 64 9d 6d 6e 0f 78 7c e4 f8 51 |.j...~d.mn.x|..Q| +00000320 17 03 03 00 99 2d 7b fa e6 dc da 89 93 da 93 91 |.....-{.........| +00000330 9c 25 08 50 66 eb a7 e4 f1 20 da 33 e5 cd a5 89 |.%.Pf.... .3....| +00000340 00 a7 47 9c 84 e6 cf 6d e1 86 02 af fb 54 ff b3 |..G....m.....T..| +00000350 b5 a4 e1 46 1a 3a 89 ad f0 c4 63 fe d2 eb bb 6c |...F.:....c....l| +00000360 6e cc a9 95 b0 e4 df f8 44 46 16 43 07 d7 8e 6e |n.......DF.C...n| +00000370 9b ee 0b 22 7a 23 f4 b8 3e fd fe 99 13 9d 18 bc |..."z#..>.......| +00000380 77 99 2f 90 21 a1 5f cc 9f 08 e2 75 44 2f bf 58 |w./.!._....uD/.X| +00000390 70 f2 95 b2 13 20 f3 ed 51 de e8 02 c6 ca 44 57 |p.... ..Q.....DW| +000003a0 eb 0b 9f 3e 61 f1 1a 6e 6b 13 f5 14 f3 43 19 f6 |...>a..nk....C..| +000003b0 7d 46 3a 73 49 2f fd 83 c3 68 c7 ba b4 e8 17 03 |}F:sI/...h......| +000003c0 03 00 35 67 2b 2b 9b f0 f3 d9 09 c4 01 20 ea 22 |..5g++....... ."| +000003d0 c9 7c e6 7a ce 3f 7f 84 c2 1f 6e eb d6 ce 85 b8 |.|.z.?....n.....| +000003e0 2c 3c 9f 77 8b 37 11 dd 64 d1 ae ba 85 50 7e ba |,<.w.7..d....P~.| +000003f0 14 a9 05 ff 82 3b e5 7d |.....;.}| >>> Flow 3 (client to server) -00000000 14 03 03 00 01 01 17 03 03 00 35 fc ac 12 d4 36 |..........5....6| -00000010 13 c6 fe 02 f8 ea 05 0b 5c cb 31 d4 8d ee ba 6f |........\.1....o| -00000020 36 ac aa 89 b9 10 f3 b3 a1 89 03 0e d2 5a 92 c7 |6............Z..| -00000030 62 4c 56 0c 42 69 68 a5 d7 79 cc b5 24 25 7b 80 |bLV.Bih..y..$%{.| -00000040 17 03 03 00 17 a3 f6 4f 1d 36 bb 5f 0b 59 12 ef |.......O.6._.Y..| -00000050 72 d4 c6 1d c8 82 94 1d f2 9c 46 d5 17 03 03 00 |r.........F.....| -00000060 13 3c 66 6b 59 a1 b2 e9 47 e8 06 fe 15 3f 0c 39 |.>> Flow 2 (server to client) -00000000 16 03 03 00 7a 02 00 00 76 03 03 ce bd 20 50 3d |....z...v.... P=| -00000010 7e 80 5d e3 c4 d1 f4 d7 9b 28 0d ad c7 2c c9 b0 |~.]......(...,..| -00000020 bb 25 e4 98 56 77 9a dd 7c 2e e7 20 00 00 00 00 |.%..Vw..|.. ....| +00000000 16 03 03 00 7a 02 00 00 76 03 03 3d 50 78 7e 02 |....z...v..=Px~.| +00000010 dc 79 3a 32 6b 6a 50 24 90 65 72 5e cd fc 96 18 |.y:2kjP$.er^....| +00000020 e1 47 21 43 50 5a 32 0f cf e7 ae 20 00 00 00 00 |.G!CPZ2.... ....| 00000030 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |................| 00000040 00 00 00 00 00 00 00 00 00 00 00 00 13 03 00 00 |................| -00000050 2e 00 2b 00 02 03 04 00 33 00 24 00 1d 00 20 75 |..+.....3.$... u| -00000060 35 5d ce ae 93 0b e6 2c c7 aa 67 6d 9d bd b2 8d |5].....,..gm....| -00000070 83 ac 17 7c 21 21 b2 c1 dc a1 4d 54 72 66 05 14 |...|!!....MTrf..| -00000080 03 03 00 01 01 17 03 03 00 17 88 68 f2 3c 98 b5 |...........h.<..| -00000090 ef 6e 2b ba aa d3 d4 0c 28 aa 3a 6f 51 a7 dc 89 |.n+.....(.:oQ...| -000000a0 fb 17 03 03 02 6d ae f6 44 17 0d 3b ee 41 5b a9 |.....m..D..;.A[.| -000000b0 d2 63 7c 98 25 e7 ca 46 29 05 9e 75 9f 71 58 99 |.c|.%..F)..u.qX.| -000000c0 57 a3 c3 88 08 54 88 ea 8f ea ca 87 88 c0 53 d7 |W....T........S.| -000000d0 de b6 3d 14 98 64 1a 6b 8f 90 e7 6a 10 e2 4b 42 |..=..d.k...j..KB| -000000e0 13 59 f0 bc a0 74 3b 5b a8 15 74 3a 30 9f 28 ed |.Y...t;[..t:0.(.| -000000f0 b2 a0 48 15 5a 3b 0c 61 26 4e 3f 5a 33 3d d9 88 |..H.Z;.a&N?Z3=..| -00000100 97 9f fe 2a d5 df f7 01 40 84 75 90 89 7d 34 23 |...*....@.u..}4#| -00000110 3e 70 85 82 94 b7 21 94 e6 0c d1 f1 88 06 ff 34 |>p....!........4| -00000120 64 2f e5 e6 80 10 2b 0c fe 18 f5 2c cc b0 27 37 |d/....+....,..'7| -00000130 2b 5a 4b 43 e8 b7 ad 97 a0 8c d1 49 bb f9 4a 65 |+ZKC.......I..Je| -00000140 99 bf cd 7f 77 ef 0f b6 d7 91 ce 4d 53 79 d0 5e |....w......MSy.^| -00000150 b7 51 5e 8d 0f 13 85 53 7d 81 27 b2 e1 5a e0 d0 |.Q^....S}.'..Z..| -00000160 d9 b0 3b c6 30 15 ac 3e 60 7f 01 90 da b1 c5 8c |..;.0..>`.......| -00000170 06 7c 8f 31 86 7e 53 5b 1a 4b 8f d0 ff 2c f9 9e |.|.1.~S[.K...,..| -00000180 c4 08 02 12 e4 97 af 3f 07 d0 25 0d 50 90 21 1f |.......?..%.P.!.| -00000190 fa 8d ea 02 16 a4 56 2e 2b e1 3f c2 e2 f5 53 d0 |......V.+.?...S.| -000001a0 6e a2 d4 b9 b6 ae 69 12 74 d4 2f 8f 55 1e 5f b8 |n.....i.t./.U._.| -000001b0 1f b6 29 ee 11 21 81 9f 37 6e 40 b1 27 22 15 7b |..)..!..7n@.'".{| -000001c0 ba bb bd ee 7a 7e 1f e4 7e 63 a1 60 53 a1 c7 0f |....z~..~c.`S...| -000001d0 f8 2e c3 07 cd 60 ec 83 0f 18 55 50 5c 11 ec 93 |.....`....UP\...| -000001e0 85 dd 38 5c 7e 4a 0a af 4b c9 22 8d 43 ce 76 62 |..8\~J..K.".C.vb| -000001f0 d7 73 3f ef 67 2d 6a 02 bd b5 8f c4 8b 64 b1 a3 |.s?.g-j......d..| -00000200 c4 40 c1 ea 7e 57 b9 25 45 61 96 97 69 69 9f 2b |.@..~W.%Ea..ii.+| -00000210 a7 56 b5 8b 80 25 3e 3c 73 14 b2 21 10 ee 47 cd |.V...%>....| -00000300 e2 01 51 80 b3 de cb ac 67 41 cb e9 92 4b ba 18 |..Q.....gA...K..| -00000310 c5 58 f4 17 03 03 00 99 9c bf 47 cb 60 c1 51 50 |.X........G.`.QP| -00000320 73 87 10 02 5b e7 b4 f5 4f 60 65 de 44 ae 5c 15 |s...[...O`e.D.\.| -00000330 0e df 8b fa 47 0f 51 0a a1 05 70 a6 8f a0 2a 27 |....G.Q...p...*'| -00000340 84 e9 a1 38 43 3d 2a e5 10 45 22 01 0a b2 8e 6d |...8C=*..E"....m| -00000350 27 53 b9 ea b5 5d 6d a7 50 69 c2 4c 50 cf 3d d9 |'S...]m.Pi.LP.=.| -00000360 47 82 62 4b 0b 42 6a 3f e5 4f a8 04 9b 7d f2 26 |G.bK.Bj?.O...}.&| -00000370 15 ce 88 74 40 59 87 2b 11 a5 ac 9a e5 3f 03 db |...t@Y.+.....?..| -00000380 33 cb 27 be d9 2a 69 1d 1e 68 6b 0e 54 0a f4 1c |3.'..*i..hk.T...| -00000390 63 b3 bb 55 63 e7 b6 b7 0e 2c ad 9e b5 1d 51 b4 |c..Uc....,....Q.| -000003a0 41 77 4b 80 17 47 c9 8f 9e 02 cd 87 2e 20 72 e4 |AwK..G....... r.| -000003b0 44 17 03 03 00 35 0e 4f 8b e7 ae ca 38 35 85 d8 |D....5.O....85..| -000003c0 fb 23 c3 39 d4 80 25 15 d3 39 4e 19 34 93 21 13 |.#.9..%..9N.4.!.| -000003d0 a2 84 2c 0f 3e 5e c3 62 95 41 c7 4d a7 81 2d 60 |..,.>^.b.A.M..-`| -000003e0 99 56 db d5 0e 2e 42 b3 16 72 22 |.V....B..r"| +00000050 2e 00 2b 00 02 03 04 00 33 00 24 00 1d 00 20 cd |..+.....3.$... .| +00000060 e6 a0 65 6b 1c 9e 5c f0 b7 f9 82 8e 37 d1 c4 35 |..ek..\.....7..5| +00000070 31 c1 3f df 4a 70 33 ba 38 d9 3f 74 0c c2 61 14 |1.?.Jp3.8.?t..a.| +00000080 03 03 00 01 01 17 03 03 00 17 63 c3 02 95 17 f4 |..........c.....| +00000090 a8 76 8d 54 ad 3c 10 c7 cc e8 08 13 d6 9b 0b 0f |.v.T.<..........| +000000a0 db 17 03 03 02 6d 0f ec 8d 0d e5 1a 85 02 3f 92 |.....m........?.| +000000b0 44 09 ac e6 da 2d c8 d7 14 68 00 9d 22 bf 05 1d |D....-...h.."...| +000000c0 cd 07 b5 8b b9 84 3f cf cc c5 48 40 00 2e e1 c9 |......?...H@....| +000000d0 0b 41 6d 39 cb 05 00 d6 7a 10 4a ba 96 e1 96 a9 |.Am9....z.J.....| +000000e0 70 d8 20 76 2f d2 70 83 cb a0 d1 72 43 db 09 cd |p. v/.p....rC...| +000000f0 2d e5 89 11 e8 81 15 13 dd 29 2a c8 88 4a d8 73 |-........)*..J.s| +00000100 35 3d 8e 8a 03 ca ed 32 a9 16 bb 71 88 d5 5f a1 |5=.....2...q.._.| +00000110 1b ec ee 9e 3d 8c f4 d0 c2 5b 72 84 3c 75 aa de |....=....[r......).@..| +00000130 3c f4 32 90 c0 25 b7 f0 fc 6b 16 c1 ab 80 69 79 |<.2..%...k....iy| +00000140 5e dd 95 5a ba e4 5a 68 64 a6 44 f5 a2 3a d6 30 |^..Z..Zhd.D..:.0| +00000150 7e b1 27 b1 79 44 ef 79 95 51 75 02 24 2c ea ab |~.'.yD.y.Qu.$,..| +00000160 d5 e1 fd aa 81 55 89 cf bc 9c 11 2b 0b 4a 99 9f |.....U.....+.J..| +00000170 50 93 68 a1 c8 79 3d d8 aa d8 54 e3 d5 1a 97 90 |P.h..y=...T.....| +00000180 33 87 a9 70 1d 9d ba 78 d0 87 8a 98 6f 1b 1e b0 |3..p...x....o...| +00000190 e8 92 78 df 21 61 88 36 fa 14 4b c9 b1 a4 93 88 |..x.!a.6..K.....| +000001a0 b4 26 9a 13 1b 8f 6c 84 bc b1 78 a8 a1 e7 64 4b |.&....l...x...dK| +000001b0 d4 56 37 b6 d1 80 6d 8d 0f c2 2f 0c 0b 9e 42 8e |.V7...m.../...B.| +000001c0 37 e0 9b 73 e4 ab cf 24 43 86 bc d0 40 fd db 4a |7..s...$C...@..J| +000001d0 c1 f6 55 56 e9 54 5c c7 3c 17 36 44 7b 99 7e 03 |..UV.T\.<.6D{.~.| +000001e0 48 f7 a9 cc 4d b9 b4 bf 09 dd 96 37 8c b5 d5 f0 |H...M......7....| +000001f0 bd af 19 0e 82 6c 5d b6 96 ca 98 a2 56 d3 68 f2 |.....l].....V.h.| +00000200 94 cd 7a 94 8d b3 97 16 03 3d 6a 94 5d 66 32 5d |..z......=j.]f2]| +00000210 11 28 d9 7b c1 8e b1 c4 ec b7 54 94 3b 80 f9 b3 |.(.{......T.;...| +00000220 9d 2d 74 3c 02 55 a0 4a 02 b7 61 19 b0 a2 e6 44 |.-t<.U.J..a....D| +00000230 3e c8 81 e3 a4 18 d7 4c 16 d2 fb e3 90 2c 61 71 |>......L.....,aq| +00000240 a0 82 28 48 de 7c 7c bd ba 27 85 e1 fd c9 df ac |..(H.||..'......| +00000250 b2 61 0f 80 f3 86 31 8f c1 a3 dc b6 43 98 c9 0e |.a....1.....C...| +00000260 73 dd 1d cf 61 f6 25 23 44 ca 5a 4c 12 6c bb 35 |s...a.%#D.ZL.l.5| +00000270 32 c4 32 0d cc 8c 11 b9 4a ee 88 92 d6 27 d4 a8 |2.2.....J....'..| +00000280 25 59 1e fe ba 41 63 50 1e b1 e2 c5 75 95 7d 56 |%Y...AcP....u.}V| +00000290 60 ed 81 d0 e7 12 05 e7 0f b4 5d 6f 27 98 76 72 |`.........]o'.vr| +000002a0 e7 8a e1 ff 5d 6b 29 9f 75 24 a5 fd 6d 1f bc 58 |....]k).u$..m..X| +000002b0 f8 b8 67 d1 b0 21 25 f1 09 c7 f9 41 f5 85 1b eb |..g..!%....A....| +000002c0 56 f6 14 83 bb 08 d5 3e ed 22 e1 c5 9c 14 cc de |V......>."......| +000002d0 d3 45 e1 0e e3 cb 61 b5 ab f6 03 41 bc 71 5d 17 |.E....a....A.q].| +000002e0 99 c6 8f 13 41 f8 78 e8 da 3d 40 1c 1a 47 a9 b2 |....A.x..=@..G..| +000002f0 e7 22 90 2f d8 8f 6f 0d 36 02 b1 36 fa 6d 26 6f |."./..o.6..6.m&o| +00000300 82 e2 54 74 a0 26 3c 0c 57 bb d7 01 ff ee 6f 16 |..Tt.&<.W.....o.| +00000310 63 92 00 17 03 03 00 99 ea 68 e4 08 10 2d 6f b6 |c........h...-o.| +00000320 a2 f8 f5 03 35 00 63 c8 da 23 4c 96 b8 2a 5c f5 |....5.c..#L..*\.| +00000330 9d 24 6f 5a 5b c3 aa d2 df d9 16 b6 9a 91 79 39 |.$oZ[.........y9| +00000340 18 35 65 28 80 97 fe 76 26 79 45 80 4c 8a 7c cc |.5e(...v&yE.L.|.| +00000350 a2 36 1a 8a ad aa f3 06 08 1f b7 4a 9b 22 7f 37 |.6.........J.".7| +00000360 62 3a ae 13 c0 f4 22 05 6f fc 92 5a e0 ed f1 5b |b:....".o..Z...[| +00000370 c6 6b 4f 18 83 a6 39 a7 5c 1c 53 32 08 76 25 03 |.kO...9.\.S2.v%.| +00000380 20 d5 47 57 76 06 38 4e bd b8 dd 7f 0e 37 b3 4e | .GWv.8N.....7.N| +00000390 f1 f3 b1 98 d4 f0 d6 00 ea 6a e9 ec a4 b0 fd 20 |.........j..... | +000003a0 2d 67 20 c8 ef 9f a1 97 00 cd 15 c2 8e c2 ba 46 |-g ............F| +000003b0 76 17 03 03 00 35 d0 f3 18 d0 71 4c 66 8c 40 ef |v....5....qLf.@.| +000003c0 57 92 f3 56 5a 42 1e 4c e6 13 5a cc ab 26 90 6a |W..VZB.L..Z..&.j| +000003d0 9b ca 49 b0 81 ec 38 30 44 27 5a fa ac d6 1f 5c |..I...80D'Z....\| +000003e0 bc 64 4b 0b c3 69 b2 5b ef 7f 4a |.dK..i.[..J| >>> Flow 3 (client to server) -00000000 14 03 03 00 01 01 17 03 03 00 35 db e3 68 0f 7c |..........5..h.|| -00000010 36 8e c4 5b 10 11 89 61 b7 f1 a9 f3 43 a5 28 e6 |6..[...a....C.(.| -00000020 86 8c f0 c3 3b 54 5b 86 3c b6 42 6e 3d 56 93 0a |....;T[.<.Bn=V..| -00000030 2c ca 2e 39 27 1c 12 e2 d7 e7 b5 57 a6 29 5c 4a |,..9'......W.)\J| -00000040 17 03 03 00 17 02 0d 23 ca 06 5e 1c 0f a8 a2 39 |.......#..^....9| -00000050 32 00 01 b5 ba e7 52 82 fa 2c e3 27 17 03 03 00 |2.....R..,.'....| -00000060 13 ea 39 b7 18 2d 01 1a c3 9c b5 51 cc d2 f3 40 |..9..-.....Q...@| -00000070 55 69 87 65 |Ui.e| +00000000 14 03 03 00 01 01 17 03 03 00 35 ef 3b a2 4d 0f |..........5.;.M.| +00000010 69 53 f2 a3 80 a0 06 a9 99 a9 15 1e bc 8b 4a 08 |iS............J.| +00000020 de 87 e7 b6 10 d6 b3 fc 89 f8 24 f9 2d 04 a1 fd |..........$.-...| +00000030 c2 ce eb 14 e9 df bf ab 80 8e f1 00 53 60 88 82 |............S`..| +00000040 17 03 03 00 17 22 aa a9 e0 1f f8 55 03 22 9b 0f |.....".....U."..| +00000050 b2 6d 73 be 10 5d 6c c6 d8 0e 5e 0d 17 03 03 00 |.ms..]l...^.....| +00000060 13 45 f2 81 7f ea ae 0d 77 bb d4 05 1e 55 af a8 |.E......w....U..| +00000070 3e 0d 10 0f |>...| diff --git a/testdata/Client-TLSv13-ClientCert-ECDSA-RSA b/testdata/Client-TLSv13-ClientCert-ECDSA-RSA index 8e87aa5..8984790 100644 --- a/testdata/Client-TLSv13-ClientCert-ECDSA-RSA +++ b/testdata/Client-TLSv13-ClientCert-ECDSA-RSA @@ -7,134 +7,134 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 7f 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 0a 00 08 00 1d 00 17 00 18 00 19 00 0b 00 02 01 |................| -000000a0 00 00 0d 00 1a 00 18 08 04 04 03 08 07 08 05 08 |................| -000000b0 06 04 01 05 01 06 01 05 03 06 03 02 01 02 03 ff |................| -000000c0 01 00 01 00 00 17 00 00 00 12 00 00 00 2b 00 09 |.............+..| +00000080 01 00 00 7f 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 19 00 0d |................| +000000b0 00 1a 00 18 08 04 04 03 08 07 08 05 08 06 04 01 |................| +000000c0 05 01 06 01 05 03 06 03 02 01 02 03 00 2b 00 09 |.............+..| 000000d0 08 03 04 03 03 03 02 03 01 00 33 00 26 00 24 00 |..........3.&.$.| 000000e0 1d 00 20 2f e5 7d a3 47 cd 62 43 15 28 da ac 5f |.. /.}.G.bC.(.._| 000000f0 bb 29 07 30 ff f6 84 af c4 cf c2 ed 90 99 5f 58 |.).0.........._X| 00000100 cb 3b 74 |.;t| >>> Flow 2 (server to client) -00000000 16 03 03 00 7a 02 00 00 76 03 03 98 a2 b1 a3 c2 |....z...v.......| -00000010 3a ad 0c cb df b0 4b 9d 37 a9 57 5f f0 c5 3f dd |:.....K.7.W_..?.| -00000020 73 c1 e6 7f 1e 45 7d ef 17 e8 61 20 00 00 00 00 |s....E}...a ....| +00000000 16 03 03 00 7a 02 00 00 76 03 03 ea 8b 99 cb 5b |....z...v......[| +00000010 d8 fb e9 14 7f 17 20 9c b8 41 01 dd ce 8a 90 4e |...... ..A.....N| +00000020 a9 f0 fb eb 71 37 24 02 d2 ee 96 20 00 00 00 00 |....q7$.... ....| 00000030 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |................| 00000040 00 00 00 00 00 00 00 00 00 00 00 00 13 03 00 00 |................| -00000050 2e 00 2b 00 02 03 04 00 33 00 24 00 1d 00 20 9b |..+.....3.$... .| -00000060 8a e8 f7 9b f3 9a 73 54 81 4c aa 41 06 e8 fd 21 |......sT.L.A...!| -00000070 f7 e6 62 2e 7a 1f 29 0e 1c 48 21 dc 82 3b 1b 14 |..b.z.)..H!..;..| -00000080 03 03 00 01 01 17 03 03 00 17 07 dc 9b 84 a2 d4 |................| -00000090 b9 80 93 7f 29 3e 7c 97 9e 46 e0 6d 0c 3d 24 4b |....)>|..F.m.=$K| -000000a0 1c 17 03 03 00 42 2c 3c 9c 8d 63 93 a7 02 57 8b |.....B,<..c...W.| -000000b0 3d e6 d1 f0 05 03 ff 91 77 55 01 6c 65 57 8f 67 |=.......wU.leW.g| -000000c0 44 f8 c1 8f c5 ee 00 9f 45 66 b0 c5 f0 61 20 b7 |D.......Ef...a .| -000000d0 4f f0 14 05 1d 47 10 af f9 11 ed 62 5e 78 12 60 |O....G.....b^x.`| -000000e0 65 b7 65 33 a9 b3 38 61 17 03 03 02 6d 9e c3 b9 |e.e3..8a....m...| -000000f0 0e 43 aa bd 17 a2 51 a8 9b a0 62 73 73 58 84 21 |.C....Q...bssX.!| -00000100 d2 fa 4f ad fe c3 56 b6 7f 93 e9 4d 4b 83 59 0c |..O...V....MK.Y.| -00000110 be 47 fd c5 f7 01 b2 03 18 77 9c ae 41 dd 26 44 |.G.......w..A.&D| -00000120 a2 8a 45 56 6d 61 bc 16 ff 52 d0 1a 48 37 c5 e8 |..EVma...R..H7..| -00000130 07 71 d1 3d c9 e2 75 3b 6f 16 43 9d a2 56 9c d6 |.q.=..u;o.C..V..| -00000140 90 d1 d4 fd 23 5e 32 84 bc 97 9e 33 4e cd 54 b6 |....#^2....3N.T.| -00000150 66 5c 52 be b0 b7 10 70 5c 3a 61 ec 4a e2 d4 43 |f\R....p\:a.J..C| -00000160 b0 87 8a 48 bd f5 81 cb ee 5a 72 de 26 13 49 31 |...H.....Zr.&.I1| -00000170 e7 02 53 54 b3 fc 86 b4 70 25 a6 f8 83 24 31 f3 |..ST....p%...$1.| -00000180 22 dd b1 ca 96 7e f3 9e dc 3b ce 7c 1f 7e 44 37 |"....~...;.|.~D7| -00000190 ba be 42 e3 14 29 14 8f ad 79 e6 d7 64 a9 11 ac |..B..)...y..d...| -000001a0 78 f5 fc 3c af e7 0a 55 26 07 a1 7e 81 1f 16 b5 |x..<...U&..~....| -000001b0 ad 4b cf 46 cf 7a ba d3 3b 2d 97 55 31 bb 20 68 |.K.F.z..;-.U1. h| -000001c0 c6 f6 19 99 af 98 25 cd 6e 76 39 03 32 14 08 fd |......%.nv9.2...| -000001d0 77 43 7d d0 f4 d4 8b 58 42 d6 6c 45 a5 b6 af 04 |wC}....XB.lE....| -000001e0 14 28 47 9f 45 bb af e8 8d e0 d6 54 55 e5 d2 ae |.(G.E......TU...| -000001f0 84 a1 0c 0b 42 5f 9a 9c 93 fb b9 cd e6 43 5f a3 |....B_.......C_.| -00000200 cc 6a 6a da 85 7d c1 37 af 04 1a 8b e7 4a 40 82 |.jj..}.7.....J@.| -00000210 82 88 0f dc 78 51 74 f7 2c c8 e0 01 eb f7 f9 ca |....xQt.,.......| -00000220 28 0a 79 c9 f9 fb 35 c1 e7 8e 65 9e 8b 40 75 29 |(.y...5...e..@u)| -00000230 f1 56 79 33 41 39 96 c4 ab 15 28 7c cc 5a cd 81 |.Vy3A9....(|.Z..| -00000240 c4 57 d2 d9 86 f7 7f 63 30 2d 89 71 29 3c 99 cc |.W.....c0-.q)<..| -00000250 d8 fb 01 03 f3 de 3d 57 5d f3 85 b5 7a a8 f1 5c |......=W]...z..\| -00000260 05 39 d7 ac 15 03 be 88 fb e8 4c d2 8f 0f 3f 68 |.9........L...?h| -00000270 c2 e0 e8 44 c0 97 83 f4 3f f2 4a ba 9e 4c b7 c1 |...D....?.J..L..| -00000280 ea 55 e4 f4 ce 55 69 83 5b 6e 02 07 06 c4 f3 70 |.U...Ui.[n.....p| -00000290 13 3e ed 76 f0 ec 7b 5d 1e 9b 5e 73 5f ef 5b 33 |.>.v..{]..^s_.[3| -000002a0 41 e9 38 45 80 c8 f2 3e 17 ec 30 8b ce 35 87 00 |A.8E...>..0..5..| -000002b0 a8 02 66 b4 fc d4 69 ae 12 df c6 a4 68 06 2d 8b |..f...i.....h.-.| -000002c0 9c b6 e3 0e 2c 2a d9 05 cc ac f1 32 e9 57 6d e4 |....,*.....2.Wm.| -000002d0 0e f5 ed d0 05 a4 4a 10 02 87 5b 90 f9 89 88 30 |......J...[....0| -000002e0 3a 65 9d 2d 41 07 7a d7 8b 16 cb 57 01 9d ad bb |:e.-A.z....W....| -000002f0 76 4a 6a 3f 77 ae 29 55 61 b5 04 6b 9f eb 6e 34 |vJj?w.)Ua..k..n4| -00000300 a7 c6 97 92 6f d3 29 0e 65 1e 83 74 e9 2c 5a 8a |....o.).e..t.,Z.| -00000310 a8 a7 7a b1 55 76 b9 6a 98 b9 09 d5 01 48 ae 06 |..z.Uv.j.....H..| -00000320 ff 88 cb 59 f4 64 f2 ad 3b 4c 8c 39 85 b1 5f ae |...Y.d..;L.9.._.| -00000330 07 c1 a9 0f f5 0e 02 27 28 74 0d 9f c5 b2 8e 18 |.......'(t......| -00000340 6a 66 b9 86 ca 41 1f 6f 4a 05 d1 0d 69 ad f0 b6 |jf...A.oJ...i...| -00000350 2d 6a 24 df 6f 9b 5c 07 b1 04 17 03 03 00 99 11 |-j$.o.\.........| -00000360 46 8d 44 89 36 f4 ff dc 5a 8e 1e 68 f3 63 03 b6 |F.D.6...Z..h.c..| -00000370 40 40 26 1b 28 41 d9 78 f5 5e 51 c6 21 b8 fa c5 |@@&.(A.x.^Q.!...| -00000380 a7 c4 20 d3 b0 c0 f0 ec 9a 0e 1a 5b 1c 8d 57 58 |.. ........[..WX| -00000390 32 f9 75 69 9a 5e 1d 96 0b fa 77 d8 c7 d1 a0 8b |2.ui.^....w.....| -000003a0 e6 f8 33 3a f9 90 22 a7 19 37 50 d8 f0 90 34 4f |..3:.."..7P...4O| -000003b0 c3 bb 1c a2 c3 b8 3e d3 6b ee a0 39 40 98 e5 93 |......>.k..9@...| -000003c0 f8 16 29 6a 1e 12 20 4d 5c bd fd 11 f6 c5 cc d6 |..)j.. M\.......| -000003d0 08 d9 bc f5 ce 95 70 2c dd 9f 70 08 7c c4 55 59 |......p,..p.|.UY| -000003e0 8f 57 25 16 36 53 b4 3c 14 df af 1c 5f ec 2a 5a |.W%.6S.<...._.*Z| -000003f0 61 7c c4 1e 96 9c aa 9b 17 03 03 00 35 ef b8 e8 |a|..........5...| -00000400 5d ef 00 77 46 05 77 37 7b f6 3e b4 e9 b4 67 a8 |]..wF.w7{.>...g.| -00000410 88 49 6d d8 2f 3a 88 db 48 47 e1 cb a5 f9 38 17 |.Im./:..HG....8.| -00000420 09 c8 a7 0b 92 7c d9 17 9f 2d 34 9c 9a d0 da 02 |.....|...-4.....| -00000430 a8 d0 |..| +00000050 2e 00 2b 00 02 03 04 00 33 00 24 00 1d 00 20 c8 |..+.....3.$... .| +00000060 c6 52 8e 3c 6f 0d ab 2d be 4c e0 01 c8 af 1f 8e |.R........t| +00000100 69 88 5d 8e a4 fa 02 b0 6f f4 0e 38 cc 95 12 e2 |i.].....o..8....| +00000110 f1 e3 47 89 a6 1d 80 26 cb 23 6e f3 83 1c e4 85 |..G....&.#n.....| +00000120 7b 1a 4d 12 c8 bf ff 07 39 a9 4e 4e d7 45 35 23 |{.M.....9.NN.E5#| +00000130 9b f9 59 6d a5 b0 49 1b 5f e7 42 62 17 00 1e 57 |..Ym..I._.Bb...W| +00000140 53 c5 22 fb 05 89 fd fe 5d de 71 e8 26 fd 6d e3 |S.".....].q.&.m.| +00000150 fc b9 cb 1f d5 d4 84 d1 67 fe 8a a0 74 ff ad ff |........g...t...| +00000160 c8 35 fe c2 9a 17 33 18 51 c2 cd 19 7c dc 5d c5 |.5....3.Q...|.].| +00000170 7c e6 d0 38 ab 28 0b 8c 78 51 aa 7f ef f0 9a c3 ||..8.(..xQ......| +00000180 df 26 d2 bc 1b b6 98 b1 16 35 9d f0 73 b7 15 f7 |.&.......5..s...| +00000190 7d 9f 3e fe 4c 75 e7 c7 5d cb c2 e5 29 4a 30 32 |}.>.Lu..]...)J02| +000001a0 e2 da 3c 2c 16 ba 89 41 28 5c 33 75 b3 ed d1 e6 |..<,...A(\3u....| +000001b0 4f f6 bb 33 62 53 9d be fe d3 53 b5 bd 3e e3 b5 |O..3bS....S..>..| +000001c0 0a 37 67 60 33 c3 72 a8 ea 55 73 3c b2 7f ed 8b |.7g`3.r..Us<....| +000001d0 59 5e 44 e4 76 0d 1e 3c 3e 1c 9c 8c 86 3d 0a a3 |Y^D.v..<>....=..| +000001e0 78 bd 13 77 eb dc 22 e5 96 ff ae 44 94 cd ef ae |x..w.."....D....| +000001f0 ca 64 ec 06 a1 38 49 17 ce a5 c4 34 86 fd 55 1f |.d...8I....4..U.| +00000200 32 31 d5 b0 8c d6 b5 bc b8 29 29 97 b5 39 a0 f8 |21.......))..9..| +00000210 b1 b5 72 24 ff ce 6f 7d 6a 0d 18 26 8f 9a e8 d3 |..r$..o}j..&....| +00000220 e6 e0 7c 9c 56 45 ca 48 44 69 05 53 40 eb 96 c5 |..|.VE.HDi.S@...| +00000230 17 aa 28 56 20 ee 82 fd de d1 55 b8 e9 27 ae 3d |..(V .....U..'.=| +00000240 e1 44 d6 0b b9 7a 25 77 b0 f1 be 64 ae cc 0d 44 |.D...z%w...d...D| +00000250 af 57 32 9f cf bc c0 07 00 0b 19 97 08 0a d5 50 |.W2............P| +00000260 20 0e ef d5 1e 2e 68 82 ae 2d 84 47 3d 9b 5b 24 | .....h..-.G=.[$| +00000270 55 95 b2 93 e0 60 a2 cd e5 72 69 b3 e2 de da 70 |U....`...ri....p| +00000280 76 88 be 1f 5a 8e 7a d8 ff 94 db b0 92 b2 a1 a1 |v...Z.z.........| +00000290 26 5b 3b d5 5e 67 16 b7 6a 9f dc ab 21 7e df 6e |&[;.^g..j...!~.n| +000002a0 2a 73 e9 20 40 4b c8 34 fc 4b be f6 d8 ba 78 d7 |*s. @K.4.K....x.| +000002b0 a4 c2 ed a9 52 f9 ea 88 67 5e 10 92 8f ba 83 cd |....R...g^......| +000002c0 19 79 82 c5 76 06 d9 98 9f 68 2e 34 82 2f 9a 41 |.y..v....h.4./.A| +000002d0 fb 63 b6 8c 79 56 62 9d bb bc b5 22 ab 28 35 f7 |.c..yVb....".(5.| +000002e0 bc c6 a8 6b e7 86 01 c3 6c e5 88 28 57 09 65 31 |...k....l..(W.e1| +000002f0 b2 5c 0a 60 46 af 94 2c d4 37 49 9b 4c e4 4b bb |.\.`F..,.7I.L.K.| +00000300 fb 0d 87 94 82 11 09 26 04 6f ec e9 a6 f4 9c ca |.......&.o......| +00000310 79 a0 d0 48 32 5a 02 58 70 81 d0 b6 6d 77 2f 6f |y..H2Z.Xp...mw/o| +00000320 4e 9b db ca 82 38 ed a6 60 8e e2 b6 14 33 f5 02 |N....8..`....3..| +00000330 4b 97 a4 86 2f 43 9d ee 88 2c 1c 58 7e 47 30 cc |K.../C...,.X~G0.| +00000340 ec 0d aa 22 13 60 be e2 c9 c4 59 90 67 96 9b 2a |...".`....Y.g..*| +00000350 41 79 49 00 71 80 e9 0d 12 c3 17 03 03 00 99 ec |AyI.q...........| +00000360 f5 a1 45 64 61 fc 61 35 d5 2f bf 20 02 68 0b 10 |..Eda.a5./. .h..| +00000370 df c4 4b e7 2c 43 bc f5 3d 0b 7e 9f a4 71 09 2c |..K.,C..=.~..q.,| +00000380 a6 cf f4 f4 b4 2c 08 0c 03 50 ac 47 74 ad 24 f1 |.....,...P.Gt.$.| +00000390 04 f3 d4 83 42 3f 35 a5 57 ff ab 59 0c 9a a2 ca |....B?5.W..Y....| +000003a0 6c 30 b7 87 73 af 53 f9 1d 6b e7 44 ec d1 bd 14 |l0..s.S..k.D....| +000003b0 15 09 cf ff 82 5e a2 6d ba 00 53 b8 b3 7c 0e e5 |.....^.m..S..|..| +000003c0 d1 e2 a2 38 25 88 aa ee 93 c8 d9 d1 88 42 42 90 |...8%........BB.| +000003d0 43 8d 22 d8 48 02 57 22 6a f4 e9 23 71 f0 64 30 |C.".H.W"j..#q.d0| +000003e0 6a 68 12 a5 3c 8c 61 5e bc 73 91 6a 01 3a 14 14 |jh..<.a^.s.j.:..| +000003f0 86 7c 4d f5 aa cc 2f f5 17 03 03 00 35 7e f6 f5 |.|M.../.....5~..| +00000400 6b 75 e2 63 64 5a 6b 9b ce 6b 76 d7 47 bc 1b 47 |ku.cdZk..kv.G..G| +00000410 9e 68 25 fe 47 2b 06 a9 72 d0 a7 3f 23 3d 71 4a |.h%.G+..r..?#=qJ| +00000420 da 29 fb e3 dd ee e6 f6 a5 32 cc eb da 61 2b 52 |.).......2...a+R| +00000430 24 26 |$&| >>> Flow 3 (client to server) -00000000 14 03 03 00 01 01 17 03 03 02 1e 57 f6 58 1b c5 |...........W.X..| -00000010 ad 34 85 01 b8 a0 3f a6 b4 b8 e1 b1 7b fa 10 f8 |.4....?.....{...| -00000020 05 c3 07 ba ef a7 08 ed d0 0e f4 4a e0 1e 49 d8 |...........J..I.| -00000030 d8 a6 82 3c ca cd 4c b8 c3 27 40 28 49 69 47 a2 |...<..L..'@(IiG.| -00000040 ab 4b 14 e2 b5 ac 02 aa 7c 92 17 c0 6e cc 42 dc |.K......|...n.B.| -00000050 ce 10 d1 cb 25 9e fe 4f 21 a3 76 1b b4 d4 62 5b |....%..O!.v...b[| -00000060 51 8a 64 4a 6c 4c 7b e8 87 79 50 51 4a b3 39 f3 |Q.dJlL{..yPQJ.9.| -00000070 37 9f 30 23 eb 6a 26 bc 49 3f 41 76 d2 c9 06 63 |7.0#.j&.I?Av...c| -00000080 41 11 58 02 0b ae ac 52 4b e6 4e 03 88 ef e6 8d |A.X....RK.N.....| -00000090 51 7b 02 e2 a5 a3 70 79 d1 16 5f 8b b9 2e d6 48 |Q{....py.._....H| -000000a0 87 2b c9 49 7f 1a 33 65 55 61 80 bd e5 cb dc 74 |.+.I..3eUa.....t| -000000b0 84 4d dd c8 9a 6b 84 c2 b5 68 de 5e 9b 42 cf 99 |.M...k...h.^.B..| -000000c0 a5 69 93 89 63 a7 94 60 0c 97 7c ab ec 18 61 a8 |.i..c..`..|...a.| -000000d0 68 e3 c8 66 ab 08 2c 96 49 76 b2 3e 40 22 5e 95 |h..f..,.Iv.>@"^.| -000000e0 7e 79 f0 53 43 2f 0d a0 c2 ec eb 6f ec 41 da ef |~y.SC/.....o.A..| -000000f0 a0 6f cb 22 bb 55 19 2d 6d 6e 04 cc 77 fb 00 a2 |.o.".U.-mn..w...| -00000100 99 53 cf b6 30 95 f4 04 83 9e ab a9 c4 cd 21 a4 |.S..0.........!.| -00000110 4a d9 e4 f9 a6 96 5e ef 8d b7 c0 62 2a 25 68 a4 |J.....^....b*%h.| -00000120 53 50 7c cf d5 9d b9 3d 78 2b 76 65 63 95 b4 8d |SP|....=x+vec...| -00000130 87 41 68 3d dc 80 be 40 24 33 b5 c3 90 ee 8f fa |.Ah=...@$3......| -00000140 f8 25 0d 48 6a c7 b5 e6 b5 ab b5 10 4b ad b3 95 |.%.Hj.......K...| -00000150 62 6b 76 9b 21 b2 96 86 0d f6 c1 a8 d3 5a 9f 3e |bkv.!........Z.>| -00000160 e8 50 2f 72 49 1c 0a fa 47 90 87 75 f8 a4 7e 95 |.P/rI...G..u..~.| -00000170 d2 74 ca 78 c5 fa f8 8d ca 83 81 ec 93 89 e0 50 |.t.x...........P| -00000180 62 49 15 87 5e 16 4c 17 aa f3 a1 1b 0c 4b 9a 68 |bI..^.L......K.h| -00000190 1b d5 48 a5 da fe c8 84 fe e6 fc 24 3d 9d 14 e8 |..H........$=...| -000001a0 e5 38 45 20 bd cb 22 2a 95 3e de 84 4f 85 6b e2 |.8E .."*.>..O.k.| -000001b0 be dc e1 1a 55 78 68 dc fd c7 c8 e2 d6 90 a7 14 |....Uxh.........| -000001c0 44 b6 6a a0 4e 01 0f 73 9b 97 ac ef 17 91 90 16 |D.j.N..s........| -000001d0 14 e5 f7 88 df 08 8b d6 48 49 c5 9b 72 81 0b b8 |........HI..r...| -000001e0 67 e4 5a b0 a6 a8 37 ef d3 96 28 dd f9 cc 24 c0 |g.Z...7...(...$.| -000001f0 6f fc 7e 68 f5 25 df 38 73 1a ea b1 3d 8d 88 90 |o.~h.%.8s...=...| -00000200 90 51 f3 f5 02 df 5a b2 5a 29 81 3c b6 aa 60 f2 |.Q....Z.Z).<..`.| -00000210 79 ea 11 54 9d 6e ad e4 9b 48 35 6a 7b 95 ac 75 |y..T.n...H5j{..u| -00000220 5e a5 dd 55 c7 97 10 aa 22 17 03 03 00 a2 12 24 |^..U...."......$| -00000230 cd 8b fc be 73 28 ab a6 1e e6 f9 c2 d3 5e 98 db |....s(.......^..| -00000240 a9 30 02 c7 87 20 c9 34 d3 11 ea 3e 9f 3e 12 c7 |.0... .4...>.>..| -00000250 55 16 8d 3a 33 8f 71 08 b0 10 e4 0a 43 6d 1e 59 |U..:3.q.....Cm.Y| -00000260 79 e4 f0 86 6a bb 4a 4e bf 03 7a 5a 7d 76 a1 be |y...j.JN..zZ}v..| -00000270 26 95 87 e4 8c 14 85 f3 a6 ec 9c 44 e2 80 04 96 |&..........D....| -00000280 12 6a c5 97 c0 0c 4e 94 49 ef f9 78 38 09 c7 65 |.j....N.I..x8..e| -00000290 6c 51 2b 2a a3 da 9c 95 37 1a da 37 f6 da c2 79 |lQ+*....7..7...y| -000002a0 be 5a 1f 0a 59 5b d8 31 b8 c5 b1 12 ef 57 1b fc |.Z..Y[.1.....W..| -000002b0 62 8f de 94 3d 02 3c 96 cf 76 02 46 b7 64 0a 41 |b...=.<..v.F.d.A| -000002c0 87 94 d6 98 61 82 8c ff 9f 42 dc f0 8e 6a 59 a5 |....a....B...jY.| -000002d0 17 03 03 00 35 ec 44 9e 59 91 95 ae 8d f5 90 13 |....5.D.Y.......| -000002e0 6e cf e5 4c a3 89 a0 65 54 f8 6c c0 b7 12 2b 26 |n..L...eT.l...+&| -000002f0 fb d6 16 33 1e cd 5f dc c1 06 f3 6e 9a 5a 30 c8 |...3.._....n.Z0.| -00000300 87 6a ee 13 06 b8 30 c6 33 3b 17 03 03 00 17 a4 |.j....0.3;......| -00000310 d8 51 e6 cd d0 30 f3 2b 5d 17 fa d4 c8 96 d1 8c |.Q...0.+].......| -00000320 2d b6 58 68 c7 93 17 03 03 00 13 1b a1 ec 18 a4 |-.Xh............| -00000330 6f c6 5a 27 a3 1c a3 75 6d bd 68 61 28 cd |o.Z'...um.ha(.| +00000000 14 03 03 00 01 01 17 03 03 02 1e 67 f8 08 c4 15 |...........g....| +00000010 47 a9 da 91 df f1 61 0f 50 21 f6 da dd a9 a6 e4 |G.....a.P!......| +00000020 00 05 29 62 d2 cc fe 14 57 a2 aa 46 16 b3 46 6e |..)b....W..F..Fn| +00000030 82 87 dc bb 1a d9 e7 c6 e9 1a 3b 7e a5 94 9b 7e |..........;~...~| +00000040 bb 07 b8 f3 de cc f1 85 d5 ee ff 0b 5a 19 c1 e3 |............Z...| +00000050 5f 47 f4 81 f4 d3 2d 85 f8 38 90 00 10 54 9a 3e |_G....-..8...T.>| +00000060 56 e4 99 a5 31 b1 dc d4 77 fe 28 3a b4 3e 63 42 |V...1...w.(:.>cB| +00000070 bc 05 c7 8a e5 d9 01 5c c9 18 39 1e 62 4f b4 58 |.......\..9.bO.X| +00000080 d3 9a 6a e1 a4 d3 ef 7f b8 0f 35 ac 2a 4a ba 77 |..j.......5.*J.w| +00000090 24 1e 24 6e 0e a2 8e f1 ba 5f fe 24 03 ed 1d e7 |$.$n....._.$....| +000000a0 43 2d fb bb 2e a9 a5 9a 18 11 39 99 a1 5a b7 92 |C-........9..Z..| +000000b0 37 91 f2 80 b2 f6 57 87 f9 a5 d9 da 36 b5 db 1a |7.....W.....6...| +000000c0 28 d8 9e f7 92 6f cf 0c 57 9a 95 42 ef 6a 50 f6 |(....o..W..B.jP.| +000000d0 38 4f 74 52 09 34 ca 8a d8 c7 a2 d2 69 bb db 13 |8OtR.4......i...| +000000e0 b1 ef f2 6d d3 f0 dd 5d b7 93 25 87 84 cd 87 6d |...m...]..%....m| +000000f0 c7 24 99 2b c8 02 25 1c 58 bc 98 03 33 15 ee 3e |.$.+..%.X...3..>| +00000100 96 d0 af 82 c7 74 71 ec ef a6 eb 88 20 55 1b fa |.....tq..... U..| +00000110 ea 01 38 5b 68 77 f1 3b 2a e6 d1 96 bc 28 b3 97 |..8[hw.;*....(..| +00000120 47 94 14 3f 6b 73 82 bf b0 ba fe 45 2a 45 45 1c |G..?ks.....E*EE.| +00000130 30 68 f5 74 07 15 18 00 a7 4f 62 df 7c ff 4c 0a |0h.t.....Ob.|.L.| +00000140 93 d6 60 8b 1f 0e 7f d3 88 43 90 f6 18 05 f1 ae |..`......C......| +00000150 ac 04 63 8b 43 b8 11 74 b1 87 e6 bc 2d 72 4a 2e |..c.C..t....-rJ.| +00000160 75 ab 16 5e 0e bc 76 6d d6 0e bc 39 0d 3c 76 01 |u..^..vm...9.fDcKC.%(D.-.| +000001b0 39 0e cd 15 a3 04 d9 db 4f a4 03 cb d2 84 da 41 |9.......O......A| +000001c0 5c 60 bf 00 77 19 68 b1 50 99 c2 88 d2 56 1e 29 |\`..w.h.P....V.)| +000001d0 c9 8c 83 98 7a 2f 04 e6 d6 09 5c 27 af a7 69 c4 |....z/....\'..i.| +000001e0 f7 4a ed b5 db d3 7a aa 75 f1 b2 8d 87 15 9a d1 |.J....z.u.......| +000001f0 00 fa 7f 58 06 2d 72 2b f7 27 b3 5b 76 57 21 35 |...X.-r+.'.[vW!5| +00000200 80 ce 8e bd e4 bb 45 01 c4 6b 43 f1 44 0a 5f 21 |......E..kC.D._!| +00000210 76 48 ae ce 8e 1d ba f7 7c 4f ae a2 d8 77 ce 9c |vH......|O...w..| +00000220 6d 69 b7 1e 78 ab 02 ed 15 17 03 03 00 a3 84 ed |mi..x...........| +00000230 ba 37 b6 6f 96 68 ef 9e b7 c6 23 5a 9f 1b ed ad |.7.o.h....#Z....| +00000240 3b 5d ab d4 22 d8 3e ab db db c5 b9 57 f8 68 d1 |;]..".>.....W.h.| +00000250 93 d5 36 fe 0c c0 fe 29 88 8b 63 ac 0e 06 4e bd |..6....)..c...N.| +00000260 9e b9 24 65 b5 9c e7 b9 58 4c 8a 07 10 9c 17 f7 |..$e....XL......| +00000270 c0 67 af ff c8 ff fc 87 1b fa c8 21 21 17 2d 43 |.g.........!!.-C| +00000280 f5 fc 4f 0d bf 01 58 b6 f1 58 08 39 f4 0d 94 69 |..O...X..X.9...i| +00000290 8f f0 c1 14 93 41 56 32 41 11 84 58 73 13 69 2a |.....AV2A..Xs.i*| +000002a0 ed 2a 34 61 73 8d 47 41 62 33 39 66 fa 3d 2a e5 |.*4as.GAb39f.=*.| +000002b0 bf 09 d6 c0 1e 3c 98 b3 86 a6 87 b5 a7 d2 cf d9 |.....<..........| +000002c0 dd f8 2e 86 f7 13 84 4a f7 3b ec 8e e5 06 f5 cd |.......J.;......| +000002d0 42 17 03 03 00 35 b2 38 87 30 58 9e 03 6e 44 dd |B....5.8.0X..nD.| +000002e0 fb 87 11 3a a0 e7 c1 2d 74 3b 35 d0 3f bc de cd |...:...-t;5.?...| +000002f0 71 61 8b 7c a5 7e c6 2d 76 67 44 9e 75 e5 9b 3b |qa.|.~.-vgD.u..;| +00000300 c5 2b 42 8a 4a 7f 0e 12 4c 2e 0f 17 03 03 00 17 |.+B.J...L.......| +00000310 d3 61 ed 75 dd 2e ee dd 79 fe d1 7c 4d 23 b1 95 |.a.u....y..|M#..| +00000320 ea 14 d6 27 d0 02 46 17 03 03 00 13 84 c1 07 6f |...'..F........o| +00000330 1c c6 22 a8 ae 6d a8 e8 62 54 ac b2 53 57 bb |.."..m..bT..SW.| diff --git a/testdata/Client-TLSv13-ClientCert-Ed25519 b/testdata/Client-TLSv13-ClientCert-Ed25519 index 94abf06..b524ef4 100644 --- a/testdata/Client-TLSv13-ClientCert-Ed25519 +++ b/testdata/Client-TLSv13-ClientCert-Ed25519 @@ -7,117 +7,117 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 7f 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 0a 00 08 00 1d 00 17 00 18 00 19 00 0b 00 02 01 |................| -000000a0 00 00 0d 00 1a 00 18 08 04 04 03 08 07 08 05 08 |................| -000000b0 06 04 01 05 01 06 01 05 03 06 03 02 01 02 03 ff |................| -000000c0 01 00 01 00 00 17 00 00 00 12 00 00 00 2b 00 09 |.............+..| +00000080 01 00 00 7f 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 19 00 0d |................| +000000b0 00 1a 00 18 08 04 04 03 08 07 08 05 08 06 04 01 |................| +000000c0 05 01 06 01 05 03 06 03 02 01 02 03 00 2b 00 09 |.............+..| 000000d0 08 03 04 03 03 03 02 03 01 00 33 00 26 00 24 00 |..........3.&.$.| 000000e0 1d 00 20 2f e5 7d a3 47 cd 62 43 15 28 da ac 5f |.. /.}.G.bC.(.._| 000000f0 bb 29 07 30 ff f6 84 af c4 cf c2 ed 90 99 5f 58 |.).0.........._X| 00000100 cb 3b 74 |.;t| >>> Flow 2 (server to client) -00000000 16 03 03 00 7a 02 00 00 76 03 03 63 7c fe 18 f1 |....z...v..c|...| -00000010 82 47 f8 e9 56 0a ef 41 1c da 7b ef 4e 37 f7 37 |.G..V..A..{.N7.7| -00000020 9c 70 58 73 97 a4 2b df 93 24 98 20 00 00 00 00 |.pXs..+..$. ....| +00000000 16 03 03 00 7a 02 00 00 76 03 03 28 10 3b 44 b1 |....z...v..(.;D.| +00000010 0f a9 77 89 f9 dd 3c 3a ad 83 a0 ca 3e 60 d6 0e |..w...<:....>`..| +00000020 ab 94 3a ec 2e 63 ef b1 41 90 48 20 00 00 00 00 |..:..c..A.H ....| 00000030 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |................| 00000040 00 00 00 00 00 00 00 00 00 00 00 00 13 03 00 00 |................| -00000050 2e 00 2b 00 02 03 04 00 33 00 24 00 1d 00 20 fe |..+.....3.$... .| -00000060 8e 92 58 47 f1 85 83 58 b6 18 1a 05 fb 40 99 25 |..XG...X.....@.%| -00000070 10 d0 6d 4c c0 43 8b b5 a9 18 51 8f 84 73 56 14 |..mL.C....Q..sV.| -00000080 03 03 00 01 01 17 03 03 00 17 3e f9 39 72 d3 bd |..........>.9r..| -00000090 1f 3f ff 30 cb 7e f8 3d a7 7d 8c 09 94 d3 79 24 |.?.0.~.=.}....y$| -000000a0 10 17 03 03 00 42 28 16 54 10 dd db 62 c6 08 c9 |.....B(.T...b...| -000000b0 56 43 8d 0e 04 bc d1 78 54 21 1f 08 c0 80 e2 76 |VC.....xT!.....v| -000000c0 8b 64 e2 63 97 a8 73 8a 14 16 2f 92 39 9c 59 e9 |.d.c..s.../.9.Y.| -000000d0 59 a0 88 4b 9d 19 49 cf 34 98 c5 2a 48 eb d2 0f |Y..K..I.4..*H...| -000000e0 95 7a 25 f2 23 b3 88 61 17 03 03 02 6d 98 62 0c |.z%.#..a....m.b.| -000000f0 ed 07 3e a7 5b 8e 69 20 90 cb ff 25 06 fb 80 dc |..>.[.i ...%....| -00000100 b6 e6 bc 95 9c 6b 1e b4 11 a7 2f 72 17 c7 b5 67 |.....k..../r...g| -00000110 93 a9 5c b8 ef aa e1 cb 6b f4 2d db e3 a4 c9 cf |..\.....k.-.....| -00000120 66 45 d9 1d 02 1d 9c b7 84 4f 83 5b 7f f3 16 0a |fE.......O.[....| -00000130 f7 37 86 19 c0 29 95 5a aa 46 62 10 c9 22 62 f0 |.7...).Z.Fb.."b.| -00000140 4f a9 a3 75 ea 46 af 75 54 9e 69 87 ce a9 d9 b9 |O..u.F.uT.i.....| -00000150 35 d6 c0 4a f0 22 0b d1 e5 4b 48 99 70 fa bc ed |5..J."...KH.p...| -00000160 8a 8b 7d a2 f0 52 3d e0 bc d3 7e ca 1b 89 b6 78 |..}..R=...~....x| -00000170 24 8d 13 0d 7d f2 3f d7 71 c9 d6 5a 00 8e 8c 7f |$...}.?.q..Z....| -00000180 ed 5b 39 f3 67 76 c3 7a 75 1e 4a 4b 63 36 e7 d4 |.[9.gv.zu.JKc6..| -00000190 04 46 e0 17 f4 d0 41 9d cf 01 f4 f7 b4 7e 11 73 |.F....A......~.s| -000001a0 c4 46 ac d3 78 54 17 83 10 12 48 d1 36 ee 37 90 |.F..xT....H.6.7.| -000001b0 f1 5f 7d f9 bc ac 95 ae 01 0e ca 0d 93 07 6e 87 |._}...........n.| -000001c0 c9 27 79 46 0f 27 a1 31 f8 92 9e 73 3d 2e 29 f5 |.'yF.'.1...s=.).| -000001d0 88 d1 67 a6 6a fb d5 59 39 65 46 b0 92 11 55 de |..g.j..Y9eF...U.| -000001e0 6f 9f 1d ea a0 71 65 4c c8 03 b7 f1 25 ff f1 c9 |o....qeL....%...| -000001f0 fa a7 1e 36 f3 91 bd d7 91 00 b5 3e 6f b1 67 5b |...6.......>o.g[| -00000200 fc 64 1d 76 0e a7 36 15 93 a1 ea 53 06 15 2b cf |.d.v..6....S..+.| -00000210 29 ea c6 5b 58 bb 08 a0 b8 9c e1 70 8d 2d 55 81 |)..[X......p.-U.| -00000220 ac d9 0d 45 ec f9 c3 56 31 00 db 46 81 68 98 db |...E...V1..F.h..| -00000230 8d 97 ce d1 b9 83 af 5f 6a a2 1a 22 2f 52 a0 d1 |......._j.."/R..| -00000240 8c 40 35 68 a2 ee 30 ef d4 bf 08 46 76 7c dd 57 |.@5h..0....Fv|.W| -00000250 c3 fb 7d fd af 01 37 cc c2 44 f6 cf 80 f4 ab c2 |..}...7..D......| -00000260 2e 82 18 5e c4 91 a8 b7 ad 29 e7 54 4f 02 47 5e |...^.....).TO.G^| -00000270 82 26 25 c6 b5 8e c9 a7 19 00 32 1b 3b e8 8c 35 |.&%.......2.;..5| -00000280 25 01 ed e4 b2 29 e2 f4 d7 0f c8 39 f8 5d 7b 1e |%....).....9.]{.| -00000290 db 7b 39 f4 e2 cd 1a 57 07 48 2b 15 e4 39 03 54 |.{9....W.H+..9.T| -000002a0 cf 39 fe 3d 15 47 bb 87 cf a5 f4 17 cc ad dd fa |.9.=.G..........| -000002b0 58 b6 e8 23 9c 1d 92 6b 32 36 12 ba 87 56 a4 2f |X..#...k26...V./| -000002c0 fe cc 93 98 62 84 5c e6 f9 fd d4 86 df ce 42 32 |....b.\.......B2| -000002d0 08 da a4 13 40 a0 33 c2 2a 54 2b da 50 5b 27 d9 |....@.3.*T+.P['.| -000002e0 3a 76 16 6c 89 bf 31 48 a3 ad c3 a6 ee 17 7d 86 |:v.l..1H......}.| -000002f0 88 52 57 77 01 94 ba dc f0 a6 c3 d3 30 ae be aa |.RWw........0...| -00000300 11 0a e8 54 8c b2 cb 7f e6 b6 d3 17 f4 2e 54 94 |...T..........T.| -00000310 31 43 33 07 5d 51 96 11 21 91 f9 7e 93 79 70 85 |1C3.]Q..!..~.yp.| -00000320 d3 0b ee fd 0e eb db ad 71 fe ba fc fe fa ef 0e |........q.......| -00000330 a1 a4 c5 99 e2 fa 3c df 8b 52 33 89 fd 15 45 1b |......<..R3...E.| -00000340 4e 5f 0e ca e9 c5 6e 11 06 ae 37 2a db 4c 9f 2c |N_....n...7*.L.,| -00000350 21 67 af e7 ae 09 e8 96 2f f0 17 03 03 00 99 ed |!g....../.......| -00000360 df 2c ff 14 ed 8e 5e 83 63 5d 82 99 19 ef 4c b1 |.,....^.c]....L.| -00000370 4b f6 88 29 27 72 b4 47 41 ab 61 58 67 7f 1c d0 |K..)'r.GA.aXg...| -00000380 a5 6d 83 3a 4e be 98 7d 55 e3 cc a5 24 41 28 91 |.m.:N..}U...$A(.| -00000390 33 b8 94 a8 e3 54 88 2b 22 89 c2 b8 86 96 d0 24 |3....T.+"......$| -000003a0 99 6c 4c 26 ee 39 67 b6 8b 30 49 b9 d4 cd c0 b3 |.lL&.9g..0I.....| -000003b0 bd f0 1d 2c 96 c7 9c 10 a7 4b 0e 2b 51 92 96 2f |...,.....K.+Q../| -000003c0 70 40 12 f3 91 53 eb 25 34 e6 ae ef df d4 3e f5 |p@...S.%4.....>.| -000003d0 fa 9f c2 85 71 5d 21 fd ee e0 3b 5a 23 db 19 e6 |....q]!...;Z#...| -000003e0 ce 04 6c e6 37 2c 43 df 4c 1f 0a 84 36 5e 26 82 |..l.7,C.L...6^&.| -000003f0 fa f4 38 ea 49 bb d2 65 17 03 03 00 35 a7 a0 78 |..8.I..e....5..x| -00000400 91 74 da 83 6f bd 49 ae 52 e2 c2 a7 d9 b4 a1 bc |.t..o.I.R.......| -00000410 b8 59 ab 56 25 60 05 39 db 3b 5e 95 6f a6 43 b9 |.Y.V%`.9.;^.o.C.| -00000420 1b 7a 84 ac ea 8a 62 f2 7c 50 68 43 0a c8 71 25 |.z....b.|PhC..q%| -00000430 44 a0 |D.| +00000050 2e 00 2b 00 02 03 04 00 33 00 24 00 1d 00 20 d9 |..+.....3.$... .| +00000060 ce 37 c6 7e 9c 0f 75 bb b6 91 c9 af 59 eb 24 07 |.7.~..u.....Y.$.| +00000070 2e 80 3a 7e d2 fc 39 9e 45 19 94 2d ae 33 2c 14 |..:~..9.E..-.3,.| +00000080 03 03 00 01 01 17 03 03 00 17 c6 b7 f1 35 ee 93 |.............5..| +00000090 75 ca 2e 3a a2 3d ed 32 5c e1 2c e0 5b 1c 01 e0 |u..:.=.2\.,.[...| +000000a0 bb 17 03 03 00 42 02 e5 db dc 80 e1 c2 6f 31 1c |.....B.......o1.| +000000b0 33 7b 76 8f 51 9c f8 a8 b0 1b 1a 8a 46 00 c7 ff |3{v.Q.......F...| +000000c0 ff 4c c9 d8 28 14 32 74 ee 59 b3 15 4b 45 90 b6 |.L..(.2t.Y..KE..| +000000d0 da 56 b3 ef d4 6f 8a eb 96 b9 94 ab b9 9e b1 2e |.V...o..........| +000000e0 fe 29 f2 0d 0d 93 66 1a 17 03 03 02 6d 84 4e 43 |.)....f.....m.NC| +000000f0 92 85 d5 e0 7a cd da a6 c0 5a bf 8b eb 83 db a0 |....z....Z......| +00000100 dc c3 e2 a8 d5 ca ad 87 75 19 08 dd 3e 2e 36 a0 |........u...>.6.| +00000110 a1 53 28 09 cd 1c 1d a0 24 77 e3 e6 4d b1 8f 36 |.S(.....$w..M..6| +00000120 43 29 79 b3 e2 fb 9e dc 39 90 b5 b7 db 6d 0a c0 |C)y.....9....m..| +00000130 55 d2 1c fd 8d 57 5b bf e3 70 b7 6a bc af 4f 34 |U....W[..p.j..O4| +00000140 e7 e1 46 d3 9a cc e4 73 33 fb e6 ad f9 b5 35 af |..F....s3.....5.| +00000150 97 77 88 11 19 7c e6 7d 8b 08 bb 78 2c 50 29 0c |.w...|.}...x,P).| +00000160 87 5f ef 04 19 34 9f 59 54 df 14 71 d1 5f e7 dc |._...4.YT..q._..| +00000170 46 2e 73 1a 07 12 be 6e 74 e1 8e 82 ca db a2 6d |F.s....nt......m| +00000180 35 5b fc 4c 71 42 45 86 35 1c c0 dc 0d 4c 40 a8 |5[.LqBE.5....L@.| +00000190 c7 ea 4a b8 33 0b 30 e2 6d a4 82 dc 28 35 1f f2 |..J.3.0.m...(5..| +000001a0 ac 23 41 10 a4 d4 1a 40 28 4d ea db 32 d5 06 de |.#A....@(M..2...| +000001b0 1e 37 91 77 34 ed b4 c8 f2 1c 44 de ee 2f dd af |.7.w4.....D../..| +000001c0 61 cc 1e 59 87 a6 be 36 b0 8e a3 61 01 aa f4 60 |a..Y...6...a...`| +000001d0 1e c8 3a 3c 53 57 31 28 3e 40 32 95 67 02 41 9c |..:@2.g.A.| +000001e0 58 28 50 51 5e 06 1d f1 57 e1 39 ba e0 ab 30 26 |X(PQ^...W.9...0&| +000001f0 25 fe b6 0a a9 d5 b3 72 61 3a 71 ec a2 44 91 5e |%......ra:q..D.^| +00000200 30 1b d4 dd 07 cf 35 6a 85 4a 95 b2 a9 f5 5c 6e |0.....5j.J....\n| +00000210 35 f9 07 7b d9 b0 a5 64 2f c3 34 23 84 3f 1a 97 |5..{...d/.4#.?..| +00000220 dd 25 75 7c 76 0f 9b 73 5b aa c0 a1 00 4b f6 b1 |.%u|v..s[....K..| +00000230 61 34 51 d0 d1 3b 00 4f 87 93 f5 45 2e 23 93 ee |a4Q..;.O...E.#..| +00000240 e6 ce e5 1c 02 22 3c c1 22 ed 33 b2 71 99 52 26 |....."<.".3.q.R&| +00000250 70 86 ad bc 41 d9 13 54 d3 3e 5d 4b 63 4d d2 6f |p...A..T.>]KcM.o| +00000260 bf a5 24 f8 7b 83 b2 0b 13 02 0d 42 74 9b 04 4e |..$.{......Bt..N| +00000270 8a 86 6b 40 92 42 3a d8 a8 21 2f ce e0 90 71 65 |..k@.B:..!/...qe| +00000280 5f ed c7 65 38 e3 85 e2 32 d5 4b c0 84 61 24 a1 |_..e8...2.K..a$.| +00000290 00 be 67 f3 59 b0 b2 f0 65 fe a6 49 19 41 f9 9b |..g.Y...e..I.A..| +000002a0 40 3a 62 ec 4d 1f 83 77 03 9d 4b 4c d2 5d 93 ca |@:b.M..w..KL.]..| +000002b0 01 39 44 dc c6 f7 18 6b 2a c9 1b 3d ef 27 6d a4 |.9D....k*..=.'m.| +000002c0 2e 8f 33 63 2b c5 fb bb 52 23 68 7e 0b 16 92 64 |..3c+...R#h~...d| +000002d0 d9 72 04 2d 0d b2 ba 67 45 ae 14 16 f1 57 3b 59 |.r.-...gE....W;Y| +000002e0 44 ba db b0 c9 d2 9b 8f 6d b2 a4 8c c2 d1 1c e4 |D.......m.......| +000002f0 ce d3 32 bf 04 d9 09 d1 28 3d 25 2d b5 d3 da 12 |..2.....(=%-....| +00000300 77 01 45 09 08 e0 df cc f3 4c c0 e0 b7 d7 d8 16 |w.E......L......| +00000310 82 19 1d 57 dc b4 27 83 48 1b 9f a9 0e cc d6 39 |...W..'.H......9| +00000320 c1 4a 66 b3 42 85 a5 a7 14 97 5c 58 fe 41 e1 2e |.Jf.B.....\X.A..| +00000330 16 e9 70 89 e7 98 a8 f3 4a 81 d4 d8 ff 5f 48 6e |..p.....J...._Hn| +00000340 60 c6 4a 07 c5 57 9c 22 25 3a 9f bf 7e 71 f3 0d |`.J..W."%:..~q..| +00000350 71 e5 a5 d4 2b 6d 70 2f c5 a3 17 03 03 00 99 b9 |q...+mp/........| +00000360 15 c7 70 bc 06 75 26 50 0f 22 90 43 99 25 0d 0f |..p..u&P.".C.%..| +00000370 05 d3 ce e7 3c 53 fb 01 d4 d2 e8 fb b7 49 87 03 |....K......#..._C.| +000003e0 75 65 ac ba 46 43 61 b4 3d be b8 49 44 ad 15 00 |ue..FCa.=..ID...| +000003f0 3b c0 07 ba 18 b2 14 71 17 03 03 00 35 d1 22 81 |;......q....5.".| +00000400 7f 21 e9 e2 7b 11 f5 df dd 3f 15 ce b5 fc 71 f3 |.!..{....?....q.| +00000410 0e f2 d0 1c a4 85 29 88 f2 ca 73 01 ee 1c e4 66 |......)...s....f| +00000420 07 fa 5c a3 32 b0 e4 2a e4 97 e5 70 b1 cd db 79 |..\.2..*...p...y| +00000430 83 1f |..| >>> Flow 3 (client to server) -00000000 14 03 03 00 01 01 17 03 03 01 50 e5 d5 ff 01 ac |..........P.....| -00000010 29 be dc aa 07 05 88 f6 e6 ae aa 3f 10 c6 72 1e |)..........?..r.| -00000020 31 1a dc e5 64 ab 1f 82 60 0a a3 24 59 4a 91 86 |1...d...`..$YJ..| -00000030 d0 90 e5 5a ca ad 5b c4 18 a6 c3 d8 56 7b 86 7c |...Z..[.....V{.|| -00000040 53 b4 59 7e 91 5d 9c 32 11 44 66 7c 75 43 d1 d9 |S.Y~.].2.Df|uC..| -00000050 dc bd 99 7d 37 37 c1 be ef 61 bf fb b4 f4 2e 2e |...}77...a......| -00000060 c5 66 fa d2 a1 86 4e 42 03 ed 7b 78 2b 82 f8 6d |.f....NB..{x+..m| -00000070 f5 12 6f 60 c7 93 03 12 43 5a 4b 21 25 88 8b 54 |..o`....CZK!%..T| -00000080 37 2e 9b 1d bb 86 4a 85 80 e2 cb b1 0b 38 05 b1 |7.....J......8..| -00000090 d2 a7 04 c6 a3 db df cb 18 90 db 17 dd f1 04 44 |...............D| -000000a0 c0 5a ce ed 39 4e 89 91 8c 00 a2 8e 5f c4 64 8d |.Z..9N......_.d.| -000000b0 22 e5 53 7c ea 2d 09 65 0f 76 31 ef 50 b6 b7 6f |".S|.-.e.v1.P..o| -000000c0 a4 63 83 c2 90 07 67 28 37 c2 56 cb 56 71 92 3c |.c....g(7.V.Vq.<| -000000d0 ea 34 3b 54 58 78 b1 c0 ef 1c fc 4e c4 c5 f7 89 |.4;TXx.....N....| -000000e0 55 f4 95 c0 bc af 1f 9e 0d f3 b8 35 54 64 c2 4b |U..........5Td.K| -000000f0 cc 4b 30 6f e0 5c 7b 51 1c 05 51 b3 6a f2 60 1f |.K0o.\{Q..Q.j.`.| -00000100 a5 26 ec ad 5f 93 1a 45 f9 88 73 5a 9a 51 fe c8 |.&.._..E..sZ.Q..| -00000110 1a e7 9b 8c 9d a6 55 68 57 80 a5 81 8e bd 1a 5f |......UhW......_| -00000120 9d 56 89 8f 32 9a 5b 4c 60 e0 b2 73 e5 5c 04 62 |.V..2.[L`..s.\.b| -00000130 62 1c ee 89 6d 00 4a bb e0 b9 5f 6f f3 a7 5e bc |b...m.J..._o..^.| -00000140 95 a1 a8 a7 94 c2 06 19 97 0f 2f ff b0 95 c6 39 |........../....9| -00000150 8d 96 59 71 87 90 34 76 b2 3b 7d 17 03 03 00 59 |..Yq..4v.;}....Y| -00000160 7d ba 65 99 35 1b 2b 93 b1 76 99 9a 5a 90 4c 2a |}.e.5.+..v..Z.L*| -00000170 2a 14 1e 99 dd 23 10 95 fb 5b 9f 28 47 4d 41 3e |*....#...[.(GMA>| -00000180 71 d4 93 20 ee 69 32 85 b5 59 2a d0 1c 19 53 84 |q.. .i2..Y*...S.| -00000190 46 0d cc 6a 9b a3 83 68 22 79 e5 e3 f4 56 a9 76 |F..j...h"y...V.v| -000001a0 a0 9f d9 3c 27 3f 28 cb ab eb f3 55 41 2b ce 6f |...<'?(....UA+.o| -000001b0 5a e5 22 c1 c9 0f 44 fc 8f 17 03 03 00 35 f6 80 |Z."...D......5..| -000001c0 8e d2 cc 5b 6d 94 18 83 d2 70 87 e5 2c f2 0a 7a |...[m....p..,..z| -000001d0 44 a4 e9 6d f3 74 02 61 1b 87 6c b7 bf 8a ba 41 |D..m.t.a..l....A| -000001e0 3b d8 18 2f 1d ad c3 9c c8 6c c9 a0 82 7c bf 2b |;../.....l...|.+| -000001f0 f8 c2 09 17 03 03 00 17 79 0a 43 29 1d d6 b5 fc |........y.C)....| -00000200 fe 27 55 b8 5a 69 f1 b9 ed 31 63 2f 51 76 e1 17 |.'U.Zi...1c/Qv..| -00000210 03 03 00 13 72 86 7e a3 6c af 2b e3 85 4c 16 74 |....r.~.l.+..L.t| -00000220 97 73 48 96 ba 46 bd |.sH..F.| +00000000 14 03 03 00 01 01 17 03 03 01 50 dd d8 5d 40 64 |..........P..]@d| +00000010 5d 35 b0 82 0d 46 97 4c a2 d1 4d dd 3c c9 0a f9 |]5...F.L..M.<...| +00000020 39 6a 1c 17 c3 f6 1a 6b 42 cc f7 37 23 7a e1 bf |9j.....kB..7#z..| +00000030 de 51 7f 87 6b 3d d6 4d ed 24 b3 de dd 62 18 4a |.Q..k=.M.$...b.J| +00000040 b5 b3 1e 0f 2f a3 c5 e8 67 65 04 bc 37 97 15 a8 |..../...ge..7...| +00000050 a8 f3 a8 79 99 82 e1 10 5d d7 f2 ee 21 46 aa b8 |...y....]...!F..| +00000060 40 9f 3b fc 12 19 c8 82 b4 8e bc b8 9b a9 f6 aa |@.;.............| +00000070 18 6b 48 4e 03 92 43 12 b8 54 f2 b7 29 0b 0a a1 |.kHN..C..T..)...| +00000080 6f c4 1c 2a af 22 c1 3d 1b 43 a5 3c 7d 39 83 5d |o..*.".=.C.<}9.]| +00000090 ee 09 fb f1 9a 4c ff b3 2a bb 85 53 04 18 5e 18 |.....L..*..S..^.| +000000a0 62 e8 cf ec 01 be 76 31 82 1a 60 19 33 c7 37 0a |b.....v1..`.3.7.| +000000b0 fa 45 4d b1 9a 1e 07 e9 9c 45 c3 89 60 a2 c9 59 |.EM......E..`..Y| +000000c0 8c 7d 02 f6 d6 5c 12 26 bd 6d 97 15 e2 07 27 be |.}...\.&.m....'.| +000000d0 2f 59 93 1b 11 0e 05 ef 83 c6 a2 c0 1a 9a 4c 60 |/Y............L`| +000000e0 a6 84 c0 72 b6 2b 7c a1 37 4c d7 eb 76 0f 00 97 |...r.+|.7L..v...| +000000f0 43 b6 25 ed 36 e1 eb 3a 3d 71 05 d8 d0 f9 80 18 |C.%.6..:=q......| +00000100 b2 9b c0 4e 2c 8e 05 41 52 a5 40 57 3c 1f 48 0c |...N,..AR.@W<.H.| +00000110 55 ea d3 76 6d 3a 26 5d 5d 71 74 1c d5 8d 96 92 |U..vm:&]]qt.....| +00000120 79 c5 9c 78 68 5f 20 12 01 06 c3 52 49 66 e4 5b |y..xh_ ....RIf.[| +00000130 41 09 fa 72 c5 d7 d9 26 1b fa a5 1d 23 b2 4a 1e |A..r...&....#.J.| +00000140 da 83 5e 89 c8 3a c4 26 f2 42 70 6d 1b 90 67 eb |..^..:.&.Bpm..g.| +00000150 37 15 35 b9 a2 b0 2b ef 93 5f 11 17 03 03 00 59 |7.5...+.._.....Y| +00000160 b4 a0 79 ba e4 3f 78 d2 11 1a 71 8a a1 a4 28 fc |..y..?x...q...(.| +00000170 44 c7 bc 32 19 06 71 1b 6d 50 20 26 d5 91 39 48 |D..2..q.mP &..9H| +00000180 59 8b fd 55 0a 35 14 f5 31 47 62 15 ee c1 69 23 |Y..U.5..1Gb...i#| +00000190 eb db 79 ef 20 47 5c ef 31 e1 ae bd 2f 72 f8 9d |..y. G\.1.../r..| +000001a0 92 cc 04 6f 73 22 5d 93 59 9f 06 cb bd 70 9b d8 |...os"].Y....p..| +000001b0 c9 41 44 8f 5b b2 59 2b a9 17 03 03 00 35 22 65 |.AD.[.Y+.....5"e| +000001c0 ef 1e dc 4c 63 ba 6d 6a 46 1c d2 9c 9a 81 4b f3 |...Lc.mjF.....K.| +000001d0 1f 58 4e 08 86 93 f8 3a 53 13 64 1f ca 20 d2 da |.XN....:S.d.. ..| +000001e0 6b df 54 88 a8 f3 af 0d 4a 1b 29 91 3a bb 90 27 |k.T.....J.).:..'| +000001f0 29 3a 97 17 03 03 00 17 09 78 1d f3 95 2e 92 af |):.......x......| +00000200 d8 af 64 59 fb 77 e3 85 de f0 37 be 11 91 2f 17 |..dY.w....7.../.| +00000210 03 03 00 13 4e a2 06 c3 90 6f d3 b0 04 a8 25 32 |....N....o....%2| +00000220 09 65 1c f2 ef 9c 32 |.e....2| diff --git a/testdata/Client-TLSv13-ClientCert-RSA-ECDSA b/testdata/Client-TLSv13-ClientCert-RSA-ECDSA index e0acf89..0cd5b76 100644 --- a/testdata/Client-TLSv13-ClientCert-RSA-ECDSA +++ b/testdata/Client-TLSv13-ClientCert-RSA-ECDSA @@ -7,129 +7,129 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 7f 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 0a 00 08 00 1d 00 17 00 18 00 19 00 0b 00 02 01 |................| -000000a0 00 00 0d 00 1a 00 18 08 04 04 03 08 07 08 05 08 |................| -000000b0 06 04 01 05 01 06 01 05 03 06 03 02 01 02 03 ff |................| -000000c0 01 00 01 00 00 17 00 00 00 12 00 00 00 2b 00 09 |.............+..| +00000080 01 00 00 7f 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 19 00 0d |................| +000000b0 00 1a 00 18 08 04 04 03 08 07 08 05 08 06 04 01 |................| +000000c0 05 01 06 01 05 03 06 03 02 01 02 03 00 2b 00 09 |.............+..| 000000d0 08 03 04 03 03 03 02 03 01 00 33 00 26 00 24 00 |..........3.&.$.| 000000e0 1d 00 20 2f e5 7d a3 47 cd 62 43 15 28 da ac 5f |.. /.}.G.bC.(.._| 000000f0 bb 29 07 30 ff f6 84 af c4 cf c2 ed 90 99 5f 58 |.).0.........._X| 00000100 cb 3b 74 |.;t| >>> Flow 2 (server to client) -00000000 16 03 03 00 7a 02 00 00 76 03 03 17 5d 17 94 35 |....z...v...]..5| -00000010 cc 45 ba fc 44 dd 02 57 2c 67 67 c1 f9 7d bb 52 |.E..D..W,gg..}.R| -00000020 fb 5e dd a2 29 43 14 95 be a7 98 20 00 00 00 00 |.^..)C..... ....| +00000000 16 03 03 00 7a 02 00 00 76 03 03 40 ad 79 0c ad |....z...v..@.y..| +00000010 83 38 58 82 dc b2 5a d1 e2 de f5 43 99 72 8a 93 |.8X...Z....C.r..| +00000020 ba b1 ea 17 21 52 a7 e9 ed dc 48 20 00 00 00 00 |....!R....H ....| 00000030 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |................| 00000040 00 00 00 00 00 00 00 00 00 00 00 00 13 03 00 00 |................| -00000050 2e 00 2b 00 02 03 04 00 33 00 24 00 1d 00 20 8f |..+.....3.$... .| -00000060 cd f2 33 7c ee 70 18 fa 98 64 43 1b 24 e2 80 80 |..3|.p...dC.$...| -00000070 a9 e3 3c 49 f3 a2 68 b6 ba 09 3b ef f4 4e 20 14 |..-..@..7S..| -00000120 8a da 06 d7 26 a9 ae e0 f4 b3 d2 33 37 06 8d 76 |....&......37..v| -00000130 24 63 42 33 65 ad dd 23 c3 cb b3 6f 8c 0c ee be |$cB3e..#...o....| -00000140 63 1a 61 13 29 2a af 74 67 6a 19 d7 22 12 8a dc |c.a.)*.tgj.."...| -00000150 ce 77 81 26 b1 1a 2b 5d 77 0c 9a 65 6d 75 f0 90 |.w.&..+]w..emu..| -00000160 95 66 84 3d d6 fd 95 c5 dd fd 80 5b 8e ab 1b 0b |.f.=.......[....| -00000170 f1 f0 b9 8c fc e2 3b ce 05 03 ef dc 4b 08 69 af |......;.....K.i.| -00000180 22 58 7b ab 6b cf 8e 63 40 e4 8d c3 5c f4 29 cc |"X{.k..c@...\.).| -00000190 d7 d2 17 94 af a3 ff 31 e4 75 78 c5 17 fb 84 f5 |.......1.ux.....| -000001a0 e0 4b f8 70 3d 57 e0 dc 70 c5 5e 44 5a ea 2a 33 |.K.p=W..p.^DZ.*3| -000001b0 22 47 a3 e4 7a 95 d6 10 7e 6f 87 b4 bc 5a 9a ba |"G..z...~o...Z..| -000001c0 99 af 7c 0d 6f 4d cc c7 0d 12 c9 99 e1 d7 90 2d |..|.oM.........-| -000001d0 8c 7b 24 11 c6 3e d0 16 fb a5 87 06 8f b5 e3 a5 |.{$..>..........| -000001e0 f2 e5 d4 76 09 9e 9f ec ef 58 b0 34 9c ff 21 aa |...v.....X.4..!.| -000001f0 48 a0 c8 2e ca 2d 8a cc ad aa 9a 07 bd cc e4 12 |H....-..........| -00000200 cd 33 5d b2 a7 95 a2 8c e0 74 5b 6f e3 dd ce af |.3]......t[o....| -00000210 05 8a fe 52 d8 23 b8 70 bd 45 90 38 05 bf d5 89 |...R.#.p.E.8....| -00000220 0f 4b 08 83 03 07 f0 24 bc 9d a9 d7 f4 0a 2b 94 |.K.....$......+.| -00000230 82 f1 7a 3b 49 85 06 0e d9 e6 c8 7c 69 f9 f6 61 |..z;I......|i..a| -00000240 34 0e 6e 8c c5 76 18 f0 88 22 a0 3d b5 9a 92 55 |4.n..v...".=...U| -00000250 88 37 ff 06 53 a9 64 4c 7d 12 c8 ac 72 de 74 d6 |.7..S.dL}...r.t.| -00000260 62 ea 27 f5 e8 d1 09 a2 b1 df 1d 32 d3 15 b0 52 |b.'........2...R| -00000270 98 fd 24 0b dd 33 0a 88 92 d1 cf c5 1a ef 27 8a |..$..3........'.| -00000280 7d b2 59 74 97 24 9c c3 cc 0e 1c a5 26 c7 5a 10 |}.Yt.$......&.Z.| -00000290 0d be 10 b2 bc 79 76 21 b5 b7 48 24 59 08 41 4d |.....yv!..H$Y.AM| -000002a0 3c 31 ad cf 02 4b ed a5 fb 0d d7 55 60 fa cf 04 |<1...K.....U`...| -000002b0 dd 84 0c 0b e9 eb ea 6d e2 33 9d 04 1d 0b fe b1 |.......m.3......| -000002c0 e2 cd 2d c8 84 2d be fd ae 9e 1a 61 70 b9 d4 6e |..-..-.....ap..n| -000002d0 74 9f 68 b3 60 aa 42 bc 98 8d d7 45 f4 3b 00 2b |t.h.`.B....E.;.+| -000002e0 0d 55 f4 14 5d 9a ab f9 d1 af 9c b3 18 e3 8d f9 |.U..]...........| -000002f0 8d 11 89 3e e7 6a f2 b8 52 fd 67 71 37 b4 ec c1 |...>.j..R.gq7...| -00000300 6f d9 d6 57 67 4d 05 48 22 3a 4b 79 3b 2c 70 17 |o..WgM.H":Ky;,p.| -00000310 03 03 00 a3 c6 8b 11 15 2c 6f 55 2f 96 01 24 f1 |........,oU/..$.| -00000320 bd c2 79 09 2f d3 ff 9a bb a4 b8 f5 f3 fe 85 d7 |..y./...........| -00000330 7a 21 b9 92 e6 b5 89 c9 fb fb e2 4a 8f 5a 5c 63 |z!.........J.Z\c| -00000340 7d 8c 4e 9a 27 1b 4a bb e4 bb f0 cf 3f 5c c6 db |}.N.'.J.....?\..| -00000350 d8 83 bf 57 be ac ed 5f 1a 2c 10 77 7c b7 70 0f |...W..._.,.w|.p.| -00000360 4b 2d 93 e5 46 d1 75 fa e4 da 73 c2 72 d6 48 6f |K-..F.u...s.r.Ho| -00000370 0d 21 eb 9d 2b d3 12 d9 d1 3c 9b 56 c3 90 2d 1b |.!..+....<.V..-.| -00000380 79 9a ab e8 2c 55 0e 67 0b 58 f8 ac 24 3a 6c a5 |y...,U.g.X..$:l.| -00000390 34 29 30 6a b3 84 5a bc 59 f8 9c 07 75 b1 e8 ed |4)0j..Z.Y...u...| -000003a0 80 96 11 ad da 74 3b d8 9c 5c 71 8f a6 30 ad 77 |.....t;..\q..0.w| -000003b0 e7 64 13 50 5e 76 ef 17 03 03 00 35 b3 db 05 94 |.d.P^v.....5....| -000003c0 08 9b e0 1d 45 12 11 c7 b0 5e 61 ac a0 e7 8e 80 |....E....^a.....| -000003d0 30 7f 20 19 69 da 73 06 a5 dd 7c 85 4e fa cc 37 |0. .i.s...|.N..7| -000003e0 2c f8 4e fd ce 2b 4b f4 fd 68 de 23 15 36 00 8c |,.N..+K..h.#.6..| -000003f0 e7 |.| +00000050 2e 00 2b 00 02 03 04 00 33 00 24 00 1d 00 20 bd |..+.....3.$... .| +00000060 d2 3a 7e c2 30 84 4f f2 39 7e 26 11 65 49 b9 b2 |.:~.0.O.9~&.eI..| +00000070 ac 63 c8 ef ea 5e f6 23 33 70 ec 16 86 49 03 14 |.c...^.#3p...I..| +00000080 03 03 00 01 01 17 03 03 00 17 16 47 c1 58 83 6b |...........G.X.k| +00000090 66 06 c4 39 42 8f 68 fb 3a 07 9e e7 74 41 0d 10 |f..9B.h.:...tA..| +000000a0 97 17 03 03 00 42 42 b2 84 94 a6 18 c6 b6 21 77 |.....BB.......!w| +000000b0 1e 02 57 4a 14 2d c4 84 17 f1 fa b4 63 0f aa d7 |..WJ.-......c...| +000000c0 4a d5 ae 75 f1 da 14 ec 51 09 93 6b 62 6f 8f 7e |J..u....Q..kbo.~| +000000d0 fe 0c 7f 63 ef 1b 87 d8 43 42 d0 f4 2d 6d 0f cc |...c....CB..-m..| +000000e0 ef 77 79 17 1e 39 1e 75 17 03 03 02 22 9c 82 27 |.wy..9.u...."..'| +000000f0 99 e0 4b 44 a7 a7 bb a9 25 a2 58 7f 70 3f 82 1a |..KD....%.X.p?..| +00000100 4b bc e1 35 3e 66 fa 4f ac 7f 7e da 73 13 06 0f |K..5>f.O..~.s...| +00000110 fe 97 ef 82 53 2e d0 e2 11 c6 ee 8d 25 d2 f0 5c |....S.......%..\| +00000120 2e b8 61 40 09 12 d4 11 9b b8 3d 38 d7 d5 a7 76 |..a@......=8...v| +00000130 ed a7 bf 6f 39 9c 83 49 57 86 de 53 da c5 ff 8a |...o9..IW..S....| +00000140 ee 47 bc 19 72 d3 cc d0 5b fc 6b 25 2f 64 2a 0c |.G..r...[.k%/d*.| +00000150 7d e9 8a 1f f8 48 d1 74 d5 70 97 e7 b4 e2 c8 ce |}....H.t.p......| +00000160 dc 74 27 e9 af b1 64 56 19 28 8a 34 93 4e 1c 03 |.t'...dV.(.4.N..| +00000170 67 ae 41 fb 5f d1 e3 20 45 6b bd 49 25 d8 b4 8b |g.A._.. Ek.I%...| +00000180 d4 96 d6 96 b2 72 72 f0 d0 68 f1 f7 f3 17 76 85 |.....rr..h....v.| +00000190 78 0e dd 35 83 8a 7a 45 c5 91 86 4b a6 b5 77 b4 |x..5..zE...K..w.| +000001a0 ef 02 43 5c 42 c7 f8 a6 1d ed 73 d2 41 02 be cb |..C\B.....s.A...| +000001b0 24 40 61 5a 5f 7a f6 bf f9 d0 bd 05 7f 90 52 16 |$@aZ_z........R.| +000001c0 65 49 c6 74 61 f0 05 fa dd 83 69 b7 ff 5a 2c 4b |eI.ta.....i..Z,K| +000001d0 63 6d d2 57 01 43 67 54 25 90 72 f8 12 7e c2 39 |cm.W.CgT%.r..~.9| +000001e0 26 a9 65 55 02 ca 87 8a e6 13 cd a4 6b eb 3c 4d |&.eU........k.#| +00000250 59 38 6c 9f be 1b ba 60 93 e8 c9 24 fb 13 11 b7 |Y8l....`...$....| +00000260 78 d8 a7 30 6d 06 0f 4d 59 5d d1 1f 81 13 33 99 |x..0m..MY]....3.| +00000270 a8 4d 63 16 53 73 40 22 4b 55 21 79 c1 ce 1c 92 |.Mc.Ss@"KU!y....| +00000280 8c d6 95 14 fd 93 5d c2 54 20 30 c5 79 b0 cd eb |......].T 0.y...| +00000290 ac 1b 50 6a 25 b7 e8 f1 0f da f3 d8 6b 17 2b 12 |..Pj%.......k.+.| +000002a0 06 a8 9a 88 be 2f f3 52 b3 d7 70 05 df 57 88 f9 |...../.R..p..W..| +000002b0 ec 59 d4 e7 ce cb c3 1f 33 3e c0 d8 04 9f 59 a0 |.Y......3>....Y.| +000002c0 04 c0 13 b3 a6 7c ce 6c c4 fa 82 cd da 11 17 b6 |.....|.l........| +000002d0 c2 40 cd e6 5a 6e d3 b5 17 f0 4d c4 34 8f 2a 28 |.@..Zn....M.4.*(| +000002e0 4d ce 93 d5 eb 7e 0a d2 57 0a 98 cf ac 48 ee a8 |M....~..W....H..| +000002f0 8a bd ec c2 d7 d9 39 af e2 a0 9f b2 fd d1 4e 96 |......9.......N.| +00000300 fa fd 34 f7 a4 3e 3d 31 9a f6 a2 a7 97 a3 43 17 |..4..>=1......C.| +00000310 03 03 00 a4 cf 0d e1 8d b7 e4 1a c0 79 0d 7e d9 |............y.~.| +00000320 70 a3 34 57 0f 72 b4 5c 05 7f 1e 16 52 ba d3 e7 |p.4W.r.\....R...| +00000330 fb e5 b8 b0 8d cf 91 7e 96 c4 70 6e cb e5 7e 51 |.......~..pn..~Q| +00000340 19 17 c1 94 e9 49 69 a0 21 59 74 a9 1d 34 9c 10 |.....Ii.!Yt..4..| +00000350 a9 10 f0 4a 51 2c e3 1d e3 59 28 f2 3b ea 66 c1 |...JQ,...Y(.;.f.| +00000360 ed 6a 8d 39 72 ea 5a 24 7a ee 9f cd 85 9d 54 60 |.j.9r.Z$z.....T`| +00000370 d4 95 fd 8d 63 a4 78 6c 2f 7d 6a a5 53 e4 42 97 |....c.xl/}j.S.B.| +00000380 e8 19 36 bf 14 9c a8 48 9f 57 ad 29 7a 30 e5 a9 |..6....H.W.)z0..| +00000390 32 e7 0f 24 9c ca 9d 6d b7 47 46 1c cb 90 7d 18 |2..$...m.GF...}.| +000003a0 39 70 d2 c1 08 28 dc d7 3a 3e 5e 62 a7 4a 4a af |9p...(..:>^b.JJ.| +000003b0 02 93 ce 4b 5d a2 96 f3 17 03 03 00 35 10 07 d6 |...K].......5...| +000003c0 82 f3 28 ef 2f 08 17 f6 0b c2 da 1f b7 52 e1 eb |..(./........R..| +000003d0 ca f4 0b c6 21 5c 54 4d f9 0b 04 c1 5a bf 63 58 |....!\TM....Z.cX| +000003e0 1c e1 da 7f f7 1f 84 77 09 3a 35 7c e6 1f 89 f2 |.......w.:5|....| +000003f0 fd 01 |..| >>> Flow 3 (client to server) -00000000 14 03 03 00 01 01 17 03 03 02 11 ee 00 8e e7 34 |...............4| -00000010 b5 6f 32 2e e9 11 e3 7f 24 ff 64 6a 47 04 6d f7 |.o2.....$.djG.m.| -00000020 3a 92 d5 45 12 92 c7 67 ea 91 31 9e 6e 61 a1 52 |:..E...g..1.na.R| -00000030 9c e6 16 17 d3 8e 9e 41 85 1f a5 6a 69 97 53 f8 |.......A...ji.S.| -00000040 35 b8 81 43 af 59 25 fc 78 42 b4 6f c1 4b 54 e2 |5..C.Y%.xB.o.KT.| -00000050 e1 c1 97 b5 74 ea c8 b7 42 20 b2 42 27 68 7d f7 |....t...B .B'h}.| -00000060 8c e0 18 53 46 e1 fc 86 55 bc 28 8a e1 95 94 24 |...SF...U.(....$| -00000070 d4 38 80 a7 7e 85 2c a9 81 c2 4b c7 51 d5 0f 1f |.8..~.,...K.Q...| -00000080 88 8a 93 7d 74 53 1e f3 2b b6 b3 4a b5 a8 0c ea |...}tS..+..J....| -00000090 c4 6e 10 c3 8f ac 96 2f c5 6b 63 f0 11 b0 38 81 |.n...../.kc...8.| -000000a0 16 3c 96 fb d0 e9 18 5a 08 a0 f4 5e f0 6d 01 ff |.<.....Z...^.m..| -000000b0 13 04 c3 f7 e8 23 2a 06 32 6d 2b f1 d4 cc 60 ab |.....#*.2m+...`.| -000000c0 c9 9e c8 08 1d 8a 06 ff 7f 26 e1 db 13 d5 cd 3e |.........&.....>| -000000d0 5f 61 11 9b 43 cc 1e 19 32 6e 01 f0 79 3e cb 02 |_a..C...2n..y>..| -000000e0 7d 4c 27 ee b0 4a 24 44 c7 ff 16 e5 59 c0 b1 2f |}L'..J$D....Y../| -000000f0 9a f6 c5 39 1f f2 f3 f0 70 89 e3 cb a4 43 81 16 |...9....p....C..| -00000100 40 dd e2 3a e1 12 be 29 64 cb f3 f9 20 2c c9 62 |@..:...)d... ,.b| -00000110 84 9c 31 fb 9b 95 a4 ac 3e 1d f4 19 bb 0a ce 89 |..1.....>.......| -00000120 3a 33 9e 40 2b da 42 5c 71 59 54 bb 65 de eb 9e |:3.@+.B\qYT.e...| -00000130 71 46 40 9f 3d 6d 88 3a 0d b9 08 63 7d 4f a3 5b |qF@.=m.:...c}O.[| -00000140 9a 67 03 a0 d9 c6 47 4b 3b 11 d0 7b 13 fb 93 d1 |.g....GK;..{....| -00000150 fc 63 dc 45 f2 b4 8b 22 12 31 20 48 6e 9a 4e 7d |.c.E...".1 Hn.N}| -00000160 3f 7e cd 09 6a ea 5f a1 0a e5 d8 80 c0 ed 6a cb |?~..j._.......j.| -00000170 0a af 1e 8f 88 63 63 13 49 02 d9 01 87 03 4f 9f |.....cc.I.....O.| -00000180 cc a2 5f 2f a8 3d 2b 9f a2 f0 81 b5 b0 d2 92 6c |.._/.=+........l| -00000190 8f 3b f6 5c 66 27 d4 98 6e 86 e5 a5 ab 3c 1b b8 |.;.\f'..n....<..| -000001a0 eb cb 72 d9 6c d8 49 9a 33 db 75 e6 3f ff 2a b0 |..r.l.I.3.u.?.*.| -000001b0 77 c6 02 f1 c0 a5 74 99 42 42 e8 97 b5 27 a9 11 |w.....t.BB...'..| -000001c0 af b7 65 b3 a8 51 dd 44 35 6e 0c 34 d5 b2 38 75 |..e..Q.D5n.4..8u| -000001d0 f0 cf 10 ff 5a 7a 16 ca bd 44 e8 99 91 50 9f db |....Zz...D...P..| -000001e0 8c ff 54 3a 24 73 de d1 29 5a 49 fc b3 d0 31 80 |..T:$s..)ZI...1.| -000001f0 6f 16 84 c1 83 cf 9d 75 d4 b5 a5 a0 a0 15 bc 03 |o......u........| -00000200 38 61 89 f5 16 98 25 f0 e8 72 28 3e d4 d6 64 66 |8a....%..r(>..df| -00000210 de ff be 71 34 7c b1 63 38 38 81 03 17 03 03 00 |...q4|.c88......| -00000220 99 3d e0 6d 2f 4c 22 62 d8 5f 0b 53 8a 99 c4 b2 |.=.m/L"b._.S....| -00000230 66 88 d0 71 0c 90 b3 2e 9c 24 d1 89 4d f0 4d 29 |f..q.....$..M.M)| -00000240 a7 11 87 db 08 cd 04 6c 1f 60 54 12 47 83 c7 82 |.......l.`T.G...| -00000250 be 1b d8 ed 2f 43 c1 cf 63 21 bc 21 80 ad 7b ed |..../C..c!.!..{.| -00000260 5c 0b 41 0d 5e 63 eb 82 15 69 d7 11 c4 3f 0d fb |\.A.^c...i...?..| -00000270 07 96 34 a9 2c 9f 7f d7 fa 2c 24 c8 52 59 c3 07 |..4.,....,$.RY..| -00000280 03 c7 88 65 8a 20 f2 1a 23 f8 18 2e 94 c6 be 77 |...e. ..#......w| -00000290 bc 6e ff 7e 83 3e 9f 1f 77 b5 2b 67 e9 3d 03 c7 |.n.~.>..w.+g.=..| -000002a0 b4 be 58 d1 12 69 39 3c 2d b3 dd 2e fb 41 b3 0b |..X..i9<-....A..| -000002b0 b2 74 d0 80 8a 90 40 ab 59 30 17 03 03 00 35 ef |.t....@.Y0....5.| -000002c0 7c c8 f8 01 6b 69 36 b2 26 9f 65 d8 a8 04 8a 41 ||...ki6.&.e....A| -000002d0 58 e3 7a 6d 55 94 ec 09 df 6a a8 0d 86 54 c3 00 |X.zmU....j...T..| -000002e0 a8 c2 46 e1 c0 83 fd 16 40 98 b3 5d c6 cc dc 3f |..F.....@..]...?| -000002f0 c2 4f 95 61 17 03 03 00 17 39 cc 91 bc 98 39 0c |.O.a.....9....9.| -00000300 1c 43 3c b5 cb 3b c0 99 68 9c 31 b5 1a d0 41 f9 |.C<..;..h.1...A.| -00000310 17 03 03 00 13 65 9c ec ea 6e ac de 8c aa 1d 5e |.....e...n.....^| -00000320 ff 7f 0d 3e 84 7a 90 6a |...>.z.j| +00000000 14 03 03 00 01 01 17 03 03 02 11 f1 43 fc 28 7d |............C.(}| +00000010 43 0b 17 e4 ed cc 95 d5 09 4e 8f 44 3c 3b 46 23 |C........N.D<;F#| +00000020 59 a4 62 a7 94 1e da b6 a7 a5 22 15 6a ed e3 eb |Y.b.......".j...| +00000030 4f 6d 0e 91 c6 20 74 af 97 80 95 db 6a b6 2d ac |Om... t.....j.-.| +00000040 a8 d9 95 84 95 5b 32 27 ec 42 42 a8 fd 05 fc ad |.....[2'.BB.....| +00000050 2e 00 e3 4a 9d 93 d1 5e fd dc 22 30 1f 9c e9 cb |...J...^.."0....| +00000060 3f 2e ac ad 0f ab b7 46 82 69 38 db c6 8a be 77 |?......F.i8....w| +00000070 7e 83 77 4c e1 f4 f2 cf c2 b1 86 ff 17 d3 1d 79 |~.wL...........y| +00000080 3e ac f8 6e 73 15 ab 02 4c bf 2a 63 41 ce 93 3b |>..ns...L.*cA..;| +00000090 af 11 70 8c 91 91 f4 14 5c 1b 63 4b 42 3b d8 ca |..p.....\.cKB;..| +000000a0 00 f6 02 b3 c8 d3 ab 01 1d f2 71 86 7b f9 13 de |..........q.{...| +000000b0 1e 39 1c e7 b5 3b b5 bb 26 33 f7 a9 3f 29 e2 8c |.9...;..&3..?)..| +000000c0 d1 67 64 11 b4 29 be 6e c9 cf c5 6e 41 43 41 e7 |.gd..).n...nACA.| +000000d0 43 9c 5d fb a1 b6 b3 f9 0f 4c 17 11 3c 56 0e 49 |C.]......L...z.U.....4..| +00000130 11 86 8a 14 8e d6 5c c0 c2 55 de da 37 c4 ac 69 |......\..U..7..i| +00000140 95 42 84 5f 1d 5f c7 32 91 a9 45 02 c3 a3 da 4f |.B._._.2..E....O| +00000150 96 da c0 a2 09 7a a6 2b 25 f4 a2 94 89 fa bd 0f |.....z.+%.......| +00000160 87 04 e1 87 00 c4 4f 45 39 7a 5a 7d 75 c5 c9 f6 |......OE9zZ}u...| +00000170 27 34 2d ba 12 c5 2c 76 06 b0 aa d0 34 e1 99 e9 |'4-...,v....4...| +00000180 9b 01 db 2a b4 d5 dd 55 2b 92 6d e3 9e fc f1 09 |...*...U+.m.....| +00000190 2b 37 8b 37 8f 70 31 ee d2 f0 86 5a 1f d3 4a 29 |+7.7.p1....Z..J)| +000001a0 7c c9 0e 97 7c 4f e6 87 b7 c8 94 f3 d2 0b 4a 1d ||...|O........J.| +000001b0 59 60 09 81 55 6a 01 38 9f ca 20 e0 6e 44 f7 b5 |Y`..Uj.8.. .nD..| +000001c0 f6 3e 2e d0 81 f6 e6 1d 15 cf c3 d8 ae 98 84 d1 |.>..............| +000001d0 0b c9 e4 65 96 f9 eb c9 60 6d 50 37 49 9f 6d b1 |...e....`mP7I.m.| +000001e0 b9 f6 25 20 81 2d cf b4 17 2b 4c a9 8a 76 8a db |..% .-...+L..v..| +000001f0 77 8c 29 47 05 0b 27 e1 52 8d 37 27 fb c0 70 26 |w.)G..'.R.7'..p&| +00000200 3b 6d 2e 74 05 75 88 e4 63 3d ac 98 3f 74 67 3b |;m.t.u..c=..?tg;| +00000210 c6 dc 41 39 2b 20 ef f9 8b 2f 4e 20 17 03 03 00 |..A9+ .../N ....| +00000220 99 7d 8a 83 dd 34 5e 37 e2 c3 85 22 f3 6b ee bc |.}...4^7...".k..| +00000230 a5 21 1b c5 2c 38 cf 99 09 5b 31 97 5e a0 8b 69 |.!..,8...[1.^..i| +00000240 75 3a 23 64 18 22 fb 31 ed ac 8b 0f ae 9c 4e ee |u:#d.".1......N.| +00000250 06 0e 3c 3a 18 d3 8e 0c dc d4 3f 7b 25 e3 90 85 |..<:......?{%...| +00000260 ca f4 8a 5c 5e 5e 44 f3 1b 57 cd 14 e0 8d 67 36 |...\^^D..W....g6| +00000270 6e c2 a6 95 60 f3 86 20 29 a6 a8 8f b3 b0 0d 57 |n...`.. )......W| +00000280 d2 1e 4a b9 d2 63 33 09 f9 c5 87 94 89 c5 fd 2e |..J..c3.........| +00000290 de b3 f0 0e 7b 4e 3e d6 21 b4 3b 58 bd 2a 35 49 |....{N>.!.;X.*5I| +000002a0 5e b0 f4 5a ca 58 dc a5 8b 45 a5 d1 7b 13 b2 00 |^..Z.X...E..{...| +000002b0 52 c4 b2 6c d1 9a b8 c5 1b fe 17 03 03 00 35 c9 |R..l..........5.| +000002c0 9b c7 94 b3 eb 5f 4e ab 8c c0 de cf b6 b4 5c ee |....._N.......\.| +000002d0 bb 5f fa 48 a2 06 f0 ed f5 b1 ba 74 0c c5 64 1a |._.H.......t..d.| +000002e0 ce 2e 9e 90 4b 6e 98 13 a0 98 99 a3 b4 6f 73 76 |....Kn.......osv| +000002f0 7b e3 26 15 17 03 03 00 17 3e a1 f0 68 e6 00 86 |{.&......>..h...| +00000300 10 f4 bf 26 b6 f5 e6 77 85 ca b7 c1 75 bb f9 78 |...&...w....u..x| +00000310 17 03 03 00 13 43 7f f3 84 ee d7 a9 59 9d c3 5c |.....C......Y..\| +00000320 c0 b7 c8 20 4e 83 ba 23 |... N..#| diff --git a/testdata/Client-TLSv13-ClientCert-RSA-RSAPSS b/testdata/Client-TLSv13-ClientCert-RSA-RSAPSS index ec18187..e557181 100644 --- a/testdata/Client-TLSv13-ClientCert-RSA-RSAPSS +++ b/testdata/Client-TLSv13-ClientCert-RSA-RSAPSS @@ -7,138 +7,138 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 7f 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 0a 00 08 00 1d 00 17 00 18 00 19 00 0b 00 02 01 |................| -000000a0 00 00 0d 00 1a 00 18 08 04 04 03 08 07 08 05 08 |................| -000000b0 06 04 01 05 01 06 01 05 03 06 03 02 01 02 03 ff |................| -000000c0 01 00 01 00 00 17 00 00 00 12 00 00 00 2b 00 09 |.............+..| +00000080 01 00 00 7f 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 19 00 0d |................| +000000b0 00 1a 00 18 08 04 04 03 08 07 08 05 08 06 04 01 |................| +000000c0 05 01 06 01 05 03 06 03 02 01 02 03 00 2b 00 09 |.............+..| 000000d0 08 03 04 03 03 03 02 03 01 00 33 00 26 00 24 00 |..........3.&.$.| 000000e0 1d 00 20 2f e5 7d a3 47 cd 62 43 15 28 da ac 5f |.. /.}.G.bC.(.._| 000000f0 bb 29 07 30 ff f6 84 af c4 cf c2 ed 90 99 5f 58 |.).0.........._X| 00000100 cb 3b 74 |.;t| >>> Flow 2 (server to client) -00000000 16 03 03 00 7a 02 00 00 76 03 03 60 e7 99 c9 b0 |....z...v..`....| -00000010 be be 74 84 1e 55 cd 83 d6 0d ba 9c a0 44 fb b4 |..t..U.......D..| -00000020 a8 f6 3c 93 12 de 47 4a 7f 32 a6 20 00 00 00 00 |..<...GJ.2. ....| +00000000 16 03 03 00 7a 02 00 00 76 03 03 46 b8 dc eb 72 |....z...v..F...r| +00000010 ac 41 0a 3c 58 14 84 a0 75 91 e1 ca d7 3c c7 2c |.A..| -000000a0 dc 17 03 03 00 20 af 35 53 ab e6 10 47 24 e5 79 |..... .5S...G$.y| -000000b0 70 53 da 8e a2 bf 9a 81 ab 4d ba 80 09 40 e4 02 |pS.......M...@..| -000000c0 8c cb cc 78 1c d4 17 03 03 02 7a 9a eb 2c 4f f5 |...x......z..,O.| -000000d0 1a b9 d5 bc 47 d1 bc 35 47 07 66 bf 6d c9 35 b2 |....G..5G.f.m.5.| -000000e0 b2 78 ef 18 22 9a e4 fa b4 f8 12 0e fd aa a4 f7 |.x.."...........| -000000f0 9f f6 5b 2a 7b 05 c1 52 f8 2e 53 84 6c ef 51 e7 |..[*{..R..S.l.Q.| -00000100 4f e2 f5 e9 4b 20 da 94 5d 97 bb c2 66 fb 74 38 |O...K ..]...f.t8| -00000110 d6 15 0c c9 6e c6 67 ac ad 6f 4d d2 bf a2 13 29 |....n.g..oM....)| -00000120 87 69 9b 4d cd 2e 83 60 db 5f ee f3 80 64 02 93 |.i.M...`._...d..| -00000130 4f 1e 35 0b 01 25 1f cd 27 24 7a 82 8d 00 94 3a |O.5..%..'$z....:| -00000140 34 b0 f2 53 36 0b f6 04 d3 25 2a 4e 2a 7e 26 98 |4..S6....%*N*~&.| -00000150 41 ce 68 64 17 c9 65 9e f7 f9 bb df ee fb cb 74 |A.hd..e........t| -00000160 db 7d 8a 43 d2 49 03 f6 e5 be e1 5e 45 df 77 c4 |.}.C.I.....^E.w.| -00000170 1d 6e 9c ec 29 51 2b 7f 5e 75 46 05 50 39 5f fa |.n..)Q+.^uF.P9_.| -00000180 5f 53 04 56 25 87 09 26 36 8d 55 ac 03 87 35 28 |_S.V%..&6.U...5(| -00000190 52 05 c0 23 ff d5 57 58 7a 63 09 9d 87 15 b4 35 |R..#..WXzc.....5| -000001a0 d9 40 19 4e 67 ce cd be 5b a0 14 e2 a8 4a ad 44 |.@.Ng...[....J.D| -000001b0 ea a9 1b 14 e7 30 05 c9 23 48 4a 7a 7a 3f cc 9a |.....0..#HJzz?..| -000001c0 ce ca 0e 5f a0 79 17 e0 e7 5b 30 79 38 2d 5b 1e |..._.y...[0y8-[.| -000001d0 5c ae 4e 1f 00 ed fb 9f b6 e7 92 42 7d f0 30 82 |\.N........B}.0.| -000001e0 70 18 dc 07 c1 64 ec 09 7e d7 8f eb 68 31 75 cb |p....d..~...h1u.| -000001f0 69 24 30 89 8b 69 df 69 86 23 77 d2 61 4b 66 7e |i$0..i.i.#w.aKf~| -00000200 6d 34 50 a5 da 86 12 22 e3 51 ac 6a 23 55 d4 d5 |m4P....".Q.j#U..| -00000210 51 73 ac 85 c9 3a 57 c2 4b 55 96 4b c6 cc 62 15 |Qs...:W.KU.K..b.| -00000220 c9 10 09 ac ec 75 1a a6 3e e8 da aa 4d fe 7d 51 |.....u..>...M.}Q| -00000230 80 c3 a7 98 5d 29 cf c6 a0 8c 37 6e a8 f0 ad 41 |....])....7n...A| -00000240 34 60 44 98 57 3a 97 1f 29 08 f4 fc 4e 76 2e 0b |4`D.W:..)...Nv..| -00000250 26 8d fa 6c 38 0e 17 8a 2c de 51 94 f5 37 63 a0 |&..l8...,.Q..7c.| -00000260 40 71 51 c0 b9 d4 04 b2 ef 88 80 8f 34 74 35 5a |@qQ.........4t5Z| -00000270 c4 96 68 4f 27 0c 53 db f4 3c d1 88 86 b2 24 4f |..hO'.S..<....$O| -00000280 c7 a7 d9 b4 56 22 e5 9d 3f ec eb 1a af 77 9a 47 |....V"..?....w.G| -00000290 26 bb d5 3d 90 1d 6d fb d9 29 7e b4 b2 b2 ec 10 |&..=..m..)~.....| -000002a0 67 de d2 02 74 b3 91 a0 c4 b3 7c ba bb 90 b5 da |g...t.....|.....| -000002b0 97 fb 84 cd 4b 5e 33 c0 0a 56 73 98 8c 81 5b 9d |....K^3..Vs...[.| -000002c0 8d 83 df c3 8d 3d 3c 58 55 a3 e7 bd ef d0 37 0b |.....=....| -000002f0 c8 ae d8 84 06 2c 64 3c 35 a7 39 e4 a6 9e 0c 59 |.....,d<5.9....Y| -00000300 89 59 9a dd c3 fb 6c ae 34 ec 66 c5 d5 1f 7b 13 |.Y....l.4.f...{.| -00000310 66 23 8d 22 93 da 53 6c 3f 85 bb 5c 52 75 ba 81 |f#."..Sl?..\Ru..| -00000320 e8 bf 57 ce a8 45 68 ad 57 2f 4e 51 d3 65 f3 d0 |..W..Eh.W/NQ.e..| -00000330 1f 09 1e 3f 5e a1 9e 56 61 ca 88 e7 44 f6 f6 93 |...?^..Va...D...| -00000340 cb ae 28 2b 74 17 03 03 00 99 de 30 0f 41 8e d8 |..(+t......0.A..| -00000350 37 a0 c4 f3 af c3 f8 39 b7 44 83 6a c4 11 9e a4 |7......9.D.j....| -00000360 a9 f0 08 22 77 ce 09 a3 2d 94 99 2a c7 1b 9c 25 |..."w...-..*...%| -00000370 b6 79 ec 7b 2f 70 6a bd 2f f0 0f e0 6d 6e c0 69 |.y.{/pj./...mn.i| -00000380 0c 52 13 1f f9 99 97 04 2f fc fb f8 0a 4b ab bc |.R....../....K..| -00000390 a3 00 02 7f 0f 30 e2 66 c2 df 63 69 ad 08 76 ec |.....0.f..ci..v.| -000003a0 58 99 42 6a 11 e6 7a 27 57 98 71 c9 4d 78 c8 4a |X.Bj..z'W.q.Mx.J| -000003b0 3a 62 59 62 fb 2b 6f 15 79 22 50 40 bf db 29 d5 |:bYb.+o.y"P@..).| -000003c0 32 e5 e7 1e 76 50 05 e4 26 24 97 79 2a 9a a5 ec |2...vP..&$.y*...| -000003d0 c7 8c 68 e3 71 97 0c 85 51 74 db 5b 86 fb fb 23 |..h.q...Qt.[...#| -000003e0 e6 ef 57 17 03 03 00 35 5c 96 e3 26 e5 49 d8 02 |..W....5\..&.I..| -000003f0 b0 d0 4d 20 15 72 76 49 48 ee 2b 0a 19 44 05 cd |..M .rvIH.+..D..| -00000400 b1 0a 76 4e a9 21 45 5e de 00 6b c3 53 7c c9 8d |..vN.!E^..k.S|..| -00000410 43 72 06 78 0c ce 78 0f 01 ca d1 92 e5 |Cr.x..x......| +00000050 2e 00 2b 00 02 03 04 00 33 00 24 00 1d 00 20 f9 |..+.....3.$... .| +00000060 c2 64 c8 93 91 3a 81 55 ca 85 23 d4 91 37 3e 01 |.d...:.U..#..7>.| +00000070 42 63 2e 2a a9 13 0c a9 f2 e6 74 14 1e 5c 52 14 |Bc.*......t..\R.| +00000080 03 03 00 01 01 17 03 03 00 17 23 71 3e 39 7a 0c |..........#q>9z.| +00000090 2a fa 89 f1 65 d1 b0 23 96 8e 6a e4 55 2c fd 34 |*...e..#..j.U,.4| +000000a0 ea 17 03 03 00 20 b7 a2 d6 ff b3 b4 db ce f8 90 |..... ..........| +000000b0 f9 a3 9c 0c 8f f0 77 3e 37 f2 d9 e7 84 65 28 f6 |......w>7....e(.| +000000c0 dd fe b9 42 03 3c 17 03 03 02 7a d4 cf 93 f6 2b |...B.<....z....+| +000000d0 64 e3 13 75 41 62 7d bd cf 4f 42 80 23 f4 03 92 |d..uAb}..OB.#...| +000000e0 35 02 5e ed bb c6 2f b1 a8 57 cf d4 69 94 6a db |5.^.../..W..i.j.| +000000f0 39 b8 3a 05 07 dd f1 1d 63 13 22 9b d7 58 68 6f |9.:.....c."..Xho| +00000100 4f ac 79 6a 47 0a 23 35 3c 9b 9f 15 04 e7 6b d8 |O.yjG.#5<.....k.| +00000110 ff df 00 6c 68 5e a0 41 6a a9 34 9f 37 98 c2 3d |...lh^.Aj.4.7..=| +00000120 51 29 73 c4 ad 34 e5 69 78 18 eb 03 55 c0 c6 0d |Q)s..4.ix...U...| +00000130 43 d5 4a 5d cb 53 e6 b9 df e8 8b 0e 98 04 89 bb |C.J].S..........| +00000140 f4 a1 48 01 af d3 42 ef 17 e7 f9 27 b4 b1 63 99 |..H...B....'..c.| +00000150 91 a6 c5 c1 cb 6d 1c 55 b1 69 1c ec b1 b7 c3 cd |.....m.U.i......| +00000160 7a 93 f2 d8 e4 c4 96 43 0a e1 18 b5 9a 3b 57 83 |z......C.....;W.| +00000170 98 ce 74 f2 4c 65 ad 01 aa 76 b5 b0 7c a0 7d 09 |..t.Le...v..|.}.| +00000180 ad d6 20 7d 12 67 f8 4c 2c 41 37 34 66 86 fe 3d |.. }.g.L,A74f..=| +00000190 44 52 f0 08 26 4c b3 e7 71 b3 89 b3 5c 78 7e db |DR..&L..q...\x~.| +000001a0 34 31 dc dc 7c 7d 28 e1 41 96 f4 2f 28 60 9f 5b |41..|}(.A../(`.[| +000001b0 b2 2b 37 6b 3f 3a 37 e2 38 7a 66 40 fe 44 44 72 |.+7k?:7.8zf@.DDr| +000001c0 b4 e3 97 f3 db 73 c8 af 96 c8 a6 24 ef ea 34 8f |.....s.....$..4.| +000001d0 5e 4b 21 22 19 d8 4a db 2e f1 23 90 d0 d2 38 f3 |^K!"..J...#...8.| +000001e0 c6 08 5d 1d c9 a3 f2 6d 01 eb 30 5e cd f4 98 f5 |..]....m..0^....| +000001f0 0d d8 68 4f 00 f4 cd 24 9f c4 3c 6a 31 5d c0 e5 |..hO...$..S8B.| +00000350 6f 99 20 c4 98 59 48 61 e0 13 80 8e 96 25 96 f8 |o. ..YHa.....%..| +00000360 c9 c8 35 9c 35 c0 13 d7 34 24 0b 6e 59 4f 1b 77 |..5.5...4$.nYO.w| +00000370 1f 9a 71 6b 6b dc 71 23 b1 a2 e8 1e c2 a0 b1 8c |..qkk.q#........| +00000380 27 5e 90 c5 f8 65 30 a2 de fc 6b b2 e3 5d 8d 9f |'^...e0...k..]..| +00000390 70 32 3c 92 47 c7 91 10 49 0d f1 3b 41 f1 14 3b |p2<.G...I..;A..;| +000003a0 09 55 f5 78 0e 91 1b 75 a0 58 fc c9 34 82 fe 51 |.U.x...u.X..4..Q| +000003b0 20 73 71 3d 7f 82 a4 29 bc 04 67 d7 30 c7 a5 4b | sq=...)..g.0..K| +000003c0 f3 94 4d 15 35 2a 1e 46 82 3f 36 f4 7b ff 9f 88 |..M.5*.F.?6.{...| +000003d0 3b e6 60 bc 86 51 59 ad 97 58 95 7e 6a 4b c9 6c |;.`..QY..X.~jK.l| +000003e0 34 96 03 17 03 03 00 35 03 94 eb e1 e5 9d eb 8f |4......5........| +000003f0 34 b1 28 3c 9d 26 40 a9 e7 4c 2b bf 37 32 b6 aa |4.(<.&@..L+.72..| +00000400 78 d2 45 0c 6c 5b 0a 0e 8a 3a b6 1a 01 09 3e 0a |x.E.l[...:....>.| +00000410 45 25 c6 83 8a 4a cc 22 d9 29 c8 8a 32 |E%...J.".)..2| >>> Flow 3 (client to server) -00000000 14 03 03 00 01 01 17 03 03 02 7a 98 e7 1d af de |..........z.....| -00000010 f0 97 05 09 b8 cc a4 5e e2 ba 26 13 bd dd a4 de |.......^..&.....| -00000020 c6 fd 81 dc 0c 55 68 d8 90 32 36 e2 1d 05 15 c4 |.....Uh..26.....| -00000030 d2 c6 2b 99 b3 22 fd 4a 15 82 34 93 f8 39 04 6c |..+..".J..4..9.l| -00000040 e0 d1 c3 d3 16 77 dc 51 65 f9 ac 04 1d 38 8e e7 |.....w.Qe....8..| -00000050 10 ee 22 c6 25 6b 20 e7 1d e7 89 c1 88 ee d9 80 |..".%k .........| -00000060 29 45 83 64 12 a6 50 18 42 04 1f 34 15 35 24 f9 |)E.d..P.B..4.5$.| -00000070 86 0b a0 be c6 4b 9b ab 7f 07 7f 74 09 78 56 77 |.....K.....t.xVw| -00000080 72 ef 57 52 22 14 38 ee 70 e8 93 38 b0 cc cc 13 |r.WR".8.p..8....| -00000090 fe 3f 04 a2 af 20 f4 cf f4 bc 22 76 54 9e 43 63 |.?... ...."vT.Cc| -000000a0 e6 2d 77 c3 b8 b2 79 79 b8 89 86 9e 3c 01 c2 4b |.-w...yy....<..K| -000000b0 a7 48 3c 7b 5d 74 6e 79 88 e1 3b 73 e0 04 57 20 |.H<{]tny..;s..W | -000000c0 f7 36 c8 1a 9a 09 b2 77 20 6d 1b 7c 01 d2 6a 66 |.6.....w m.|..jf| -000000d0 8e 9a 14 02 ef 7d 26 52 eb 50 93 56 77 d7 04 3b |.....}&R.P.Vw..;| -000000e0 62 6f 9e 64 f4 f5 d6 83 f6 27 d8 37 05 cb dc 86 |bo.d.....'.7....| -000000f0 df 7f 0a 7e bc 23 bf 5a b4 72 b9 5e 1c 8b b5 e8 |...~.#.Z.r.^....| -00000100 b8 d7 3e a8 72 0a 2b c0 cc b0 6b a2 f9 5a db 1d |..>.r.+...k..Z..| -00000110 ea 5a b1 28 d0 ad 0c db 91 45 b9 b7 cd 25 51 1b |.Z.(.....E...%Q.| -00000120 47 e8 9e bf 25 6b 65 a9 c7 ed 39 a1 68 49 83 55 |G...%ke...9.hI.U| -00000130 3c 74 36 dc 71 f6 38 72 20 94 53 bf fb 0a 1c b4 |..r....v..Z/..c| -00000170 70 06 40 a8 57 46 c5 02 e1 74 71 2b e3 16 9e 6e |p.@.WF...tq+...n| -00000180 54 00 cc f1 9b ab e5 89 88 f8 84 47 c4 8a da 4a |T..........G...J| -00000190 62 d2 8d 64 8d 38 58 23 29 fa e9 41 c3 72 7b 3a |b..d.8X#)..A.r{:| -000001a0 5c fa b4 f5 12 be 1f cc 35 92 ec 24 8b c4 78 ef |\.......5..$..x.| -000001b0 3e db 36 a1 78 6c e6 51 a7 c4 1b fd bd 4d 6f b9 |>.6.xl.Q.....Mo.| -000001c0 7d 51 c3 a5 e7 cb 2a 20 99 74 4e 1d 1a 4f 6d ce |}Q....* .tN..Om.| -000001d0 fb 11 77 1c e5 20 f1 0e 38 8b 5e 6c af f4 98 63 |..w.. ..8.^l...c| -000001e0 e7 38 1c 31 62 12 0e e7 13 4b b9 ec c0 8d 84 aa |.8.1b....K......| -000001f0 1c 18 6e 4d 90 13 dc 01 a2 87 0e d8 b2 36 c1 d6 |..nM.........6..| -00000200 03 f6 a0 4c 83 de 88 b2 4e 97 be 4f 75 7b fb 42 |...L....N..Ou{.B| -00000210 84 e2 94 28 68 b0 37 4f bc 86 5d d4 74 84 15 53 |...(h.7O..].t..S| -00000220 a8 c8 47 86 0e fc d0 54 59 81 cb a6 c1 37 3b 1a |..G....TY....7;.| -00000230 2d a3 d7 2c 8c 23 f6 1f 0e 31 98 09 57 00 45 dc |-..,.#...1..W.E.| -00000240 35 e7 8f a7 24 74 e6 b0 3a 40 8c be e3 ff 0b 08 |5...$t..:@......| -00000250 3d c8 3d 84 ce 2c 1c 05 81 0c b5 83 8a de 2f 9f |=.=..,......../.| -00000260 6a 83 88 a0 c2 9d 26 2d 0f 9e 40 33 48 b7 59 c3 |j.....&-..@3H.Y.| -00000270 98 9c aa 3c 95 4b 86 35 02 91 dd 62 e0 2c 67 b6 |...<.K.5...b.,g.| -00000280 65 33 09 dc b4 17 03 03 00 99 94 6d 12 c3 3d 58 |e3.........m..=X| -00000290 0d 5d 8b 94 ba 26 20 97 12 a8 65 02 d1 d2 8c 8d |.]...& ...e.....| -000002a0 82 cb eb fa b3 e8 72 8b f2 4f 17 c8 52 53 9e 83 |......r..O..RS..| -000002b0 54 dc 84 37 be 3b 79 81 59 61 6f 67 ff cb c3 ae |T..7.;y.Yaog....| -000002c0 a1 9f d9 b0 a9 9d d0 8a 55 1f 58 48 a8 c6 2e c9 |........U.XH....| -000002d0 8e 79 6d 16 1b 68 db 45 40 84 a5 6a b1 fe a6 76 |.ym..h.E@..j...v| -000002e0 de 22 c9 a9 9a 95 a2 1d 96 86 9e 79 8f ed 0f fb |.".........y....| -000002f0 63 10 a0 d5 38 d5 78 e2 a6 6d 97 09 6e 17 1a 85 |c...8.x..m..n...| -00000300 2b 51 a4 a8 59 a1 06 6b 89 37 1e 5a 99 a3 66 89 |+Q..Y..k.7.Z..f.| -00000310 50 bc f7 49 e7 a9 82 da ec cf eb 33 76 af 65 76 |P..I.......3v.ev| -00000320 a5 84 93 17 03 03 00 35 5d 1d 31 e0 3b 1f 3f d6 |.......5].1.;.?.| -00000330 6c f9 55 6e 8f 86 1f 4f 85 a1 b5 3f c3 1e 3e ff |l.Un...O...?..>.| -00000340 29 9c a7 1d 06 e9 de d2 98 d5 fb 37 2e e6 2e ba |)..........7....| -00000350 b3 77 d0 d0 e6 ef 84 4e 05 14 47 2c 5e 17 03 03 |.w.....N..G,^...| -00000360 00 17 80 d7 97 10 67 71 db aa 0f 6f 76 86 20 37 |......gq...ov. 7| -00000370 0e a7 f1 53 71 c1 fe f7 09 17 03 03 00 13 79 a8 |...Sq.........y.| -00000380 bd 36 37 a9 5b b0 57 de c7 ea 2e 71 25 62 81 ea |.67.[.W....q%b..| -00000390 b5 |.| +00000000 14 03 03 00 01 01 17 03 03 02 7a 3e 62 91 75 b4 |..........z>b.u.| +00000010 58 7d 61 ac 42 4b 1b 91 86 cd 3f c0 6d 30 5a 01 |X}a.BK....?.m0Z.| +00000020 11 1e 77 87 92 50 bb a0 d2 c6 84 b6 10 37 02 ab |..w..P.......7..| +00000030 2d c2 c2 12 0a db f5 8f e4 1f dd 16 ec 83 ad db |-...............| +00000040 2d 8b ec fa aa 56 44 4e d4 af ce d2 9f 44 3d de |-....VDN.....D=.| +00000050 12 29 db bc 29 2a df 99 d7 d0 53 79 84 a4 b8 2d |.)..)*....Sy...-| +00000060 8b 5c e6 a4 b7 98 07 5a f4 63 10 21 87 13 09 07 |.\.....Z.c.!....| +00000070 28 98 49 48 07 70 c1 ab 8b 62 6d 40 a8 47 27 67 |(.IH.p...bm@.G'g| +00000080 d6 ad 29 8d 2e 14 34 14 18 6b dd f0 76 3b 91 f9 |..)...4..k..v;..| +00000090 e1 93 a2 1c 3a 5e 18 a3 c9 ca b0 c9 cf d9 3c f5 |....:^........<.| +000000a0 a3 38 c7 83 53 67 14 ba 65 6f 11 a2 ef 78 7e ea |.8..Sg..eo...x~.| +000000b0 4a 90 c9 aa bf e9 8e ff 8c 9d 7c 5f 56 c3 9b 16 |J.........|_V...| +000000c0 c1 8a a9 51 24 20 86 dc 99 ac d2 28 af 7b 2d 6e |...Q$ .....(.{-n| +000000d0 16 9b 71 71 82 00 94 51 a4 4f 22 c1 26 a2 6f 67 |..qq...Q.O".&.og| +000000e0 d9 45 ff 80 13 39 16 0f 9c 43 76 54 e5 12 0f 89 |.E...9...CvT....| +000000f0 95 ed 75 df eb cb 6b d2 77 fd fa 37 d7 a3 31 b5 |..u...k.w..7..1.| +00000100 61 47 69 8f 99 55 70 d0 96 b0 f7 a9 1b 53 69 a3 |aGi..Up......Si.| +00000110 e4 59 cc a1 d9 4b d5 4f e2 47 c1 53 30 60 50 03 |.Y...K.O.G.S0`P.| +00000120 c7 07 67 3f 68 ce 8c 32 7e f1 93 12 ba d8 67 21 |..g?h..2~.....g!| +00000130 71 4f c9 ca ae 7b 56 8d f7 64 14 e3 8d d6 a6 ed |qO...{V..d......| +00000140 d0 63 5e 00 1e f7 8a 0c 1e c3 24 e0 bd e2 e8 99 |.c^.......$.....| +00000150 da ca 01 9e fb 21 9e 1f 57 98 f1 36 7d c8 a8 7b |.....!..W..6}..{| +00000160 4b 27 13 fb 8c ab d6 b3 27 3e f5 b5 08 eb cb a9 |K'......'>......| +00000170 b0 a4 d4 3e c9 14 08 75 51 83 48 03 e7 79 65 30 |...>...uQ.H..ye0| +00000180 a4 1a 4f a8 7a 41 c8 af 9e 74 89 4d ec eb 58 9b |..O.zA...t.M..X.| +00000190 20 db 80 ce e0 c8 a7 1c b2 62 fc 85 7d 87 ca 00 | ........b..}...| +000001a0 64 4c 25 4d 3c b2 bf 9d 46 c5 04 b5 dd 7a 29 87 |dL%M<...F....z).| +000001b0 29 30 2e bc 42 31 9b f2 eb 7b 58 63 91 28 6f 43 |)0..B1...{Xc.(oC| +000001c0 6b c1 4e 00 b2 4b 9d 0c ef 18 5b 61 ec 77 84 e1 |k.N..K....[a.w..| +000001d0 88 49 f9 e2 71 2e 35 23 b8 73 6d c2 52 d1 2f ad |.I..q.5#.sm.R./.| +000001e0 55 40 4e a2 b0 14 1b 50 d7 9d 12 80 89 ab 88 a5 |U@N....P........| +000001f0 01 16 88 d5 4f 95 0c ce 79 c7 49 27 4b 44 4d fe |....O...y.I'KDM.| +00000200 f5 cd 95 08 b9 26 8d 52 ff d7 bc 47 11 16 d5 d0 |.....&.R...G....| +00000210 7d 4c 3c 04 74 92 5b 85 d2 2c 95 b8 4b 02 0b 66 |}L<.t.[..,..K..f| +00000220 60 7d b9 12 6e d3 06 73 cc c2 69 b9 fe ad f9 4c |`}..n..s..i....L| +00000230 f6 24 a0 eb 96 f0 b8 7c 32 dc 4c 67 04 83 15 84 |.$.....|2.Lg....| +00000240 f9 ef 70 e7 55 85 0e 8f b3 78 20 2c ed 69 29 89 |..p.U....x ,.i).| +00000250 d4 d8 5e 97 16 59 90 0f 79 41 6e cf 02 d3 9d 08 |..^..Y..yAn.....| +00000260 e4 0c 27 0c 74 97 c6 d6 89 6b c9 65 37 7b ae 6b |..'.t....k.e7{.k| +00000270 b7 0f e8 70 57 a3 1c 95 8d 66 da 4e 34 51 c8 e0 |...pW....f.N4Q..| +00000280 0e 83 e3 24 64 17 03 03 00 99 e3 31 2c ae ae 1c |...$d......1,...| +00000290 64 6c fc 36 c8 9f c2 88 16 c7 b2 ae 4a ef 3a 90 |dl.6........J.:.| +000002a0 f4 ad f2 91 58 37 7c 94 c2 e3 ed 76 c5 90 fb e6 |....X7|....v....| +000002b0 88 08 a6 a2 53 5a 78 cb bd f2 3c 6e 36 b4 cd 87 |....SZx...XCK.>> Flow 2 (server to client) -00000000 16 03 03 00 7a 02 00 00 76 03 03 be 96 55 22 ae |....z...v....U".| -00000010 2e be 57 a1 0a 48 2e e3 ac 8e a7 d0 d5 a6 47 a9 |..W..H........G.| -00000020 c4 11 bb e1 37 73 19 6b de 6b 2e 20 00 00 00 00 |....7s.k.k. ....| +00000000 16 03 03 00 7a 02 00 00 76 03 03 24 80 76 3d db |....z...v..$.v=.| +00000010 cf 32 53 04 de ce 2e 74 95 bb 30 a8 d5 5e ab ed |.2S....t..0..^..| +00000020 3c 1e 1a ae 92 63 8f 40 0b ce a4 20 00 00 00 00 |<....c.@... ....| 00000030 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |................| 00000040 00 00 00 00 00 00 00 00 00 00 00 00 13 03 00 00 |................| -00000050 2e 00 2b 00 02 03 04 00 33 00 24 00 1d 00 20 0f |..+.....3.$... .| -00000060 ae 71 f3 56 39 91 5f 75 18 40 73 b7 82 b9 67 05 |.q.V9._u.@s...g.| -00000070 09 d6 be 04 1f 66 b4 c4 18 1a 19 1d e7 bb 15 14 |.....f..........| -00000080 03 03 00 01 01 17 03 03 00 17 7d 5b c9 52 40 79 |..........}[.R@y| -00000090 4b 2b 2e b9 cb 7c 16 1b 2e df 3c e9 69 24 ea 47 |K+...|....<.i$.G| -000000a0 7f 17 03 03 02 22 a0 a0 bf fa 2c 0c 99 08 ad 4d |....."....,....M| -000000b0 03 05 54 93 67 8f 95 31 61 16 cb ef 2f 30 7f b8 |..T.g..1a.../0..| -000000c0 f8 97 c9 7a a8 71 e8 f2 ab 73 51 c4 1c a5 f4 6c |...z.q...sQ....l| -000000d0 54 6e f0 42 ae 58 25 84 de 9b e1 08 2a df ba 1e |Tn.B.X%.....*...| -000000e0 e5 c7 8e 57 b8 a6 e4 6a c8 02 0d 77 e7 79 f7 a2 |...W...j...w.y..| -000000f0 3a 18 f2 c5 f5 74 71 83 26 49 a6 2f 5c ac a4 a7 |:....tq.&I./\...| -00000100 0d f3 65 5a a9 ed a0 f5 f1 ce c9 80 bc 75 f2 e7 |..eZ.........u..| -00000110 68 11 b5 fb aa a8 e0 85 b9 37 b6 04 f6 f3 6d 8a |h........7....m.| -00000120 ed 5c 0e 9a 25 52 f2 84 ca 2c 19 54 c1 0c 5e 24 |.\..%R...,.T..^$| -00000130 e2 32 3e 99 18 84 17 84 8c 03 55 06 4f a0 ff 16 |.2>.......U.O...| -00000140 89 9e 1e d4 75 1e 3f a5 4d 0b 24 41 bc ca 6e 48 |....u.?.M.$A..nH| -00000150 77 53 e3 12 ee 00 69 11 19 c8 9b 43 b0 49 d3 a7 |wS....i....C.I..| -00000160 48 69 08 d0 14 fa d1 2b d5 66 a3 40 b4 51 4b e3 |Hi.....+.f.@.QK.| -00000170 f0 d3 c2 97 de 19 e8 02 66 9a ba 9f 59 7a 77 a4 |........f...Yzw.| -00000180 d1 29 71 5f 60 04 f6 f2 f5 d6 ce df 6a 19 6d 6a |.)q_`.......j.mj| -00000190 ae a5 df 25 d3 fb da 4c 54 d1 1e d8 68 59 d0 a8 |...%...LT...hY..| -000001a0 3d 6a ce 84 57 0e 01 8f d6 f1 7f cd 9f 4c 26 ae |=j..W........L&.| -000001b0 88 b5 af 31 b4 15 c0 bc 70 86 d4 7e 3f 7c 69 39 |...1....p..~?|i9| -000001c0 ff db 74 5b 18 54 dc 55 ec 7f 60 c8 38 03 1f e8 |..t[.T.U..`.8...| -000001d0 a0 9f 3b 79 12 ca c4 3f 41 d3 3d 80 88 a2 7e fa |..;y...?A.=...~.| -000001e0 a1 5c f0 df 1b 61 73 e0 2a d3 d8 88 0e 22 20 09 |.\...as.*...." .| -000001f0 62 42 3a 09 77 e5 39 c1 f2 a1 e5 29 f8 ab 4b de |bB:.w.9....)..K.| -00000200 0c 3c 39 e8 13 34 73 d0 e3 25 39 bf f7 23 c4 1b |.<9..4s..%9..#..| -00000210 06 c0 c4 16 80 14 15 a0 09 ac f0 fb 77 40 30 14 |............w@0.| -00000220 07 5d 1c 34 58 90 27 53 3f da c5 2a 7d 0f b7 4c |.].4X.'S?..*}..L| -00000230 15 09 ea cf f1 51 6c 84 3a f1 f7 d0 66 b8 fb 0c |.....Ql.:...f...| -00000240 82 1e 86 2d 23 84 b8 d2 df d7 db a6 f2 7c da d8 |...-#........|..| -00000250 e3 f8 a9 2c 0a fb 65 e8 2a 16 f6 c8 b7 dc b5 03 |...,..e.*.......| -00000260 fd bc 76 67 c5 0a 9e 8a c6 89 04 b4 e1 5b 23 89 |..vg.........[#.| -00000270 ca 03 73 4c e2 49 3e a8 ce c9 4c 0a 98 8c 78 b9 |..sL.I>...L...x.| -00000280 12 d4 32 94 84 66 5a d3 07 78 df 74 00 d7 ca df |..2..fZ..x.t....| -00000290 40 e6 b6 37 08 bc a8 fa 9a 28 e7 77 e2 78 39 d8 |@..7.....(.w.x9.| -000002a0 e3 71 e5 2b f6 dc 9b 20 3e 38 77 80 f7 c9 e2 81 |.q.+... >8w.....| -000002b0 07 4c 06 43 b7 b1 ff 1d f9 b4 24 ca ad db d3 f5 |.L.C......$.....| -000002c0 3b 05 d8 0f 1e 6d 1a 6d 17 03 03 00 a4 fd 5d 1f |;....m.m......].| -000002d0 1c 88 af a8 df 19 44 bd 80 81 78 fd 2d 84 ff a4 |......D...x.-...| -000002e0 51 45 9a 98 7c 45 cb 84 2c fb 54 d1 33 06 67 e4 |QE..|E..,.T.3.g.| -000002f0 95 f2 c5 5e 1b 49 41 b3 73 6c 5e 4d 2c 2d 77 1f |...^.IA.sl^M,-w.| -00000300 59 cb 39 e9 87 3a 10 83 72 ab b3 ce f8 28 94 8f |Y.9..:..r....(..| -00000310 47 8f 3d 2e 65 0a 42 b0 a5 13 61 bb 3b c7 a9 52 |G.=.e.B...a.;..R| -00000320 cd 26 f6 ab c1 d3 3a a4 51 a6 7a 74 3b 76 19 ee |.&....:.Q.zt;v..| -00000330 71 09 b6 b8 e6 3d 3e a3 df db a9 69 52 fe 66 3a |q....=>....iR.f:| -00000340 dc 19 f6 56 ea 81 10 ab 43 2e e2 17 20 08 92 62 |...V....C... ..b| -00000350 62 98 73 cb 16 9a 13 7d b3 b4 6a fd 18 28 25 05 |b.s....}..j..(%.| -00000360 b2 3f e7 14 94 cf 9d 67 74 11 83 21 da d8 36 da |.?.....gt..!..6.| -00000370 8e 17 03 03 00 35 89 67 70 a6 1c 3b 7c 59 59 23 |.....5.gp..;|YY#| -00000380 92 33 ee 35 11 5d 8c fb bd f0 21 a4 8d 09 e3 e7 |.3.5.]....!.....| -00000390 dd 96 8c ad cc 57 97 6a 4d 33 49 cc f6 c6 a9 4d |.....W.jM3I....M| -000003a0 9b 3f 22 88 f5 06 b3 c2 a3 34 46 |.?"......4F| +00000050 2e 00 2b 00 02 03 04 00 33 00 24 00 1d 00 20 d2 |..+.....3.$... .| +00000060 b3 86 f1 35 22 26 89 f4 07 ab b8 f5 27 a6 d5 c9 |...5"&......'...| +00000070 87 00 59 43 b8 df da 92 f6 f5 ed f4 8d 04 26 14 |..YC..........&.| +00000080 03 03 00 01 01 17 03 03 00 17 ed 6b 14 3a 82 c5 |...........k.:..| +00000090 88 9d a4 96 c7 c4 c7 73 63 c6 58 65 d0 d4 a6 cb |.......sc.Xe....| +000000a0 dc 17 03 03 02 22 e8 c5 15 54 3c 26 7b 87 8c d3 |....."...T<&{...| +000000b0 99 b0 af 98 21 1b 8f be f5 d8 40 c9 05 97 39 fd |....!.....@...9.| +000000c0 3d b2 da 2d 80 26 c9 24 cd 14 0b 48 2e d7 c4 dc |=..-.&.$...H....| +000000d0 4c 61 1e 5d 46 ce 66 cd 94 50 a4 e8 c4 d7 f0 48 |La.]F.f..P.....H| +000000e0 20 16 52 fb 12 04 17 48 7d 65 49 50 c5 b8 e6 9c | .R....H}eIP....| +000000f0 be f6 58 09 ea 8b 94 51 93 cf 0d 7a 76 88 78 cb |..X....Q...zv.x.| +00000100 37 83 43 fa 37 d5 5b 3f 10 1d 07 b1 bb 9b ac 3a |7.C.7.[?.......:| +00000110 43 e0 62 b1 fe 64 43 83 53 49 96 9e 81 1c 05 64 |C.b..dC.SI.....d| +00000120 40 2a 1b 98 5f ed 8d 47 52 2c db 84 8b 6a 1e 3b |@*.._..GR,...j.;| +00000130 de bb 7d 20 e6 cf 2a 79 2e c4 54 71 56 2f 79 45 |..} ..*y..TqV/yE| +00000140 07 3f 05 6c 82 e8 ab f7 62 0a 28 e0 db 83 6b bd |.?.l....b.(...k.| +00000150 55 81 8f 3f b6 1f d0 83 cd 97 67 71 56 f5 13 aa |U..?......gqV...| +00000160 45 95 65 ce 1e 42 bf 6a 83 6e bc 2e 41 28 79 b7 |E.e..B.j.n..A(y.| +00000170 b8 3f 6e 64 14 8d ed 3a a4 02 06 46 17 e5 c7 f8 |.?nd...:...F....| +00000180 72 f1 5f 9b 14 96 c9 c6 53 e6 32 b2 0b cc d5 d7 |r._.....S.2.....| +00000190 89 1e d9 52 fb 8f 48 8b 41 6e c6 f3 55 57 41 5d |...R..H.An..UWA]| +000001a0 95 03 9c 34 ea 3c a8 58 8d b7 89 82 e1 40 e0 60 |...4.<.X.....@.`| +000001b0 22 ab 23 30 e8 f0 4e 21 a1 11 0a 7f 18 80 ad de |".#0..N!........| +000001c0 41 ba a1 12 60 31 60 0f 84 f6 91 b1 ae ca f5 81 |A...`1`.........| +000001d0 3e d6 4e 3a 89 b6 b0 fe 3f 27 18 20 65 a9 d4 6c |>.N:....?'. e..l| +000001e0 ac 8a 46 08 e2 7d 06 6d 52 8c 69 9e 24 9b 8d f9 |..F..}.mR.i.$...| +000001f0 b7 a7 74 87 bd f9 84 ca 18 7d 5b 50 1d 8e 64 e1 |..t......}[P..d.| +00000200 39 6f f7 56 5a ef 08 6b e2 a1 87 e4 7a 5e ea b6 |9o.VZ..k....z^..| +00000210 12 75 2d ee e9 af a4 36 99 91 88 11 97 f3 d5 fb |.u-....6........| +00000220 8b 52 59 bc 9c 18 03 5b b1 59 47 ae d4 bb a1 65 |.RY....[.YG....e| +00000230 cf bf 40 54 e5 e7 6e e0 0c 26 0e a1 d2 4d 41 19 |..@T..n..&...MA.| +00000240 36 b5 b6 48 33 96 8a e3 a5 56 9b 34 16 ae 36 48 |6..H3....V.4..6H| +00000250 c5 ff 12 a7 33 f4 76 40 de d1 4b 41 ed 18 3b 04 |....3.v@..KA..;.| +00000260 06 32 6e f3 57 c6 be 72 58 7f 78 b7 91 65 00 a8 |.2n.W..rX.x..e..| +00000270 8d 5c 7f ff 0a 62 d4 99 82 b2 6b c8 80 3e 89 30 |.\...b....k..>.0| +00000280 dd 31 60 7a 00 6e a2 13 c7 58 08 b0 d5 32 03 2e |.1`z.n...X...2..| +00000290 08 86 a2 97 7a f0 a1 95 10 5f a2 d6 fc e7 a3 93 |....z...._......| +000002a0 16 a2 3d 33 04 e7 aa 3b 99 a5 ce c7 2c 28 71 bb |..=3...;....,(q.| +000002b0 ed e6 b9 5a a5 ec d1 44 54 e0 ff 41 cf 1a cb ff |...Z...DT..A....| +000002c0 67 43 6b af 87 19 40 74 17 03 03 00 a4 bc ef 32 |gCk...@t.......2| +000002d0 22 da e9 d5 93 ce 06 bd 3d 6c 2e f0 0c de ec b8 |".......=l......| +000002e0 12 d6 28 17 c6 64 aa 8d 4b 04 76 9e 41 3c 4a 94 |..(..d..K.v.Aru@.0.| +000003a0 fd 46 9d 5e 79 39 e1 a8 f9 27 2b |.F.^y9...'+| >>> Flow 3 (client to server) -00000000 14 03 03 00 01 01 17 03 03 00 35 f4 b7 bd 05 e3 |..........5.....| -00000010 04 c1 da 80 2f 16 6c 14 fe 7e bd 74 65 ab 76 e8 |..../.l..~.te.v.| -00000020 7a 62 dc 89 11 10 ee 58 93 fc 30 0e 30 fa b6 a0 |zb.....X..0.0...| -00000030 48 11 5d 78 9a fc 6b 44 1c 67 52 21 b4 b8 69 18 |H.]x..kD.gR!..i.| -00000040 17 03 03 00 17 12 f2 ed 80 d2 91 8a bc 19 25 1d |..............%.| -00000050 54 d6 56 04 b4 4d 1a 01 9f ea 7f 0c 17 03 03 00 |T.V..M..........| -00000060 13 aa bb f9 4e 8f 2e 49 9c 07 65 31 8a 14 05 d8 |....N..I..e1....| -00000070 d5 3a 83 23 |.:.#| +00000000 14 03 03 00 01 01 17 03 03 00 35 09 35 dd b0 97 |..........5.5...| +00000010 7b a4 5b ef 16 90 e4 15 aa 19 e4 5b e8 f1 11 c0 |{.[........[....| +00000020 e0 fa 4b 0e df a3 4a 7c cd 9a 0a c4 05 65 e9 5b |..K...J|.....e.[| +00000030 8b 0b e0 3c b2 5a cc eb 87 2b 67 0d 9f 19 d0 ec |...<.Z...+g.....| +00000040 17 03 03 00 17 68 1f ad 70 7c 49 62 6b 2f 67 15 |.....h..p|Ibk/g.| +00000050 d1 bf bb 35 b3 b3 2b f3 12 27 b6 0e 17 03 03 00 |...5..+..'......| +00000060 13 23 39 42 9f 8a 9e 68 41 39 fa 3b 50 bc 56 59 |.#9B...hA9.;P.VY| +00000070 d0 3a 5a 9a |.:Z.| diff --git a/testdata/Client-TLSv13-Ed25519 b/testdata/Client-TLSv13-Ed25519 index e509e8a..3a2915d 100644 --- a/testdata/Client-TLSv13-Ed25519 +++ b/testdata/Client-TLSv13-Ed25519 @@ -7,63 +7,63 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 7f 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 0a 00 08 00 1d 00 17 00 18 00 19 00 0b 00 02 01 |................| -000000a0 00 00 0d 00 1a 00 18 08 04 04 03 08 07 08 05 08 |................| -000000b0 06 04 01 05 01 06 01 05 03 06 03 02 01 02 03 ff |................| -000000c0 01 00 01 00 00 17 00 00 00 12 00 00 00 2b 00 09 |.............+..| +00000080 01 00 00 7f 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 19 00 0d |................| +000000b0 00 1a 00 18 08 04 04 03 08 07 08 05 08 06 04 01 |................| +000000c0 05 01 06 01 05 03 06 03 02 01 02 03 00 2b 00 09 |.............+..| 000000d0 08 03 04 03 03 03 02 03 01 00 33 00 26 00 24 00 |..........3.&.$.| 000000e0 1d 00 20 2f e5 7d a3 47 cd 62 43 15 28 da ac 5f |.. /.}.G.bC.(.._| 000000f0 bb 29 07 30 ff f6 84 af c4 cf c2 ed 90 99 5f 58 |.).0.........._X| 00000100 cb 3b 74 |.;t| >>> Flow 2 (server to client) -00000000 16 03 03 00 7a 02 00 00 76 03 03 41 71 01 fb 3b |....z...v..Aq..;| -00000010 86 8b 75 5d 8d 98 1d 98 e7 19 0c 87 87 d0 a6 b5 |..u]............| -00000020 5f 51 70 32 37 bc 58 b6 93 fb b1 20 00 00 00 00 |_Qp27.X.... ....| +00000000 16 03 03 00 7a 02 00 00 76 03 03 b2 4d aa 76 5b |....z...v...M.v[| +00000010 b7 38 95 18 e6 81 66 f8 27 82 26 2c b3 44 50 b0 |.8....f.'.&,.DP.| +00000020 f4 a8 f5 f2 87 f0 9d 85 4f ac 60 20 00 00 00 00 |........O.` ....| 00000030 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |................| 00000040 00 00 00 00 00 00 00 00 00 00 00 00 13 03 00 00 |................| -00000050 2e 00 2b 00 02 03 04 00 33 00 24 00 1d 00 20 17 |..+.....3.$... .| -00000060 4e 27 d2 df c9 6d 88 15 a2 02 f2 fc 4d 87 65 92 |N'...m......M.e.| -00000070 67 92 90 6c 8b e0 fb 27 2b d6 e8 e1 0e b2 7b 14 |g..l...'+.....{.| -00000080 03 03 00 01 01 17 03 03 00 17 ef ca 93 ae 3b 4b |..............;K| -00000090 ef ba c7 f1 44 89 61 b5 6c 05 c5 d9 59 4d 50 ab |....D.a.l...YMP.| -000000a0 ff 17 03 03 01 50 71 7e a6 0b 61 c5 f1 b0 9b ab |.....Pq~..a.....| -000000b0 3e 15 7a 0c ac 01 d7 cb 3e 04 85 e1 7a 59 95 92 |>.z.....>...zY..| -000000c0 cb 91 5f 91 a4 e2 1b 6a d7 72 d5 ee 70 ae 51 ed |.._....j.r..p.Q.| -000000d0 c7 78 ea 69 e5 a6 0b cc 72 43 6f 2e da c3 74 4c |.x.i....rCo...tL| -000000e0 00 53 79 38 3b 10 7e 98 25 32 ad 7f e4 0b 9b ad |.Sy8;.~.%2......| -000000f0 4a 5d f4 d9 a1 fe d6 ce 32 ff 2d 2e 26 49 78 3f |J]......2.-.&Ix?| -00000100 4e 37 e9 c7 d3 af b7 4d 75 f2 71 f2 20 b8 28 64 |N7.....Mu.q. .(d| -00000110 7c 0c 7a 3c f0 35 4e c6 ba 2d fc 76 53 a5 76 f9 ||.z<.5N..-.vS.v.| -00000120 3e e3 4e 41 b9 52 e1 dc 62 9f 13 bf b7 ef c2 c1 |>.NA.R..b.......| -00000130 ef 9c 04 4d 4c d0 20 e8 7e 62 bc 23 8a c0 02 62 |...ML. .~b.#...b| -00000140 1d 8e c1 6f e0 23 70 0e 08 5c a0 47 92 40 5c 31 |...o.#p..\.G.@\1| -00000150 d9 03 5b a5 9a dd 2f b9 4f 8a 4a 8d d9 c3 63 cb |..[.../.O.J...c.| -00000160 61 16 3c be 9e dc 9d 11 bf c8 b9 5b 2d 69 5d 94 |a.<........[-i].| -00000170 ef 6b 87 2d 59 42 05 51 88 9d 5a 8d bc ae 7c 65 |.k.-YB.Q..Z...|e| -00000180 e2 a1 b5 eb c6 23 30 3c ab 52 f1 a3 90 77 1c a2 |.....#0<.R...w..| -00000190 65 e0 ef 9c c7 1f b3 ad 7a 63 01 d9 b6 5c de c5 |e.......zc...\..| -000001a0 3e ec b0 0c 1c 34 ea e1 8e d9 68 67 d8 1b 0c 94 |>....4....hg....| -000001b0 4d 0a e1 e7 c7 4f 6e 03 c2 0f d6 4e 87 b9 e4 5c |M....On....N...\| -000001c0 d6 d7 4a f0 90 fb 8c 56 ce 20 d3 09 db a2 3a 8f |..J....V. ....:.| -000001d0 56 bc 1f 5d d8 0f ab 05 9c 2e 96 7e 09 bf 0f 45 |V..].......~...E| -000001e0 81 83 81 63 d5 0e ef fb bd db 1d c8 17 4a ef d1 |...c.........J..| -000001f0 ce 9d 76 c5 1c 3a 17 03 03 00 59 f8 6e 9b 48 45 |..v..:....Y.n.HE| -00000200 96 86 f0 87 4f 95 75 72 90 16 ee 40 e6 a5 da d6 |....O.ur...@....| -00000210 9a 93 5a f2 e1 14 c7 ef 99 5e 55 80 9c 2b a5 f0 |..Z......^U..+..| -00000220 24 d0 0c b3 5c cd 7e 9f a7 8d 80 6d 24 0f 55 44 |$...\.~....m$.UD| -00000230 25 23 04 30 0a b8 4b 87 81 7d f6 46 af a0 e9 6c |%#.0..K..}.F...l| -00000240 ce cc 3b 8f 93 75 2b d3 65 84 0d fc 11 b3 49 93 |..;..u+.e.....I.| -00000250 21 8c 12 28 17 03 03 00 35 11 5a 66 4d 6e f2 a1 |!..(....5.ZfMn..| -00000260 d5 c7 e0 0d fb c0 23 72 61 40 56 c9 2b cf 19 91 |......#ra@V.+...| -00000270 1e 9a 0b 20 65 dd f2 ec 54 f8 6a 6f a0 7f bf d2 |... e...T.jo....| -00000280 92 e0 41 ae 8c a0 4e 33 be a0 f8 8e b3 c7 |..A...N3......| +00000050 2e 00 2b 00 02 03 04 00 33 00 24 00 1d 00 20 e7 |..+.....3.$... .| +00000060 c2 3e 68 73 d9 fd 6e 69 16 15 85 84 24 45 36 47 |.>hs..ni....$E6G| +00000070 1b ad d9 c4 dc 4a 61 c6 12 5c 22 bf 1e 2f 59 14 |.....Ja..\"../Y.| +00000080 03 03 00 01 01 17 03 03 00 17 0f a4 05 81 10 48 |...............H| +00000090 c7 b7 78 9b 56 14 6c 9f 55 28 e3 4c 42 80 cc 1c |..x.V.l.U(.LB...| +000000a0 31 17 03 03 01 50 0d af 3b 08 02 84 89 42 b5 75 |1....P..;....B.u| +000000b0 c5 8f 9f c2 b1 dc cb 7c 6a d5 31 41 9a 16 8f fa |.......|j.1A....| +000000c0 74 40 21 5d f9 cc b0 1d 30 80 87 9a b2 57 58 53 |t@!]....0....WXS| +000000d0 2c 9e 5c 97 20 9c 81 77 16 25 62 9b fc a4 e1 9a |,.\. ..w.%b.....| +000000e0 80 c8 9a 4c f6 fc ae 79 a5 c2 26 4b 55 41 ff d0 |...L...y..&KUA..| +000000f0 25 4b 70 c9 ad b6 04 80 65 19 e0 fe 05 e7 b4 dc |%Kp.....e.......| +00000100 53 8f f8 3b ed 2c df b9 08 c2 da 60 b9 23 17 50 |S..;.,.....`.#.P| +00000110 da 0f 24 76 15 21 e6 e9 a8 f5 3e 08 cc 1b ee 92 |..$v.!....>.....| +00000120 2b 01 92 8d f9 4f 5a 3a 53 11 fc 32 52 cc af cd |+....OZ:S..2R...| +00000130 7b 94 0e 76 10 c2 16 36 2d a4 64 69 1c 05 70 20 |{..v...6-.di..p | +00000140 0d 23 cd 4a 33 c5 c7 db db 0f f8 b6 42 0c 83 0a |.#.J3.......B...| +00000150 a1 73 68 fb 87 2c 9d d2 d3 cf d7 3a bb 36 7e 83 |.sh..,.....:.6~.| +00000160 c3 3f bc e2 61 d9 c2 8b 15 a2 cc bf 14 a0 69 f4 |.?..a.........i.| +00000170 22 02 a9 ff 5e 55 37 6e 61 86 71 73 94 2f 7e 50 |"...^U7na.qs./~P| +00000180 45 96 cf 23 dd 39 90 5d 57 04 a3 d0 9f 97 f8 56 |E..#.9.]W......V| +00000190 fa cf 7a a9 e6 57 1f cb 33 a0 82 7a 84 94 1f 6d |..z..W..3..z...m| +000001a0 d8 0b c7 fb bc 62 94 36 4a d6 96 ce f6 f2 7f 06 |.....b.6J.......| +000001b0 18 59 66 77 77 12 8c 74 06 61 8f b6 37 35 65 fd |.Yfww..t.a..75e.| +000001c0 f1 0b fe e6 cc a9 64 f5 b5 0d 06 4e 38 4b 4b 78 |......d....N8KKx| +000001d0 be 6a cc 67 9e 39 f8 f2 27 33 a9 2d bc 9c 5e 06 |.j.g.9..'3.-..^.| +000001e0 b9 fb 76 0c be 8d 2a a5 6d cf 83 55 4f c5 6e 6e |..v...*.m..UO.nn| +000001f0 d0 08 8b f6 5a 61 17 03 03 00 59 c1 cc 58 14 33 |....Za....Y..X.3| +00000200 5a 39 b5 40 46 e8 b1 28 06 08 22 d3 27 b4 e6 ef |Z9.@F..(..".'...| +00000210 10 79 08 d4 ce 9e e2 cb 0b 86 a4 b1 80 e4 1b ac |.y..............| +00000220 71 15 fd 16 5b aa 01 c2 7b e3 c2 84 01 c0 f6 04 |q...[...{.......| +00000230 a7 31 2b ec f2 50 bf 5a 07 6f b8 03 9f d2 c6 ad |.1+..P.Z.o......| +00000240 73 18 81 f5 fd 9a 5a b2 bc 9f 85 94 9f f6 da da |s.....Z.........| +00000250 dd 56 bc 66 17 03 03 00 35 9f 7e 2e 02 66 bb ac |.V.f....5.~..f..| +00000260 3d d8 92 70 c9 35 c6 df ff 0f 81 b5 ca d4 56 4a |=..p.5........VJ| +00000270 24 06 06 57 28 e9 9d 82 0e 40 06 a7 f8 cc bc 6c |$..W(....@.....l| +00000280 a2 ea 2b 0e 88 77 05 de 3d 30 a0 6f bc 98 |..+..w..=0.o..| >>> Flow 3 (client to server) -00000000 14 03 03 00 01 01 17 03 03 00 35 a6 8b c2 c6 31 |..........5....1| -00000010 c1 73 78 0f f6 09 bb 09 d5 bc da 6b e6 21 e7 3e |.sx........k.!.>| -00000020 19 ba 60 74 d4 32 71 37 a0 13 d8 ae e0 85 f7 71 |..`t.2q7.......q| -00000030 d0 4e 2f 29 81 bb 8b 86 24 67 5b c9 b7 6e 6a 11 |.N/)....$g[..nj.| -00000040 17 03 03 00 17 43 59 8a 71 7c f9 e8 b9 36 56 bc |.....CY.q|...6V.| -00000050 07 67 34 1c f9 47 b0 fa 3a a0 15 9a 17 03 03 00 |.g4..G..:.......| -00000060 13 dc 3e d0 92 97 41 13 06 65 b2 af e5 fa 16 d5 |..>...A..e......| -00000070 9b 82 57 91 |..W.| +00000000 14 03 03 00 01 01 17 03 03 00 35 1c 60 8f 01 6b |..........5.`..k| +00000010 7c e3 d4 28 24 d8 7c 85 7f 63 44 23 97 7c a0 de ||..($.|..cD#.|..| +00000020 70 61 9e d9 ce 35 d9 3b 81 68 09 12 c1 b9 5e f5 |pa...5.;.h....^.| +00000030 32 23 9b 47 fc be 74 3c e6 1b 3f cd e8 c1 f1 4f |2#.G..t<..?....O| +00000040 17 03 03 00 17 1a 16 bc fe 99 30 d8 97 c1 00 d9 |..........0.....| +00000050 fd 1a 44 bd 84 35 dc 66 62 eb 28 3d 17 03 03 00 |..D..5.fb.(=....| +00000060 13 b4 8a 54 df ae 97 ce 2e ae fa 38 ca 02 a1 d6 |...T.......8....| +00000070 f5 40 64 2b |.@d+| diff --git a/testdata/Client-TLSv13-ExportKeyingMaterial b/testdata/Client-TLSv13-ExportKeyingMaterial index 13ac4fc..13ae971 100644 --- a/testdata/Client-TLSv13-ExportKeyingMaterial +++ b/testdata/Client-TLSv13-ExportKeyingMaterial @@ -7,85 +7,85 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 7f 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 0a 00 08 00 1d 00 17 00 18 00 19 00 0b 00 02 01 |................| -000000a0 00 00 0d 00 1a 00 18 08 04 04 03 08 07 08 05 08 |................| -000000b0 06 04 01 05 01 06 01 05 03 06 03 02 01 02 03 ff |................| -000000c0 01 00 01 00 00 17 00 00 00 12 00 00 00 2b 00 09 |.............+..| +00000080 01 00 00 7f 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 19 00 0d |................| +000000b0 00 1a 00 18 08 04 04 03 08 07 08 05 08 06 04 01 |................| +000000c0 05 01 06 01 05 03 06 03 02 01 02 03 00 2b 00 09 |.............+..| 000000d0 08 03 04 03 03 03 02 03 01 00 33 00 26 00 24 00 |..........3.&.$.| 000000e0 1d 00 20 2f e5 7d a3 47 cd 62 43 15 28 da ac 5f |.. /.}.G.bC.(.._| 000000f0 bb 29 07 30 ff f6 84 af c4 cf c2 ed 90 99 5f 58 |.).0.........._X| 00000100 cb 3b 74 |.;t| >>> Flow 2 (server to client) -00000000 16 03 03 00 7a 02 00 00 76 03 03 5a a0 51 7e b3 |....z...v..Z.Q~.| -00000010 75 e4 ba 57 52 a0 56 68 55 2b 40 16 e3 d4 b1 4f |u..WR.VhU+@....O| -00000020 5e 2c a0 ab 31 76 e8 c5 ab ca 60 20 00 00 00 00 |^,..1v....` ....| +00000000 16 03 03 00 7a 02 00 00 76 03 03 48 e6 a7 a9 4c |....z...v..H...L| +00000010 c3 a7 cc 18 b7 71 7d ed c5 6a cb ca b5 9f 00 fd |.....q}..j......| +00000020 f8 2c ac 9c 1f 24 27 b9 c6 55 8e 20 00 00 00 00 |.,...$'..U. ....| 00000030 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |................| 00000040 00 00 00 00 00 00 00 00 00 00 00 00 13 03 00 00 |................| -00000050 2e 00 2b 00 02 03 04 00 33 00 24 00 1d 00 20 1e |..+.....3.$... .| -00000060 8e a4 e9 85 bd af 87 81 48 56 10 3d 4d d2 07 42 |........HV.=M..B| -00000070 7f a2 db 93 42 98 df 67 6d 79 b3 fb 4f bb 67 14 |....B..gmy..O.g.| -00000080 03 03 00 01 01 17 03 03 00 17 db c6 9e 4c ff 07 |.............L..| -00000090 33 5a d9 47 e2 08 d5 10 bf 70 c5 5b 22 48 a7 fd |3Z.G.....p.["H..| -000000a0 8d 17 03 03 02 6d cd a7 97 1c 26 3c a9 70 93 c5 |.....m....&<.p..| -000000b0 98 ac 09 11 75 24 a1 97 4a a7 65 a0 d7 40 08 c9 |....u$..J.e..@..| -000000c0 fd 31 5f 47 c3 95 38 cf cd e0 77 52 db c1 fe 3a |.1_G..8...wR...:| -000000d0 2e 5f ae 5a 9a cf 96 5f 83 f5 7e 6b b0 d7 bf 27 |._.Z..._..~k...'| -000000e0 bd 22 af a1 05 79 48 c7 56 e9 56 a9 4f 34 82 9c |."...yH.V.V.O4..| -000000f0 41 c5 cf 72 d1 56 18 d4 fb d7 94 e1 72 9f 2a c0 |A..r.V......r.*.| -00000100 2f 3b fe de 46 36 4f 0d 15 12 4d e2 2a fb 42 20 |/;..F6O...M.*.B | -00000110 1e 7f 0f 50 be 56 10 2d 83 9f c0 c4 9e 0a 29 c4 |...P.V.-......).| -00000120 07 a1 ba c0 70 d4 93 8a 27 a1 e2 00 98 11 3e 4e |....p...'.....>N| -00000130 07 46 54 68 5a d2 e3 85 ca 6d 66 b1 28 d7 a3 c9 |.FThZ....mf.(...| -00000140 cb 9b 5b 4c 94 4a 56 69 dc 6e ba 84 08 7e 31 14 |..[L.JVi.n...~1.| -00000150 5d a0 e0 00 b2 23 63 fe 67 8c ae 75 56 44 9c 9c |]....#c.g..uVD..| -00000160 c4 4c 31 a9 d7 df 3b ec 59 1e 2e 85 fd 08 8d ba |.L1...;.Y.......| -00000170 b2 09 f6 3e 19 7b 29 ab 6a b3 5a 00 be 76 fb 39 |...>.{).j.Z..v.9| -00000180 98 c4 3e 4b a6 ae 68 ba 6c 9a a6 5d 20 33 96 55 |..>K..h.l..] 3.U| -00000190 27 66 aa c2 c0 6d f0 80 cc c7 64 5f 7b 42 56 b4 |'f...m....d_{BV.| -000001a0 a2 6b a3 29 9a 49 d2 fc 74 53 21 fe e3 87 ab d9 |.k.).I..tS!.....| -000001b0 e4 3e e7 8a a0 c6 49 08 d1 45 14 53 fb 28 39 cb |.>....I..E.S.(9.| -000001c0 99 86 c2 3f dc b3 f6 86 a7 87 b2 88 d9 4f 62 d6 |...?.........Ob.| -000001d0 d4 bb 84 93 56 5a 99 8e 8a 5b 1b 9a 1c ef 4a f1 |....VZ...[....J.| -000001e0 85 62 08 1f 27 c2 20 a1 9c 73 91 05 d8 9b 32 90 |.b..'. ..s....2.| -000001f0 74 80 08 dd 52 87 9f 6e c3 89 14 f3 23 0e 1f d0 |t...R..n....#...| -00000200 3c e0 51 48 a4 b2 f2 43 05 bd a3 95 35 70 37 cc |<.QH...C....5p7.| -00000210 89 f3 23 b7 70 5f 36 24 78 ea 21 ec 7c 06 3a d6 |..#.p_6$x.!.|.:.| -00000220 b5 fd d1 c4 bb 32 39 78 6a f6 ed 91 83 c8 d4 bd |.....29xj.......| -00000230 33 55 cf a8 5a b9 46 ec fa 87 5a c0 35 d1 f6 5e |3U..Z.F...Z.5..^| -00000240 1f 7a 8e 82 e1 97 38 f9 ad 6e 00 ba d1 4b 82 dd |.z....8..n...K..| -00000250 b0 87 0e 18 70 27 6c cd dd 0d d7 4b 46 e9 a3 dc |....p'l....KF...| -00000260 5d 60 e7 eb a9 b4 99 f2 bc 9f a4 ed dc c6 63 24 |]`............c$| -00000270 f8 91 f3 ee 7f 47 40 03 95 34 53 8c 38 90 3f 0f |.....G@..4S.8.?.| -00000280 a6 d8 a1 a7 39 64 45 7e 9e 94 aa 3e 19 df 28 f1 |....9dE~...>..(.| -00000290 ab 14 22 ce e8 80 a6 73 59 f7 92 85 13 20 6c cf |.."....sY.... l.| -000002a0 d8 ff ce f4 5d 79 f8 37 38 b6 9f 81 97 9f 72 31 |....]y.78.....r1| -000002b0 e0 fe ca d2 03 cd 3b 00 9f cb 55 a7 de 79 80 d8 |......;...U..y..| -000002c0 0b ae 5a e6 a7 ba a5 35 da d3 03 95 56 c0 ac c9 |..Z....5....V...| -000002d0 2a 36 cf 53 d0 44 48 b3 19 6c 44 ab 6b a1 7f a2 |*6.S.DH..lD.k...| -000002e0 f6 18 90 4f 16 a9 d5 77 ef 01 81 e1 ef a7 b9 3f |...O...w.......?| -000002f0 35 82 66 c7 9c 82 cc 00 fa 74 71 ed 99 ab fc d5 |5.f......tq.....| -00000300 ce 0a 05 80 56 5f 54 79 a9 b2 82 38 af 52 94 d1 |....V_Ty...8.R..| -00000310 7e 15 1e 17 03 03 00 99 94 6e e7 f3 9a a6 90 24 |~........n.....$| -00000320 c8 59 16 e6 58 d1 a2 55 ab 90 d6 59 00 06 0f 22 |.Y..X..U...Y..."| -00000330 2d 7e 1a 13 ce 64 05 a0 e2 a2 22 36 d4 51 69 ce |-~...d...."6.Qi.| -00000340 8c 13 85 2e ad a3 9d c9 cf 50 be 06 db 75 41 1e |.........P...uA.| -00000350 01 64 8e 55 13 31 42 a0 b9 90 30 75 a3 b5 a1 36 |.d.U.1B...0u...6| -00000360 e8 1d 5f 32 f4 8f 68 f3 ca d9 f2 36 cf 77 2a ae |.._2..h....6.w*.| -00000370 03 db 01 bb 51 25 bb 65 76 0a 81 bf db 6a 0a 85 |....Q%.ev....j..| -00000380 3d 2a ee 71 ff a5 91 75 3f 44 23 31 70 1f b4 4c |=*.q...u?D#1p..L| -00000390 a1 f2 ec cb ac bb de 36 3a 46 a6 3d a8 c5 57 92 |.......6:F.=..W.| -000003a0 a4 7c d4 54 fa de b6 77 62 95 24 aa 63 70 4a 04 |.|.T...wb.$.cpJ.| -000003b0 cb 17 03 03 00 35 07 18 23 d6 3d 11 1c 50 e1 22 |.....5..#.=..P."| -000003c0 c7 83 33 84 c3 e1 30 b0 43 68 19 2b c4 43 95 25 |..3...0.Ch.+.C.%| -000003d0 8c b7 37 c1 d0 3c ef f4 4f 29 b7 18 34 25 d2 8a |..7..<..O)..4%..| -000003e0 44 52 37 4e ff f9 aa 2b 33 61 4a |DR7N...+3aJ| +00000050 2e 00 2b 00 02 03 04 00 33 00 24 00 1d 00 20 dd |..+.....3.$... .| +00000060 be 27 eb a0 9c b1 22 6a 8c 29 9a d4 47 c2 ee 14 |.'...."j.)..G...| +00000070 39 0c 60 81 c9 06 3f dc e5 e0 24 9a c4 88 35 14 |9.`...?...$...5.| +00000080 03 03 00 01 01 17 03 03 00 17 25 70 5a e5 6b 9e |..........%pZ.k.| +00000090 56 b9 cf 83 48 b0 bc 99 6a 86 e1 cb 4e ce b5 10 |V...H...j...N...| +000000a0 e0 17 03 03 02 6d c7 a6 79 ef b0 81 d6 e4 0e 02 |.....m..y.......| +000000b0 59 32 88 cc b1 0d 53 f6 33 9b d2 e8 74 a9 0a a7 |Y2....S.3...t...| +000000c0 f9 76 e9 6e 0d 16 75 0b e0 8f 5c b5 31 47 6b 68 |.v.n..u...\.1Gkh| +000000d0 52 c7 c2 84 cb 48 81 a3 da bd a1 50 5c ec 5c a7 |R....H.....P\.\.| +000000e0 10 01 58 cc 03 c3 53 04 03 69 80 f4 ad 4d ce 72 |..X...S..i...M.r| +000000f0 26 4e 6c c7 2c 31 69 2b fd 97 67 5e 7d e0 05 b3 |&Nl.,1i+..g^}...| +00000100 f4 40 64 a1 bd a3 fd a8 f9 7b 18 82 89 8f 25 f9 |.@d......{....%.| +00000110 ca ca c4 8f e4 90 7b 26 7a d5 b2 1e fa 05 db ad |......{&z.......| +00000120 8a 9f 93 e9 13 5b 28 cc cb 8b 30 f2 4c 1d 73 09 |.....[(...0.L.s.| +00000130 7f 6b 63 5c 29 36 2f fc a5 6e eb 24 79 f8 7c 63 |.kc\)6/..n.$y.|c| +00000140 1f ef 41 72 98 69 7c d6 8d f9 76 d4 4d af b0 71 |..Ar.i|...v.M..q| +00000150 2e f7 f8 b5 73 45 05 52 fa 25 46 02 28 0d d9 7a |....sE.R.%F.(..z| +00000160 60 13 b9 6c 6d fb f3 be e3 04 74 76 72 d6 a4 91 |`..lm.....tvr...| +00000170 d1 2c 0d 1e fa 23 ef c7 80 ff 1e aa 1b af 50 58 |.,...#........PX| +00000180 77 ea 49 d9 22 4d ed bc bf a6 0a 41 8e e7 5b 31 |w.I."M.....A..[1| +00000190 de 33 05 10 46 a5 54 aa 5e 90 5c 15 64 2d 1b e9 |.3..F.T.^.\.d-..| +000001a0 5c fc 93 8d 2f b2 af 74 d7 d2 c6 7f 27 68 fd 44 |\.../..t....'h.D| +000001b0 13 60 70 87 e8 08 e1 e2 af 7f 1a 2c 29 5f 45 fe |.`p........,)_E.| +000001c0 49 9a d0 42 c9 51 ef f7 5b ae 02 df 27 1c 29 20 |I..B.Q..[...'.) | +000001d0 35 4f 3d 7d 74 97 0c 20 be f8 a3 c9 b7 ff 65 69 |5O=}t.. ......ei| +000001e0 08 89 92 fe 85 65 9f 8a 00 4b 9f 39 8d 6f 29 7c |.....e...K.9.o)|| +000001f0 7c e9 16 e4 bd 06 a3 b0 5b 7f cf f0 74 14 56 a2 ||.......[...t.V.| +00000200 76 61 b8 79 10 44 55 4f 25 55 a7 be a4 eb 2e 7d |va.y.DUO%U.....}| +00000210 9a b8 7a d8 d7 34 b6 ef 6c f7 fb ef fd 16 c2 61 |..z..4..l......a| +00000220 89 bb 98 22 c6 80 9e 33 7f e9 35 7a 58 b6 33 1c |..."...3..5zX.3.| +00000230 d6 87 68 b7 62 21 3b 26 9b f1 b1 f2 92 d5 4b 19 |..h.b!;&......K.| +00000240 02 58 05 3c 81 cf 00 5a 54 86 a5 61 8f 71 ae 32 |.X.<...ZT..a.q.2| +00000250 f2 0f 08 3b 13 4d f3 e6 03 2e 73 9c 50 4a b7 6c |...;.M....s.PJ.l| +00000260 d8 0a 04 fc b5 44 a5 45 c8 86 c9 9f 29 b4 00 90 |.....D.E....)...| +00000270 d8 8b e0 c8 ba 63 9f 42 65 ef ba 5b dc b2 61 53 |.....c.Be..[..aS| +00000280 e6 4b 29 72 51 c9 21 d4 d7 2d 14 56 82 80 32 36 |.K)rQ.!..-.V..26| +00000290 fd 72 b6 16 6f 06 71 f9 60 4f 32 ce f6 83 94 75 |.r..o.q.`O2....u| +000002a0 d9 23 d3 41 f8 e7 90 60 80 a8 a5 95 c0 a2 dd 2e |.#.A...`........| +000002b0 e7 60 73 5b c0 a5 a0 bd 8b bc cc 32 8a 9e 30 6a |.`s[.......2..0j| +000002c0 72 2f 61 24 56 0b 1e 3e 52 92 d2 e0 11 cd 52 69 |r/a$V..>R.....Ri| +000002d0 c4 73 7f 72 95 fd f5 c4 72 d7 77 73 85 bf be e0 |.s.r....r.ws....| +000002e0 cd 3c 3b 3d 92 63 91 ba c8 a8 d2 32 40 6a 33 91 |.<;=.c.....2@j3.| +000002f0 c0 71 fe ea 76 9f a9 96 dc c0 a9 bd 67 b6 23 42 |.q..v.......g.#B| +00000300 d9 1b 3d 8d d4 5f 81 38 74 1c db 36 9e bd 79 fd |..=.._.8t..6..y.| +00000310 30 c5 db 17 03 03 00 99 61 1e 25 cb 11 26 61 72 |0.......a.%..&ar| +00000320 a0 9a de 5b ad 5b ad 8a 29 43 eb 76 5a 16 a4 d3 |...[.[..)C.vZ...| +00000330 d4 a1 84 e4 7e a1 2b 76 75 b6 a5 a6 36 da d3 bf |....~.+vu...6...| +00000340 0c 3a 39 ca ef 3f 02 22 63 3d 5d c1 30 94 ba 32 |.:9..?."c=].0..2| +00000350 fe c0 20 c1 ba c8 fa 29 e8 1c c6 ab f0 c9 53 a4 |.. ....)......S.| +00000360 73 d0 9a 2d 50 d8 b4 0c db e5 4a 9f 98 38 34 c9 |s..-P.....J..84.| +00000370 9f ff 63 a9 50 7b 26 00 64 26 4d 0d 20 d5 e5 27 |..c.P{&.d&M. ..'| +00000380 e1 41 7b 5a 03 97 0a 14 8c 55 3c 45 4b 72 ce de |.A{Z.....U>> Flow 3 (client to server) -00000000 14 03 03 00 01 01 17 03 03 00 35 7d e0 1b 46 05 |..........5}..F.| -00000010 4a e2 11 2c a4 22 62 cb bc e7 f4 11 d2 05 ca c6 |J..,."b.........| -00000020 17 98 10 88 03 12 d1 1e 6a dc e8 bb 91 df 65 47 |........j.....eG| -00000030 78 f0 32 d1 7d c0 56 92 78 56 6b 75 cc 2d eb 2d |x.2.}.V.xVku.-.-| -00000040 17 03 03 00 17 ad cc 95 e5 1c 77 7c de 6f e8 8d |..........w|.o..| -00000050 06 8e b6 8e d0 95 3f 71 0b 15 6e 0e 17 03 03 00 |......?q..n.....| -00000060 13 8e 23 c7 75 9d f7 e1 b9 b5 ed 79 86 e0 64 68 |..#.u......y..dh| -00000070 01 ef 70 e1 |..p.| +00000000 14 03 03 00 01 01 17 03 03 00 35 a6 7f ef 71 68 |..........5...qh| +00000010 8b 86 84 20 a6 e7 65 3f 3f f8 c6 8b 62 40 31 e2 |... ..e??...b@1.| +00000020 1a ee 8d 0a 64 88 ea 4b 83 5f c5 ff 1b 9d aa 5f |....d..K._....._| +00000030 ce a4 31 76 06 90 da ad b9 17 49 0b a6 b5 37 80 |..1v......I...7.| +00000040 17 03 03 00 17 2b be e8 98 11 37 0d db 46 69 0d |.....+....7..Fi.| +00000050 51 34 ee 13 00 c3 f1 12 8a 13 21 b7 17 03 03 00 |Q4........!.....| +00000060 13 8d ec 94 6f 55 b1 d5 c0 d6 a3 6e a2 8d 67 76 |....oU.....n..gv| +00000070 7b c7 b8 1d |{...| diff --git a/testdata/Client-TLSv13-HelloRetryRequest b/testdata/Client-TLSv13-HelloRetryRequest index d6b570f..a669920 100644 --- a/testdata/Client-TLSv13-HelloRetryRequest +++ b/testdata/Client-TLSv13-HelloRetryRequest @@ -7,11 +7,11 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 7b 00 05 00 05 01 00 00 00 00 00 0a 00 |...{............| -00000090 06 00 04 00 1d 00 17 00 0b 00 02 01 00 00 0d 00 |................| -000000a0 1a 00 18 08 04 04 03 08 07 08 05 08 06 04 01 05 |................| -000000b0 01 06 01 05 03 06 03 02 01 02 03 ff 01 00 01 00 |................| -000000c0 00 17 00 00 00 12 00 00 00 2b 00 09 08 03 04 03 |.........+......| +00000080 01 00 00 7b 00 0b 00 02 01 00 ff 01 00 01 00 00 |...{............| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 06 00 04 00 1d 00 17 00 0d 00 1a 00 18 |................| +000000b0 08 04 04 03 08 07 08 05 08 06 04 01 05 01 06 01 |................| +000000c0 05 03 06 03 02 01 02 03 00 2b 00 09 08 03 04 03 |.........+......| 000000d0 03 03 02 03 01 00 33 00 26 00 24 00 1d 00 20 2f |......3.&.$... /| 000000e0 e5 7d a3 47 cd 62 43 15 28 da ac 5f bb 29 07 30 |.}.G.bC.(.._.).0| 000000f0 ff f6 84 af c4 cf c2 ed 90 99 5f 58 cb 3b 74 |.........._X.;t| @@ -32,11 +32,11 @@ 00000050 00 00 00 32 cc a9 cc a8 c0 2b c0 2f c0 2c c0 30 |...2.....+./.,.0| 00000060 c0 09 c0 13 c0 0a c0 14 00 9c 00 9d 00 2f 00 35 |............./.5| 00000070 c0 12 00 0a c0 23 c0 27 00 3c c0 07 c0 11 00 05 |.....#.'.<......| -00000080 13 03 13 01 13 02 01 00 00 9c 00 05 00 05 01 00 |................| -00000090 00 00 00 00 0a 00 06 00 04 00 1d 00 17 00 0b 00 |................| -000000a0 02 01 00 00 0d 00 1a 00 18 08 04 04 03 08 07 08 |................| -000000b0 05 08 06 04 01 05 01 06 01 05 03 06 03 02 01 02 |................| -000000c0 03 ff 01 00 01 00 00 17 00 00 00 12 00 00 00 2b |...............+| +00000080 13 03 13 01 13 02 01 00 00 9c 00 0b 00 02 01 00 |................| +00000090 ff 01 00 01 00 00 17 00 00 00 12 00 00 00 05 00 |................| +000000a0 05 01 00 00 00 00 00 0a 00 06 00 04 00 1d 00 17 |................| +000000b0 00 0d 00 1a 00 18 08 04 04 03 08 07 08 05 08 06 |................| +000000c0 04 01 05 01 06 01 05 03 06 03 02 01 02 03 00 2b |...............+| 000000d0 00 09 08 03 04 03 03 03 02 03 01 00 33 00 47 00 |............3.G.| 000000e0 45 00 17 00 41 04 1e 18 37 ef 0d 19 51 88 35 75 |E...A...7...Q.5u| 000000f0 71 b5 e5 54 5b 12 2e 8f 09 67 fd a7 24 20 3e b2 |q..T[....g..$ >.| @@ -44,76 +44,76 @@ 00000110 5b 83 56 e2 32 42 e9 58 b6 d7 49 a6 b5 68 1a 41 |[.V.2B.X..I..h.A| 00000120 03 56 6b dc 5a 89 |.Vk.Z.| >>> Flow 4 (server to client) -00000000 16 03 03 00 9b 02 00 00 97 03 03 4f 5c 5c 6c f2 |...........O\\l.| -00000010 79 f3 d8 d4 be 78 c3 a4 b6 82 a5 ee 37 c3 a1 f7 |y....x......7...| -00000020 87 83 ac 75 62 29 48 80 55 64 9b 20 00 00 00 00 |...ub)H.Ud. ....| +00000000 16 03 03 00 9b 02 00 00 97 03 03 9a 1f 7a fa 06 |.............z..| +00000010 c4 5f 92 61 62 d2 a5 f3 ae b9 a6 d8 6b eb 13 a7 |._.ab.......k...| +00000020 2f 17 62 79 3a ca 42 8b 18 06 15 20 00 00 00 00 |/.by:.B.... ....| 00000030 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |................| 00000040 00 00 00 00 00 00 00 00 00 00 00 00 13 03 00 00 |................| 00000050 4f 00 2b 00 02 03 04 00 33 00 45 00 17 00 41 04 |O.+.....3.E...A.| -00000060 be 02 77 b3 71 8c 25 30 15 18 cd 54 f8 99 b7 a4 |..w.q.%0...T....| -00000070 1b 43 6e a5 bf 94 d3 7e 8f 07 4e 78 15 af 48 fe |.Cn....~..Nx..H.| -00000080 14 60 0d f1 1b 31 f5 30 5b 37 34 da d2 b8 a9 43 |.`...1.0[74....C| -00000090 5e 5e 9e 32 9c 7c 94 21 fc 1e db 0a b3 e1 f5 7a |^^.2.|.!.......z| -000000a0 17 03 03 00 17 fc 15 53 2f 26 26 78 e5 5e 22 74 |.......S/&&x.^"t| -000000b0 8a cb 74 2c f8 4c 04 5d 0b 53 d9 93 17 03 03 02 |..t,.L.].S......| -000000c0 6d 58 f2 20 bc 2e 2b c7 67 79 b1 19 09 d8 73 9c |mX. ..+.gy....s.| -000000d0 74 b4 55 b4 24 5e a3 66 f1 a3 81 55 cb 77 5e c1 |t.U.$^.f...U.w^.| -000000e0 5e b1 ba 4e ff 29 6e 10 a3 9c 20 68 fb c1 35 a8 |^..N.)n... h..5.| -000000f0 02 10 0e b6 b1 a1 84 d1 e4 41 92 15 93 ea 9c c1 |.........A......| -00000100 93 4b 54 28 da 49 f5 eb a5 a5 92 3b 91 37 48 8a |.KT(.I.....;.7H.| -00000110 4a 0a 3c 3a b9 10 2b 1b e8 33 4f e2 1b a4 e1 0e |J.<:..+..3O.....| -00000120 4c 81 38 13 36 f2 87 e9 58 be e4 16 d9 eb 17 9d |L.8.6...X.......| -00000130 61 69 7b 41 c9 29 99 bd b1 5b 66 49 3d f1 e5 6f |ai{A.)...[fI=..o| -00000140 e4 91 a1 48 a3 89 91 00 8c 33 2c 0b 07 82 10 26 |...H.....3,....&| -00000150 fb 7b c6 b0 64 56 1b 2b 1f 21 3a be 72 6d 9b fe |.{..dV.+.!:.rm..| -00000160 ad bd 1c 59 05 38 9b 27 88 55 76 88 45 cf 03 be |...Y.8.'.Uv.E...| -00000170 2a 8d 5f a6 39 1f 5e b7 1c 68 28 60 f5 cb e4 5e |*._.9.^..h(`...^| -00000180 08 6c 3c 85 72 6f 31 26 30 0c 25 94 0e 4d 5b 5b |.l<.ro1&0.%..M[[| -00000190 46 ba 0e 27 e1 17 3d 68 95 7e 2f a4 a0 16 54 e2 |F..'..=h.~/...T.| -000001a0 35 3b a5 79 c8 45 2d e0 57 33 02 4e 81 bd dc 6a |5;.y.E-.W3.N...j| -000001b0 9b b7 1e a8 9e ff 75 7f 11 47 9c ac 60 05 bd 9d |......u..G..`...| -000001c0 59 2b 92 5a 94 f4 ca 8f 3e 53 b3 8a a5 ab 28 e2 |Y+.Z....>S....(.| -000001d0 9f ed 29 f2 8b c7 82 92 86 d8 12 71 b1 97 24 26 |..)........q..$&| -000001e0 f5 96 fc 16 a8 ff 39 1c 87 62 ec 4a b4 c3 03 13 |......9..b.J....| -000001f0 e8 17 57 6b 48 6c 08 08 b0 6d 1f 1a 8c 1f 48 66 |..WkHl...m....Hf| -00000200 aa 51 38 59 ac 1e 58 e7 ff 85 e1 60 e0 e5 42 65 |.Q8Y..X....`..Be| -00000210 9e ff ab 65 bb 06 b2 8b c6 f2 95 ad 3c eb c7 1c |...e........<...| -00000220 d6 2a 60 d3 e4 5f cb 65 ee 3d 45 75 93 53 eb 70 |.*`.._.e.=Eu.S.p| -00000230 5c f4 ae 5c 6b e0 f1 6d 2c fe 88 cb 32 b4 53 90 |\..\k..m,...2.S.| -00000240 c5 5b 9e 8c de 08 ff 49 86 2a a5 ef 59 50 f8 68 |.[.....I.*..YP.h| -00000250 2a 3b e5 44 2a e8 7d c9 6e 5c c1 4f 99 d7 2b 67 |*;.D*.}.n\.O..+g| -00000260 98 72 38 64 b3 e9 64 95 c1 1c 9d 5c 82 d9 e7 1e |.r8d..d....\....| -00000270 ac cf 12 05 d8 da eb 75 69 e3 fb 08 c3 c7 d2 2d |.......ui......-| -00000280 aa 3f 9d cc b7 31 b5 03 59 67 03 32 6f ed bc 87 |.?...1..Yg.2o...| -00000290 47 c6 69 79 23 98 94 b7 4a 58 5f 68 5c 14 77 b5 |G.iy#...JX_h\.w.| -000002a0 4b db 6e d9 c2 74 d0 8a 94 a6 3f 61 7a 1d b8 53 |K.n..t....?az..S| -000002b0 c7 fb 1c d7 b7 ae 2b f2 c7 fc ed c3 77 47 8a be |......+.....wG..| -000002c0 c4 0a e2 3a da f6 f0 06 15 df 32 06 5e 81 17 aa |...:......2.^...| -000002d0 25 5c b0 56 56 ce 93 11 42 4d b1 b5 b5 d4 c9 47 |%\.VV...BM.....G| -000002e0 df 7c 44 ac 23 bc 49 f6 aa f8 9a e3 fc 4e 7e 11 |.|D.#.I......N~.| -000002f0 e5 da cc 0e c3 4e 57 5e 0d 7c 5a 98 e8 25 65 2e |.....NW^.|Z..%e.| -00000300 d0 9e 73 f1 eb 16 3b c4 bc 87 97 37 38 45 a0 77 |..s...;....78E.w| -00000310 79 37 30 aa 05 0a 42 04 e2 e3 09 ce 5b d7 04 c1 |y70...B.....[...| -00000320 b1 c4 89 bc 5d 92 eb 9a a2 b4 12 87 98 05 17 03 |....]...........| -00000330 03 00 99 0d 23 22 ba 58 d1 0a 8d 15 c6 ab 47 92 |....#".X......G.| -00000340 4b ab 8b 31 d3 cd f6 c9 17 31 62 e2 4f 78 3d 87 |K..1.....1b.Ox=.| -00000350 9f f9 54 10 4b db 86 99 dd eb e7 75 9d d1 dc 1c |..T.K......u....| -00000360 03 e2 b2 ae 61 69 66 33 e0 0f 95 4a 41 4f 36 6d |....aif3...JAO6m| -00000370 ed bd 80 51 8b 6c 92 dc 29 af 8d 17 12 b8 3d d7 |...Q.l..).....=.| -00000380 db 05 63 4f ad e5 6e 32 5b 02 27 f6 8f e3 7c 02 |..cO..n2[.'...|.| -00000390 15 c8 5e c8 f3 14 45 7c 2f 2d 81 aa ec 01 4f 12 |..^...E|/-....O.| -000003a0 f3 aa c8 e5 ca 52 62 41 7d ca f2 9e 40 c3 36 d3 |.....RbA}...@.6.| -000003b0 d8 40 be 59 0c 6a 67 aa 75 03 1c b7 b7 4b 21 3f |.@.Y.jg.u....K!?| -000003c0 13 28 10 e7 3f a1 25 1a 5d e4 a0 b9 17 03 03 00 |.(..?.%.].......| -000003d0 35 93 e3 71 c4 3b b0 4a 37 6d 1a 97 a5 c4 17 c4 |5..q.;.J7m......| -000003e0 cd 0c a0 f5 bb 06 1d 0c f6 0f c4 c3 de b9 0a b7 |................| -000003f0 37 9c d6 d4 43 a6 37 78 76 69 31 33 ed d8 db b4 |7...C.7xvi13....| -00000400 3a ac cc 0d db 1b |:.....| +00000060 d1 56 18 67 59 a5 e1 ed 99 0f ca e5 6b 5f e3 d9 |.V.gY.......k_..| +00000070 e3 fd e6 a2 50 93 bf 87 85 60 e7 7f 0b a0 96 c4 |....P....`......| +00000080 29 55 63 de fe 6b 75 99 b2 a6 75 92 61 d0 96 19 |)Uc..ku...u.a...| +00000090 f5 60 8f ec e9 d3 98 4a b9 6b 98 26 c1 3e 27 7e |.`.....J.k.&.>'~| +000000a0 17 03 03 00 17 5a aa bb 35 67 ec 83 da 8e 85 bd |.....Z..5g......| +000000b0 ae a5 0d c9 8b cd 03 bf 96 2b 35 61 17 03 03 02 |.........+5a....| +000000c0 6d 85 0c 7c d5 ff 0f 77 0a a4 b7 97 aa d3 f7 af |m..|...w........| +000000d0 4b 58 cb 24 4d 9f a6 d8 e2 c3 10 ce 3a 5d e4 cc |KX.$M.......:]..| +000000e0 84 7d 1f 71 bd b6 25 0c 10 75 d3 8d b6 12 04 56 |.}.q..%..u.....V| +000000f0 63 af 53 e5 cc 29 ce f7 18 7a 93 91 73 ae ff c1 |c.S..)...z..s...| +00000100 2e 2b 3d 76 ab 99 c8 e0 fd 69 b3 67 39 e9 58 40 |.+=v.....i.g9.X@| +00000110 4a 63 e8 71 c5 8d de 44 fb ef 4d 0a dc ae 51 12 |Jc.q...D..M...Q.| +00000120 7e ea 6a 25 32 8e 5b 08 6e c7 b2 87 00 4e 35 d8 |~.j%2.[.n....N5.| +00000130 cd 3b bd 8c dc e8 55 a9 2f 65 d1 7f c1 28 33 f9 |.;....U./e...(3.| +00000140 70 e1 af d8 2d 64 4c ac 5a 3a 16 6d 3e 97 a7 0e |p...-dL.Z:.m>...| +00000150 cd 28 05 1c ea 28 8d 63 a3 41 e2 3a 24 27 f4 43 |.(...(.c.A.:$'.C| +00000160 97 c8 89 09 ed 8b 96 74 b3 dc 98 f4 0c c2 6f 25 |.......t......o%| +00000170 fc 30 8a f8 25 49 e1 91 fb c6 39 23 ca d5 16 08 |.0..%I....9#....| +00000180 5f bf 10 88 71 a4 c5 ac e7 ad 9e 5a 4d e8 d3 1f |_...q......ZM...| +00000190 f0 5d 83 9d c9 e2 b3 f8 e4 a3 a5 57 5d ca 30 74 |.].........W].0t| +000001a0 a6 1b c7 51 50 05 5f 7e 93 71 1a 8d fc 04 d6 fe |...QP._~.q......| +000001b0 4e 4b 95 54 18 43 19 4d d2 dc 81 a8 94 76 7e 23 |NK.T.C.M.....v~#| +000001c0 56 8c 86 f9 15 d2 a8 0c 48 4e 0e 81 df e0 31 52 |V.......HN....1R| +000001d0 c9 2e b4 39 f3 cf ae e2 29 72 01 ed 34 4f 09 ce |...9....)r..4O..| +000001e0 64 de a9 9b 84 61 3a bb 0b ac 4e b1 6d 37 41 10 |d....a:...N.m7A.| +000001f0 5b cf 99 b1 3e e6 f5 7b 1c d4 d0 d5 34 fc ab c6 |[...>..{....4...| +00000200 29 8e 0b 53 e4 7b 35 33 e4 e3 f6 77 9b f6 c6 ae |)..S.{53...w....| +00000210 73 3c c5 80 c8 72 f7 56 6c 4c ce e5 a7 05 63 ee |s<...r.VlL....c.| +00000220 07 e0 1d 3e 73 3e 55 73 ba 63 a8 d7 99 6a 48 57 |...>s>Us.c...jHW| +00000230 0c 55 51 42 4b 27 91 4b 75 b3 3b 4c 29 f1 52 e8 |.UQBK'.Ku.;L).R.| +00000240 85 f9 49 53 ed 87 6d 9e 8f 5c 29 7c 5c 9c 4e 9a |..IS..m..\)|\.N.| +00000250 90 a8 99 2a 53 65 f7 d9 61 ef 6a 56 2a da 76 ed |...*Se..a.jV*.v.| +00000260 04 84 11 f5 1c 40 82 52 7d fa 00 79 43 12 42 b4 |.....@.R}..yC.B.| +00000270 ca 7a 86 d5 8d d6 c5 7b 04 13 79 08 72 0c ce d7 |.z.....{..y.r...| +00000280 88 9a f2 2c b5 9a 18 a4 d2 87 48 ce ab 17 33 fd |...,......H...3.| +00000290 cf 22 3c 72 03 86 af 35 2a b3 fe 24 0e 86 d8 82 |."......D..| +000002c0 14 12 cd 16 e5 6a 58 1b 3f f8 70 d6 47 e6 1b 98 |.....jX.?.p.G...| +000002d0 74 9c 21 2b 6d f8 8a 47 05 86 b1 fa 63 9d cc 19 |t.!+m..G....c...| +000002e0 da 9a a0 ea 5a 26 98 e6 b7 d0 da 03 b3 1d 33 e8 |....Z&........3.| +000002f0 55 74 ee 4b 6a 06 0f f1 45 35 72 81 bb c9 61 4e |Ut.Kj...E5r...aN| +00000300 60 d6 83 e6 ab 08 77 a4 f9 73 e5 d8 cb 66 9f 41 |`.....w..s...f.A| +00000310 00 15 2c 09 0e ad 16 02 6c 06 5f bc bf 47 f1 5a |..,.....l._..G.Z| +00000320 85 97 ab 88 e8 45 b0 31 96 ad 56 00 97 59 17 03 |.....E.1..V..Y..| +00000330 03 00 99 5e 77 80 46 1d 2f 47 9f b3 43 4d a6 2b |...^w.F./G..CM.+| +00000340 e9 f7 72 a2 d0 c6 69 7c df 5d ce a0 3b 89 e2 69 |..r...i|.]..;..i| +00000350 e7 35 5e 00 fb 87 10 4a a8 41 02 b7 89 fa 88 fc |.5^....J.A......| +00000360 72 63 ce bf 41 61 16 91 55 06 cd b6 fa 78 09 bc |rc..Aa..U....x..| +00000370 f6 21 a0 c2 1f f3 fa 34 2a 9e b9 8a 0c 72 81 02 |.!.....4*....r..| +00000380 66 a7 da 6b d6 e2 aa 99 6d 4b 42 f5 19 83 52 89 |f..k....mKB...R.| +00000390 9a 26 56 5d d5 a4 a7 bd ad b4 10 db ee 87 1d 15 |.&V]............| +000003a0 15 df 30 95 d8 61 e2 c4 88 47 e1 91 e3 85 33 fe |..0..a...G....3.| +000003b0 7d 02 0c 22 6b 52 22 a7 cf bf bf f0 9d 25 65 e0 |}.."kR"......%e.| +000003c0 6b da a2 8c 9a 00 3d 68 78 55 38 69 17 03 03 00 |k.....=hxU8i....| +000003d0 35 c8 ca 51 96 aa c1 4b a0 09 d3 bc d9 ea 35 db |5..Q...K......5.| +000003e0 f2 8d bb ab b3 23 09 a1 d1 9c 40 3e e4 84 d3 1c |.....#....@>....| +000003f0 60 64 5c ff 01 c7 78 69 c2 4a fb e1 c3 d6 f0 57 |`d\...xi.J.....W| +00000400 fa 3a 5f 7a 8b 70 |.:_z.p| >>> Flow 5 (client to server) -00000000 17 03 03 00 35 ee c2 44 be 17 16 64 cc e6 68 9b |....5..D...d..h.| -00000010 4d 75 86 c5 b5 9b f3 1c 7c b5 98 3f 9c 7b 07 65 |Mu......|..?.{.e| -00000020 53 f1 6c d9 cd 17 54 3f 64 d3 ca 47 9c 1e 2d 13 |S.l...T?d..G..-.| -00000030 fa 29 5e d8 91 5a 05 e8 03 21 17 03 03 00 17 41 |.)^..Z...!.....A| -00000040 a1 aa 11 80 44 b8 26 a8 06 62 46 65 59 35 0b 06 |....D.&..bFeY5..| -00000050 8e bf 6c 02 9d 5f 17 03 03 00 13 40 6d 8b 65 c6 |..l.._.....@m.e.| -00000060 9c 9d b1 ec 29 f3 3d 23 56 28 f6 5a 5b e3 |....).=#V(.Z[.| +00000000 17 03 03 00 35 24 4a 53 55 49 92 7a 21 a2 db 69 |....5$JSUI.z!..i| +00000010 e5 2b 00 29 83 cb 91 32 17 48 73 96 89 d1 b2 11 |.+.)...2.Hs.....| +00000020 c4 23 48 41 eb df eb 5a 10 c2 78 4e a2 e4 f0 38 |.#HA...Z..xN...8| +00000030 4a 1c b6 d3 bb 52 bc 7e f6 94 17 03 03 00 17 74 |J....R.~.......t| +00000040 04 34 8d 27 19 da f3 d8 14 30 1b 85 ad 1e 99 cd |.4.'.....0......| +00000050 06 f0 a3 50 94 48 17 03 03 00 13 ac 8f 7e 2e 9c |...P.H.......~..| +00000060 90 96 db 33 e2 e9 94 c1 c9 95 f2 7a d1 8f |...3.......z..| diff --git a/testdata/Client-TLSv13-KeyUpdate b/testdata/Client-TLSv13-KeyUpdate index 02c0a1a..1b8004a 100644 --- a/testdata/Client-TLSv13-KeyUpdate +++ b/testdata/Client-TLSv13-KeyUpdate @@ -7,97 +7,97 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 7f 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 0a 00 08 00 1d 00 17 00 18 00 19 00 0b 00 02 01 |................| -000000a0 00 00 0d 00 1a 00 18 08 04 04 03 08 07 08 05 08 |................| -000000b0 06 04 01 05 01 06 01 05 03 06 03 02 01 02 03 ff |................| -000000c0 01 00 01 00 00 17 00 00 00 12 00 00 00 2b 00 09 |.............+..| +00000080 01 00 00 7f 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 0a 00 08 00 1d 00 17 00 18 00 19 00 0d |................| +000000b0 00 1a 00 18 08 04 04 03 08 07 08 05 08 06 04 01 |................| +000000c0 05 01 06 01 05 03 06 03 02 01 02 03 00 2b 00 09 |.............+..| 000000d0 08 03 04 03 03 03 02 03 01 00 33 00 26 00 24 00 |..........3.&.$.| 000000e0 1d 00 20 2f e5 7d a3 47 cd 62 43 15 28 da ac 5f |.. /.}.G.bC.(.._| 000000f0 bb 29 07 30 ff f6 84 af c4 cf c2 ed 90 99 5f 58 |.).0.........._X| 00000100 cb 3b 74 |.;t| >>> Flow 2 (server to client) -00000000 16 03 03 00 7a 02 00 00 76 03 03 70 a7 d4 99 55 |....z...v..p...U| -00000010 7d 12 fd ca 3a 43 97 78 16 66 c2 bd 22 8b 6c 91 |}...:C.x.f..".l.| -00000020 85 92 99 76 c8 4c 0f 4c dc 94 0b 20 00 00 00 00 |...v.L.L... ....| +00000000 16 03 03 00 7a 02 00 00 76 03 03 dc 81 c4 82 2e |....z...v.......| +00000010 a2 4f c4 c2 53 c2 bc 6a bd f3 46 84 b5 ba 66 b5 |.O..S..j..F...f.| +00000020 8b 67 7c 90 51 40 12 39 18 e1 bf 20 00 00 00 00 |.g|.Q@.9... ....| 00000030 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |................| 00000040 00 00 00 00 00 00 00 00 00 00 00 00 13 03 00 00 |................| -00000050 2e 00 2b 00 02 03 04 00 33 00 24 00 1d 00 20 df |..+.....3.$... .| -00000060 af ca 9c 12 9b 83 69 24 89 3e 44 fe 1c 31 dd 0d |......i$.>D..1..| -00000070 3b 52 fd 8e b6 c6 7b 05 9e d4 cc 62 a5 f0 27 14 |;R....{....b..'.| -00000080 03 03 00 01 01 17 03 03 00 17 a8 47 c6 45 41 bc |...........G.EA.| -00000090 7e e3 fb 85 43 5d 6a 69 07 7f 62 05 9d 9e 5f 1f |~...C]ji..b..._.| -000000a0 9a 17 03 03 02 6d 7d 46 ba ff 8a 8a 3d a2 d0 29 |.....m}F....=..)| -000000b0 1e 0d 18 03 84 13 03 de cf 64 15 28 71 9a bb 80 |.........d.(q...| -000000c0 d0 4f de 07 d8 f4 47 d5 78 1c 93 e1 50 27 70 81 |.O....G.x...P'p.| -000000d0 34 c2 0d 63 ee 76 20 dd c7 34 71 e5 c7 04 91 62 |4..c.v ..4q....b| -000000e0 06 73 5c 71 e9 ce 13 f9 1c 5b 29 b5 16 64 0f 5b |.s\q.....[)..d.[| -000000f0 35 53 0d ba a6 26 1c 98 fa 20 41 a0 08 b1 d1 74 |5S...&... A....t| -00000100 cd 00 92 7e b4 ce 0e b8 2a 6d e0 25 57 2f e1 af |...~....*m.%W/..| -00000110 2c 23 03 03 1d b6 98 70 ec 7d 57 a9 6c 8f 25 3d |,#.....p.}W.l.%=| -00000120 63 a3 0e 53 b2 15 8d 1d 62 14 04 50 a9 bc ab 7d |c..S....b..P...}| -00000130 ac fa 6a 68 ed f0 72 fd 9a 04 ac bd 44 10 a6 f0 |..jh..r.....D...| -00000140 df 55 30 54 eb a1 c8 27 4d 6d 97 a1 c0 fc ca a5 |.U0T...'Mm......| -00000150 c0 9c b8 29 53 13 f2 c8 81 f1 3d f8 35 e5 8d b0 |...)S.....=.5...| -00000160 d9 c1 68 31 80 4f fb 3a 7a fc 20 ce 75 22 dc f6 |..h1.O.:z. .u"..| -00000170 94 e9 ff c4 5a c2 1d e9 a2 55 11 df 5d 29 92 17 |....Z....U..])..| -00000180 5e 9d df 16 97 e3 f0 d0 b6 bd 88 cf 5f 53 e5 da |^..........._S..| -00000190 08 98 37 ec d5 1d 8b 4b 59 33 6e 67 d7 e5 eb 9e |..7....KY3ng....| -000001a0 31 90 6b 75 c7 41 7c 1d 84 c3 78 03 0e 2b ce 5c |1.ku.A|...x..+.\| -000001b0 9a c2 e8 20 7c 8e bc 4a 6e e6 b9 30 ff b3 c0 33 |... |..Jn..0...3| -000001c0 73 91 f7 b6 13 bc 2c 85 97 ed a6 23 ed c1 e0 ce |s.....,....#....| -000001d0 8a 67 9a a3 b2 80 bb 06 ea 9c ec cd 27 f6 1f ae |.g..........'...| -000001e0 22 6e e4 c6 ec 5d e3 d9 99 8d 5e 15 5c d0 f1 83 |"n...]....^.\...| -000001f0 f2 dc 20 a0 67 ee e0 94 05 e3 d7 e9 a2 65 ae d8 |.. .g........e..| -00000200 da 12 2a db cd 2b 31 c3 ec 12 5b e0 5e 48 66 00 |..*..+1...[.^Hf.| -00000210 d9 f5 b8 28 1f ef 90 e8 8f a7 78 d7 1c 49 1d 10 |...(......x..I..| -00000220 d0 79 08 23 12 e1 30 91 7f 26 43 e2 0d dd 0f 6b |.y.#..0..&C....k| -00000230 ca ac 25 5f 18 86 40 fd 04 50 f6 dc fb 25 e4 67 |..%_..@..P...%.g| -00000240 d5 94 fe 3a 55 7f 0e 63 31 f2 96 40 cd 61 c4 e1 |...:U..c1..@.a..| -00000250 06 bc 5f 80 e9 1d 69 7c 70 7e e6 7f 25 00 75 ce |.._...i|p~..%.u.| -00000260 49 e4 bc 4c f4 79 8a d7 67 f3 50 a3 85 d2 96 cb |I..L.y..g.P.....| -00000270 51 f4 99 93 d6 20 cf 0d 5f 2d 87 83 df 7b d2 76 |Q.... .._-...{.v| -00000280 da 9c 47 fb 08 80 43 8e 1f c7 db 8e a9 a7 d5 bb |..G...C.........| -00000290 a3 af 0a 3e a3 a3 8c eb eb e0 93 45 56 a3 eb f0 |...>.......EV...| -000002a0 6e cd be 8f 42 4c aa 39 36 0e f2 d6 cc 37 ce a4 |n...BL.96....7..| -000002b0 31 c0 e0 24 3e 52 8c 3f dc 6e 73 e0 0e ef 54 b7 |1..$>R.?.ns...T.| -000002c0 27 2f 80 f8 16 0b 27 ea 73 66 c1 59 0b 91 a6 ae |'/....'.sf.Y....| -000002d0 f9 d7 d3 60 c0 b0 da 0f 83 19 c2 e0 6e e0 d0 a6 |...`........n...| -000002e0 87 74 91 f8 6c 46 e3 cd 3a 4c e5 ee 48 94 5b bc |.t..lF..:L..H.[.| -000002f0 e4 b5 ed 35 ba 11 c7 0d 76 e9 0a 52 11 a1 35 c2 |...5....v..R..5.| -00000300 e3 c3 9d fa 9d 9b 45 59 6a de 5b 9c c8 7e c3 00 |......EYj.[..~..| -00000310 16 06 d9 17 03 03 00 99 63 23 47 37 41 24 5e b5 |........c#G7A$^.| -00000320 7a 9d 0c 74 c7 f8 c8 62 9e c1 8a 44 29 22 d0 96 |z..t...b...D)"..| -00000330 c7 94 a1 c5 f6 80 1f 23 70 d5 61 cf b5 87 41 26 |.......#p.a...A&| -00000340 74 74 9b f4 1c 9d eb b3 da 39 0f 93 74 6a 2d 44 |tt.......9..tj-D| -00000350 b2 04 31 c0 b0 e8 27 1e eb 6e 1d 76 aa a7 15 11 |..1...'..n.v....| -00000360 fd 5a 46 68 e2 76 ec 92 fe 25 41 10 0f 99 da cf |.ZFh.v...%A.....| -00000370 1a 04 a2 09 8e a1 73 ca 74 7e f7 d2 0e f1 cf 74 |......s.t~.....t| -00000380 14 c4 bc 66 6e 28 58 24 09 cb bc da 4d da 4f af |...fn(X$....M.O.| -00000390 b8 c5 18 37 34 02 e2 60 b9 cc e9 4b 93 08 0a 22 |...74..`...K..."| -000003a0 b6 a1 85 b2 ab cd 9c b6 1b 1d 18 46 63 4c 11 c5 |...........FcL..| -000003b0 67 17 03 03 00 35 10 30 1b 3e 00 ea 4a 8a ab f7 |g....5.0.>..J...| -000003c0 19 f8 3b 99 5f 56 a6 a3 ed dd 43 33 d9 8f 17 30 |..;._V....C3...0| -000003d0 f5 a9 fb cd df 5e 95 e8 ff 35 1d 8d de d2 48 5a |.....^...5....HZ| -000003e0 af a1 b5 60 4f 75 98 58 1c 24 a1 |...`Ou.X.$.| +00000050 2e 00 2b 00 02 03 04 00 33 00 24 00 1d 00 20 3b |..+.....3.$... ;| +00000060 6b 2a e6 c2 7e b6 59 68 e4 e3 f2 f3 14 e5 72 bc |k*..~.Yh......r.| +00000070 c9 61 b4 b0 0a c6 41 0d a9 8e d9 9b 7d 2a 11 14 |.a....A.....}*..| +00000080 03 03 00 01 01 17 03 03 00 17 43 af 38 b9 56 06 |..........C.8.V.| +00000090 2d 10 e3 e5 1d 1b 1e a9 5f 90 ca 0d a9 52 33 86 |-......._....R3.| +000000a0 85 17 03 03 02 6d ac 6a a1 8f 42 27 74 80 25 f9 |.....m.j..B't.%.| +000000b0 1f 48 49 2d c2 33 38 e7 93 7e b0 b2 50 b8 6a ea |.HI-.38..~..P.j.| +000000c0 a6 81 ef 9b 55 83 4e 93 df 92 97 6f 00 f5 c4 fc |....U.N....o....| +000000d0 ec b1 19 dd 68 b5 bd c4 bb ba 63 9a e4 c9 24 af |....h.....c...$.| +000000e0 88 13 65 11 bf ea d9 07 e9 46 fd 5b 60 ce 57 46 |..e......F.[`.WF| +000000f0 8b a9 bd c6 58 1a 3b bd 5e fb 0f 46 ec fc 8b 2c |....X.;.^..F...,| +00000100 ea a7 19 06 6a e5 6f 10 7a 27 04 6b aa a4 2c f4 |....j.o.z'.k..,.| +00000110 ef 3b e8 8a 51 88 fd e0 ae 33 b1 4c b3 04 5e 91 |.;..Q....3.L..^.| +00000120 b0 98 0b 9f 38 a3 3c fb 9f d5 d2 36 e4 09 19 18 |....8.<....6....| +00000130 a5 b3 12 aa c9 03 ac b5 ab bb f1 7a 02 d2 dd 75 |...........z...u| +00000140 0e cb 60 09 39 23 c3 b2 c1 8e e0 18 57 72 54 61 |..`.9#......WrTa| +00000150 4c 99 35 1d ba 31 01 0c 48 d2 f2 88 22 9c 91 7d |L.5..1..H..."..}| +00000160 e3 74 f9 b3 52 bf 0e 0b e1 31 7c 2c cb fd f2 8c |.t..R....1|,....| +00000170 bf 27 40 6d 26 b7 62 47 56 91 22 00 67 9a df 4f |.'@m&.bGV.".g..O| +00000180 f0 47 57 3c a6 46 4d 16 f6 8d fc 2d 91 c4 1a bf |.GW<.FM....-....| +00000190 38 63 ec 63 fe 97 14 80 aa 5b 60 ff c8 77 57 9c |8c.c.....[`..wW.| +000001a0 d5 86 a6 76 96 b3 e9 db c9 eb dd 94 84 2a 46 f5 |...v.........*F.| +000001b0 6a c1 10 66 59 f1 13 b9 41 f3 89 26 ba 52 69 95 |j..fY...A..&.Ri.| +000001c0 b1 f3 66 30 f8 aa 90 f7 90 49 19 48 4c 25 4a 1f |..f0.....I.HL%J.| +000001d0 12 9d 67 32 79 bb 53 d8 c5 d1 b4 6e 89 75 49 c0 |..g2y.S....n.uI.| +000001e0 65 86 ac 72 23 2f 97 d3 ae e2 64 79 5e e2 10 4e |e..r#/....dy^..N| +000001f0 55 0c c6 70 d3 2e 4a 6c b0 73 0a 11 eb ae f7 a1 |U..p..Jl.s......| +00000200 a1 f0 5f 67 45 46 d3 8c 11 ff 21 62 7d ed f9 0e |.._gEF....!b}...| +00000210 2a ba b3 82 f5 6b c1 4a 4e cc 11 90 48 81 96 7a |*....k.JN...H..z| +00000220 df f9 22 ae 53 31 14 9d c9 5c 85 e7 db a2 dd 02 |..".S1...\......| +00000230 56 eb d0 fe 20 35 21 c9 33 63 b5 b7 a8 93 30 7f |V... 5!.3c....0.| +00000240 86 1f d1 af b1 ff 3e 9a d1 a8 90 d9 9c 86 55 e8 |......>.......U.| +00000250 d0 4c c4 6d a3 ce c6 c0 df f8 a8 b6 43 03 ae fc |.L.m........C...| +00000260 7d 94 7b fe be 85 46 d8 42 9d b6 15 b9 a3 27 3d |}.{...F.B.....'=| +00000270 80 64 54 c8 53 c4 a7 94 52 8f 9d 4c 58 54 a5 c4 |.dT.S...R..LXT..| +00000280 e0 e7 2e cb f3 8c d0 82 3f 95 76 c9 ea ea 80 41 |........?.v....A| +00000290 21 5d 3e a3 1e be 4e 0b ce 10 ab 61 a5 76 ef 62 |!]>...N....a.v.b| +000002a0 50 1b 52 a8 75 23 fd eb ea 76 f9 d8 41 3c a2 e4 |P.R.u#...v..A<..| +000002b0 21 cb 56 f7 40 81 78 56 22 06 2a 38 fc 1f d8 9f |!.V.@.xV".*8....| +000002c0 38 b0 7a 93 f0 8c ad 3e 54 27 a2 d7 8b 2c 79 46 |8.z....>T'...,yF| +000002d0 15 65 f1 55 b2 2a 06 a1 97 9b 47 23 f8 9a 3f 88 |.e.U.*....G#..?.| +000002e0 8e 26 7e 13 cd 6e 8b cb d5 a5 78 48 f7 ba ad d8 |.&~..n....xH....| +000002f0 08 3b 34 5b 52 cd e3 2d 12 ac 81 00 c0 d0 4d df |.;4[R..-......M.| +00000300 56 d6 40 86 91 31 3d ba 6b 41 bc 51 6f ac b2 df |V.@..1=.kA.Qo...| +00000310 90 4b 78 17 03 03 00 99 21 0f 5b 18 54 84 98 0c |.Kx.....!.[.T...| +00000320 3a 7b 0b db 99 0e 09 f6 b7 4f a9 cc da bf 4c ac |:{.......O....L.| +00000330 5f 44 fc ba 9d 5d 52 d5 ec 2e 08 0c cc 3c e1 72 |_D...]R......<.r| +00000340 10 77 5b 7b 55 f7 c1 44 a3 25 e0 48 20 9a 3a de |.w[{U..D.%.H .:.| +00000350 2f ae 30 a9 e9 5b 75 84 e3 59 f0 6b 23 a6 d8 20 |/.0..[u..Y.k#.. | +00000360 16 51 2a 19 61 60 35 28 74 41 32 fa 97 8d 3b ed |.Q*.a`5(tA2...;.| +00000370 ff 64 94 d7 27 4c 9b 1e 5e b8 89 43 e3 ae 2a b6 |.d..'L..^..C..*.| +00000380 60 a8 bb f0 d1 75 85 15 bb 95 3c 82 f1 62 da b1 |`....u....<..b..| +00000390 25 d2 58 7d 67 7f 02 5b b4 91 68 3c 70 10 09 94 |%.X}g..[..h>> Flow 3 (client to server) -00000000 14 03 03 00 01 01 17 03 03 00 35 a5 8d 0a 81 b7 |..........5.....| -00000010 76 39 48 24 74 8a a8 f0 91 9b b7 10 14 e3 1f fe |v9H$t...........| -00000020 a5 2f 96 6a 7a c3 9d 90 66 99 46 78 c8 d0 1d ba |./.jz...f.Fx....| -00000030 34 be 04 c1 a9 4d 17 60 06 a8 04 18 f3 53 9b 33 |4....M.`.....S.3| -00000040 17 03 03 00 17 14 2c cf 98 1c b3 44 d5 cb 9a 8a |......,....D....| -00000050 46 84 e8 d2 7d 81 bf 74 e6 08 4b 1c |F...}..t..K.| +00000000 14 03 03 00 01 01 17 03 03 00 35 c9 09 ac f5 44 |..........5....D| +00000010 40 83 88 5a b9 46 70 b9 ff 9b 2e bb b4 7e 72 b0 |@..Z.Fp......~r.| +00000020 85 26 d6 37 33 ec d1 ac ce f4 db 72 8c e1 07 b5 |.&.73......r....| +00000030 d0 ce ee 2f 19 77 62 ec 97 ae 1b e1 5f 85 bf c4 |.../.wb....._...| +00000040 17 03 03 00 17 1c ae 0f 1d 50 be 4b d0 64 4f 23 |.........P.K.dO#| +00000050 41 60 d9 c7 f5 60 a6 5c 38 14 fd d5 |A`...`.\8...| >>> Flow 4 (server to client) -00000000 17 03 03 00 16 3e c3 0e 81 bd 7c e9 21 c8 d1 3f |.....>....|.!..?| -00000010 94 a9 37 43 21 42 3b 81 ba 65 53 |..7C!B;..eS| +00000000 17 03 03 00 16 ad 61 13 66 9c 3c dd 88 42 2c 6c |......a.f.<..B,l| +00000010 d1 22 5d b4 b2 6f f0 68 4f 37 4d |."]..o.hO7M| >>> Flow 5 (client to server) -00000000 17 03 03 00 16 63 a6 48 59 77 ae a9 a7 40 e2 57 |.....c.HYw...@.W| -00000010 9b 41 bb e8 14 06 01 46 71 46 77 |.A.....FqFw| +00000000 17 03 03 00 16 e5 b5 ff ad d4 f5 e5 55 04 83 a7 |............U...| +00000010 59 43 9a 3e 68 4d 38 6f b1 1c 30 |YC.>hM8o..0| >>> Flow 6 (server to client) -00000000 17 03 03 00 1a 20 8a 20 30 bc 48 17 8f ed 57 bb |..... . 0.H...W.| -00000010 e8 2a da 2a 21 5b 4d 11 74 13 32 6f 1c d6 7c |.*.*![M.t.2o..|| +00000000 17 03 03 00 1a 64 0c f4 8e 8f 2b 04 e2 36 28 77 |.....d....+..6(w| +00000010 a2 28 97 4b 15 ba 1b b2 10 31 b3 4d 87 09 af |.(.K.....1.M...| >>> Flow 7 (client to server) -00000000 17 03 03 00 1d fb 5b 0c dc f1 6b 02 a7 f6 68 21 |......[...k...h!| -00000010 a4 5c 29 7e 52 08 5f 4d fb cb e4 a6 ae c9 e0 09 |.\)~R._M........| -00000020 01 02 17 03 03 00 13 4e 79 eb 2d 97 87 45 9d 73 |.......Ny.-..E.s| -00000030 6f 13 be c5 68 50 ef 03 4c 18 |o...hP..L.| +00000000 17 03 03 00 1d 90 c9 33 bf fc 76 12 3d af 9e c8 |.......3..v.=...| +00000010 8c ca e7 a1 63 6e 80 91 b1 7f 5e e4 dc c2 e6 1c |....cn....^.....| +00000020 b6 2b 17 03 03 00 13 ef a8 30 91 b1 20 fe 82 79 |.+.......0.. ..y| +00000030 44 31 a8 af 99 bb 5e 97 75 a3 |D1....^.u.| diff --git a/testdata/Client-TLSv13-P256-ECDHE b/testdata/Client-TLSv13-P256-ECDHE index 7280daf..fa8d312 100644 --- a/testdata/Client-TLSv13-P256-ECDHE +++ b/testdata/Client-TLSv13-P256-ECDHE @@ -7,88 +7,88 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 9a 00 05 00 05 01 00 00 00 00 00 0a 00 |................| -00000090 04 00 02 00 17 00 0b 00 02 01 00 00 0d 00 1a 00 |................| -000000a0 18 08 04 04 03 08 07 08 05 08 06 04 01 05 01 06 |................| -000000b0 01 05 03 06 03 02 01 02 03 ff 01 00 01 00 00 17 |................| -000000c0 00 00 00 12 00 00 00 2b 00 09 08 03 04 03 03 03 |.......+........| +00000080 01 00 00 9a 00 0b 00 02 01 00 ff 01 00 01 00 00 |................| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 04 00 02 00 17 00 0d 00 1a 00 18 08 04 |................| +000000b0 04 03 08 07 08 05 08 06 04 01 05 01 06 01 05 03 |................| +000000c0 06 03 02 01 02 03 00 2b 00 09 08 03 04 03 03 03 |.......+........| 000000d0 02 03 01 00 33 00 47 00 45 00 17 00 41 04 1e 18 |....3.G.E...A...| 000000e0 37 ef 0d 19 51 88 35 75 71 b5 e5 54 5b 12 2e 8f |7...Q.5uq..T[...| 000000f0 09 67 fd a7 24 20 3e b2 56 1c ce 97 28 5e f8 2b |.g..$ >.V...(^.+| 00000100 2d 4f 9e f1 07 9f 6c 4b 5b 83 56 e2 32 42 e9 58 |-O....lK[.V.2B.X| 00000110 b6 d7 49 a6 b5 68 1a 41 03 56 6b dc 5a 89 |..I..h.A.Vk.Z.| >>> Flow 2 (server to client) -00000000 16 03 03 00 9b 02 00 00 97 03 03 fe 3a 17 76 b0 |............:.v.| -00000010 7f a1 ed 8e fa 88 7a c6 d0 78 62 83 db b8 a3 72 |......z..xb....r| -00000020 77 c7 18 54 f3 07 3b 08 f0 fb be 20 00 00 00 00 |w..T..;.... ....| +00000000 16 03 03 00 9b 02 00 00 97 03 03 1c 1a ee 30 2f |..............0/| +00000010 02 10 0c 84 ee 6a 2c d1 67 76 00 8a 16 e5 15 c5 |.....j,.gv......| +00000020 4c d7 a9 26 33 43 9a 9a d6 f8 e7 20 00 00 00 00 |L..&3C..... ....| 00000030 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |................| 00000040 00 00 00 00 00 00 00 00 00 00 00 00 13 03 00 00 |................| 00000050 4f 00 2b 00 02 03 04 00 33 00 45 00 17 00 41 04 |O.+.....3.E...A.| -00000060 e2 a0 62 23 50 9d 82 7d bc f4 f4 e7 ed d0 6c 6e |..b#P..}......ln| -00000070 f2 46 f4 e6 11 5f e0 f3 02 e3 13 67 e3 92 da 39 |.F..._.....g...9| -00000080 15 a2 3a c7 80 16 e6 25 fd 86 59 56 08 ee 78 eb |..:....%..YV..x.| -00000090 d9 ba 36 69 d3 fe bc fc 92 a1 1b 48 a1 a5 6c 09 |..6i.......H..l.| -000000a0 14 03 03 00 01 01 17 03 03 00 17 0f 26 b2 e7 86 |............&...| -000000b0 1a 6f e5 19 28 d1 0c 5f 4d 45 7e e6 9f f8 16 03 |.o..(.._ME~.....| -000000c0 d2 71 17 03 03 02 6d 2e bc 2a 2c eb e1 97 06 37 |.q....m..*,....7| -000000d0 87 39 bf f1 79 3a ba 23 51 26 37 a1 ba 2c 30 d9 |.9..y:.#Q&7..,0.| -000000e0 65 f8 8e 54 b7 1a 8a ff e8 eb 50 ab f4 e5 0f 07 |e..T......P.....| -000000f0 94 6b 3d 40 2f bc f7 1c 51 b7 6a 22 78 da 4c ab |.k=@/...Q.j"x.L.| -00000100 74 2b b5 f9 c5 2f f5 b8 8a c0 3b c3 56 d8 79 94 |t+.../....;.V.y.| -00000110 d7 2c bc 7e 2d a8 aa 7d 93 1e 24 49 34 a2 c8 83 |.,.~-..}..$I4...| -00000120 fc 0e b2 c7 f8 15 9c fd 6f 67 d8 32 e4 ce e6 c2 |........og.2....| -00000130 a5 ae c2 8b 40 dd b5 46 dc b9 40 e1 21 47 0e 55 |....@..F..@.!G.U| -00000140 7b f5 87 35 6d 10 22 04 a3 4f f8 95 54 0c 41 a6 |{..5m."..O..T.A.| -00000150 95 7b 0e 96 4b 73 c2 75 c9 87 ce a9 89 06 a9 7a |.{..Ks.u.......z| -00000160 26 ec 81 70 48 4d 24 f4 09 00 aa 92 ac a2 77 9d |&..pHM$.......w.| -00000170 ad aa 18 0f e0 f7 91 c9 80 46 c2 db e7 87 fd 3d |.........F.....=| -00000180 f2 8f ee cb 26 7d ae 1f 17 6e d0 d4 cd 11 80 a2 |....&}...n......| -00000190 57 57 88 78 2e 32 ac 2f 1c ad 5b 86 d2 94 55 9f |WW.x.2./..[...U.| -000001a0 cd 41 b7 cf 6d bb 45 6a 0b 72 79 91 81 1a 79 b3 |.A..m.Ej.ry...y.| -000001b0 6e 7f f4 8a 7b c0 b0 a6 00 0e c0 fe 67 4e e3 96 |n...{.......gN..| -000001c0 5b 0f 1b 47 b5 43 94 91 e9 c4 5f 0b 04 46 bd 53 |[..G.C...._..F.S| -000001d0 f0 44 a9 0c 46 39 d0 e0 9c 25 76 4e 26 f4 49 12 |.D..F9...%vN&.I.| -000001e0 42 7a a7 19 98 f0 93 1f 42 78 c7 1c 87 f0 92 ab |Bz......Bx......| -000001f0 ec 8b f9 4f e3 60 ea fd 88 b5 9d 68 18 59 60 ee |...O.`.....h.Y`.| -00000200 66 a9 0a 24 33 4a 9f c1 c0 e1 70 a0 c3 b1 8d f5 |f..$3J....p.....| -00000210 4a eb 5e f6 8f a9 2f c7 df 88 40 41 61 b3 3e 18 |J.^.../...@Aa.>.| -00000220 66 f7 e1 b7 a6 a9 3a 10 73 ab a4 ce 39 40 8a 78 |f.....:.s...9@.x| -00000230 47 7f bc c9 08 c3 f0 0e 1e 09 87 bf fc e0 46 38 |G.............F8| -00000240 e7 79 4e 9e 50 94 e7 94 ab 54 47 a7 07 7f 9d 7c |.yN.P....TG....|| -00000250 9e 83 9b ba dd 33 5d de db 80 9f a0 7d 9f c3 57 |.....3].....}..W| -00000260 83 45 0d a6 82 61 75 b7 14 54 0c 7e 94 8a fb 4a |.E...au..T.~...J| -00000270 9b 62 bf 8f ae 37 76 23 a0 e0 c0 e0 c1 2c 53 28 |.b...7v#.....,S(| -00000280 4c 5b b7 b3 c1 4e bb e5 cd e8 b0 7b 8e 38 b0 bb |L[...N.....{.8..| -00000290 74 d2 00 63 b4 7b 97 a3 48 52 0f f2 60 0c 0b e4 |t..c.{..HR..`...| -000002a0 b4 0f 1c 9c 97 e1 fa ff 26 61 f8 3c ee 41 66 f8 |........&a.<.Af.| -000002b0 b3 91 cd 30 bd ef 81 cf 23 3a ea fd b8 96 b6 e3 |...0....#:......| -000002c0 bd 32 f2 0f 7a 3d 08 2c 50 a4 16 4e a6 2b 6b 2e |.2..z=.,P..N.+k.| -000002d0 3e 7e a0 bc 10 c2 3c 30 65 fc 26 cd 2b 51 54 27 |>~....<0e.&.+QT'| -000002e0 29 62 eb 99 bb 0b f8 29 ce 8a 21 87 c1 8e f8 6c |)b.....)..!....l| -000002f0 17 fe 96 08 db 03 ef 22 ab 2a 55 8e 11 15 19 97 |.......".*U.....| -00000300 66 9b f3 16 b4 ce 7c 29 f7 e0 ba 1a 14 46 42 20 |f.....|).....FB | -00000310 38 8b 26 8a 53 13 83 a0 a5 76 2d 4c 3c 88 6e a0 |8.&.S....v-L<.n.| -00000320 38 23 69 20 d1 3e c9 40 9b 46 4c 09 d9 50 80 49 |8#i .>.@.FL..P.I| -00000330 bd 59 d9 ec 17 03 03 00 99 a2 f2 c7 ce c6 45 c8 |.Y............E.| -00000340 45 9a 9d a8 83 d9 81 ff 2d ef 81 f9 b7 3d 0e 79 |E.......-....=.y| -00000350 54 5f f4 ca f0 41 20 91 f7 5c 53 49 09 ee b6 27 |T_...A ..\SI...'| -00000360 82 61 0f 1e b9 2d 0f 4e dd e7 3f 05 3c eb bc 2c |.a...-.N..?.<..,| -00000370 81 ca 5d 2f e5 56 f8 ec e5 cb 69 da e9 16 79 ba |..]/.V....i...y.| -00000380 61 8d a9 09 31 2f d3 4c 87 bf 6c 1a 50 df 81 cd |a...1/.L..l.P...| -00000390 ba 4c 28 a1 47 05 13 65 f5 6d a0 fb 04 f6 5f 78 |.L(.G..e.m...._x| -000003a0 d9 28 67 99 ee b9 a1 07 85 3c 5b 17 48 f3 87 43 |.(g......<[.H..C| -000003b0 ca 40 12 59 85 34 da 67 8a 26 3e 0c 11 9f 42 82 |.@.Y.4.g.&>...B.| -000003c0 81 80 56 5b a9 6f c2 73 9d 9a 5e ab 97 a2 a4 49 |..V[.o.s..^....I| -000003d0 9f 73 17 03 03 00 35 7c 74 eb 0d 2b 2f b3 92 2e |.s....5|t..+/...| -000003e0 54 12 f9 cb ae fb d4 8d 6f 7f 93 c5 bd 54 1d d5 |T.......o....T..| -000003f0 06 71 bf 3f 43 71 7b ce 20 9d a9 12 bf dd 2c 3c |.q.?Cq{. .....,<| -00000400 b5 7e 9d 3a 56 e3 8b d1 15 0e 69 35 |.~.:V.....i5| +00000060 f0 2e aa 75 ea 32 f4 3c ea b7 61 13 0f 22 8d 39 |...u.2.<..a..".9| +00000070 9e 0a 53 c8 d6 92 ea 5e 87 5b 46 d3 71 2d d1 df |..S....^.[F.q-..| +00000080 fa 1e 9a 6a 0e b2 bc d7 91 6e 26 56 17 24 11 d8 |...j.....n&V.$..| +00000090 0f be c0 1d f5 fd c7 9d 2d 3c a0 0f ee 03 70 1f |........-<....p.| +000000a0 14 03 03 00 01 01 17 03 03 00 17 8e 76 66 0d 44 |............vf.D| +000000b0 aa a2 d9 80 84 7c 6d 42 f0 ee 9f a3 6c b8 83 21 |.....|mB....l..!| +000000c0 5d 7b 17 03 03 02 6d 18 d3 53 cc 09 6a 23 fc c5 |]{....m..S..j#..| +000000d0 a9 2e 73 b4 3d ea 54 56 42 f5 1f 71 3e 8f 8e 7b |..s.=.TVB..q>..{| +000000e0 12 18 d7 d6 ab ed 24 5f 16 c8 18 5e e0 28 84 40 |......$_...^.(.@| +000000f0 89 49 a7 91 57 d6 2b a0 9c ab 5d 85 ac 4f 6b 70 |.I..W.+...]..Okp| +00000100 c3 31 e0 57 87 d7 7c 45 27 34 54 eb 85 02 14 2c |.1.W..|E'4T....,| +00000110 a0 53 4f ec 21 9f 04 91 38 b8 df 2c 5d 0b 79 0a |.SO.!...8..,].y.| +00000120 4f 96 79 15 72 de b5 fb 43 1f d8 71 62 d8 e0 69 |O.y.r...C..qb..i| +00000130 21 13 87 ab e5 b8 e5 86 01 74 25 b7 39 fc 86 e2 |!........t%.9...| +00000140 2f de 0b 1f 8c db b2 98 b3 47 c1 4e dd db 36 d3 |/........G.N..6.| +00000150 28 de cf 4c 4d 54 8e a3 e5 d3 38 19 1f 4b 05 7f |(..LMT....8..K..| +00000160 9a e1 59 4c a3 4e 42 b6 71 0d 9c 96 e4 d8 29 73 |..YL.NB.q.....)s| +00000170 4e e6 f5 87 56 04 99 c2 56 15 6c 8b 04 7c e5 83 |N...V...V.l..|..| +00000180 8b f3 42 e8 97 7a b0 cc 7d 15 b8 84 d3 08 dd c1 |..B..z..}.......| +00000190 89 f5 d4 19 d2 f6 fd 32 b4 37 6e 6a cc 0c 7a 69 |.......2.7nj..zi| +000001a0 09 57 78 36 d4 5b 8c 23 0f e6 39 08 4c 58 3e 3f |.Wx6.[.#..9.LX>?| +000001b0 b1 a0 ae 2e 85 b7 64 45 dd e1 ae c4 91 53 8c 6f |......dE.....S.o| +000001c0 02 70 45 f0 97 7b c8 90 88 0e 95 ed 1e 81 fc 86 |.pE..{..........| +000001d0 27 83 3d 32 43 d6 e4 f3 84 c6 c4 c1 b2 1c 0d 4a |'.=2C..........J| +000001e0 22 78 cd 1c f8 0a aa 19 1a 96 cc 46 6d a0 7f c7 |"x.........Fm...| +000001f0 2f d8 68 de 48 7d ae 42 b3 75 2a d5 ab cf e7 a7 |/.h.H}.B.u*.....| +00000200 a1 e6 66 e0 88 d8 14 25 81 21 4a 6f f7 7c 84 57 |..f....%.!Jo.|.W| +00000210 9c cd 45 8a c0 2d 5f 97 b6 66 96 f1 be d8 02 d2 |..E..-_..f......| +00000220 a4 8e fb 0d c4 cc 02 12 1d b7 76 73 8d 73 8e 71 |..........vs.s.q| +00000230 ec 62 4b ba d1 94 98 e5 de 45 f4 92 22 79 9a 2e |.bK......E.."y..| +00000240 b4 12 a6 f8 ab 8a 52 c3 df f8 77 a9 71 8b ff d6 |......R...w.q...| +00000250 2b bc 47 0b 63 5b 0f cf f8 f1 86 7a 72 91 78 7b |+.G.c[.....zr.x{| +00000260 b8 52 74 96 40 4c 08 f3 ca 46 ef d9 b9 6d 7a dc |.Rt.@L...F...mz.| +00000270 2c da f1 c2 c4 1f 19 38 84 cf 7d b7 5d f2 19 a7 |,......8..}.]...| +00000280 bc 81 70 48 1c 5d da e7 e1 8f 94 33 fa b9 44 97 |..pH.].....3..D.| +00000290 52 7a 22 75 f3 3e 08 f5 d3 66 be 63 8e e6 fc 7b |Rz"u.>...f.c...{| +000002a0 54 6d 14 2e 88 09 c7 a1 a6 b7 8e f3 9f 66 dd a4 |Tm...........f..| +000002b0 ec 81 e9 4b 44 69 29 78 95 dd 44 80 f5 f9 41 23 |...KDi)x..D...A#| +000002c0 97 53 71 63 2d cc d0 47 d6 f7 3f 6b 61 5f 44 33 |.Sqc-..G..?ka_D3| +000002d0 61 d1 35 94 42 7b 88 b9 af 6f e2 c1 71 7b d9 12 |a.5.B{...o..q{..| +000002e0 2c b6 57 fa 42 98 27 6d 8a da f8 dd de 6f b2 ea |,.W.B.'m.....o..| +000002f0 c8 de 5c 09 cd 47 36 10 0f 52 72 39 b2 e5 92 19 |..\..G6..Rr9....| +00000300 81 2a e0 ae aa cc b5 d1 68 98 c4 69 02 fc 86 1a |.*......h..i....| +00000310 79 9c 11 54 fc 43 8a ed 63 50 83 49 ac bf 4c ad |y..T.C..cP.I..L.| +00000320 80 04 98 fd 33 19 76 49 8f fe 5a 0f 22 69 3e eb |....3.vI..Z."i>.| +00000330 d8 eb 51 71 17 03 03 00 99 42 4d 4b db 37 6c c3 |..Qq.....BMK.7l.| +00000340 fb 93 1f a6 7a 86 3c 5e 88 e5 75 d4 a1 73 4a b3 |....z.<^..u..sJ.| +00000350 0b 99 f1 a6 98 5f 6d 0f 00 0e 4f fa a3 5e 7d f0 |....._m...O..^}.| +00000360 41 dd dd 5c 71 3b 10 f9 75 07 d5 6c f2 83 83 5c |A..\q;..u..l...\| +00000370 60 32 d9 d2 b3 13 1b 6c 84 2b 02 58 da b6 18 4e |`2.....l.+.X...N| +00000380 ea 7d b3 46 2b a9 ec e7 65 3a 8e 2f 77 48 92 72 |.}.F+...e:./wH.r| +00000390 6a 82 47 bd 82 2b f7 01 6b c4 22 e2 43 78 78 03 |j.G..+..k.".Cxx.| +000003a0 3c 40 d9 6c d1 b3 5e 21 4d 52 74 e4 07 70 56 21 |<@.l..^!MRt..pV!| +000003b0 05 37 37 82 13 cd e6 ce 3f 93 61 74 b4 9a 42 7d |.77.....?.at..B}| +000003c0 26 fa 15 4f ed b7 63 22 3c 92 f3 72 9c d2 80 17 |&..O..c"<..r....| +000003d0 30 f0 17 03 03 00 35 8c f6 08 33 76 5a a4 7b ef |0.....5...3vZ.{.| +000003e0 0d 91 b6 bf fa 9e 39 19 6f 79 77 4c 4d 74 95 71 |......9.oywLMt.q| +000003f0 00 73 37 17 50 ef 55 fb 71 04 36 87 2e 16 5e 25 |.s7.P.U.q.6...^%| +00000400 9b d4 9c 52 f9 ec c5 26 7e 58 ed 9f |...R...&~X..| >>> Flow 3 (client to server) -00000000 14 03 03 00 01 01 17 03 03 00 35 07 f8 0f 71 b3 |..........5...q.| -00000010 74 36 f9 e0 2c a4 ac bc 9f 19 fc a7 aa 3d 8e cb |t6..,........=..| -00000020 22 4b 8f 54 f3 4f b2 a5 85 8a c9 ab b0 b7 62 61 |"K.T.O........ba| -00000030 58 dc 64 88 bb 43 6e 61 af 02 88 ca d8 15 b3 02 |X.d..Cna........| -00000040 17 03 03 00 17 25 37 e4 43 40 29 dd 4b fd a6 22 |.....%7.C@).K.."| -00000050 00 75 02 49 c6 64 a1 ed de ed 96 cb 17 03 03 00 |.u.I.d..........| -00000060 13 d6 49 0b ba 13 f3 5b 80 63 79 c8 6a f6 2d df |..I....[.cy.j.-.| -00000070 3f d3 2c 8b |?.,.| +00000000 14 03 03 00 01 01 17 03 03 00 35 f5 7f 27 09 c2 |..........5..'..| +00000010 54 9d e7 a7 3b 14 b3 f2 a6 6d 27 5f 9b 79 04 17 |T...;....m'_.y..| +00000020 28 5c de 4f 67 cf a5 24 e4 d3 c5 e1 38 fa 7e e8 |(\.Og..$....8.~.| +00000030 97 03 7e 66 3b d0 6b e7 f8 7e 97 e0 db 6a da 79 |..~f;.k..~...j.y| +00000040 17 03 03 00 17 30 1a e2 fe 4a 7a 03 03 82 f6 05 |.....0...Jz.....| +00000050 e8 18 67 1d 14 ab 4f 3c 22 c6 45 f5 17 03 03 00 |..g...O<".E.....| +00000060 13 f8 8f 43 e7 74 3c a0 28 b2 71 5a 85 69 e5 86 |...C.t<.(.qZ.i..| +00000070 06 e3 4c 91 |..L.| diff --git a/testdata/Client-TLSv13-X25519-ECDHE b/testdata/Client-TLSv13-X25519-ECDHE index b430ce0..855f63d 100644 --- a/testdata/Client-TLSv13-X25519-ECDHE +++ b/testdata/Client-TLSv13-X25519-ECDHE @@ -7,84 +7,84 @@ 00000050 cc a8 c0 2b c0 2f c0 2c c0 30 c0 09 c0 13 c0 0a |...+./.,.0......| 00000060 c0 14 00 9c 00 9d 00 2f 00 35 c0 12 00 0a c0 23 |......./.5.....#| 00000070 c0 27 00 3c c0 07 c0 11 00 05 13 03 13 01 13 02 |.'.<............| -00000080 01 00 00 79 00 05 00 05 01 00 00 00 00 00 0a 00 |...y............| -00000090 04 00 02 00 1d 00 0b 00 02 01 00 00 0d 00 1a 00 |................| -000000a0 18 08 04 04 03 08 07 08 05 08 06 04 01 05 01 06 |................| -000000b0 01 05 03 06 03 02 01 02 03 ff 01 00 01 00 00 17 |................| -000000c0 00 00 00 12 00 00 00 2b 00 09 08 03 04 03 03 03 |.......+........| +00000080 01 00 00 79 00 0b 00 02 01 00 ff 01 00 01 00 00 |...y............| +00000090 17 00 00 00 12 00 00 00 05 00 05 01 00 00 00 00 |................| +000000a0 00 0a 00 04 00 02 00 1d 00 0d 00 1a 00 18 08 04 |................| +000000b0 04 03 08 07 08 05 08 06 04 01 05 01 06 01 05 03 |................| +000000c0 06 03 02 01 02 03 00 2b 00 09 08 03 04 03 03 03 |.......+........| 000000d0 02 03 01 00 33 00 26 00 24 00 1d 00 20 2f e5 7d |....3.&.$... /.}| 000000e0 a3 47 cd 62 43 15 28 da ac 5f bb 29 07 30 ff f6 |.G.bC.(.._.).0..| 000000f0 84 af c4 cf c2 ed 90 99 5f 58 cb 3b 74 |........_X.;t| >>> Flow 2 (server to client) -00000000 16 03 03 00 7a 02 00 00 76 03 03 94 fd 21 44 52 |....z...v....!DR| -00000010 54 21 7e 4a 1c 83 6a ce c7 21 df b2 f3 1e 4c 73 |T!~J..j..!....Ls| -00000020 d3 f0 8b cc 24 58 17 5c 9c 0c 28 20 00 00 00 00 |....$X.\..( ....| +00000000 16 03 03 00 7a 02 00 00 76 03 03 6c f6 24 8a 4a |....z...v..l.$.J| +00000010 82 87 8f c9 9a a3 5a d2 4a 24 d3 52 c8 5d 52 95 |......Z.J$.R.]R.| +00000020 0f 12 e8 8e e6 0c a6 5d 60 de 3c 20 00 00 00 00 |.......]`.< ....| 00000030 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |................| 00000040 00 00 00 00 00 00 00 00 00 00 00 00 13 03 00 00 |................| -00000050 2e 00 2b 00 02 03 04 00 33 00 24 00 1d 00 20 a0 |..+.....3.$... .| -00000060 72 12 62 31 e2 99 77 93 96 75 a3 64 33 87 33 ab |r.b1..w..u.d3.3.| -00000070 be 61 78 45 34 c4 e7 14 d0 c1 3b cc bb cc 78 14 |.axE4.....;...x.| -00000080 03 03 00 01 01 17 03 03 00 17 13 0e ae 6e fd 8b |.............n..| -00000090 f0 27 06 82 41 f5 68 63 1c 58 38 ad 3a 9e 59 4d |.'..A.hc.X8.:.YM| -000000a0 49 17 03 03 02 6d d8 a3 1c 91 84 93 3d 8d 27 4e |I....m......=.'N| -000000b0 70 a7 fd ac be cb 87 bc 20 19 ef c3 1a be ad b2 |p....... .......| -000000c0 b2 9d 4a e8 00 31 81 e0 43 09 4a b4 90 cc 1a d5 |..J..1..C.J.....| -000000d0 e9 47 56 64 cc e6 cc 3e fa a6 a9 8f 79 0c ea 47 |.GVd...>....y..G| -000000e0 55 5c 29 1a 3c ce 32 ea 45 30 66 01 07 30 22 60 |U\).<.2.E0f..0"`| -000000f0 a0 2b 63 40 29 18 a2 7f 81 bd af 6a dd a9 44 8f |.+c@)......j..D.| -00000100 d3 e8 58 8d 63 11 00 e2 31 9f 98 3c 15 a0 8b 9e |..X.c...1..<....| -00000110 61 12 df a8 87 b5 2e 81 41 ed 3b a6 12 77 05 69 |a.......A.;..w.i| -00000120 09 d1 9d cb 56 ee 86 24 cc ac 4c ff 17 b6 99 a2 |....V..$..L.....| -00000130 c9 22 8a 9c 07 b3 a6 72 aa 33 30 8e 42 18 1d af |.".....r.30.B...| -00000140 73 a5 28 99 12 05 bd 5e 34 cc 72 9a e4 51 2d 46 |s.(....^4.r..Q-F| -00000150 35 55 8d 7b f3 ce f5 50 43 70 f1 4a ea 92 eb bd |5U.{...PCp.J....| -00000160 18 72 b4 e9 90 fe e2 18 64 61 20 02 18 78 e8 75 |.r......da ..x.u| -00000170 33 00 ff cc 72 f2 89 0e fe 7d 7a 07 f8 64 95 6f |3...r....}z..d.o| -00000180 0b 3b 76 96 8f c1 d9 9f 6b 1a 10 28 d7 94 36 dc |.;v.....k..(..6.| -00000190 87 de f2 95 a3 f6 15 44 13 2e 0d 88 aa 86 10 38 |.......D.......8| -000001a0 ff 5f 58 a9 b8 e0 b9 4c fb a6 bb 1f f5 f6 25 4c |._X....L......%L| -000001b0 d5 ab bb 62 70 82 7f 47 5e 05 99 aa 1c d4 12 be |...bp..G^.......| -000001c0 77 2c 67 a3 5f 6c 9f 93 37 36 5f 96 34 8e 22 9d |w,g._l..76_.4.".| -000001d0 a4 5e 4f 8c ce 54 e7 ea 7c 40 f5 9b 20 84 2e 96 |.^O..T..|@.. ...| -000001e0 32 37 6b 65 cf e8 0d cb 3b 54 67 32 ed f6 49 b9 |27ke....;Tg2..I.| -000001f0 d0 4f 36 e6 8a 1c df 35 ee 8a be 3f 8f 5a c9 35 |.O6....5...?.Z.5| -00000200 3d 1b 7e 78 e4 0a d6 f4 6d 3e 48 dc 0d 4e 03 47 |=.~x....m>H..N.G| -00000210 81 db 60 a9 fb 17 8c 39 5e 7d 77 07 21 13 3b 53 |..`....9^}w.!.;S| -00000220 f2 50 bb c3 16 37 24 b8 ef 4a 45 ad 3e ce 05 6a |.P...7$..JE.>..j| -00000230 25 fa 27 05 c8 f9 c5 d5 c3 b0 82 a8 0c ca ef 66 |%.'............f| -00000240 58 a4 51 85 ee 94 2a 07 d9 a4 e5 1a b9 b8 9d a1 |X.Q...*.........| -00000250 42 ae 3c 01 dc c2 96 84 a6 bd e4 e2 e6 37 f4 16 |B.<..........7..| -00000260 51 62 9c ce 26 d5 fe ce 69 7a f5 dd f2 b9 7c d5 |Qb..&...iz....|.| -00000270 9f 9d f6 ca d2 a3 3b 9d 73 99 72 38 3b be 3e 93 |......;.s.r8;.>.| -00000280 d1 81 19 76 10 25 5b f7 3b b9 c3 21 b5 ef 1b 09 |...v.%[.;..!....| -00000290 a5 97 76 a2 b6 4e a7 9e 9c b5 0a 9a a4 99 ec 5c |..v..N.........\| -000002a0 02 fc 1a 83 b8 a2 f1 a5 16 0f 09 7a 21 2b 75 cd |...........z!+u.| -000002b0 23 b5 cc 29 d5 09 3a 5e 88 9b 6b 4f 41 30 2a 42 |#..)..:^..kOA0*B| -000002c0 03 98 56 2b 19 da e0 6f 5b f0 ee b9 a0 3d 98 12 |..V+...o[....=..| -000002d0 41 af 96 ee 1c ae 55 84 b4 c5 98 f7 50 a7 62 cd |A.....U.....P.b.| -000002e0 d7 99 4f be c8 65 fa 64 a3 2b bd b2 cc 9a 96 89 |..O..e.d.+......| -000002f0 bb 9a 78 8f 60 5f 37 12 96 28 21 3d b5 0f 9c 3e |..x.`_7..(!=...>| -00000300 ce 74 8b 9a 66 f0 ef af 38 1e 07 8e ca 6f 5a 35 |.t..f...8....oZ5| -00000310 c9 87 71 17 03 03 00 99 c1 76 e9 d2 52 3f 6d 1b |..q......v..R?m.| -00000320 ca eb 7d 24 2e c9 12 1b 44 f0 9c 06 95 26 d0 a3 |..}$....D....&..| -00000330 04 e1 f1 8f e4 c0 83 91 e2 cf da 6c a1 b3 87 05 |...........l....| -00000340 18 ae f1 7f 8d d3 43 9a f9 a8 9e 73 89 1a 61 2d |......C....s..a-| -00000350 4f 2b 33 0b fd c0 12 0e d2 32 06 52 26 99 1d ce |O+3......2.R&...| -00000360 49 11 a2 ec 23 ad 7f 22 1f 6e c6 12 21 f3 56 1c |I...#..".n..!.V.| -00000370 fe d1 32 dd 1f b5 36 5d e3 78 fb 9c 3e 74 00 aa |..2...6].x..>t..| -00000380 9d fd 92 f8 45 f9 1f e8 c3 4d 89 a8 91 d0 6c 2c |....E....M....l,| -00000390 4f 82 52 f4 43 b0 1b fa 16 75 a4 78 f9 24 d1 3a |O.R.C....u.x.$.:| -000003a0 1e 6b 97 6f 0e 3d bb 34 b3 0a 83 2f 56 88 b8 0e |.k.o.=.4.../V...| -000003b0 90 17 03 03 00 35 cd f0 e5 f9 3f 62 e7 67 25 5f |.....5....?b.g%_| -000003c0 4f 11 d9 d9 d0 e3 3b 9a a9 c0 27 1d d3 a4 06 1f |O.....;...'.....| -000003d0 8d 61 b4 38 aa fe fd f8 6c 10 57 b6 7d 9c 92 96 |.a.8....l.W.}...| -000003e0 c9 70 c2 67 a7 76 7d bb ab 0e 2d |.p.g.v}...-| +00000050 2e 00 2b 00 02 03 04 00 33 00 24 00 1d 00 20 1b |..+.....3.$... .| +00000060 e6 5f 3d 83 17 1c a6 90 45 f9 00 d9 96 be 4a 58 |._=.....E.....JX| +00000070 ec 82 73 4d e6 8c 74 e9 80 bc 3a 48 1b 93 71 14 |..sM..t...:H..q.| +00000080 03 03 00 01 01 17 03 03 00 17 71 c1 fc 68 5e 33 |..........q..h^3| +00000090 54 8f 43 df 20 55 ac 3b e8 a4 ee 68 ff 88 7c 71 |T.C. U.;...h..|q| +000000a0 92 17 03 03 02 6d 2a 26 5c 45 13 5f 75 46 56 41 |.....m*&\E._uFVA| +000000b0 25 92 a1 6f cd 7b 01 e2 cb 76 81 4d 33 f0 9d d1 |%..o.{...v.M3...| +000000c0 0d db b1 90 1a a7 d9 a8 4a 79 b1 12 59 62 0d c8 |........Jy..Yb..| +000000d0 cc 92 16 26 27 3e 07 b6 8a 15 77 a8 f6 c3 02 e7 |...&'>....w.....| +000000e0 44 0d b5 d3 11 57 6b 81 15 7d 23 b3 91 82 21 3c |D....Wk..}#...!<| +000000f0 0a 0c ef d5 5b 96 5d 85 aa 3a 1e a6 7b fc 3a eb |....[.]..:..{.:.| +00000100 24 af 13 fa 7f 90 0a 83 b5 0a 0b d0 f7 0c 2d 99 |$.............-.| +00000110 75 9b 84 0c d8 dc 60 a3 62 ed 64 55 02 73 a1 74 |u.....`.b.dU.s.t| +00000120 c1 53 c6 97 a5 23 7c 19 c8 f7 1c 97 e9 e9 f8 ee |.S...#|.........| +00000130 4c 47 7e c4 5e 0f 03 fc 60 9e ba 47 ea a9 9b ef |LG~.^...`..G....| +00000140 9a 04 62 e3 db bf 30 d7 5a 1f 20 c9 4c 37 ff 0e |..b...0.Z. .L7..| +00000150 46 d9 ce 85 c5 47 16 43 9a 89 0b 97 44 7a be 09 |F....G.C....Dz..| +00000160 5d 03 a0 b1 1f a6 ca 78 0d fb f4 1a 6d 3a ec 40 |]......x....m:.@| +00000170 1e 58 fc 67 5e bb 69 a1 ae 1d 6d bc b4 80 b9 71 |.X.g^.i...m....q| +00000180 1a 11 12 35 6a 2a 0c dc b3 b5 4b 0a 06 a7 8b be |...5j*....K.....| +00000190 38 4b 70 32 d4 51 e3 99 5b 60 28 e7 9a 60 90 6b |8Kp2.Q..[`(..`.k| +000001a0 1f 3a 9b 4b 66 fd e6 76 b5 8c 29 c3 36 ae a8 81 |.:.Kf..v..).6...| +000001b0 7e 7c bf e7 46 7d 13 27 0d 38 75 f0 15 e1 64 93 |~|..F}.'.8u...d.| +000001c0 1e 26 bc a8 5d 95 60 a2 e5 42 7f 2f 08 a1 e8 d3 |.&..].`..B./....| +000001d0 79 e8 5e 1f 02 45 cc 05 ca 63 7b f2 d9 ad af ab |y.^..E...c{.....| +000001e0 5a 94 f0 16 e7 60 14 c2 3d 05 3f 8d bb 33 c1 ca |Z....`..=.?..3..| +000001f0 79 28 04 c7 20 07 c8 13 89 7a 11 a2 54 6d b8 d5 |y(.. ....z..Tm..| +00000200 e1 b7 b1 43 48 9b a9 b9 e8 e0 40 7e 5a 36 24 70 |...CH.....@~Z6$p| +00000210 42 9a 51 70 6e 22 8a 2b 4b 9d b0 58 ff ae a9 45 |B.Qpn".+K..X...E| +00000220 34 b2 8b c1 35 d8 65 a5 7e 1f 32 fd 51 21 79 00 |4...5.e.~.2.Q!y.| +00000230 79 20 f7 5f 8a e2 e0 b3 4a 78 3b 03 a8 03 b6 ef |y ._....Jx;.....| +00000240 b2 25 37 e9 f3 ce 22 f0 2b fc f8 dd be 50 10 22 |.%7...".+....P."| +00000250 0b fa fb 04 ab a7 33 07 48 2f ca ec 0d fe 19 75 |......3.H/.....u| +00000260 cc c5 3d 17 36 06 5c 07 08 15 df 36 6c 4f f4 73 |..=.6.\....6lO.s| +00000270 50 49 ff 47 ba 47 6d e1 bb 2d 8f 77 d5 44 a9 87 |PI.G.Gm..-.w.D..| +00000280 2a 05 12 52 bf 2b e2 4b 64 94 9c 89 bb 2c 65 cb |*..R.+.Kd....,e.| +00000290 59 2a f0 1a 15 b2 e3 6e 5a cc 48 b4 44 6c 44 07 |Y*.....nZ.H.DlD.| +000002a0 80 01 93 25 86 83 f2 8f 01 e6 ef 5e 9a 36 4e 7f |...%.......^.6N.| +000002b0 bc 27 0e 4d f0 67 3a de 29 b5 e9 6a 7f 4b b4 77 |.'.M.g:.)..j.K.w| +000002c0 9b e2 3b 73 c9 51 e5 a6 df 97 a7 02 fa f2 f7 db |..;s.Q..........| +000002d0 df 71 fb d1 ad 64 37 46 3e de 57 de 1d fc 8f 6e |.q...d7F>.W....n| +000002e0 bb 6f 58 3f 87 00 d1 a3 52 a5 35 12 17 83 19 a4 |.oX?....R.5.....| +000002f0 2b be 31 bd dc a6 62 ca c3 09 39 e1 cd 0b 64 44 |+.1...b...9...dD| +00000300 1a ef 65 26 f3 e5 31 fb 61 56 df d3 11 d9 cc 65 |..e&..1.aV.....e| +00000310 7f 8f ab 17 03 03 00 99 94 ce 37 3c e1 7f b1 f5 |..........7<....| +00000320 7e 2b 04 17 45 3d 38 40 1b 82 0e f7 22 ef 28 ce |~+..E=8@....".(.| +00000330 1a 69 33 a6 ad c6 1f ab 08 12 31 b4 c7 41 ac c5 |.i3.......1..A..| +00000340 b3 e5 4b 84 56 d9 0c 53 58 4c 8f 40 3a 34 66 d0 |..K.V..SXL.@:4f.| +00000350 c7 8f 9b b3 26 25 1f 68 fc 97 ba a7 de ac cf c5 |....&%.h........| +00000360 8b b3 26 99 68 6e ca e9 65 47 07 bd 38 15 f3 0c |..&.hn..eG..8...| +00000370 d0 14 8e 6d 89 a2 ad cd ad ef 00 54 07 5a 4b ef |...m.......T.ZK.| +00000380 02 ce b9 a1 b0 d0 d6 f7 bb e0 91 51 72 87 99 50 |...........Qr..P| +00000390 f4 68 4c 0e d8 fa 00 d4 dd bd 1d 2e 7b f6 e2 61 |.hL.........{..a| +000003a0 d3 a8 46 9c f7 dc 2a 04 be 3c 42 85 4f ad 59 20 |..F...*..>> Flow 3 (client to server) -00000000 14 03 03 00 01 01 17 03 03 00 35 7d 7c fa 64 ea |..........5}|.d.| -00000010 ba 90 be e8 a7 0c 0c 48 10 fc 2d ac 5e dd 1c cf |.......H..-.^...| -00000020 e8 d3 d9 98 3b c2 2b 80 93 44 22 85 bf cb ec c6 |....;.+..D".....| -00000030 4a 13 6d 68 80 22 8b af aa f4 7c de 6b 28 fe ef |J.mh."....|.k(..| -00000040 17 03 03 00 17 4e bd e5 fe 5c 6b 9c bb 48 b8 23 |.....N...\k..H.#| -00000050 55 0f f7 21 25 cb 4c ae 74 b7 54 a2 17 03 03 00 |U..!%.L.t.T.....| -00000060 13 c8 35 e9 be f6 74 09 23 55 ec 78 05 83 89 38 |..5...t.#U.x...8| -00000070 ee 1c b3 3e |...>| +00000000 14 03 03 00 01 01 17 03 03 00 35 19 50 85 5d 08 |..........5.P.].| +00000010 c9 5e 25 05 37 ed cc 54 fe ba 86 3e 8a d4 e9 fd |.^%.7..T...>....| +00000020 66 54 6e a3 1f 8b 4f 95 cf 04 51 db 60 96 ae 78 |fTn...O...Q.`..x| +00000030 6b 7d 19 63 03 2a b6 e5 97 37 26 79 98 3f 85 52 |k}.c.*...7&y.?.R| +00000040 17 03 03 00 17 c9 80 91 3e 92 1e a7 9b 00 a3 01 |........>.......| +00000050 19 31 d0 6f 2e 69 0c 15 03 73 20 36 17 03 03 00 |.1.o.i...s 6....| +00000060 13 97 85 32 6f a2 9c 72 be ca 43 db 18 a7 98 b7 |...2o..r..C.....| +00000070 67 44 71 ce |gDq.| From 5bf846b35c1113b30f33078fc8a39f7ede4a5358 Mon Sep 17 00:00:00 2001 From: Roland Shoemaker Date: Wed, 15 May 2024 13:46:38 -0700 Subject: [PATCH 20/39] crypto/tls: populate Leaf in X509KeyPair Fixes #67065 Change-Id: I189e194de8aa94523eb64e1dd294a70cb81cbdf6 Reviewed-on: https://go-review.googlesource.com/c/go/+/585856 Auto-Submit: Roland Shoemaker LUCI-TryBot-Result: Go LUCI Reviewed-by: Filippo Valsorda Reviewed-by: Damien Neil --- tls.go | 29 ++++++++++++++++++++------- tls_test.go | 57 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 79 insertions(+), 7 deletions(-) diff --git a/tls.go b/tls.go index 8509b7d..b30f0b8 100644 --- a/tls.go +++ b/tls.go @@ -22,6 +22,7 @@ import ( "encoding/pem" "errors" "fmt" + "internal/godebug" "net" "os" "strings" @@ -222,11 +223,14 @@ func (d *Dialer) DialContext(ctx context.Context, network, addr string) (net.Con return c, nil } -// LoadX509KeyPair reads and parses a public/private key pair from a pair -// of files. The files must contain PEM encoded data. The certificate file -// may contain intermediate certificates following the leaf certificate to -// form a certificate chain. On successful return, Certificate.Leaf will -// be nil because the parsed form of the certificate is not retained. +// LoadX509KeyPair reads and parses a public/private key pair from a pair of +// files. The files must contain PEM encoded data. The certificate file may +// contain intermediate certificates following the leaf certificate to form a +// certificate chain. On successful return, Certificate.Leaf will be populated. +// +// Before Go 1.23 Certificate.Leaf was left nil, and the parsed certificate was +// discarded. This behavior can be re-enabled by setting "x509keypairleaf=0" +// in the GODEBUG environment variable. func LoadX509KeyPair(certFile, keyFile string) (Certificate, error) { certPEMBlock, err := os.ReadFile(certFile) if err != nil { @@ -239,9 +243,14 @@ func LoadX509KeyPair(certFile, keyFile string) (Certificate, error) { return X509KeyPair(certPEMBlock, keyPEMBlock) } +var x509keypairleaf = godebug.New("x509keypairleaf") + // X509KeyPair parses a public/private key pair from a pair of -// PEM encoded data. On successful return, Certificate.Leaf will be nil because -// the parsed form of the certificate is not retained. +// PEM encoded data. On successful return, Certificate.Leaf will be populated. +// +// Before Go 1.23 Certificate.Leaf was left nil, and the parsed certificate was +// discarded. This behavior can be re-enabled by setting "x509keypairleaf=0" +// in the GODEBUG environment variable. func X509KeyPair(certPEMBlock, keyPEMBlock []byte) (Certificate, error) { fail := func(err error) (Certificate, error) { return Certificate{}, err } @@ -296,6 +305,12 @@ func X509KeyPair(certPEMBlock, keyPEMBlock []byte) (Certificate, error) { return fail(err) } + if x509keypairleaf.Value() != "0" { + cert.Leaf = x509Cert + } else { + x509keypairleaf.IncNonDefault() + } + cert.PrivateKey, err = parsePrivateKey(keyDERBlock.Bytes) if err != nil { return fail(err) diff --git a/tls_test.go b/tls_test.go index 69b57de..158b459 100644 --- a/tls_test.go +++ b/tls_test.go @@ -8,13 +8,19 @@ import ( "bytes" "context" "crypto" + "crypto/ecdsa" + "crypto/elliptic" + "crypto/rand" "crypto/x509" + "crypto/x509/pkix" "encoding/json" + "encoding/pem" "errors" "fmt" "internal/testenv" "io" "math" + "math/big" "net" "os" "reflect" @@ -1945,3 +1951,54 @@ func TestHandshakeKyber(t *testing.T) { }) } } + +func TestX509KeyPairPopulateCertificate(t *testing.T) { + key, err := ecdsa.GenerateKey(elliptic.P256(), rand.Reader) + if err != nil { + t.Fatal(err) + } + keyDER, err := x509.MarshalPKCS8PrivateKey(key) + if err != nil { + t.Fatal(err) + } + keyPEM := pem.EncodeToMemory(&pem.Block{Type: "PRIVATE KEY", Bytes: keyDER}) + tmpl := &x509.Certificate{ + SerialNumber: big.NewInt(1), + Subject: pkix.Name{CommonName: "test"}, + } + certDER, err := x509.CreateCertificate(rand.Reader, tmpl, tmpl, key.Public(), key) + if err != nil { + t.Fatal(err) + } + certPEM := pem.EncodeToMemory(&pem.Block{Type: "CERTIFICATE", Bytes: certDER}) + + t.Run("x509keypairleaf=0", func(t *testing.T) { + t.Setenv("GODEBUG", "x509keypairleaf=0") + cert, err := X509KeyPair(certPEM, keyPEM) + if err != nil { + t.Fatal(err) + } + if cert.Leaf != nil { + t.Fatal("Leaf should not be populated") + } + }) + t.Run("x509keypairleaf=1", func(t *testing.T) { + t.Setenv("GODEBUG", "x509keypairleaf=1") + cert, err := X509KeyPair(certPEM, keyPEM) + if err != nil { + t.Fatal(err) + } + if cert.Leaf == nil { + t.Fatal("Leaf should be populated") + } + }) + t.Run("GODEBUG unset", func(t *testing.T) { + cert, err := X509KeyPair(certPEM, keyPEM) + if err != nil { + t.Fatal(err) + } + if cert.Leaf == nil { + t.Fatal("Leaf should be populated") + } + }) +} From c96cbeb1bf7371c867c99415567cc413ffc8f78e Mon Sep 17 00:00:00 2001 From: Roland Shoemaker Date: Wed, 15 May 2024 10:51:44 -0700 Subject: [PATCH 21/39] crypto/tls: allow 256KiB certificate messages During handshake, lift the message length limit, but only for certificate messages. Fixes #50773 Change-Id: Ida9d83f4219c4386ca71ed3ef72b22259665a187 Reviewed-on: https://go-review.googlesource.com/c/go/+/585402 LUCI-TryBot-Result: Go LUCI Reviewed-by: Filippo Valsorda Auto-Submit: Roland Shoemaker Reviewed-by: Damien Neil --- common.go | 13 +++++++------ conn.go | 16 +++++++++++++-- tls_test.go | 56 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 77 insertions(+), 8 deletions(-) diff --git a/common.go b/common.go index 945b3dd..601d5b8 100644 --- a/common.go +++ b/common.go @@ -59,12 +59,13 @@ func VersionName(version uint16) string { } const ( - maxPlaintext = 16384 // maximum plaintext payload length - maxCiphertext = 16384 + 2048 // maximum ciphertext payload length - maxCiphertextTLS13 = 16384 + 256 // maximum ciphertext length in TLS 1.3 - recordHeaderLen = 5 // record header length - maxHandshake = 65536 // maximum handshake we support (protocol max is 16 MB) - maxUselessRecords = 16 // maximum number of consecutive non-advancing records + maxPlaintext = 16384 // maximum plaintext payload length + maxCiphertext = 16384 + 2048 // maximum ciphertext payload length + maxCiphertextTLS13 = 16384 + 256 // maximum ciphertext length in TLS 1.3 + recordHeaderLen = 5 // record header length + maxHandshake = 65536 // maximum handshake we support (protocol max is 16 MB) + maxHandshakeCertificateMsg = 262144 // maximum certificate message size (256 KiB) + maxUselessRecords = 16 // maximum number of consecutive non-advancing records ) // TLS record types. diff --git a/conn.go b/conn.go index 3ffd26d..850b56f 100644 --- a/conn.go +++ b/conn.go @@ -1089,10 +1089,22 @@ func (c *Conn) readHandshake(transcript transcriptHash) (any, error) { return nil, err } data := c.hand.Bytes() + + maxHandshakeSize := maxHandshake + // hasVers indicates we're past the first message, forcing someone trying to + // make us just allocate a large buffer to at least do the initial part of + // the handshake first. + if c.haveVers && data[0] == typeCertificate { + // Since certificate messages are likely to be the only messages that + // can be larger than maxHandshake, we use a special limit for just + // those messages. + maxHandshakeSize = maxHandshakeCertificateMsg + } + n := int(data[1])<<16 | int(data[2])<<8 | int(data[3]) - if n > maxHandshake { + if n > maxHandshakeSize { c.sendAlertLocked(alertInternalError) - return nil, c.in.setErrorLocked(fmt.Errorf("tls: handshake message of length %d bytes exceeds maximum of %d bytes", n, maxHandshake)) + return nil, c.in.setErrorLocked(fmt.Errorf("tls: handshake message of length %d bytes exceeds maximum of %d bytes", n, maxHandshakeSize)) } if err := c.readHandshakeBytes(4 + n); err != nil { return nil, err diff --git a/tls_test.go b/tls_test.go index 158b459..320ef70 100644 --- a/tls_test.go +++ b/tls_test.go @@ -13,6 +13,7 @@ import ( "crypto/rand" "crypto/x509" "crypto/x509/pkix" + "encoding/asn1" "encoding/json" "encoding/pem" "errors" @@ -2002,3 +2003,58 @@ func TestX509KeyPairPopulateCertificate(t *testing.T) { } }) } + +func TestEarlyLargeCertMsg(t *testing.T) { + client, server := localPipe(t) + + go func() { + if _, err := client.Write([]byte{byte(recordTypeHandshake), 3, 4, 0, 4, typeCertificate, 1, 255, 255}); err != nil { + t.Log(err) + } + }() + + expectedErr := "tls: handshake message of length 131071 bytes exceeds maximum of 65536 bytes" + servConn := Server(server, testConfig) + err := servConn.Handshake() + if err == nil { + t.Fatal("unexpected success") + } + if err.Error() != expectedErr { + t.Fatalf("unexpected error: got %q, want %q", err, expectedErr) + } +} + +func TestLargeCertMsg(t *testing.T) { + k, err := ecdsa.GenerateKey(elliptic.P256(), rand.Reader) + if err != nil { + t.Fatal(err) + } + tmpl := &x509.Certificate{ + SerialNumber: big.NewInt(1), + Subject: pkix.Name{CommonName: "test"}, + ExtraExtensions: []pkix.Extension{ + { + Id: asn1.ObjectIdentifier{1, 2, 3}, + // Ballast to inflate the certificate beyond the + // regular handshake record size. + Value: make([]byte, 65536), + }, + }, + } + cert, err := x509.CreateCertificate(rand.Reader, tmpl, tmpl, k.Public(), k) + if err != nil { + t.Fatal(err) + } + + clientConfig, serverConfig := testConfig.Clone(), testConfig.Clone() + clientConfig.InsecureSkipVerify = true + serverConfig.Certificates = []Certificate{ + { + Certificate: [][]byte{cert}, + PrivateKey: k, + }, + } + if _, _, err := testHandshake(t, clientConfig, serverConfig); err != nil { + t.Fatalf("unexpected failure :%s", err) + } +} From 2621b1f66ca117b19f94de397f65ecc4cc4b440d Mon Sep 17 00:00:00 2001 From: Ian Lance Taylor Date: Wed, 22 May 2024 13:38:40 -0700 Subject: [PATCH 22/39] all: change from sort functions to slices functions where feasible Doing this because the slices functions are slightly faster and slightly easier to use. It also removes one dependency layer. This CL does not change packages that are used during bootstrap, as the bootstrap compiler does not have the required slices functions. It does not change the go/scanner package because the ErrorList Len, Swap, and Less methods are part of the Go 1 API. Change-Id: If52899be791c829198e11d2408727720b91ebe8a Reviewed-on: https://go-review.googlesource.com/c/go/+/587655 LUCI-TryBot-Result: Go LUCI Reviewed-by: Ian Lance Taylor Auto-Submit: Ian Lance Taylor Commit-Queue: Ian Lance Taylor Reviewed-by: Damien Neil --- tls_test.go | 51 ++++++++++++++++++++++++++++++--------------------- 1 file changed, 30 insertions(+), 21 deletions(-) diff --git a/tls_test.go b/tls_test.go index 320ef70..fda3cd3 100644 --- a/tls_test.go +++ b/tls_test.go @@ -26,7 +26,6 @@ import ( "os" "reflect" "slices" - "sort" "strings" "testing" "time" @@ -1548,61 +1547,71 @@ func TestCipherSuites(t *testing.T) { } // Check that the list is sorted according to the documented criteria. - isBetter := func(a, b int) bool { - aSuite, bSuite := cipherSuiteByID(prefOrder[a]), cipherSuiteByID(prefOrder[b]) - aName, bName := CipherSuiteName(prefOrder[a]), CipherSuiteName(prefOrder[b]) + isBetter := func(a, b uint16) int { + aSuite, bSuite := cipherSuiteByID(a), cipherSuiteByID(b) + aName, bName := CipherSuiteName(a), CipherSuiteName(b) // * < RC4 if !strings.Contains(aName, "RC4") && strings.Contains(bName, "RC4") { - return true + return -1 } else if strings.Contains(aName, "RC4") && !strings.Contains(bName, "RC4") { - return false + return +1 } // * < CBC_SHA256 if !strings.Contains(aName, "CBC_SHA256") && strings.Contains(bName, "CBC_SHA256") { - return true + return -1 } else if strings.Contains(aName, "CBC_SHA256") && !strings.Contains(bName, "CBC_SHA256") { - return false + return +1 } // * < 3DES if !strings.Contains(aName, "3DES") && strings.Contains(bName, "3DES") { - return true + return -1 } else if strings.Contains(aName, "3DES") && !strings.Contains(bName, "3DES") { - return false + return +1 } // ECDHE < * if aSuite.flags&suiteECDHE != 0 && bSuite.flags&suiteECDHE == 0 { - return true + return -1 } else if aSuite.flags&suiteECDHE == 0 && bSuite.flags&suiteECDHE != 0 { - return false + return +1 } // AEAD < CBC if aSuite.aead != nil && bSuite.aead == nil { - return true + return -1 } else if aSuite.aead == nil && bSuite.aead != nil { - return false + return +1 } // AES < ChaCha20 if strings.Contains(aName, "AES") && strings.Contains(bName, "CHACHA20") { - return i == 0 // true for cipherSuitesPreferenceOrder + // negative for cipherSuitesPreferenceOrder + if i == 0 { + return -1 + } else { + return +1 + } } else if strings.Contains(aName, "CHACHA20") && strings.Contains(bName, "AES") { - return i != 0 // true for cipherSuitesPreferenceOrderNoAES + // negative for cipherSuitesPreferenceOrderNoAES + if i != 0 { + return -1 + } else { + return +1 + } } // AES-128 < AES-256 if strings.Contains(aName, "AES_128") && strings.Contains(bName, "AES_256") { - return true + return -1 } else if strings.Contains(aName, "AES_256") && strings.Contains(bName, "AES_128") { - return false + return +1 } // ECDSA < RSA if aSuite.flags&suiteECSign != 0 && bSuite.flags&suiteECSign == 0 { - return true + return -1 } else if aSuite.flags&suiteECSign == 0 && bSuite.flags&suiteECSign != 0 { - return false + return +1 } t.Fatalf("two ciphersuites are equal by all criteria: %v and %v", aName, bName) panic("unreachable") } - if !sort.SliceIsSorted(prefOrder, isBetter) { + if !slices.IsSortedFunc(prefOrder, isBetter) { t.Error("preference order is not sorted according to the rules") } } From a58f39d686e945e271c66a1aa712c36e145d50d2 Mon Sep 17 00:00:00 2001 From: Russ Cox Date: Tue, 21 May 2024 23:50:52 -0400 Subject: [PATCH 23/39] =?UTF-8?q?all:=20document=20legacy=20//go:linkname?= =?UTF-8?q?=20for=20modules=20with=20=E2=89=A55,000=20dependents?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit For #67401. Change-Id: Ifea84af92017b405466937f50fb8f28e6893c8cb Reviewed-on: https://go-review.googlesource.com/c/go/+/587220 Reviewed-by: Cherry Mui LUCI-TryBot-Result: Go LUCI Auto-Submit: Russ Cox --- badlinkname.go | 3 --- cipher_suites.go | 10 ++++++++++ 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/badlinkname.go b/badlinkname.go index 97350e4..4eef04d 100644 --- a/badlinkname.go +++ b/badlinkname.go @@ -14,9 +14,6 @@ import _ "unsafe" //go:linkname aeadAESGCMTLS13 //go:linkname cipherSuiteTLS13ByID -//go:linkname cipherSuitesTLS13 -//go:linkname defaultCipherSuitesTLS13 -//go:linkname defaultCipherSuitesTLS13NoAES //go:linkname errShutdown // The compiler doesn't allow linknames on methods, for good reasons. diff --git a/cipher_suites.go b/cipher_suites.go index 83301f3..5f37bf6 100644 --- a/cipher_suites.go +++ b/cipher_suites.go @@ -18,6 +18,7 @@ import ( "hash" "internal/cpu" "runtime" + _ "unsafe" // for linkname "golang.org/x/crypto/chacha20poly1305" ) @@ -197,6 +198,15 @@ type cipherSuiteTLS13 struct { hash crypto.Hash } +// cipherSuitesTLS13 should be an internal detail, +// but widely used packages access it using linkname. +// Notable members of the hall of shame include: +// - github.com/quic-go/quic-go +// +// Do not remove or change the type signature. +// See go.dev/issue/67401. +// +//go:linkname cipherSuitesTLS13 var cipherSuitesTLS13 = []*cipherSuiteTLS13{ // TODO: replace with a map. {TLS_AES_128_GCM_SHA256, 16, aeadAESGCMTLS13, crypto.SHA256}, {TLS_CHACHA20_POLY1305_SHA256, 32, aeadChaCha20Poly1305, crypto.SHA256}, From a2d887fa30ddc1c3854fbabeebd7c3e0c17516f4 Mon Sep 17 00:00:00 2001 From: Russ Cox Date: Wed, 22 May 2024 15:46:02 -0400 Subject: [PATCH 24/39] =?UTF-8?q?all:=20document=20legacy=20//go:linkname?= =?UTF-8?q?=20for=20modules=20with=20=E2=89=A5200=20dependents?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Ignored these linknames which have not worked for a while: github.com/xtls/xray-core: context.newCancelCtx removed in CL 463999 (Feb 2023) github.com/u-root/u-root: funcPC removed in CL 513837 (Jul 2023) tinygo.org/x/drivers: net.useNetdev never existed For #67401. Change-Id: I9293f4ef197bb5552b431de8939fa94988a060ce Reviewed-on: https://go-review.googlesource.com/c/go/+/587576 Auto-Submit: Russ Cox Reviewed-by: Cherry Mui LUCI-TryBot-Result: Go LUCI --- badlinkname.go | 1 - cipher_suites.go | 9 +++++++++ common.go | 10 ++++++++++ 3 files changed, 19 insertions(+), 1 deletion(-) diff --git a/badlinkname.go b/badlinkname.go index 4eef04d..841030a 100644 --- a/badlinkname.go +++ b/badlinkname.go @@ -12,7 +12,6 @@ import _ "unsafe" // This may change in the future. Please do not depend on them // in new code. -//go:linkname aeadAESGCMTLS13 //go:linkname cipherSuiteTLS13ByID //go:linkname errShutdown diff --git a/cipher_suites.go b/cipher_suites.go index 5f37bf6..b2f330b 100644 --- a/cipher_suites.go +++ b/cipher_suites.go @@ -533,6 +533,15 @@ func aeadAESGCM(key, noncePrefix []byte) aead { return ret } +// aeadAESGCMTLS13 should be an internal detail, +// but widely used packages access it using linkname. +// Notable members of the hall of shame include: +// - github.com/xtls/xray-core +// +// Do not remove or change the type signature. +// See go.dev/issue/67401. +// +//go:linkname aeadAESGCMTLS13 func aeadAESGCMTLS13(key, nonceMask []byte) aead { if len(nonceMask) != aeadNonceLength { panic("tls: internal error: wrong nonce length") diff --git a/common.go b/common.go index 601d5b8..498d345 100644 --- a/common.go +++ b/common.go @@ -25,6 +25,7 @@ import ( "strings" "sync" "time" + _ "unsafe" // for linkname ) const ( @@ -1129,6 +1130,15 @@ func (c *Config) mutualVersion(isClient bool, peerVersions []uint16) (uint16, bo return 0, false } +// errNoCertificates should be an internal detail, +// but widely used packages access it using linkname. +// Notable members of the hall of shame include: +// - github.com/xtls/xray-core +// +// Do not remove or change the type signature. +// See go.dev/issue/67401. +// +//go:linkname errNoCertificates var errNoCertificates = errors.New("tls: no certificates configured") // getCertificate returns the best certificate for the given ClientHelloInfo, From ce1cbd081a93548dce5a1973091ca72b5fc57ebd Mon Sep 17 00:00:00 2001 From: Roland Shoemaker Date: Thu, 11 Apr 2024 08:50:36 -0700 Subject: [PATCH 25/39] crypto/tls: add ech client support This CL adds a (very opinionated) client-side ECH implementation. In particular, if a user configures a ECHConfigList, by setting the Config.EncryptedClientHelloConfigList, but we determine that none of the configs are appropriate, we will not fallback to plaintext SNI, and will instead return an error. It is then up to the user to decide if they wish to fallback to plaintext themselves (by removing the config list). Additionally if Config.EncryptedClientHelloConfigList is provided, we will not offer TLS support lower than 1.3, since negotiating any other version, while offering ECH, is a hard error anyway. Similarly, if a user wishes to fallback to plaintext SNI by using 1.2, they may do so by removing the config list. With regard to PSK GREASE, we match the boringssl behavior, which does not include PSK identities/binders in the outer hello when doing ECH. If the server rejects ECH, we will return a ECHRejectionError error, which, if provided by the server, will contain a ECHConfigList in the RetryConfigList field containing configs that should be used if the user wishes to retry. It is up to the user to replace their existing Config.EncryptedClientHelloConfigList with the retry config list. Fixes #63369 Cq-Include-Trybots: luci.golang.try:gotip-linux-amd64-longtest Change-Id: I9bc373c044064221a647a388ac61624efd6bbdbf Reviewed-on: https://go-review.googlesource.com/c/go/+/578575 Reviewed-by: Ian Lance Taylor Reviewed-by: Filippo Valsorda Reviewed-by: Than McIntosh Reviewed-by: Dmitri Shuralyov Auto-Submit: Roland Shoemaker LUCI-TryBot-Result: Go LUCI --- alert.go | 2 + bogo_config.json | 61 +++++++- bogo_shim_test.go | 243 +++++++++++++++++-------------- common.go | 107 ++++++++++---- conn.go | 2 + ech.go | 283 +++++++++++++++++++++++++++++++++++++ ech_test.go | 48 +++++++ handshake_client.go | 166 ++++++++++++++++++---- handshake_client_test.go | 125 ++++++++++++++++ handshake_client_tls13.go | 148 ++++++++++++++++--- handshake_messages.go | 252 +++++++++++++++++++++++++-------- handshake_messages_test.go | 6 + handshake_test.go | 11 +- tls_test.go | 11 +- 14 files changed, 1214 insertions(+), 251 deletions(-) create mode 100644 ech.go create mode 100644 ech_test.go diff --git a/alert.go b/alert.go index 33022cd..2301c06 100644 --- a/alert.go +++ b/alert.go @@ -58,6 +58,7 @@ const ( alertUnknownPSKIdentity alert = 115 alertCertificateRequired alert = 116 alertNoApplicationProtocol alert = 120 + alertECHRequired alert = 121 ) var alertText = map[alert]string{ @@ -94,6 +95,7 @@ var alertText = map[alert]string{ alertUnknownPSKIdentity: "unknown PSK identity", alertCertificateRequired: "certificate required", alertNoApplicationProtocol: "no application protocol", + alertECHRequired: "encrypted client hello required", } func (e alert) String() string { diff --git a/bogo_config.json b/bogo_config.json index 21ee32c..8e4cec2 100644 --- a/bogo_config.json +++ b/bogo_config.json @@ -1,5 +1,45 @@ { "DisabledTests": { + "*-Async": "We don't support boringssl concept of async", + + "TLS-ECH-Client-Reject-NoClientCertificate-TLS12": "We won't attempt to negotiate 1.2 if ECH is enabled", + "TLS-ECH-Client-Reject-TLS12": "We won't attempt to negotiate 1.2 if ECH is enabled", + "TLS-ECH-Client-TLS12-RejectRetryConfigs": "We won't attempt to negotiate 1.2 if ECH is enabled", + "TLS-ECH-Client-Rejected-OverrideName-TLS12": "We won't attempt to negotiate 1.2 if ECH is enabled", + "TLS-ECH-Client-Reject-TLS12-NoFalseStart": "We won't attempt to negotiate 1.2 if ECH is enabled", + "TLS-ECH-Client-TLS12SessionTicket": "We won't attempt to negotiate 1.2 if ECH is enabled", + "TLS-ECH-Client-TLS12SessionID": "We won't attempt to negotiate 1.2 if ECH is enabled", + + "TLS-ECH-Client-Reject-ResumeInnerSession-TLS12": "We won't attempt to negotiate 1.2 if ECH is enabled (we could possibly test this if we had the ability to indicate not to send ECH on resumption?)", + + "TLS-ECH-Client-Reject-EarlyDataRejected": "We don't support switiching out ECH configs with this level of granularity", + + "TLS-ECH-Client-NoNPN": "We don't support NPN", + + "TLS-ECH-Client-ChannelID": "We don't support sending channel ID", + "TLS-ECH-Client-Reject-NoChannelID-TLS13": "We don't support sending channel ID", + "TLS-ECH-Client-Reject-NoChannelID-TLS12": "We don't support sending channel ID", + + "TLS-ECH-Client-GREASE-IgnoreHRRExtension": "We don't support ECH GREASE because we don't fallback to plaintext", + "TLS-ECH-Client-NoSupportedConfigs-GREASE": "We don't support ECH GREASE because we don't fallback to plaintext", + "TLS-ECH-Client-GREASEExtensions": "We don't support ECH GREASE because we don't fallback to plaintext", + "TLS-ECH-Client-GREASE-NoOverrideName": "We don't support ECH GREASE because we don't fallback to plaintext", + + "TLS-ECH-Client-UnsolicitedInnerServerNameAck": "We don't allow sending empty SNI without skipping certificate verification, TODO: could add special flag to bogo to indicate 'empty sni'", + + "TLS-ECH-Client-NoSupportedConfigs": "We don't support fallback to cleartext when there are no valid ECH configs", + "TLS-ECH-Client-SkipInvalidPublicName": "We don't support fallback to cleartext when there are no valid ECH configs", + + "TLS-ECH-Client-Reject-RandomHRRExtension": "TODO: bogo test cases have mismatching public certificates and public names in ECH configs. Can be removed once bogo fixed", + "TLS-ECH-Client-Reject-UnsupportedRetryConfigs": "TODO: bogo test cases have mismatching public certificates and public names in ECH configs. Can be removed once bogo fixed", + "TLS-ECH-Client-Reject-NoRetryConfigs": "TODO: bogo test cases have mismatching public certificates and public names in ECH configs. Can be removed once bogo fixed", + "TLS-ECH-Client-Reject": "TODO: bogo test cases have mismatching public certificates and public names in ECH configs. Can be removed once bogo fixed", + "TLS-ECH-Client-Reject-HelloRetryRequest": "TODO: bogo test cases have mismatching public certificates and public names in ECH configs. Can be removed once bogo fixed", + "TLS-ECH-Client-Reject-NoClientCertificate-TLS13": "TODO: bogo test cases have mismatching public certificates and public names in ECH configs. Can be removed once bogo fixed", + "TLS-ECH-Client-Reject-OverrideName-TLS13": "TODO: bogo test cases have mismatching public certificates and public names in ECH configs. Can be removed once bogo fixed", + + "*ECH-Server*": "no ECH server support", + "SendV2ClientHello*": "We don't support SSLv2", "*QUIC*": "No QUIC support", "Compliance-fips*": "No FIPS", "*DTLS*": "No DTLS", @@ -16,8 +56,6 @@ "GarbageCertificate*": "TODO ask davidben, alertDecode vs alertBadCertificate", "SendBogusAlertType": "sending wrong alert type", "EchoTLS13CompatibilitySessionID": "TODO reject compat session ID", - "*ECH-Server*": "no ECH server support", - "TLS-ECH-Client-UnsolictedHRRExtension": "TODO", "*Client-P-224*": "no P-224 support", "*Server-P-224*": "no P-224 support", "CurveID-Resume*": "unexposed curveID is not stored in the ticket yet", @@ -180,6 +218,23 @@ "DuplicateCertCompressionExt-TLS13": "TODO: first pass, this should be fixed", "Client-RejectJDK11DowngradeRandom": "TODO: first pass, this should be fixed", "CheckClientCertificateTypes": "TODO: first pass, this should be fixed", - "CheckECDSACurve-TLS12": "TODO: first pass, this should be fixed" + "CheckECDSACurve-TLS12": "TODO: first pass, this should be fixed", + "ALPNClient-RejectUnknown-TLS-TLS1": "TODO: first pass, this should be fixed", + "ALPNClient-RejectUnknown-TLS-TLS11": "TODO: first pass, this should be fixed", + "ALPNClient-RejectUnknown-TLS-TLS12": "TODO: first pass, this should be fixed", + "ALPNClient-RejectUnknown-TLS-TLS13": "TODO: first pass, this should be fixed", + "ClientHelloPadding": "TODO: first pass, this should be fixed", + "TLS13-ExpectTicketEarlyDataSupport": "TODO: first pass, this should be fixed", + "TLS13-EarlyData-TooMuchData-Client-TLS-Sync": "TODO: first pass, this should be fixed", + "TLS13-EarlyData-TooMuchData-Client-TLS-Sync-SplitHandshakeRecords": "TODO: first pass, this should be fixed", + "TLS13-EarlyData-TooMuchData-Client-TLS-Sync-PackHandshake": "TODO: first pass, this should be fixed", + "WrongMessageType-TLS13-EndOfEarlyData-TLS": "TODO: first pass, this should be fixed", + "TrailingMessageData-TLS13-EndOfEarlyData-TLS": "TODO: first pass, this should be fixed", + "SendHelloRetryRequest-2-TLS13": "TODO: first pass, this should be fixed", + "EarlyData-SkipEndOfEarlyData-TLS13": "TODO: first pass, this should be fixed", + "EarlyData-Server-BadFinished-TLS13": "TODO: first pass, this should be fixed", + "EarlyData-UnexpectedHandshake-Server-TLS13": "TODO: first pass, this should be fixed", + "EarlyData-CipherMismatch-Client-TLS13": "TODO: first pass, this should be fixed", + "Resume-Server-UnofferedCipher-TLS13": "TODO: first pass, this should be fixed" } } diff --git a/bogo_shim_test.go b/bogo_shim_test.go index 4a95dc1..ad5195c 100644 --- a/bogo_shim_test.go +++ b/bogo_shim_test.go @@ -1,7 +1,9 @@ package tls import ( + "bytes" "crypto/x509" + "encoding/base64" "encoding/json" "encoding/pem" "flag" @@ -48,93 +50,35 @@ var ( shimID = flag.Uint64("shim-id", 0, "") _ = flag.Bool("ipv6", false, "") - // Unimplemented flags - // -advertise-alpn - // -advertise-npn - // -allow-hint-mismatch - // -async - // -check-close-notify - // -cipher - // -curves - // -delegated-credential - // -dtls - // -ech-config-list - // -ech-server-config - // -enable-channel-id - // -enable-early-data - // -enable-ech-grease - // -enable-grease - // -enable-ocsp-stapling - // -enable-signed-cert-timestamps - // -expect-advertised-alpn - // -expect-certificate-types - // -expect-channel-id - // -expect-cipher-aes - // -expect-client-ca-list - // -expect-curve-id - // -expect-early-data-reason - // -expect-extended-master-secret - // -expect-hrr - // -expect-key-usage-invalid - // -expect-msg-callback - // -expect-no-session - // -expect-peer-cert-file - // -expect-peer-signature-algorithm - // -expect-peer-verify-pref - // -expect-secure-renegotiation - // -expect-server-name - // -expect-ticket-supports-early-data - // -export-keying-material - // -export-traffic-secrets - // -fail-cert-callback - // -fail-early-callback - // -fallback-scsv - // -false-start - // -forbid-renegotiation-after-handshake - // -handshake-twice - // -host-name - // -ignore-rsa-key-usage - // -implicit-handshake - // -install-cert-compression-algs - // -install-ddos-callback - // -install-one-cert-compression-alg - // -jdk11-workaround - // -key-update - // -max-cert-list - // -max-send-fragment - // -no-ticket - // -no-tls1 - // -no-tls11 - // -no-tls12 - // -ocsp-response - // -on-resume-expect-accept-early-data - // -on-resume-expect-reject-early-data - // -on-shim-cipher - // -on-shim-curves - // -peek-then-read - // -psk - // -read-with-unfinished-write - // -reject-alpn - // -renegotiate-explicit - // -renegotiate-freely - // -renegotiate-ignore - // -renegotiate-once - // -select-alpn - // -select-next-proto - // -send-alert - // -send-channel-id - // -server-preference - // -shim-shuts-down - // -signed-cert-timestamps - // -signing-prefs - // -srtp-profiles - // -tls-unique - // -use-client-ca-list - // -use-ocsp-callback - // -use-old-client-cert-callback - // -verify-fail - // -verify-peer - // -verify-prefs + echConfigListB64 = flag.String("ech-config-list", "", "") + expectECHAccepted = flag.Bool("expect-ech-accept", false, "") + expectHRR = flag.Bool("expect-hrr", false, "") + expectedECHRetryConfigs = flag.String("expect-ech-retry-configs", "", "") + expectNoECHRetryConfigs = flag.Bool("expect-no-ech-retry-configs", false, "") + onInitialExpectECHAccepted = flag.Bool("on-initial-expect-ech-accept", false, "") + _ = flag.Bool("expect-no-ech-name-override", false, "") + _ = flag.String("expect-ech-name-override", "", "") + _ = flag.Bool("reverify-on-resume", false, "") + onResumeECHConfigListB64 = flag.String("on-resume-ech-config-list", "", "") + _ = flag.Bool("on-resume-expect-reject-early-data", false, "") + onResumeExpectECHAccepted = flag.Bool("on-resume-expect-ech-accept", false, "") + _ = flag.Bool("on-resume-expect-no-ech-name-override", false, "") + expectedServerName = flag.String("expect-server-name", "", "") + + expectSessionMiss = flag.Bool("expect-session-miss", false, "") + + _ = flag.Bool("enable-early-data", false, "") + _ = flag.Bool("on-resume-expect-accept-early-data", false, "") + _ = flag.Bool("expect-ticket-supports-early-data", false, "") + onResumeShimWritesFirst = flag.Bool("on-resume-shim-writes-first", false, "") + + advertiseALPN = flag.String("advertise-alpn", "", "") + expectALPN = flag.String("expect-alpn", "", "") + + hostName = flag.String("host-name", "", "") + + verifyPeer = flag.Bool("verify-peer", false, "") + _ = flag.Bool("use-custom-verify-callback", false, "") ) type stringSlice []string @@ -168,11 +112,23 @@ func bogoShim() { ClientSessionCache: NewLRUClientSessionCache(0), } - if *noTLS13 && cfg.MaxVersion == VersionTLS13 { cfg.MaxVersion = VersionTLS12 } + if *advertiseALPN != "" { + alpns := *advertiseALPN + for len(alpns) > 0 { + alpnLen := int(alpns[0]) + cfg.NextProtos = append(cfg.NextProtos, alpns[1:1+alpnLen]) + alpns = alpns[alpnLen+1:] + } + } + + if *hostName != "" { + cfg.ServerName = *hostName + } + if *keyfile != "" || *certfile != "" { pair, err := LoadX509KeyPair(*certfile, *keyfile) if err != nil { @@ -198,6 +154,18 @@ func bogoShim() { if *requireAnyClientCertificate { cfg.ClientAuth = RequireAnyClientCert } + if *verifyPeer { + cfg.ClientAuth = VerifyClientCertIfGiven + } + + if *echConfigListB64 != "" { + echConfigList, err := base64.StdEncoding.DecodeString(*echConfigListB64) + if err != nil { + log.Fatalf("parse ech-config-list err: %s", err) + } + cfg.EncryptedClientHelloConfigList = echConfigList + cfg.MinVersion = VersionTLS13 + } if len(*curves) != 0 { for _, curveStr := range *curves { @@ -210,6 +178,14 @@ func bogoShim() { } for i := 0; i < *resumeCount+1; i++ { + if i > 0 && (*onResumeECHConfigListB64 != "") { + echConfigList, err := base64.StdEncoding.DecodeString(*onResumeECHConfigListB64) + if err != nil { + log.Fatalf("parse ech-config-list err: %s", err) + } + cfg.EncryptedClientHelloConfigList = echConfigList + } + conn, err := net.Dial("tcp", net.JoinHostPort("localhost", *port)) if err != nil { log.Fatalf("dial err: %s", err) @@ -230,7 +206,7 @@ func bogoShim() { tlsConn = Client(conn, cfg) } - if *shimWritesFirst { + if i == 0 && *shimWritesFirst { if _, err := tlsConn.Write([]byte("hello")); err != nil { log.Fatalf("write err: %s", err) } @@ -238,19 +214,65 @@ func bogoShim() { for { buf := make([]byte, 500) - n, err := tlsConn.Read(buf) - if err == io.EOF { - break - } + var n int + n, err = tlsConn.Read(buf) if err != nil { - log.Fatalf("read err: %s", err) + break } buf = buf[:n] for i := range buf { buf[i] ^= 0xff } - if _, err := tlsConn.Write(buf); err != nil { - log.Fatalf("write err: %s", err) + if _, err = tlsConn.Write(buf); err != nil { + break + } + } + if err != nil && err != io.EOF { + retryErr, ok := err.(*ECHRejectionError) + if !ok { + log.Fatalf("unexpected error type returned: %v", err) + } + if *expectNoECHRetryConfigs && len(retryErr.RetryConfigList) > 0 { + log.Fatalf("expected no ECH retry configs, got some") + } + if *expectedECHRetryConfigs != "" { + expectedRetryConfigs, err := base64.StdEncoding.DecodeString(*expectedECHRetryConfigs) + if err != nil { + log.Fatalf("failed to decode expected retry configs: %s", err) + } + if !bytes.Equal(retryErr.RetryConfigList, expectedRetryConfigs) { + log.Fatalf("unexpected retry list returned: got %x, want %x", retryErr.RetryConfigList, expectedRetryConfigs) + } + } + log.Fatalf("conn error: %s", err) + } + + cs := tlsConn.ConnectionState() + if cs.HandshakeComplete { + if *expectALPN != "" && cs.NegotiatedProtocol != *expectALPN { + log.Fatalf("unexpected protocol negotiated: want %q, got %q", *expectALPN, cs.NegotiatedProtocol) + } + + if *expectECHAccepted && !cs.ECHAccepted { + log.Fatal("expected ECH to be accepted, but connection state shows it was not") + } else if i == 0 && *onInitialExpectECHAccepted && !cs.ECHAccepted { + log.Fatal("expected ECH to be accepted, but connection state shows it was not") + } else if i > 0 && *onResumeExpectECHAccepted && !cs.ECHAccepted { + log.Fatal("expected ECH to be accepted on resumption, but connection state shows it was not") + } else if i == 0 && !*expectECHAccepted && cs.ECHAccepted { + log.Fatal("did not expect ECH, but it was accepted") + } + + if *expectHRR && !cs.testingOnlyDidHRR { + log.Fatal("expected HRR but did not do it") + } + + if *expectSessionMiss && cs.DidResume { + log.Fatal("unexpected session resumption") + } + + if *expectedServerName != "" && cs.ServerName != *expectedServerName { + log.Fatalf("unexpected server name: got %q, want %q", cs.ServerName, *expectedServerName) } } @@ -275,21 +297,26 @@ func TestBogoSuite(t *testing.T) { if testing.Short() { t.Skip("skipping in short mode") } - if testenv.Builder() != "" && runtime.GOOS == "windows" { t.Skip("#66913: windows network connections are flakey on builders") } - const boringsslModVer = "v0.0.0-20240517213134-ba62c812f01f" - output, err := exec.Command("go", "mod", "download", "-json", "github.com/google/boringssl@"+boringsslModVer).CombinedOutput() - if err != nil { - t.Fatalf("failed to download boringssl: %s", err) - } - var j struct { - Dir string - } - if err := json.Unmarshal(output, &j); err != nil { - t.Fatalf("failed to parse 'go mod download' output: %s", err) + var bogoDir string + if *bogoLocalDir != "" { + bogoDir = *bogoLocalDir + } else { + const boringsslModVer = "v0.0.0-20240517213134-ba62c812f01f" + output, err := exec.Command("go", "mod", "download", "-json", "github.com/google/boringssl@"+boringsslModVer).CombinedOutput() + if err != nil { + t.Fatalf("failed to download boringssl: %s", err) + } + var j struct { + Dir string + } + if err := json.Unmarshal(output, &j); err != nil { + t.Fatalf("failed to parse 'go mod download' output: %s", err) + } + bogoDir = j.Dir } cwd, err := os.Getwd() @@ -319,7 +346,7 @@ func TestBogoSuite(t *testing.T) { cmd := exec.Command(goCmd, args...) out := &strings.Builder{} cmd.Stdout, cmd.Stderr = io.MultiWriter(os.Stdout, out), os.Stderr - cmd.Dir = filepath.Join(j.Dir, "ssl/test/runner") + cmd.Dir = filepath.Join(bogoDir, "ssl/test/runner") err = cmd.Run() if err != nil { t.Fatalf("bogo failed: %s", err) diff --git a/common.go b/common.go index 498d345..5fd92d3 100644 --- a/common.go +++ b/common.go @@ -125,6 +125,8 @@ const ( extensionKeyShare uint16 = 51 extensionQUICTransportParameters uint16 = 57 extensionRenegotiationInfo uint16 = 0xff01 + extensionECHOuterExtensions uint16 = 0xfd00 + extensionEncryptedClientHello uint16 = 0xfe0d ) // TLS signaling cipher suite values @@ -287,6 +289,11 @@ type ConnectionState struct { // resumed connections that don't support Extended Master Secret (RFC 7627). TLSUnique []byte + // ECHAccepted indicates if Encrypted Client Hello was offered by the client + // and accepted by the server. Currently, ECH is supported only on the + // client side. + ECHAccepted bool + // ekm is a closure exposed via ExportKeyingMaterial. ekm func(label string, context []byte, length int) ([]byte, error) @@ -777,6 +784,41 @@ type Config struct { // used for debugging. KeyLogWriter io.Writer + // EncryptedClientHelloConfigList is a serialized ECHConfigList. If + // provided, clients will attempt to connect to servers using Encrypted + // Client Hello (ECH) using one of the provided ECHConfigs. Servers + // currently ignore this field. + // + // If the list contains no valid ECH configs, the handshake will fail + // and return an error. + // + // If EncryptedClientHelloConfigList is set, MinVersion, if set, must + // be VersionTLS13. + // + // When EncryptedClientHelloConfigList is set, the handshake will only + // succeed if ECH is sucessfully negotiated. If the server rejects ECH, + // an ECHRejectionError error will be returned, which may contain a new + // ECHConfigList that the server suggests using. + // + // How this field is parsed may change in future Go versions, if the + // encoding described in the final Encrypted Client Hello RFC changes. + EncryptedClientHelloConfigList []byte + + // EncryptedClientHelloRejectionVerify, if not nil, is called when ECH is + // rejected, in order to verify the ECH provider certificate in the outer + // Client Hello. If it returns a non-nil error, the handshake is aborted and + // that error results. + // + // Unlike VerifyPeerCertificate and VerifyConnection, normal certificate + // verification will not be performed before calling + // EncryptedClientHelloRejectionVerify. + // + // If EncryptedClientHelloRejectionVerify is nil and ECH is rejected, the + // roots in RootCAs will be used to verify the ECH providers public + // certificate. VerifyPeerCertificate and VerifyConnection are not called + // when ECH is rejected, even if set, and InsecureSkipVerify is ignored. + EncryptedClientHelloRejectionVerify func(ConnectionState) error + // mutex protects sessionTicketKeys and autoSessionTicketKeys. mutex sync.RWMutex // sessionTicketKeys contains zero or more ticket keys. If set, it means @@ -836,36 +878,38 @@ func (c *Config) Clone() *Config { c.mutex.RLock() defer c.mutex.RUnlock() return &Config{ - Rand: c.Rand, - Time: c.Time, - Certificates: c.Certificates, - NameToCertificate: c.NameToCertificate, - GetCertificate: c.GetCertificate, - GetClientCertificate: c.GetClientCertificate, - GetConfigForClient: c.GetConfigForClient, - VerifyPeerCertificate: c.VerifyPeerCertificate, - VerifyConnection: c.VerifyConnection, - RootCAs: c.RootCAs, - NextProtos: c.NextProtos, - ServerName: c.ServerName, - ClientAuth: c.ClientAuth, - ClientCAs: c.ClientCAs, - InsecureSkipVerify: c.InsecureSkipVerify, - CipherSuites: c.CipherSuites, - PreferServerCipherSuites: c.PreferServerCipherSuites, - SessionTicketsDisabled: c.SessionTicketsDisabled, - SessionTicketKey: c.SessionTicketKey, - ClientSessionCache: c.ClientSessionCache, - UnwrapSession: c.UnwrapSession, - WrapSession: c.WrapSession, - MinVersion: c.MinVersion, - MaxVersion: c.MaxVersion, - CurvePreferences: c.CurvePreferences, - DynamicRecordSizingDisabled: c.DynamicRecordSizingDisabled, - Renegotiation: c.Renegotiation, - KeyLogWriter: c.KeyLogWriter, - sessionTicketKeys: c.sessionTicketKeys, - autoSessionTicketKeys: c.autoSessionTicketKeys, + Rand: c.Rand, + Time: c.Time, + Certificates: c.Certificates, + NameToCertificate: c.NameToCertificate, + GetCertificate: c.GetCertificate, + GetClientCertificate: c.GetClientCertificate, + GetConfigForClient: c.GetConfigForClient, + VerifyPeerCertificate: c.VerifyPeerCertificate, + VerifyConnection: c.VerifyConnection, + RootCAs: c.RootCAs, + NextProtos: c.NextProtos, + ServerName: c.ServerName, + ClientAuth: c.ClientAuth, + ClientCAs: c.ClientCAs, + InsecureSkipVerify: c.InsecureSkipVerify, + CipherSuites: c.CipherSuites, + PreferServerCipherSuites: c.PreferServerCipherSuites, + SessionTicketsDisabled: c.SessionTicketsDisabled, + SessionTicketKey: c.SessionTicketKey, + ClientSessionCache: c.ClientSessionCache, + UnwrapSession: c.UnwrapSession, + WrapSession: c.WrapSession, + MinVersion: c.MinVersion, + MaxVersion: c.MaxVersion, + CurvePreferences: c.CurvePreferences, + DynamicRecordSizingDisabled: c.DynamicRecordSizingDisabled, + Renegotiation: c.Renegotiation, + KeyLogWriter: c.KeyLogWriter, + EncryptedClientHelloConfigList: c.EncryptedClientHelloConfigList, + EncryptedClientHelloRejectionVerify: c.EncryptedClientHelloRejectionVerify, + sessionTicketKeys: c.sessionTicketKeys, + autoSessionTicketKeys: c.autoSessionTicketKeys, } } @@ -1052,6 +1096,9 @@ func (c *Config) supportedVersions(isClient bool) []uint16 { continue } } + if isClient && c.EncryptedClientHelloConfigList != nil && v < VersionTLS13 { + continue + } if c != nil && c.MinVersion != 0 && v < c.MinVersion { continue } diff --git a/conn.go b/conn.go index 850b56f..bdbc2bd 100644 --- a/conn.go +++ b/conn.go @@ -71,6 +71,7 @@ type Conn struct { // resumptionSecret is the resumption_master_secret for handling // or sending NewSessionTicket messages. resumptionSecret []byte + echAccepted bool // ticketKeys is the set of active session ticket keys for this // connection. The first one is used to encrypt new tickets and @@ -1652,6 +1653,7 @@ func (c *Conn) connectionStateLocked() ConnectionState { } else { state.ekm = c.ekm } + state.ECHAccepted = c.echAccepted return state } diff --git a/ech.go b/ech.go new file mode 100644 index 0000000..7bf6858 --- /dev/null +++ b/ech.go @@ -0,0 +1,283 @@ +// Copyright 2024 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +package tls + +import ( + "crypto/internal/hpke" + "errors" + "strings" + + "golang.org/x/crypto/cryptobyte" +) + +type echCipher struct { + KDFID uint16 + AEADID uint16 +} + +type echExtension struct { + Type uint16 + Data []byte +} + +type echConfig struct { + raw []byte + + Version uint16 + Length uint16 + + ConfigID uint8 + KemID uint16 + PublicKey []byte + SymmetricCipherSuite []echCipher + + MaxNameLength uint8 + PublicName []byte + Extensions []echExtension +} + +var errMalformedECHConfig = errors.New("tls: malformed ECHConfigList") + +// parseECHConfigList parses a draft-ietf-tls-esni-18 ECHConfigList, returning a +// slice of parsed ECHConfigs, in the same order they were parsed, or an error +// if the list is malformed. +func parseECHConfigList(data []byte) ([]echConfig, error) { + s := cryptobyte.String(data) + // Skip the length prefix + var length uint16 + if !s.ReadUint16(&length) { + return nil, errMalformedECHConfig + } + if length != uint16(len(data)-2) { + return nil, errMalformedECHConfig + } + var configs []echConfig + for len(s) > 0 { + var ec echConfig + ec.raw = []byte(s) + if !s.ReadUint16(&ec.Version) { + return nil, errMalformedECHConfig + } + if !s.ReadUint16(&ec.Length) { + return nil, errMalformedECHConfig + } + if len(ec.raw) < int(ec.Length)+4 { + return nil, errMalformedECHConfig + } + ec.raw = ec.raw[:ec.Length+4] + if ec.Version != extensionEncryptedClientHello { + s.Skip(int(ec.Length)) + continue + } + if !s.ReadUint8(&ec.ConfigID) { + return nil, errMalformedECHConfig + } + if !s.ReadUint16(&ec.KemID) { + return nil, errMalformedECHConfig + } + if !s.ReadUint16LengthPrefixed((*cryptobyte.String)(&ec.PublicKey)) { + return nil, errMalformedECHConfig + } + var cipherSuites cryptobyte.String + if !s.ReadUint16LengthPrefixed(&cipherSuites) { + return nil, errMalformedECHConfig + } + for !cipherSuites.Empty() { + var c echCipher + if !cipherSuites.ReadUint16(&c.KDFID) { + return nil, errMalformedECHConfig + } + if !cipherSuites.ReadUint16(&c.AEADID) { + return nil, errMalformedECHConfig + } + ec.SymmetricCipherSuite = append(ec.SymmetricCipherSuite, c) + } + if !s.ReadUint8(&ec.MaxNameLength) { + return nil, errMalformedECHConfig + } + var publicName cryptobyte.String + if !s.ReadUint8LengthPrefixed(&publicName) { + return nil, errMalformedECHConfig + } + ec.PublicName = publicName + var extensions cryptobyte.String + if !s.ReadUint16LengthPrefixed(&extensions) { + return nil, errMalformedECHConfig + } + for !extensions.Empty() { + var e echExtension + if !extensions.ReadUint16(&e.Type) { + return nil, errMalformedECHConfig + } + if !extensions.ReadUint16LengthPrefixed((*cryptobyte.String)(&e.Data)) { + return nil, errMalformedECHConfig + } + ec.Extensions = append(ec.Extensions, e) + } + + configs = append(configs, ec) + } + return configs, nil +} + +func pickECHConfig(list []echConfig) *echConfig { + for _, ec := range list { + if _, ok := hpke.SupportedKEMs[ec.KemID]; !ok { + continue + } + var validSCS bool + for _, cs := range ec.SymmetricCipherSuite { + if _, ok := hpke.SupportedAEADs[cs.AEADID]; !ok { + continue + } + if _, ok := hpke.SupportedKDFs[cs.KDFID]; !ok { + continue + } + validSCS = true + break + } + if !validSCS { + continue + } + if !validDNSName(string(ec.PublicName)) { + continue + } + var unsupportedExt bool + for _, ext := range ec.Extensions { + // If high order bit is set to 1 the extension is mandatory. + // Since we don't support any extensions, if we see a mandatory + // bit, we skip the config. + if ext.Type&uint16(1<<15) != 0 { + unsupportedExt = true + } + } + if unsupportedExt { + continue + } + return &ec + } + return nil +} + +func pickECHCipherSuite(suites []echCipher) (echCipher, error) { + for _, s := range suites { + // NOTE: all of the supported AEADs and KDFs are fine, rather than + // imposing some sort of preference here, we just pick the first valid + // suite. + if _, ok := hpke.SupportedAEADs[s.AEADID]; !ok { + continue + } + if _, ok := hpke.SupportedKDFs[s.KDFID]; !ok { + continue + } + return s, nil + } + return echCipher{}, errors.New("tls: no supported symmetric ciphersuites for ECH") +} + +func encodeInnerClientHello(inner *clientHelloMsg, maxNameLength int) ([]byte, error) { + h, err := inner.marshalMsg(true) + if err != nil { + return nil, err + } + h = h[4:] // strip four byte prefix + + var paddingLen int + if inner.serverName != "" { + paddingLen = max(0, maxNameLength-len(inner.serverName)) + } else { + paddingLen = maxNameLength + 9 + } + paddingLen = 31 - ((len(h) + paddingLen - 1) % 32) + + return append(h, make([]byte, paddingLen)...), nil +} + +func generateOuterECHExt(id uint8, kdfID, aeadID uint16, encodedKey []byte, payload []byte) ([]byte, error) { + var b cryptobyte.Builder + b.AddUint8(0) // outer + b.AddUint16(kdfID) + b.AddUint16(aeadID) + b.AddUint8(id) + b.AddUint16LengthPrefixed(func(b *cryptobyte.Builder) { b.AddBytes(encodedKey) }) + b.AddUint16LengthPrefixed(func(b *cryptobyte.Builder) { b.AddBytes(payload) }) + return b.Bytes() +} + +func computeAndUpdateOuterECHExtension(outer, inner *clientHelloMsg, ech *echContext, useKey bool) error { + var encapKey []byte + if useKey { + encapKey = ech.encapsulatedKey + } + encodedInner, err := encodeInnerClientHello(inner, int(ech.config.MaxNameLength)) + if err != nil { + return err + } + // NOTE: the tag lengths for all of the supported AEADs are the same (16 + // bytes), so we have hardcoded it here. If we add support for another AEAD + // with a different tag length, we will need to change this. + encryptedLen := len(encodedInner) + 16 // AEAD tag length + outer.encryptedClientHello, err = generateOuterECHExt(ech.config.ConfigID, ech.kdfID, ech.aeadID, encapKey, make([]byte, encryptedLen)) + if err != nil { + return err + } + serializedOuter, err := outer.marshal() + if err != nil { + return err + } + serializedOuter = serializedOuter[4:] // strip the four byte prefix + encryptedInner, err := ech.hpkeContext.Seal(serializedOuter, encodedInner) + if err != nil { + return err + } + outer.encryptedClientHello, err = generateOuterECHExt(ech.config.ConfigID, ech.kdfID, ech.aeadID, encapKey, encryptedInner) + if err != nil { + return err + } + return nil +} + +// validDNSName is a rather rudimentary check for the validity of a DNS name. +// This is used to check if the public_name in a ECHConfig is valid when we are +// picking a config. This can be somewhat lax because even if we pick a +// valid-looking name, the DNS layer will later reject it anyway. +func validDNSName(name string) bool { + if len(name) > 253 { + return false + } + labels := strings.Split(name, ".") + if len(labels) <= 1 { + return false + } + for _, l := range labels { + labelLen := len(l) + if labelLen == 0 { + return false + } + for i, r := range l { + if r == '-' && (i == 0 || i == labelLen-1) { + return false + } + if (r < '0' || r > '9') && (r < 'a' || r > 'z') && (r < 'A' || r > 'Z') && r != '-' { + return false + } + } + } + return true +} + +// ECHRejectionError is the error type returned when ECH is rejected by a remote +// server. If the server offered a ECHConfigList to use for retries, the +// RetryConfigList field will contain this list. +// +// The client may treat an ECHRejectionError with an empty set of RetryConfigs +// as a secure signal from the server. +type ECHRejectionError struct { + RetryConfigList []byte +} + +func (e *ECHRejectionError) Error() string { + return "tls: server rejected ECH" +} diff --git a/ech_test.go b/ech_test.go new file mode 100644 index 0000000..96312a4 --- /dev/null +++ b/ech_test.go @@ -0,0 +1,48 @@ +// Copyright 2024 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +package tls + +import ( + "encoding/hex" + "testing" +) + +func TestDecodeECHConfigLists(t *testing.T) { + for _, tc := range []struct { + list string + numConfigs int + }{ + {"0045fe0d0041590020002092a01233db2218518ccbbbbc24df20686af417b37388de6460e94011974777090004000100010012636c6f7564666c6172652d6563682e636f6d0000", 1}, + {"0105badd00050504030201fe0d0066000010004104e62b69e2bf659f97be2f1e0d948a4cd5976bb7a91e0d46fbdda9a91e9ddcba5a01e7d697a80a18f9c3c4a31e56e27c8348db161a1cf51d7ef1942d4bcf7222c1000c000100010001000200010003400e7075626c69632e6578616d706c650000fe0d003d00002000207d661615730214aeee70533366f36a609ead65c0c208e62322346ab5bcd8de1c000411112222400e7075626c69632e6578616d706c650000fe0d004d000020002085bd6a03277c25427b52e269e0c77a8eb524ba1eb3d2f132662d4b0ac6cb7357000c000100010001000200010003400e7075626c69632e6578616d706c650008aaaa000474657374", 3}, + } { + b, err := hex.DecodeString(tc.list) + if err != nil { + t.Fatal(err) + } + configs, err := parseECHConfigList(b) + if err != nil { + t.Fatal(err) + } + if len(configs) != tc.numConfigs { + t.Fatalf("unexpected number of configs parsed: got %d want %d", len(configs), tc.numConfigs) + } + } + +} + +func TestSkipBadConfigs(t *testing.T) { + b, err := hex.DecodeString("00c8badd00050504030201fe0d0029006666000401020304000c000100010001000200010003400e7075626c69632e6578616d706c650000fe0d003d000020002072e8a23b7aef67832bcc89d652e3870a60f88ca684ec65d6eace6b61f136064c000411112222400e7075626c69632e6578616d706c650000fe0d004d00002000200ce95810a81d8023f41e83679bc92701b2acd46c75869f95c72bc61c6b12297c000c000100010001000200010003400e7075626c69632e6578616d706c650008aaaa000474657374") + if err != nil { + t.Fatal(err) + } + configs, err := parseECHConfigList(b) + if err != nil { + t.Fatal(err) + } + config := pickECHConfig(configs) + if config != nil { + t.Fatal("pickECHConfig picked an invalid config") + } +} diff --git a/handshake_client.go b/handshake_client.go index d80b232..553d2dd 100644 --- a/handshake_client.go +++ b/handshake_client.go @@ -10,6 +10,7 @@ import ( "crypto" "crypto/ecdsa" "crypto/ed25519" + "crypto/internal/hpke" "crypto/internal/mlkem768" "crypto/rsa" "crypto/subtle" @@ -40,27 +41,27 @@ type clientHandshakeState struct { var testingOnlyForceClientHelloSignatureAlgorithms []SignatureScheme -func (c *Conn) makeClientHello() (*clientHelloMsg, *keySharePrivateKeys, error) { +func (c *Conn) makeClientHello() (*clientHelloMsg, *keySharePrivateKeys, *echContext, error) { config := c.config if len(config.ServerName) == 0 && !config.InsecureSkipVerify { - return nil, nil, errors.New("tls: either ServerName or InsecureSkipVerify must be specified in the tls.Config") + return nil, nil, nil, errors.New("tls: either ServerName or InsecureSkipVerify must be specified in the tls.Config") } nextProtosLength := 0 for _, proto := range config.NextProtos { if l := len(proto); l == 0 || l > 255 { - return nil, nil, errors.New("tls: invalid NextProtos value") + return nil, nil, nil, errors.New("tls: invalid NextProtos value") } else { nextProtosLength += 1 + l } } if nextProtosLength > 0xffff { - return nil, nil, errors.New("tls: NextProtos values too large") + return nil, nil, nil, errors.New("tls: NextProtos values too large") } supportedVersions := config.supportedVersions(roleClient) if len(supportedVersions) == 0 { - return nil, nil, errors.New("tls: no supported versions satisfy MinVersion and MaxVersion") + return nil, nil, nil, errors.New("tls: no supported versions satisfy MinVersion and MaxVersion") } maxVersion := config.maxSupportedVersion(roleClient) @@ -112,7 +113,7 @@ func (c *Conn) makeClientHello() (*clientHelloMsg, *keySharePrivateKeys, error) _, err := io.ReadFull(config.rand(), hello.random) if err != nil { - return nil, nil, errors.New("tls: short read from Rand: " + err.Error()) + return nil, nil, nil, errors.New("tls: short read from Rand: " + err.Error()) } // A random session ID is used to detect when the server accepted a ticket @@ -123,7 +124,7 @@ func (c *Conn) makeClientHello() (*clientHelloMsg, *keySharePrivateKeys, error) if c.quic == nil { hello.sessionId = make([]byte, 32) if _, err := io.ReadFull(config.rand(), hello.sessionId); err != nil { - return nil, nil, errors.New("tls: short read from Rand: " + err.Error()) + return nil, nil, nil, errors.New("tls: short read from Rand: " + err.Error()) } } @@ -151,15 +152,15 @@ func (c *Conn) makeClientHello() (*clientHelloMsg, *keySharePrivateKeys, error) if curveID == x25519Kyber768Draft00 { keyShareKeys.ecdhe, err = generateECDHEKey(config.rand(), X25519) if err != nil { - return nil, nil, err + return nil, nil, nil, err } seed := make([]byte, mlkem768.SeedSize) if _, err := io.ReadFull(config.rand(), seed); err != nil { - return nil, nil, err + return nil, nil, nil, err } keyShareKeys.kyber, err = mlkem768.NewKeyFromSeed(seed) if err != nil { - return nil, nil, err + return nil, nil, nil, err } // For draft-tls-westerbaan-xyber768d00-03, we send both a hybrid // and a standard X25519 key share, since most servers will only @@ -172,11 +173,11 @@ func (c *Conn) makeClientHello() (*clientHelloMsg, *keySharePrivateKeys, error) } } else { if _, ok := curveForCurveID(curveID); !ok { - return nil, nil, errors.New("tls: CurvePreferences includes unsupported curve") + return nil, nil, nil, errors.New("tls: CurvePreferences includes unsupported curve") } keyShareKeys.ecdhe, err = generateECDHEKey(config.rand(), curveID) if err != nil { - return nil, nil, err + return nil, nil, nil, err } hello.keyShares = []keyShare{{group: curveID, data: keyShareKeys.ecdhe.PublicKey().Bytes()}} } @@ -185,7 +186,7 @@ func (c *Conn) makeClientHello() (*clientHelloMsg, *keySharePrivateKeys, error) if c.quic != nil { p, err := c.quicGetTransportParameters() if err != nil { - return nil, nil, err + return nil, nil, nil, err } if p == nil { p = []byte{} @@ -193,7 +194,60 @@ func (c *Conn) makeClientHello() (*clientHelloMsg, *keySharePrivateKeys, error) hello.quicTransportParameters = p } - return hello, keyShareKeys, nil + var ech *echContext + if c.config.EncryptedClientHelloConfigList != nil { + if c.config.MinVersion != 0 && c.config.MinVersion < VersionTLS13 { + return nil, nil, nil, errors.New("tls: MinVersion must be >= VersionTLS13 if EncryptedClientHelloConfigList is populated") + } + if c.config.MaxVersion != 0 && c.config.MaxVersion <= VersionTLS12 { + return nil, nil, nil, errors.New("tls: MaxVersion must be >= VersionTLS13 if EncryptedClientHelloConfigList is populated") + } + echConfigs, err := parseECHConfigList(c.config.EncryptedClientHelloConfigList) + if err != nil { + return nil, nil, nil, err + } + echConfig := pickECHConfig(echConfigs) + if echConfig == nil { + return nil, nil, nil, errors.New("tls: EncryptedClientHelloConfigList contains no valid configs") + } + ech = &echContext{config: echConfig} + hello.encryptedClientHello = []byte{1} // indicate inner hello + // We need to explicitly set these 1.2 fields to nil, as we do not + // marshal them when encoding the inner hello, otherwise transcripts + // will later mismatch. + hello.supportedPoints = nil + hello.ticketSupported = false + hello.secureRenegotiationSupported = false + hello.extendedMasterSecret = false + + echPK, err := hpke.ParseHPKEPublicKey(ech.config.KemID, ech.config.PublicKey) + if err != nil { + return nil, nil, nil, err + } + suite, err := pickECHCipherSuite(ech.config.SymmetricCipherSuite) + if err != nil { + return nil, nil, nil, err + } + ech.kdfID, ech.aeadID = suite.KDFID, suite.AEADID + info := append([]byte("tls ech\x00"), ech.config.raw...) + ech.encapsulatedKey, ech.hpkeContext, err = hpke.SetupSender(ech.config.KemID, suite.KDFID, suite.AEADID, echPK, info) + if err != nil { + return nil, nil, nil, err + } + } + + return hello, keyShareKeys, ech, nil +} + +type echContext struct { + config *echConfig + hpkeContext *hpke.Sender + encapsulatedKey []byte + innerHello *clientHelloMsg + innerTranscript hash.Hash + kdfID uint16 + aeadID uint16 + echRejected bool } func (c *Conn) clientHandshake(ctx context.Context) (err error) { @@ -205,11 +259,10 @@ func (c *Conn) clientHandshake(ctx context.Context) (err error) { // need to be reset. c.didResume = false - hello, keyShareKeys, err := c.makeClientHello() + hello, keyShareKeys, ech, err := c.makeClientHello() if err != nil { return err } - c.serverName = hello.serverName session, earlySecret, binderKey, err := c.loadSession(hello) if err != nil { @@ -231,6 +284,31 @@ func (c *Conn) clientHandshake(ctx context.Context) (err error) { }() } + if ech != nil { + // Split hello into inner and outer + ech.innerHello = hello.clone() + + // Overwrite the server name in the outer hello with the public facing + // name. + hello.serverName = string(ech.config.PublicName) + // Generate a new random for the outer hello. + hello.random = make([]byte, 32) + _, err = io.ReadFull(c.config.rand(), hello.random) + if err != nil { + return errors.New("tls: short read from Rand: " + err.Error()) + } + + // NOTE: we don't do PSK GREASE, in line with boringssl, it's meant to + // work around _possibly_ broken middleboxes, but there is little-to-no + // evidence that this is actually a problem. + + if err := computeAndUpdateOuterECHExtension(hello, ech.innerHello, ech, true); err != nil { + return err + } + } + + c.serverName = hello.serverName + if _, err := c.writeHandshakeRecord(hello, nil); err != nil { return err } @@ -283,6 +361,7 @@ func (c *Conn) clientHandshake(ctx context.Context) (err error) { session: session, earlySecret: earlySecret, binderKey: binderKey, + echContext: ech, } return hs.handshake() } @@ -303,7 +382,11 @@ func (c *Conn) loadSession(hello *clientHelloMsg) ( return nil, nil, nil, nil } - hello.ticketSupported = true + echInner := bytes.Equal(hello.encryptedClientHello, []byte{1}) + + // ticketSupported is a TLS 1.2 extension (as TLS 1.3 replaced tickets with PSK + // identities) and ECH requires and forces TLS 1.3. + hello.ticketSupported = true && !echInner if hello.supportedVersions[0] == VersionTLS13 { // Require DHE on resumption as it guarantees forward secrecy against @@ -422,13 +505,7 @@ func (c *Conn) loadSession(hello *clientHelloMsg) ( earlySecret = cipherSuite.extract(session.secret, nil) binderKey = cipherSuite.deriveSecret(earlySecret, resumptionBinderLabel, nil) transcript := cipherSuite.hash.New() - helloBytes, err := hello.marshalWithoutBinders() - if err != nil { - return nil, nil, nil, err - } - transcript.Write(helloBytes) - pskBinders := [][]byte{cipherSuite.finishedHash(binderKey, transcript)} - if err := hello.updateBinders(pskBinders); err != nil { + if err := computeAndUpdatePSK(hello, binderKey, transcript, cipherSuite.finishedHash); err != nil { return nil, nil, nil, err } @@ -1009,7 +1086,32 @@ func (c *Conn) verifyServerCertificate(certificates [][]byte) error { certs[i] = cert.cert } - if !c.config.InsecureSkipVerify { + echRejected := c.config.EncryptedClientHelloConfigList != nil && !c.echAccepted + if echRejected { + if c.config.EncryptedClientHelloRejectionVerify != nil { + if err := c.config.EncryptedClientHelloRejectionVerify(c.connectionStateLocked()); err != nil { + c.sendAlert(alertBadCertificate) + return err + } + } else { + opts := x509.VerifyOptions{ + Roots: c.config.RootCAs, + CurrentTime: c.config.time(), + DNSName: c.serverName, + Intermediates: x509.NewCertPool(), + } + + for _, cert := range certs[1:] { + opts.Intermediates.AddCert(cert) + } + var err error + c.verifiedChains, err = certs[0].Verify(opts) + if err != nil { + c.sendAlert(alertBadCertificate) + return &CertificateVerificationError{UnverifiedCertificates: certs, Err: err} + } + } + } else if !c.config.InsecureSkipVerify { opts := x509.VerifyOptions{ Roots: c.config.RootCAs, CurrentTime: c.config.time(), @@ -1039,14 +1141,14 @@ func (c *Conn) verifyServerCertificate(certificates [][]byte) error { c.activeCertHandles = activeHandles c.peerCertificates = certs - if c.config.VerifyPeerCertificate != nil { + if c.config.VerifyPeerCertificate != nil && !echRejected { if err := c.config.VerifyPeerCertificate(certificates, c.verifiedChains); err != nil { c.sendAlert(alertBadCertificate) return err } } - if c.config.VerifyConnection != nil { + if c.config.VerifyConnection != nil && !echRejected { if err := c.config.VerifyConnection(c.connectionStateLocked()); err != nil { c.sendAlert(alertBadCertificate) return err @@ -1169,3 +1271,13 @@ func hostnameInSNI(name string) string { } return name } + +func computeAndUpdatePSK(m *clientHelloMsg, binderKey []byte, transcript hash.Hash, finishedHash func([]byte, hash.Hash) []byte) error { + helloBytes, err := m.marshalWithoutBinders() + if err != nil { + return err + } + transcript.Write(helloBytes) + pskBinders := [][]byte{finishedHash(binderKey, transcript)} + return m.updateBinders(pskBinders) +} diff --git a/handshake_client_test.go b/handshake_client_test.go index a32b48a..4570f5b 100644 --- a/handshake_client_test.go +++ b/handshake_client_test.go @@ -7,9 +7,14 @@ package tls import ( "bytes" "context" + "crypto/ecdsa" + "crypto/elliptic" + "crypto/rand" "crypto/rsa" "crypto/x509" + "crypto/x509/pkix" "encoding/base64" + "encoding/hex" "encoding/pem" "errors" "fmt" @@ -2809,3 +2814,123 @@ func TestHandshakeRSATooBig(t *testing.T) { t.Errorf("Conn.processCertsFromClient unexpected error: want %q, got %q", expectedErr, err) } } + +func TestTLS13ECHRejectionCallbacks(t *testing.T) { + k, err := ecdsa.GenerateKey(elliptic.P256(), rand.Reader) + if err != nil { + t.Fatal(err) + } + tmpl := &x509.Certificate{ + SerialNumber: big.NewInt(1), + Subject: pkix.Name{CommonName: "test"}, + DNSNames: []string{"example.golang"}, + NotBefore: testConfig.Time().Add(-time.Hour), + NotAfter: testConfig.Time().Add(time.Hour), + } + certDER, err := x509.CreateCertificate(rand.Reader, tmpl, tmpl, k.Public(), k) + if err != nil { + t.Fatal(err) + } + cert, err := x509.ParseCertificate(certDER) + if err != nil { + t.Fatal(err) + } + + clientConfig, serverConfig := testConfig.Clone(), testConfig.Clone() + serverConfig.Certificates = []Certificate{ + { + Certificate: [][]byte{certDER}, + PrivateKey: k, + }, + } + serverConfig.MinVersion = VersionTLS13 + clientConfig.RootCAs = x509.NewCertPool() + clientConfig.RootCAs.AddCert(cert) + clientConfig.MinVersion = VersionTLS13 + clientConfig.EncryptedClientHelloConfigList, _ = hex.DecodeString("0041fe0d003d0100200020204bed0a11fc0dde595a9b78d966b0011128eb83f65d3c91c1cc5ac786cd246f000400010001ff0e6578616d706c652e676f6c616e670000") + clientConfig.ServerName = "example.golang" + + for _, tc := range []struct { + name string + expectedErr string + + verifyConnection func(ConnectionState) error + verifyPeerCertificate func([][]byte, [][]*x509.Certificate) error + encryptedClientHelloRejectionVerify func(ConnectionState) error + }{ + { + name: "no callbacks", + expectedErr: "tls: server rejected ECH", + }, + { + name: "EncryptedClientHelloRejectionVerify, no err", + encryptedClientHelloRejectionVerify: func(ConnectionState) error { + return nil + }, + expectedErr: "tls: server rejected ECH", + }, + { + name: "EncryptedClientHelloRejectionVerify, err", + encryptedClientHelloRejectionVerify: func(ConnectionState) error { + return errors.New("callback err") + }, + // testHandshake returns the server side error, so we just need to + // check alertBadCertificate was sent + expectedErr: "callback err", + }, + { + name: "VerifyConnection, err", + verifyConnection: func(ConnectionState) error { + return errors.New("callback err") + }, + expectedErr: "tls: server rejected ECH", + }, + { + name: "VerifyPeerCertificate, err", + verifyPeerCertificate: func([][]byte, [][]*x509.Certificate) error { + return errors.New("callback err") + }, + expectedErr: "tls: server rejected ECH", + }, + } { + t.Run(tc.name, func(t *testing.T) { + c, s := localPipe(t) + done := make(chan error) + + go func() { + serverErr := Server(s, serverConfig).Handshake() + s.Close() + done <- serverErr + }() + + cConfig := clientConfig.Clone() + cConfig.VerifyConnection = tc.verifyConnection + cConfig.VerifyPeerCertificate = tc.verifyPeerCertificate + cConfig.EncryptedClientHelloRejectionVerify = tc.encryptedClientHelloRejectionVerify + + clientErr := Client(c, cConfig).Handshake() + c.Close() + + if tc.expectedErr == "" && clientErr != nil { + t.Fatalf("unexpected err: %s", clientErr) + } else if clientErr != nil && tc.expectedErr != clientErr.Error() { + t.Fatalf("unexpected err: got %q, want %q", clientErr, tc.expectedErr) + } + }) + } +} + +func TestECHTLS12Server(t *testing.T) { + clientConfig, serverConfig := testConfig.Clone(), testConfig.Clone() + + serverConfig.MaxVersion = VersionTLS12 + clientConfig.MinVersion = 0 + + clientConfig.EncryptedClientHelloConfigList, _ = hex.DecodeString("0041fe0d003d0100200020204bed0a11fc0dde595a9b78d966b0011128eb83f65d3c91c1cc5ac786cd246f000400010001ff0e6578616d706c652e676f6c616e670000") + + expectedErr := "server: tls: client offered only unsupported versions: [304]\nclient: remote error: tls: protocol version not supported" + _, _, err := testHandshake(t, clientConfig, serverConfig) + if err == nil || err.Error() != expectedErr { + t.Fatalf("unexpected handshake error: got %q, want %q", err, expectedErr) + } +} diff --git a/handshake_client_tls13.go b/handshake_client_tls13.go index 820532b..6744e71 100644 --- a/handshake_client_tls13.go +++ b/handshake_client_tls13.go @@ -11,6 +11,7 @@ import ( "crypto/hmac" "crypto/internal/mlkem768" "crypto/rsa" + "crypto/subtle" "errors" "hash" "slices" @@ -35,6 +36,8 @@ type clientHandshakeStateTLS13 struct { transcript hash.Hash masterSecret []byte trafficSecret []byte // client_application_traffic_secret_0 + + echContext *echContext } // handshake requires hs.c, hs.hello, hs.serverHello, hs.keyShareKeys, and, @@ -68,6 +71,13 @@ func (hs *clientHandshakeStateTLS13) handshake() error { return err } + if hs.echContext != nil { + hs.echContext.innerTranscript = hs.suite.hash.New() + if err := transcriptMsg(hs.echContext.innerHello, hs.echContext.innerTranscript); err != nil { + return err + } + } + if bytes.Equal(hs.serverHello.random, helloRetryRequestRandom) { if err := hs.sendDummyChangeCipherSpec(); err != nil { return err @@ -77,6 +87,41 @@ func (hs *clientHandshakeStateTLS13) handshake() error { } } + var echRetryConfigList []byte + if hs.echContext != nil { + confTranscript := cloneHash(hs.echContext.innerTranscript, hs.suite.hash) + confTranscript.Write(hs.serverHello.original[:30]) + confTranscript.Write(make([]byte, 8)) + confTranscript.Write(hs.serverHello.original[38:]) + acceptConfirmation := hs.suite.expandLabel( + hs.suite.extract(hs.echContext.innerHello.random, nil), + "ech accept confirmation", + confTranscript.Sum(nil), + 8, + ) + if subtle.ConstantTimeCompare(acceptConfirmation, hs.serverHello.random[len(hs.serverHello.random)-8:]) == 1 { + hs.hello = hs.echContext.innerHello + c.serverName = c.config.ServerName + hs.transcript = hs.echContext.innerTranscript + c.echAccepted = true + + if hs.serverHello.encryptedClientHello != nil { + c.sendAlert(alertUnsupportedExtension) + return errors.New("tls: unexpected encrypted_client_hello extension in server hello despite ECH being accepted") + } + + if hs.hello.serverName == "" && hs.serverHello.serverNameAck { + c.sendAlert(alertUnsupportedExtension) + return errors.New("tls: unexpected server_name extension in server hello") + } + } else { + hs.echContext.echRejected = true + // If the server sent us retry configs, we'll return these to + // the user so they can update their Config. + echRetryConfigList = hs.serverHello.encryptedClientHello + } + } + if err := transcriptMsg(hs.serverHello, hs.transcript); err != nil { return err } @@ -110,6 +155,11 @@ func (hs *clientHandshakeStateTLS13) handshake() error { return err } + if hs.echContext != nil && hs.echContext.echRejected { + c.sendAlert(alertECHRequired) + return &ECHRejectionError{echRetryConfigList} + } + c.isHandshakeComplete.Store(true) return nil @@ -201,6 +251,48 @@ func (hs *clientHandshakeStateTLS13) processHelloRetryRequest() error { return err } + var isInnerHello bool + hello := hs.hello + if hs.echContext != nil { + chHash = hs.echContext.innerTranscript.Sum(nil) + hs.echContext.innerTranscript.Reset() + hs.echContext.innerTranscript.Write([]byte{typeMessageHash, 0, 0, uint8(len(chHash))}) + hs.echContext.innerTranscript.Write(chHash) + + if hs.serverHello.encryptedClientHello != nil { + if len(hs.serverHello.encryptedClientHello) != 8 { + hs.c.sendAlert(alertDecodeError) + return errors.New("tls: malformed encrypted client hello extension") + } + + confTranscript := cloneHash(hs.echContext.innerTranscript, hs.suite.hash) + hrrHello := make([]byte, len(hs.serverHello.original)) + copy(hrrHello, hs.serverHello.original) + hrrHello = bytes.Replace(hrrHello, hs.serverHello.encryptedClientHello, make([]byte, 8), 1) + confTranscript.Write(hrrHello) + acceptConfirmation := hs.suite.expandLabel( + hs.suite.extract(hs.echContext.innerHello.random, nil), + "hrr ech accept confirmation", + confTranscript.Sum(nil), + 8, + ) + if subtle.ConstantTimeCompare(acceptConfirmation, hs.serverHello.encryptedClientHello) == 1 { + hello = hs.echContext.innerHello + c.serverName = c.config.ServerName + isInnerHello = true + c.echAccepted = true + } + } + + if err := transcriptMsg(hs.serverHello, hs.echContext.innerTranscript); err != nil { + return err + } + } else if hs.serverHello.encryptedClientHello != nil { + // Unsolicited ECH extension should be rejected + c.sendAlert(alertUnsupportedExtension) + return errors.New("tls: unexpected ECH extension in serverHello") + } + // The only HelloRetryRequest extensions we support are key_share and // cookie, and clients must abort the handshake if the HRR would not result // in any change in the ClientHello. @@ -210,7 +302,7 @@ func (hs *clientHandshakeStateTLS13) processHelloRetryRequest() error { } if hs.serverHello.cookie != nil { - hs.hello.cookie = hs.serverHello.cookie + hello.cookie = hs.serverHello.cookie } if hs.serverHello.serverShare.group != 0 { @@ -222,7 +314,7 @@ func (hs *clientHandshakeStateTLS13) processHelloRetryRequest() error { // a group we advertised but did not send a key share for, and send a key // share for it this time. if curveID := hs.serverHello.selectedGroup; curveID != 0 { - if !slices.Contains(hs.hello.supportedCurves, curveID) { + if !slices.Contains(hello.supportedCurves, curveID) { c.sendAlert(alertIllegalParameter) return errors.New("tls: server selected unsupported group") } @@ -248,10 +340,10 @@ func (hs *clientHandshakeStateTLS13) processHelloRetryRequest() error { return err } hs.keyShareKeys = &keySharePrivateKeys{curveID: curveID, ecdhe: key} - hs.hello.keyShares = []keyShare{{group: curveID, data: key.PublicKey().Bytes()}} + hello.keyShares = []keyShare{{group: curveID, data: key.PublicKey().Bytes()}} } - if len(hs.hello.pskIdentities) > 0 { + if len(hello.pskIdentities) > 0 { pskSuite := cipherSuiteTLS13ByID(hs.session.cipherSuite) if pskSuite == nil { return c.sendAlert(alertInternalError) @@ -259,7 +351,7 @@ func (hs *clientHandshakeStateTLS13) processHelloRetryRequest() error { if pskSuite.hash == hs.suite.hash { // Update binders and obfuscated_ticket_age. ticketAge := c.config.time().Sub(time.Unix(int64(hs.session.createdAt), 0)) - hs.hello.pskIdentities[0].obfuscatedTicketAge = uint32(ticketAge/time.Millisecond) + hs.session.ageAdd + hello.pskIdentities[0].obfuscatedTicketAge = uint32(ticketAge/time.Millisecond) + hs.session.ageAdd transcript := hs.suite.hash.New() transcript.Write([]byte{typeMessageHash, 0, 0, uint8(len(chHash))}) @@ -267,27 +359,40 @@ func (hs *clientHandshakeStateTLS13) processHelloRetryRequest() error { if err := transcriptMsg(hs.serverHello, transcript); err != nil { return err } - helloBytes, err := hs.hello.marshalWithoutBinders() - if err != nil { - return err - } - transcript.Write(helloBytes) - pskBinders := [][]byte{hs.suite.finishedHash(hs.binderKey, transcript)} - if err := hs.hello.updateBinders(pskBinders); err != nil { + + if err := computeAndUpdatePSK(hello, hs.binderKey, transcript, hs.suite.finishedHash); err != nil { return err } } else { // Server selected a cipher suite incompatible with the PSK. - hs.hello.pskIdentities = nil - hs.hello.pskBinders = nil + hello.pskIdentities = nil + hello.pskBinders = nil } } - if hs.hello.earlyData { - hs.hello.earlyData = false + if hello.earlyData { + hello.earlyData = false c.quicRejectedEarlyData() } + if isInnerHello { + // Any extensions which have changed in hello, but are mirrored in the + // outer hello and compressed, need to be copied to the outer hello, so + // they can be properly decompressed by the server. For now, the only + // extension which may have changed is keyShares. + hs.hello.keyShares = hello.keyShares + hs.echContext.innerHello = hello + if err := transcriptMsg(hs.echContext.innerHello, hs.echContext.innerTranscript); err != nil { + return err + } + + if err := computeAndUpdateOuterECHExtension(hs.hello, hs.echContext.innerHello, hs.echContext, false); err != nil { + return err + } + } else { + hs.hello = hello + } + if _, err := hs.c.writeHandshakeRecord(hs.hello, hs.transcript); err != nil { return err } @@ -503,6 +608,10 @@ func (hs *clientHandshakeStateTLS13) readServerParameters() error { return errors.New("tls: server accepted 0-RTT with the wrong ALPN") } } + if hs.echContext != nil && !hs.echContext.echRejected && encryptedExtensions.echRetryConfigs != nil { + c.sendAlert(alertUnsupportedExtension) + return errors.New("tls: server sent ECH retry configs after accepting ECH") + } return nil } @@ -656,6 +765,13 @@ func (hs *clientHandshakeStateTLS13) sendClientCertificate() error { return nil } + if hs.echContext != nil && hs.echContext.echRejected { + if _, err := hs.c.writeHandshakeRecord(&certificateMsgTLS13{}, hs.transcript); err != nil { + return err + } + return nil + } + cert, err := c.getClientCertificate(&CertificateRequestInfo{ AcceptableCAs: hs.certReq.certificateAuthorities, SignatureSchemes: hs.certReq.supportedSignatureAlgorithms, diff --git a/handshake_messages.go b/handshake_messages.go index 86ec493..8620b66 100644 --- a/handshake_messages.go +++ b/handshake_messages.go @@ -7,6 +7,7 @@ package tls import ( "errors" "fmt" + "slices" "strings" "golang.org/x/crypto/cryptobyte" @@ -95,9 +96,10 @@ type clientHelloMsg struct { pskIdentities []pskIdentity pskBinders [][]byte quicTransportParameters []byte + encryptedClientHello []byte } -func (m *clientHelloMsg) marshal() ([]byte, error) { +func (m *clientHelloMsg) marshalMsg(echInner bool) ([]byte, error) { var exts cryptobyte.Builder if len(m.serverName) > 0 { // RFC 6066, Section 3 @@ -111,7 +113,7 @@ func (m *clientHelloMsg) marshal() ([]byte, error) { }) }) } - if len(m.supportedPoints) > 0 { + if len(m.supportedPoints) > 0 && !echInner { // RFC 4492, Section 5.1.2 exts.AddUint16(extensionSupportedPoints) exts.AddUint16LengthPrefixed(func(exts *cryptobyte.Builder) { @@ -120,14 +122,14 @@ func (m *clientHelloMsg) marshal() ([]byte, error) { }) }) } - if m.ticketSupported { + if m.ticketSupported && !echInner { // RFC 5077, Section 3.2 exts.AddUint16(extensionSessionTicket) exts.AddUint16LengthPrefixed(func(exts *cryptobyte.Builder) { exts.AddBytes(m.sessionTicket) }) } - if m.secureRenegotiationSupported { + if m.secureRenegotiationSupported && !echInner { // RFC 5746, Section 3.2 exts.AddUint16(extensionRenegotiationInfo) exts.AddUint16LengthPrefixed(func(exts *cryptobyte.Builder) { @@ -136,7 +138,7 @@ func (m *clientHelloMsg) marshal() ([]byte, error) { }) }) } - if m.extendedMasterSecret { + if m.extendedMasterSecret && !echInner { // RFC 7627 exts.AddUint16(extensionExtendedMasterSecret) exts.AddUint16(0) // empty extension_data @@ -158,101 +160,158 @@ func (m *clientHelloMsg) marshal() ([]byte, error) { exts.AddBytes(m.quicTransportParameters) }) } + if len(m.encryptedClientHello) > 0 { + exts.AddUint16(extensionEncryptedClientHello) + exts.AddUint16LengthPrefixed(func(exts *cryptobyte.Builder) { + exts.AddBytes(m.encryptedClientHello) + }) + } + // Note that any extension that can be compressed during ECH must be + // contiguous. If any additional extensions are to be compressed they must + // be added to the following block, so that they can be properly + // decompressed on the other side. + var echOuterExts []uint16 if m.ocspStapling { // RFC 4366, Section 3.6 - exts.AddUint16(extensionStatusRequest) - exts.AddUint16LengthPrefixed(func(exts *cryptobyte.Builder) { - exts.AddUint8(1) // status_type = ocsp - exts.AddUint16(0) // empty responder_id_list - exts.AddUint16(0) // empty request_extensions - }) + if echInner { + echOuterExts = append(echOuterExts, extensionStatusRequest) + } else { + exts.AddUint16(extensionStatusRequest) + exts.AddUint16LengthPrefixed(func(exts *cryptobyte.Builder) { + exts.AddUint8(1) // status_type = ocsp + exts.AddUint16(0) // empty responder_id_list + exts.AddUint16(0) // empty request_extensions + }) + } } if len(m.supportedCurves) > 0 { // RFC 4492, sections 5.1.1 and RFC 8446, Section 4.2.7 - exts.AddUint16(extensionSupportedCurves) - exts.AddUint16LengthPrefixed(func(exts *cryptobyte.Builder) { + if echInner { + echOuterExts = append(echOuterExts, extensionSupportedCurves) + } else { + exts.AddUint16(extensionSupportedCurves) exts.AddUint16LengthPrefixed(func(exts *cryptobyte.Builder) { - for _, curve := range m.supportedCurves { - exts.AddUint16(uint16(curve)) - } + exts.AddUint16LengthPrefixed(func(exts *cryptobyte.Builder) { + for _, curve := range m.supportedCurves { + exts.AddUint16(uint16(curve)) + } + }) }) - }) + } } if len(m.supportedSignatureAlgorithms) > 0 { // RFC 5246, Section 7.4.1.4.1 - exts.AddUint16(extensionSignatureAlgorithms) - exts.AddUint16LengthPrefixed(func(exts *cryptobyte.Builder) { + if echInner { + echOuterExts = append(echOuterExts, extensionSignatureAlgorithms) + } else { + exts.AddUint16(extensionSignatureAlgorithms) exts.AddUint16LengthPrefixed(func(exts *cryptobyte.Builder) { - for _, sigAlgo := range m.supportedSignatureAlgorithms { - exts.AddUint16(uint16(sigAlgo)) - } + exts.AddUint16LengthPrefixed(func(exts *cryptobyte.Builder) { + for _, sigAlgo := range m.supportedSignatureAlgorithms { + exts.AddUint16(uint16(sigAlgo)) + } + }) }) - }) + } } if len(m.supportedSignatureAlgorithmsCert) > 0 { // RFC 8446, Section 4.2.3 - exts.AddUint16(extensionSignatureAlgorithmsCert) - exts.AddUint16LengthPrefixed(func(exts *cryptobyte.Builder) { + if echInner { + echOuterExts = append(echOuterExts, extensionSignatureAlgorithmsCert) + } else { + exts.AddUint16(extensionSignatureAlgorithmsCert) exts.AddUint16LengthPrefixed(func(exts *cryptobyte.Builder) { - for _, sigAlgo := range m.supportedSignatureAlgorithmsCert { - exts.AddUint16(uint16(sigAlgo)) - } + exts.AddUint16LengthPrefixed(func(exts *cryptobyte.Builder) { + for _, sigAlgo := range m.supportedSignatureAlgorithmsCert { + exts.AddUint16(uint16(sigAlgo)) + } + }) }) - }) + } } if len(m.alpnProtocols) > 0 { // RFC 7301, Section 3.1 - exts.AddUint16(extensionALPN) - exts.AddUint16LengthPrefixed(func(exts *cryptobyte.Builder) { + if echInner { + echOuterExts = append(echOuterExts, extensionALPN) + } else { + exts.AddUint16(extensionALPN) exts.AddUint16LengthPrefixed(func(exts *cryptobyte.Builder) { - for _, proto := range m.alpnProtocols { - exts.AddUint8LengthPrefixed(func(exts *cryptobyte.Builder) { - exts.AddBytes([]byte(proto)) - }) - } + exts.AddUint16LengthPrefixed(func(exts *cryptobyte.Builder) { + for _, proto := range m.alpnProtocols { + exts.AddUint8LengthPrefixed(func(exts *cryptobyte.Builder) { + exts.AddBytes([]byte(proto)) + }) + } + }) }) - }) + } } if len(m.supportedVersions) > 0 { // RFC 8446, Section 4.2.1 - exts.AddUint16(extensionSupportedVersions) - exts.AddUint16LengthPrefixed(func(exts *cryptobyte.Builder) { - exts.AddUint8LengthPrefixed(func(exts *cryptobyte.Builder) { - for _, vers := range m.supportedVersions { - exts.AddUint16(vers) - } + if echInner { + echOuterExts = append(echOuterExts, extensionSupportedVersions) + } else { + exts.AddUint16(extensionSupportedVersions) + exts.AddUint16LengthPrefixed(func(exts *cryptobyte.Builder) { + exts.AddUint8LengthPrefixed(func(exts *cryptobyte.Builder) { + for _, vers := range m.supportedVersions { + exts.AddUint16(vers) + } + }) }) - }) + } } if len(m.cookie) > 0 { // RFC 8446, Section 4.2.2 - exts.AddUint16(extensionCookie) - exts.AddUint16LengthPrefixed(func(exts *cryptobyte.Builder) { + if echInner { + echOuterExts = append(echOuterExts, extensionCookie) + } else { + exts.AddUint16(extensionCookie) exts.AddUint16LengthPrefixed(func(exts *cryptobyte.Builder) { - exts.AddBytes(m.cookie) + exts.AddUint16LengthPrefixed(func(exts *cryptobyte.Builder) { + exts.AddBytes(m.cookie) + }) }) - }) + } } if len(m.keyShares) > 0 { // RFC 8446, Section 4.2.8 - exts.AddUint16(extensionKeyShare) - exts.AddUint16LengthPrefixed(func(exts *cryptobyte.Builder) { + if echInner { + echOuterExts = append(echOuterExts, extensionKeyShare) + } else { + exts.AddUint16(extensionKeyShare) exts.AddUint16LengthPrefixed(func(exts *cryptobyte.Builder) { - for _, ks := range m.keyShares { - exts.AddUint16(uint16(ks.group)) - exts.AddUint16LengthPrefixed(func(exts *cryptobyte.Builder) { - exts.AddBytes(ks.data) - }) - } + exts.AddUint16LengthPrefixed(func(exts *cryptobyte.Builder) { + for _, ks := range m.keyShares { + exts.AddUint16(uint16(ks.group)) + exts.AddUint16LengthPrefixed(func(exts *cryptobyte.Builder) { + exts.AddBytes(ks.data) + }) + } + }) }) - }) + } } if len(m.pskModes) > 0 { // RFC 8446, Section 4.2.9 - exts.AddUint16(extensionPSKModes) + if echInner { + echOuterExts = append(echOuterExts, extensionPSKModes) + } else { + exts.AddUint16(extensionPSKModes) + exts.AddUint16LengthPrefixed(func(exts *cryptobyte.Builder) { + exts.AddUint8LengthPrefixed(func(exts *cryptobyte.Builder) { + exts.AddBytes(m.pskModes) + }) + }) + } + } + if len(echOuterExts) > 0 && echInner { + exts.AddUint16(extensionECHOuterExtensions) exts.AddUint16LengthPrefixed(func(exts *cryptobyte.Builder) { exts.AddUint8LengthPrefixed(func(exts *cryptobyte.Builder) { - exts.AddBytes(m.pskModes) + for _, e := range echOuterExts { + exts.AddUint16(e) + } }) }) } @@ -288,7 +347,9 @@ func (m *clientHelloMsg) marshal() ([]byte, error) { b.AddUint16(m.vers) addBytesWithLength(b, m.random, 32) b.AddUint8LengthPrefixed(func(b *cryptobyte.Builder) { - b.AddBytes(m.sessionId) + if !echInner { + b.AddBytes(m.sessionId) + } }) b.AddUint16LengthPrefixed(func(b *cryptobyte.Builder) { for _, suite := range m.cipherSuites { @@ -309,6 +370,10 @@ func (m *clientHelloMsg) marshal() ([]byte, error) { return b.Bytes() } +func (m *clientHelloMsg) marshal() ([]byte, error) { + return m.marshalMsg(false) +} + // marshalWithoutBinders returns the ClientHello through the // PreSharedKeyExtension.identities field, according to RFC 8446, Section // 4.2.11.2. Note that m.pskBinders must be set to slices of the correct length. @@ -611,6 +676,39 @@ func (m *clientHelloMsg) originalBytes() []byte { return m.original } +func (m *clientHelloMsg) clone() *clientHelloMsg { + return &clientHelloMsg{ + original: slices.Clone(m.original), + vers: m.vers, + random: slices.Clone(m.random), + sessionId: slices.Clone(m.sessionId), + cipherSuites: slices.Clone(m.cipherSuites), + compressionMethods: slices.Clone(m.compressionMethods), + serverName: m.serverName, + ocspStapling: m.ocspStapling, + supportedCurves: slices.Clone(m.supportedCurves), + supportedPoints: slices.Clone(m.supportedPoints), + ticketSupported: m.ticketSupported, + sessionTicket: slices.Clone(m.sessionTicket), + supportedSignatureAlgorithms: slices.Clone(m.supportedSignatureAlgorithms), + supportedSignatureAlgorithmsCert: slices.Clone(m.supportedSignatureAlgorithmsCert), + secureRenegotiationSupported: m.secureRenegotiationSupported, + secureRenegotiation: slices.Clone(m.secureRenegotiation), + extendedMasterSecret: m.extendedMasterSecret, + alpnProtocols: slices.Clone(m.alpnProtocols), + scts: m.scts, + supportedVersions: slices.Clone(m.supportedVersions), + cookie: slices.Clone(m.cookie), + keyShares: slices.Clone(m.keyShares), + earlyData: m.earlyData, + pskModes: slices.Clone(m.pskModes), + pskIdentities: slices.Clone(m.pskIdentities), + pskBinders: slices.Clone(m.pskBinders), + quicTransportParameters: slices.Clone(m.quicTransportParameters), + encryptedClientHello: slices.Clone(m.encryptedClientHello), + } +} + type serverHelloMsg struct { original []byte vers uint16 @@ -630,6 +728,8 @@ type serverHelloMsg struct { selectedIdentityPresent bool selectedIdentity uint16 supportedPoints []uint8 + encryptedClientHello []byte + serverNameAck bool // HelloRetryRequest extensions cookie []byte @@ -724,6 +824,16 @@ func (m *serverHelloMsg) marshal() ([]byte, error) { }) }) } + if len(m.encryptedClientHello) > 0 { + exts.AddUint16(extensionEncryptedClientHello) + exts.AddUint16LengthPrefixed(func(exts *cryptobyte.Builder) { + exts.AddBytes(m.encryptedClientHello) + }) + } + if m.serverNameAck { + exts.AddUint16(extensionServerName) + exts.AddUint16(0) + } extBytes, err := exts.Bytes() if err != nil { @@ -856,6 +966,16 @@ func (m *serverHelloMsg) unmarshal(data []byte) bool { len(m.supportedPoints) == 0 { return false } + case extensionEncryptedClientHello: // encrypted_client_hello + m.encryptedClientHello = make([]byte, len(extData)) + if !extData.CopyBytes(m.encryptedClientHello) { + return false + } + case extensionServerName: + if len(extData) != 0 { + return false + } + m.serverNameAck = true default: // Ignore unknown extensions. continue @@ -877,6 +997,7 @@ type encryptedExtensionsMsg struct { alpnProtocol string quicTransportParameters []byte earlyData bool + echRetryConfigs []byte } func (m *encryptedExtensionsMsg) marshal() ([]byte, error) { @@ -906,6 +1027,12 @@ func (m *encryptedExtensionsMsg) marshal() ([]byte, error) { b.AddUint16(extensionEarlyData) b.AddUint16(0) // empty extension_data } + if len(m.echRetryConfigs) > 0 { + b.AddUint16(extensionEncryptedClientHello) + b.AddUint16LengthPrefixed(func(b *cryptobyte.Builder) { + b.AddBytes(m.echRetryConfigs) + }) + } }) }) @@ -950,6 +1077,11 @@ func (m *encryptedExtensionsMsg) unmarshal(data []byte) bool { case extensionEarlyData: // RFC 8446, Section 4.2.10 m.earlyData = true + case extensionEncryptedClientHello: + m.echRetryConfigs = make([]byte, len(extData)) + if !extData.CopyBytes(m.echRetryConfigs) { + return false + } default: // Ignore unknown extensions. continue diff --git a/handshake_messages_test.go b/handshake_messages_test.go index 6c083f1..197a1c5 100644 --- a/handshake_messages_test.go +++ b/handshake_messages_test.go @@ -272,6 +272,12 @@ func (*serverHelloMsg) Generate(rand *rand.Rand, size int) reflect.Value { m.selectedIdentityPresent = true m.selectedIdentity = uint16(rand.Intn(0xffff)) } + if rand.Intn(10) > 5 { + m.encryptedClientHello = randomBytes(rand.Intn(50)+1, rand) + } + if rand.Intn(10) > 5 { + m.serverNameAck = rand.Intn(2) == 1 + } return reflect.ValueOf(m) } diff --git a/handshake_test.go b/handshake_test.go index 480e050..57fc761 100644 --- a/handshake_test.go +++ b/handshake_test.go @@ -41,11 +41,12 @@ import ( // reference connection will always change. var ( - update = flag.Bool("update", false, "update golden files on failure") - fast = flag.Bool("fast", false, "impose a quick, possibly flaky timeout on recorded tests") - keyFile = flag.String("keylog", "", "destination file for KeyLogWriter") - bogoMode = flag.Bool("bogo-mode", false, "Enabled bogo shim mode, ignore everything else") - bogoFilter = flag.String("bogo-filter", "", "BoGo test filter") + update = flag.Bool("update", false, "update golden files on failure") + fast = flag.Bool("fast", false, "impose a quick, possibly flaky timeout on recorded tests") + keyFile = flag.String("keylog", "", "destination file for KeyLogWriter") + bogoMode = flag.Bool("bogo-mode", false, "Enabled bogo shim mode, ignore everything else") + bogoFilter = flag.String("bogo-filter", "", "BoGo test filter") + bogoLocalDir = flag.String("bogo-local-dir", "", "Local BoGo to use, instead of fetching from source") ) func runTestAndUpdateIfNeeded(t *testing.T, name string, run func(t *testing.T, update bool), wait bool) { diff --git a/tls_test.go b/tls_test.go index fda3cd3..fc50406 100644 --- a/tls_test.go +++ b/tls_test.go @@ -771,7 +771,7 @@ func TestWarningAlertFlood(t *testing.T) { } func TestCloneFuncFields(t *testing.T) { - const expectedCount = 8 + const expectedCount = 9 called := 0 c1 := Config{ @@ -807,6 +807,10 @@ func TestCloneFuncFields(t *testing.T) { called |= 1 << 7 return nil, nil }, + EncryptedClientHelloRejectionVerify: func(ConnectionState) error { + called |= 1 << 8 + return nil + }, } c2 := c1.Clone() @@ -819,6 +823,7 @@ func TestCloneFuncFields(t *testing.T) { c2.VerifyConnection(ConnectionState{}) c2.UnwrapSession(nil, ConnectionState{}) c2.WrapSession(ConnectionState{}, nil) + c2.EncryptedClientHelloRejectionVerify(ConnectionState{}) if called != (1< Date: Wed, 22 May 2024 22:01:35 -0400 Subject: [PATCH 26/39] crypto/tls: add linkname comments dropped from CL 587220 A bad merge syncing before the submit of CL 587220 dropped these. (I forgot to write the file out.) For #67401. Change-Id: I6f2ba69f388907f3d24eeef55c80cbb2cf51f580 Reviewed-on: https://go-review.googlesource.com/c/go/+/587755 LUCI-TryBot-Result: Go LUCI Reviewed-by: Cherry Mui Reviewed-by: Marten Seemann --- defaults.go | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/defaults.go b/defaults.go index df64def..ef1a613 100644 --- a/defaults.go +++ b/defaults.go @@ -7,6 +7,7 @@ package tls import ( "internal/godebug" "slices" + _ "unsafe" // for linkname ) // Defaults are collected in this file to allow distributions to more easily patch @@ -56,12 +57,31 @@ func defaultCipherSuites() []uint16 { // defaultCipherSuitesTLS13 is also the preference order, since there are no // disabled by default TLS 1.3 cipher suites. The same AES vs ChaCha20 logic as // cipherSuitesPreferenceOrder applies. +// +// defaultCipherSuitesTLS13 should be an internal detail, +// but widely used packages access it using linkname. +// Notable members of the hall of shame include: +// - github.com/quic-go/quic-go +// +// Do not remove or change the type signature. +// See go.dev/issue/67401. +// +//go:linkname defaultCipherSuitesTLS13 var defaultCipherSuitesTLS13 = []uint16{ TLS_AES_128_GCM_SHA256, TLS_AES_256_GCM_SHA384, TLS_CHACHA20_POLY1305_SHA256, } +// defaultCipherSuitesTLS13NoAES should be an internal detail, +// but widely used packages access it using linkname. +// Notable members of the hall of shame include: +// - github.com/quic-go/quic-go +// +// Do not remove or change the type signature. +// See go.dev/issue/67401. +// +//go:linkname defaultCipherSuitesTLS13NoAES var defaultCipherSuitesTLS13NoAES = []uint16{ TLS_CHACHA20_POLY1305_SHA256, TLS_AES_128_GCM_SHA256, From ab6f57c1153cff2c7e9ebade926a0e7242f9815d Mon Sep 17 00:00:00 2001 From: Russ Cox Date: Wed, 22 May 2024 23:06:30 -0400 Subject: [PATCH 27/39] all: document legacy //go:linkname for final round of modules MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Add linknames for most modules with ≥50 dependents. Add linknames for a few other modules that we know are important but are below 50. Remove linknames from badlinkname.go that do not merit inclusion (very small number of dependents). We can add them back later if the need arises. Fixes #67401. (For now.) Change-Id: I1e49fec0292265256044d64b1841d366c4106002 Reviewed-on: https://go-review.googlesource.com/c/go/+/587756 Auto-Submit: Russ Cox TryBot-Bypass: Russ Cox Reviewed-by: Cherry Mui --- badlinkname.go | 23 ----------------------- cipher_suites.go | 2 ++ defaults.go | 2 ++ 3 files changed, 4 insertions(+), 23 deletions(-) delete mode 100644 badlinkname.go diff --git a/badlinkname.go b/badlinkname.go deleted file mode 100644 index 841030a..0000000 --- a/badlinkname.go +++ /dev/null @@ -1,23 +0,0 @@ -// Copyright 2024 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -package tls - -import _ "unsafe" - -// As of Go 1.22, the symbols below are found to be pulled via -// linkname in the wild. We provide a push linkname here, to -// keep them accessible with pull linknames. -// This may change in the future. Please do not depend on them -// in new code. - -//go:linkname cipherSuiteTLS13ByID -//go:linkname errShutdown - -// The compiler doesn't allow linknames on methods, for good reasons. -// We use this trick to push linknames of the methods. -// Do not call them in this package. - -//go:linkname badlinkname_halfConn_incSeq crypto/tls.(*halfConn).incSeq -func badlinkname_halfConn_incSeq(*halfConn) diff --git a/cipher_suites.go b/cipher_suites.go index b2f330b..eebc668 100644 --- a/cipher_suites.go +++ b/cipher_suites.go @@ -202,6 +202,7 @@ type cipherSuiteTLS13 struct { // but widely used packages access it using linkname. // Notable members of the hall of shame include: // - github.com/quic-go/quic-go +// - github.com/sagernet/quic-go // // Do not remove or change the type signature. // See go.dev/issue/67401. @@ -537,6 +538,7 @@ func aeadAESGCM(key, noncePrefix []byte) aead { // but widely used packages access it using linkname. // Notable members of the hall of shame include: // - github.com/xtls/xray-core +// - github.com/v2fly/v2ray-core // // Do not remove or change the type signature. // See go.dev/issue/67401. diff --git a/defaults.go b/defaults.go index ef1a613..9b28acd 100644 --- a/defaults.go +++ b/defaults.go @@ -62,6 +62,7 @@ func defaultCipherSuites() []uint16 { // but widely used packages access it using linkname. // Notable members of the hall of shame include: // - github.com/quic-go/quic-go +// - github.com/sagernet/quic-go // // Do not remove or change the type signature. // See go.dev/issue/67401. @@ -77,6 +78,7 @@ var defaultCipherSuitesTLS13 = []uint16{ // but widely used packages access it using linkname. // Notable members of the hall of shame include: // - github.com/quic-go/quic-go +// - github.com/sagernet/quic-go // // Do not remove or change the type signature. // See go.dev/issue/67401. From 4eb40171ff4865864f0b5186b1654412ec96f85c Mon Sep 17 00:00:00 2001 From: cuishuang Date: Sun, 2 Jun 2024 00:51:35 +0800 Subject: [PATCH 28/39] all: make function comments match function names Change-Id: Ideb9ef00e7bc660b005fc080973fd9f3d36c5a1f Reviewed-on: https://go-review.googlesource.com/c/go/+/589536 TryBot-Result: Gopher Robot Reviewed-by: Michael Knyszek Run-TryBot: shuang cui LUCI-TryBot-Result: Go LUCI Auto-Submit: Ian Lance Taylor Reviewed-by: Ian Lance Taylor --- handshake_server_test.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/handshake_server_test.go b/handshake_server_test.go index bc45a28..44bc8f1 100644 --- a/handshake_server_test.go +++ b/handshake_server_test.go @@ -1078,7 +1078,7 @@ func TestHandshakeServerSNIGetCertificate(t *testing.T) { runServerTestTLS12(t, test) } -// TestHandshakeServerSNICertForNameNotFound is similar to +// TestHandshakeServerSNIGetCertificateNotFound is similar to // TestHandshakeServerSNICertForName, but tests to make sure that when the // GetCertificate method doesn't return a cert, we fall back to what's in // the NameToCertificate map. @@ -1096,7 +1096,7 @@ func TestHandshakeServerSNIGetCertificateNotFound(t *testing.T) { runServerTestTLS12(t, test) } -// TestHandshakeServerSNICertForNameError tests to make sure that errors in +// TestHandshakeServerSNIGetCertificateError tests to make sure that errors in // GetCertificate result in a tls alert. func TestHandshakeServerSNIGetCertificateError(t *testing.T) { const errMsg = "TestHandshakeServerSNIGetCertificateError error" From 93a55ff19ea6bf7a19d19fb6070db3c35eb4c550 Mon Sep 17 00:00:00 2001 From: Roland Shoemaker Date: Thu, 23 May 2024 10:01:09 -0700 Subject: [PATCH 29/39] crypto/tls: better bogo test output handling Use the bogo JSON output format to make the test output more readable. Cq-Include-Trybots: luci.golang.try:gotip-linux-amd64-longtest Change-Id: Ie1a67c6a031bc1d5d8b2cdfaf78d094a0967bc2a Reviewed-on: https://go-review.googlesource.com/c/go/+/587955 Reviewed-by: Michael Knyszek Reviewed-by: Filippo Valsorda LUCI-TryBot-Result: Go LUCI --- bogo_config.json | 7 ----- bogo_shim_test.go | 80 ++++++++++++++++++++++++++++++++++++++--------- 2 files changed, 66 insertions(+), 21 deletions(-) diff --git a/bogo_config.json b/bogo_config.json index 8e4cec2..2363dd5 100644 --- a/bogo_config.json +++ b/bogo_config.json @@ -30,13 +30,6 @@ "TLS-ECH-Client-NoSupportedConfigs": "We don't support fallback to cleartext when there are no valid ECH configs", "TLS-ECH-Client-SkipInvalidPublicName": "We don't support fallback to cleartext when there are no valid ECH configs", - "TLS-ECH-Client-Reject-RandomHRRExtension": "TODO: bogo test cases have mismatching public certificates and public names in ECH configs. Can be removed once bogo fixed", - "TLS-ECH-Client-Reject-UnsupportedRetryConfigs": "TODO: bogo test cases have mismatching public certificates and public names in ECH configs. Can be removed once bogo fixed", - "TLS-ECH-Client-Reject-NoRetryConfigs": "TODO: bogo test cases have mismatching public certificates and public names in ECH configs. Can be removed once bogo fixed", - "TLS-ECH-Client-Reject": "TODO: bogo test cases have mismatching public certificates and public names in ECH configs. Can be removed once bogo fixed", - "TLS-ECH-Client-Reject-HelloRetryRequest": "TODO: bogo test cases have mismatching public certificates and public names in ECH configs. Can be removed once bogo fixed", - "TLS-ECH-Client-Reject-NoClientCertificate-TLS13": "TODO: bogo test cases have mismatching public certificates and public names in ECH configs. Can be removed once bogo fixed", - "TLS-ECH-Client-Reject-OverrideName-TLS13": "TODO: bogo test cases have mismatching public certificates and public names in ECH configs. Can be removed once bogo fixed", "*ECH-Server*": "no ECH server support", "SendV2ClientHello*": "We don't support SSLv2", diff --git a/bogo_shim_test.go b/bogo_shim_test.go index ad5195c..b9db73d 100644 --- a/bogo_shim_test.go +++ b/bogo_shim_test.go @@ -305,8 +305,8 @@ func TestBogoSuite(t *testing.T) { if *bogoLocalDir != "" { bogoDir = *bogoLocalDir } else { - const boringsslModVer = "v0.0.0-20240517213134-ba62c812f01f" - output, err := exec.Command("go", "mod", "download", "-json", "github.com/google/boringssl@"+boringsslModVer).CombinedOutput() + const boringsslModVer = "v0.0.0-20240523173554-273a920f84e8" + output, err := exec.Command("go", "mod", "download", "-json", "boringssl.googlesource.com/boringssl.git@"+boringsslModVer).CombinedOutput() if err != nil { t.Fatalf("failed to download boringssl: %s", err) } @@ -324,6 +324,8 @@ func TestBogoSuite(t *testing.T) { t.Fatal(err) } + resultsFile := filepath.Join(t.TempDir(), "results.json") + args := []string{ "test", ".", @@ -332,8 +334,7 @@ func TestBogoSuite(t *testing.T) { "-shim-extra-flags=-bogo-mode", "-allow-unimplemented", "-loose-errors", // TODO(roland): this should be removed eventually - "-pipe", - "-v", + fmt.Sprintf("-json-output=%s", resultsFile), } if *bogoFilter != "" { args = append(args, fmt.Sprintf("-test=%s", *bogoFilter)) @@ -345,21 +346,72 @@ func TestBogoSuite(t *testing.T) { } cmd := exec.Command(goCmd, args...) out := &strings.Builder{} - cmd.Stdout, cmd.Stderr = io.MultiWriter(os.Stdout, out), os.Stderr + cmd.Stderr = out cmd.Dir = filepath.Join(bogoDir, "ssl/test/runner") err = cmd.Run() - if err != nil { - t.Fatalf("bogo failed: %s", err) + // NOTE: we don't immediately check the error, because the failure could be either because + // the runner failed for some unexpected reason, or because a test case failed, and we + // cannot easily differentiate these cases. We check if the JSON results file was written, + // which should only happen if the failure was because of a test failure, and use that + // to determine the failure mode. + + resultsJSON, jsonErr := os.ReadFile(resultsFile) + if jsonErr != nil { + if err != nil { + t.Fatalf("bogo failed: %s\n%s", err, out) + } + t.Fatalf("failed to read results JSON file: %s", err) } - if *bogoFilter == "" { - assertPass := func(t *testing.T, name string) { - t.Helper() - if !strings.Contains(out.String(), "PASSED ("+name+")\n") { - t.Errorf("Expected test %s did not run", name) + var results bogoResults + if err := json.Unmarshal(resultsJSON, &results); err != nil { + t.Fatalf("failed to parse results JSON: %s", err) + } + + // assertResults contains test results we want to make sure + // are present in the output. They are only checked if -bogo-filter + // was not passed. + assertResults := map[string]string{ + "CurveTest-Client-Kyber-TLS13": "PASS", + "CurveTest-Server-Kyber-TLS13": "PASS", + } + + for name, result := range results.Tests { + // This is not really the intended way to do this... but... it works? + t.Run(name, func(t *testing.T) { + if result.Actual == "FAIL" && result.IsUnexpected { + t.Fatal(result.Error) } + if expectedResult, ok := assertResults[name]; ok && expectedResult != result.Actual { + t.Fatalf("unexpected result: got %s, want %s", result.Actual, assertResults[name]) + } + delete(assertResults, name) + if result.Actual == "SKIP" { + t.Skip() + } + }) + } + if *bogoFilter == "" { + // Anything still in assertResults did not show up in the results, so we should fail + for name, expectedResult := range assertResults { + t.Run(name, func(t *testing.T) { + t.Fatalf("expected test to run with result %s, but it was not present in the test results", expectedResult) + }) } - assertPass(t, "CurveTest-Client-Kyber-TLS13") - assertPass(t, "CurveTest-Server-Kyber-TLS13") } } + +// bogoResults is a copy of boringssl.googlesource.com/boringssl/testresults.Results +type bogoResults struct { + Version int `json:"version"` + Interrupted bool `json:"interrupted"` + PathDelimiter string `json:"path_delimiter"` + SecondsSinceEpoch float64 `json:"seconds_since_epoch"` + NumFailuresByType map[string]int `json:"num_failures_by_type"` + Tests map[string]struct { + Actual string `json:"actual"` + Expected string `json:"expected"` + IsUnexpected bool `json:"is_unexpected"` + Error string `json:"error,omitempty"` + } `json:"tests"` +} From 2b758fa0c8e7968d70f02fc00ea7685c159890e9 Mon Sep 17 00:00:00 2001 From: Roland Shoemaker Date: Wed, 29 May 2024 10:38:15 -0700 Subject: [PATCH 30/39] crypto/tls: fix test caching for bogo Use a stat to tell the test caching infrastructure that we care about the bogo config file. Change-Id: Iae2336bfc45cd6a9e73cb83a3b68ade8b4f23927 Reviewed-on: https://go-review.googlesource.com/c/go/+/589155 LUCI-TryBot-Result: Go LUCI Reviewed-by: Filippo Valsorda Reviewed-by: Michael Knyszek Auto-Submit: Roland Shoemaker --- bogo_shim_test.go | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/bogo_shim_test.go b/bogo_shim_test.go index b9db73d..09b20a1 100644 --- a/bogo_shim_test.go +++ b/bogo_shim_test.go @@ -301,6 +301,14 @@ func TestBogoSuite(t *testing.T) { t.Skip("#66913: windows network connections are flakey on builders") } + // In order to make Go test caching work as expected, we stat the + // bogo_config.json file, so that the Go testing hooks know that it is + // important for this test and will invalidate a cached test result if the + // file changes. + if _, err := os.Stat("bogo_config.json"); err != nil { + t.Fatal(err) + } + var bogoDir string if *bogoLocalDir != "" { bogoDir = *bogoLocalDir From ed714f63924341e0965fb0a00e1a47dbbab7a570 Mon Sep 17 00:00:00 2001 From: Chance Zibolski Date: Fri, 7 Jun 2024 15:24:08 +0000 Subject: [PATCH 31/39] net/http: check GetConfigForClient in server.ServeTLS Just like for tls.Config.GetCertificate the http.Server.ServeTLS method should be checking tls.Config.GetConfigForClient before trying top open the specified certFile/keyFile. This was previously fixed for crypto/tls when using tls.Listen in CL205059, but the same change for net/http was missed. I've added a comment src/crypto/tls/tls.go in the relevant section in the hope that any future changes of a similar nature consider will consider updating net/http as needed as well. Change-Id: I312303bc497d92aa2f4627fe2620c70779cbcc99 GitHub-Last-Rev: 6ed29a900816a13690a9f3e26476d9bc1055a6f7 GitHub-Pull-Request: golang/go#66795 Reviewed-on: https://go-review.googlesource.com/c/go/+/578396 Reviewed-by: Filippo Valsorda Reviewed-by: Damien Neil LUCI-TryBot-Result: Go LUCI Reviewed-by: Cherry Mui --- tls.go | 1 + 1 file changed, 1 insertion(+) diff --git a/tls.go b/tls.go index b30f0b8..f3089f0 100644 --- a/tls.go +++ b/tls.go @@ -87,6 +87,7 @@ func NewListener(inner net.Listener, config *Config) net.Listener { // The configuration config must be non-nil and must include // at least one certificate or else set GetCertificate. func Listen(network, laddr string, config *Config) (net.Listener, error) { + // If this condition changes, consider updating http.Server.ServeTLS too. if config == nil || len(config.Certificates) == 0 && config.GetCertificate == nil && config.GetConfigForClient == nil { return nil, errors.New("tls: neither Certificates, GetCertificate, nor GetConfigForClient set in Config") From a2c0ebe2c2f8552ea7bd36e52747ef7612402edd Mon Sep 17 00:00:00 2001 From: Clide Stefani Date: Fri, 7 Jun 2024 16:37:13 -0400 Subject: [PATCH 32/39] crypto/tls: improve error log produced during TestBogoSuite The existing implementation logs some errors to the results file created in TestBogoSuite. This change would additionally log json errors to the results file. Change-Id: Ib1a6f612ed83f6c5046531ee259c4e85dd71402a Reviewed-on: https://go-review.googlesource.com/c/go/+/591379 Reviewed-by: Filippo Valsorda Auto-Submit: Filippo Valsorda Reviewed-by: Roland Shoemaker Reviewed-by: Michael Pratt LUCI-TryBot-Result: Go LUCI --- bogo_shim_test.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bogo_shim_test.go b/bogo_shim_test.go index 09b20a1..5dc3b7c 100644 --- a/bogo_shim_test.go +++ b/bogo_shim_test.go @@ -368,7 +368,7 @@ func TestBogoSuite(t *testing.T) { if err != nil { t.Fatalf("bogo failed: %s\n%s", err, out) } - t.Fatalf("failed to read results JSON file: %s", err) + t.Fatalf("failed to read results JSON file: %s", jsonErr) } var results bogoResults From f1ed02fbf295444bb2282c000560ebe94273e5e5 Mon Sep 17 00:00:00 2001 From: Clide Stefani Date: Thu, 13 Jun 2024 14:57:12 -0400 Subject: [PATCH 33/39] crypto/tls: add support for -expect-version to bogo_shim_test The existing implementation of bogo_shim_test does not support tests that use the expect-version flag. This change adds support for this flag. Updates #51434. Change-Id: Ie23fdb06d15ec0593ca58f28144e83f93ef7f200 Reviewed-on: https://go-review.googlesource.com/c/go/+/592635 Auto-Submit: Roland Shoemaker LUCI-TryBot-Result: Go LUCI Reviewed-by: Roland Shoemaker Reviewed-by: David Chase --- bogo_shim_test.go | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/bogo_shim_test.go b/bogo_shim_test.go index 5dc3b7c..2d8100d 100644 --- a/bogo_shim_test.go +++ b/bogo_shim_test.go @@ -33,8 +33,9 @@ var ( trustCert = flag.String("trust-cert", "", "") - minVersion = flag.Int("min-version", VersionSSL30, "") - maxVersion = flag.Int("max-version", VersionTLS13, "") + minVersion = flag.Int("min-version", VersionSSL30, "") + maxVersion = flag.Int("max-version", VersionTLS13, "") + expectVersion = flag.Int("expect-version", 0, "") noTLS13 = flag.Bool("no-tls13", false, "") @@ -252,7 +253,9 @@ func bogoShim() { if *expectALPN != "" && cs.NegotiatedProtocol != *expectALPN { log.Fatalf("unexpected protocol negotiated: want %q, got %q", *expectALPN, cs.NegotiatedProtocol) } - + if *expectVersion != 0 && cs.Version != uint16(*expectVersion) { + log.Fatalf("expected ssl version %q, got %q", uint16(*expectVersion), cs.Version) + } if *expectECHAccepted && !cs.ECHAccepted { log.Fatal("expected ECH to be accepted, but connection state shows it was not") } else if i == 0 && *onInitialExpectECHAccepted && !cs.ECHAccepted { From 861b74c00ca12cd5176ba72402fe3d6a75a231ac Mon Sep 17 00:00:00 2001 From: Filippo Valsorda Date: Sun, 23 Jun 2024 14:10:14 +0200 Subject: [PATCH 34/39] crypto/tls: replay test recordings without network There is no reason to go across a pipe when replaying a conn recording. This avoids the complexity of using localPipe and goroutines, and makes handshake benchmarks more accurate, as we don't measure network overhead. Also note how it removes the need for -fast: operating locally we know when the flow is over and can error out immediately, without waiting for a read from the feeder on the other side of the pipe to timeout. Avoids some noise in #67979, but doesn't fix the two root causes: localPipe flakes and testing.B races. Updates #67979 Change-Id: I153d3fa5a24847f3947823e8c3a7bc639f89bc1d Reviewed-on: https://go-review.googlesource.com/c/go/+/594255 Auto-Submit: Filippo Valsorda LUCI-TryBot-Result: Go LUCI Reviewed-by: Roland Shoemaker Reviewed-by: Joedian Reid --- handshake_client_test.go | 276 +++++++++++++++++---------------------- handshake_server_test.go | 95 +++----------- handshake_test.go | 72 +++++++++- 3 files changed, 210 insertions(+), 233 deletions(-) diff --git a/handshake_client_test.go b/handshake_client_test.go index 4570f5b..501f9c6 100644 --- a/handshake_client_test.go +++ b/handshake_client_test.go @@ -283,7 +283,7 @@ func (test *clientTest) loadData() (flows [][]byte, err error) { } func (test *clientTest) run(t *testing.T, write bool) { - var clientConn, serverConn net.Conn + var clientConn net.Conn var recordingConn *recordingConn var childProcess *exec.Cmd var stdin opensslInput @@ -302,178 +302,138 @@ func (test *clientTest) run(t *testing.T, write bool) { } }() } else { - clientConn, serverConn = localPipe(t) + flows, err := test.loadData() + if err != nil { + t.Fatalf("failed to load data from %s: %v", test.dataPath(), err) + } + clientConn = &replayingConn{t: t, flows: flows, reading: false} } - doneChan := make(chan bool) - defer func() { - clientConn.Close() - <-doneChan - }() - go func() { - defer close(doneChan) + config := test.config + if config == nil { + config = testConfig + } + client := Client(clientConn, config) + defer client.Close() - config := test.config - if config == nil { - config = testConfig + if _, err := client.Write([]byte("hello\n")); err != nil { + t.Errorf("Client.Write failed: %s", err) + return + } + + for i := 1; i <= test.numRenegotiations; i++ { + // The initial handshake will generate a + // handshakeComplete signal which needs to be quashed. + if i == 1 && write { + <-stdout.handshakeComplete } - client := Client(clientConn, config) - defer client.Close() - if _, err := client.Write([]byte("hello\n")); err != nil { + // OpenSSL will try to interleave application data and + // a renegotiation if we send both concurrently. + // Therefore: ask OpensSSL to start a renegotiation, run + // a goroutine to call client.Read and thus process the + // renegotiation request, watch for OpenSSL's stdout to + // indicate that the handshake is complete and, + // finally, have OpenSSL write something to cause + // client.Read to complete. + if write { + stdin <- opensslRenegotiate + } + + signalChan := make(chan struct{}) + + go func() { + defer close(signalChan) + + buf := make([]byte, 256) + n, err := client.Read(buf) + + if test.checkRenegotiationError != nil { + newErr := test.checkRenegotiationError(i, err) + if err != nil && newErr == nil { + return + } + err = newErr + } + + if err != nil { + t.Errorf("Client.Read failed after renegotiation #%d: %s", i, err) + return + } + + buf = buf[:n] + if !bytes.Equal([]byte(opensslSentinel), buf) { + t.Errorf("Client.Read returned %q, but wanted %q", string(buf), opensslSentinel) + } + + if expected := i + 1; client.handshakes != expected { + t.Errorf("client should have recorded %d handshakes, but believes that %d have occurred", expected, client.handshakes) + } + }() + + if write && test.renegotiationExpectedToFail != i { + <-stdout.handshakeComplete + stdin <- opensslSendSentinel + } + <-signalChan + } + + if test.sendKeyUpdate { + if write { + <-stdout.handshakeComplete + stdin <- opensslKeyUpdate + } + + doneRead := make(chan struct{}) + + go func() { + defer close(doneRead) + + buf := make([]byte, 256) + n, err := client.Read(buf) + + if err != nil { + t.Errorf("Client.Read failed after KeyUpdate: %s", err) + return + } + + buf = buf[:n] + if !bytes.Equal([]byte(opensslSentinel), buf) { + t.Errorf("Client.Read returned %q, but wanted %q", string(buf), opensslSentinel) + } + }() + + if write { + // There's no real reason to wait for the client KeyUpdate to + // send data with the new server keys, except that s_server + // drops writes if they are sent at the wrong time. + <-stdout.readKeyUpdate + stdin <- opensslSendSentinel + } + <-doneRead + + if _, err := client.Write([]byte("hello again\n")); err != nil { t.Errorf("Client.Write failed: %s", err) return } + } - for i := 1; i <= test.numRenegotiations; i++ { - // The initial handshake will generate a - // handshakeComplete signal which needs to be quashed. - if i == 1 && write { - <-stdout.handshakeComplete - } - - // OpenSSL will try to interleave application data and - // a renegotiation if we send both concurrently. - // Therefore: ask OpensSSL to start a renegotiation, run - // a goroutine to call client.Read and thus process the - // renegotiation request, watch for OpenSSL's stdout to - // indicate that the handshake is complete and, - // finally, have OpenSSL write something to cause - // client.Read to complete. - if write { - stdin <- opensslRenegotiate - } - - signalChan := make(chan struct{}) - - go func() { - defer close(signalChan) - - buf := make([]byte, 256) - n, err := client.Read(buf) - - if test.checkRenegotiationError != nil { - newErr := test.checkRenegotiationError(i, err) - if err != nil && newErr == nil { - return - } - err = newErr - } - - if err != nil { - t.Errorf("Client.Read failed after renegotiation #%d: %s", i, err) - return - } - - buf = buf[:n] - if !bytes.Equal([]byte(opensslSentinel), buf) { - t.Errorf("Client.Read returned %q, but wanted %q", string(buf), opensslSentinel) - } - - if expected := i + 1; client.handshakes != expected { - t.Errorf("client should have recorded %d handshakes, but believes that %d have occurred", expected, client.handshakes) - } - }() - - if write && test.renegotiationExpectedToFail != i { - <-stdout.handshakeComplete - stdin <- opensslSendSentinel - } - <-signalChan - } - - if test.sendKeyUpdate { - if write { - <-stdout.handshakeComplete - stdin <- opensslKeyUpdate - } - - doneRead := make(chan struct{}) - - go func() { - defer close(doneRead) - - buf := make([]byte, 256) - n, err := client.Read(buf) - - if err != nil { - t.Errorf("Client.Read failed after KeyUpdate: %s", err) - return - } - - buf = buf[:n] - if !bytes.Equal([]byte(opensslSentinel), buf) { - t.Errorf("Client.Read returned %q, but wanted %q", string(buf), opensslSentinel) - } - }() - - if write { - // There's no real reason to wait for the client KeyUpdate to - // send data with the new server keys, except that s_server - // drops writes if they are sent at the wrong time. - <-stdout.readKeyUpdate - stdin <- opensslSendSentinel - } - <-doneRead - - if _, err := client.Write([]byte("hello again\n")); err != nil { - t.Errorf("Client.Write failed: %s", err) - return - } - } - - if test.validate != nil { - if err := test.validate(client.ConnectionState()); err != nil { - t.Errorf("validate callback returned error: %s", err) - } - } - - // If the server sent us an alert after our last flight, give it a - // chance to arrive. - if write && test.renegotiationExpectedToFail == 0 { - if err := peekError(client); err != nil { - t.Errorf("final Read returned an error: %s", err) - } - } - }() - - if !write { - flows, err := test.loadData() - if err != nil { - t.Fatalf("%s: failed to load data from %s: %v", test.name, test.dataPath(), err) - } - for i, b := range flows { - if i%2 == 1 { - if *fast { - serverConn.SetWriteDeadline(time.Now().Add(1 * time.Second)) - } else { - serverConn.SetWriteDeadline(time.Now().Add(1 * time.Minute)) - } - serverConn.Write(b) - continue - } - bb := make([]byte, len(b)) - if *fast { - serverConn.SetReadDeadline(time.Now().Add(1 * time.Second)) - } else { - serverConn.SetReadDeadline(time.Now().Add(1 * time.Minute)) - } - _, err := io.ReadFull(serverConn, bb) - if err != nil { - t.Fatalf("%s, flow %d: %s", test.name, i+1, err) - } - if !bytes.Equal(b, bb) { - t.Fatalf("%s, flow %d: mismatch on read: got:%x want:%x", test.name, i+1, bb, b) - } + if test.validate != nil { + if err := test.validate(client.ConnectionState()); err != nil { + t.Errorf("validate callback returned error: %s", err) } } - <-doneChan - if !write { - serverConn.Close() + // If the server sent us an alert after our last flight, give it a + // chance to arrive. + if write && test.renegotiationExpectedToFail == 0 { + if err := peekError(client); err != nil { + t.Errorf("final Read returned an error: %s", err) + } } if write { + clientConn.Close() path := test.dataPath() out, err := os.OpenFile(path, os.O_WRONLY|os.O_CREATE|os.O_TRUNC, 0644) if err != nil { diff --git a/handshake_server_test.go b/handshake_server_test.go index 44bc8f1..94d3d0f 100644 --- a/handshake_server_test.go +++ b/handshake_server_test.go @@ -21,6 +21,7 @@ import ( "os/exec" "path/filepath" "runtime" + "slices" "strings" "testing" "time" @@ -659,7 +660,7 @@ func (test *serverTest) loadData() (flows [][]byte, err error) { } func (test *serverTest) run(t *testing.T, write bool) { - var clientConn, serverConn net.Conn + var serverConn net.Conn var recordingConn *recordingConn var childProcess *exec.Cmd @@ -676,65 +677,33 @@ func (test *serverTest) run(t *testing.T, write bool) { } }() } else { - clientConn, serverConn = localPipe(t) + flows, err := test.loadData() + if err != nil { + t.Fatalf("Failed to load data from %s", test.dataPath()) + } + serverConn = &replayingConn{t: t, flows: flows, reading: true} } config := test.config if config == nil { config = testConfig } server := Server(serverConn, config) - connStateChan := make(chan ConnectionState, 1) - go func() { - _, err := server.Write([]byte("hello, world\n")) - if len(test.expectHandshakeErrorIncluding) > 0 { - if err == nil { - t.Errorf("Error expected, but no error returned") - } else if s := err.Error(); !strings.Contains(s, test.expectHandshakeErrorIncluding) { - t.Errorf("Error expected containing '%s' but got '%s'", test.expectHandshakeErrorIncluding, s) - } - } else { - if err != nil { - t.Logf("Error from Server.Write: '%s'", err) - } - } - server.Close() - serverConn.Close() - connStateChan <- server.ConnectionState() - }() - if !write { - flows, err := test.loadData() + _, err := server.Write([]byte("hello, world\n")) + if len(test.expectHandshakeErrorIncluding) > 0 { + if err == nil { + t.Errorf("Error expected, but no error returned") + } else if s := err.Error(); !strings.Contains(s, test.expectHandshakeErrorIncluding) { + t.Errorf("Error expected containing '%s' but got '%s'", test.expectHandshakeErrorIncluding, s) + } + } else { if err != nil { - t.Fatalf("%s: failed to load data from %s", test.name, test.dataPath()) + t.Logf("Error from Server.Write: '%s'", err) } - for i, b := range flows { - if i%2 == 0 { - if *fast { - clientConn.SetWriteDeadline(time.Now().Add(1 * time.Second)) - } else { - clientConn.SetWriteDeadline(time.Now().Add(1 * time.Minute)) - } - clientConn.Write(b) - continue - } - bb := make([]byte, len(b)) - if *fast { - clientConn.SetReadDeadline(time.Now().Add(1 * time.Second)) - } else { - clientConn.SetReadDeadline(time.Now().Add(1 * time.Minute)) - } - n, err := io.ReadFull(clientConn, bb) - if err != nil { - t.Fatalf("%s #%d: %s\nRead %d, wanted %d, got %x, wanted %x\n", test.name, i+1, err, n, len(bb), bb[:n], b) - } - if !bytes.Equal(b, bb) { - t.Fatalf("%s #%d: mismatch on read: got:%x want:%x", test.name, i+1, bb, b) - } - } - clientConn.Close() } + server.Close() - connState := <-connStateChan + connState := server.ConnectionState() peerCerts := connState.PeerCertificates if len(peerCerts) == len(test.expectedPeerCerts) { for i, peerCert := range peerCerts { @@ -754,6 +723,7 @@ func (test *serverTest) run(t *testing.T, write bool) { } if write { + serverConn.Close() path := test.dataPath() out, err := os.OpenFile(path, os.O_WRONLY|os.O_CREATE|os.O_TRUNC, 0644) if err != nil { @@ -1330,37 +1300,14 @@ func benchmarkHandshakeServer(b *testing.B, version uint16, cipherSuite uint16, serverConn.Close() flows := serverConn.(*recordingConn).flows - feeder := make(chan struct{}) - clientConn, serverConn = localPipe(b) - - go func() { - for range feeder { - for i, f := range flows { - if i%2 == 0 { - clientConn.Write(f) - continue - } - ff := make([]byte, len(f)) - n, err := io.ReadFull(clientConn, ff) - if err != nil { - b.Errorf("#%d: %s\nRead %d, wanted %d, got %x, wanted %x\n", i+1, err, n, len(ff), ff[:n], f) - } - if !bytes.Equal(f, ff) { - b.Errorf("#%d: mismatch on read: got:%x want:%x", i+1, ff, f) - } - } - } - }() - b.ResetTimer() for i := 0; i < b.N; i++ { - feeder <- struct{}{} - server := Server(serverConn, config) + replay := &replayingConn{t: b, flows: slices.Clone(flows), reading: true} + server := Server(replay, config) if err := server.Handshake(); err != nil { b.Fatalf("handshake failed: %v", err) } } - close(feeder) } func BenchmarkHandshakeServer(b *testing.B) { diff --git a/handshake_test.go b/handshake_test.go index 57fc761..bc3d23d 100644 --- a/handshake_test.go +++ b/handshake_test.go @@ -6,6 +6,7 @@ package tls import ( "bufio" + "bytes" "crypto/ed25519" "crypto/x509" "encoding/hex" @@ -42,7 +43,6 @@ import ( var ( update = flag.Bool("update", false, "update golden files on failure") - fast = flag.Bool("fast", false, "impose a quick, possibly flaky timeout on recorded tests") keyFile = flag.String("keylog", "", "destination file for KeyLogWriter") bogoMode = flag.Bool("bogo-mode", false, "Enabled bogo shim mode, ignore everything else") bogoFilter = flag.String("bogo-filter", "", "BoGo test filter") @@ -223,6 +223,76 @@ func parseTestData(r io.Reader) (flows [][]byte, err error) { return flows, nil } +// replayingConn is a net.Conn that replays flows recorded by recordingConn. +type replayingConn struct { + t testing.TB + sync.Mutex + flows [][]byte + reading bool +} + +var _ net.Conn = (*replayingConn)(nil) + +func (r *replayingConn) Read(b []byte) (n int, err error) { + r.Lock() + defer r.Unlock() + + if !r.reading { + r.t.Errorf("expected write, got read") + return 0, fmt.Errorf("recording expected write, got read") + } + + n = copy(b, r.flows[0]) + r.flows[0] = r.flows[0][n:] + if len(r.flows[0]) == 0 { + r.flows = r.flows[1:] + if len(r.flows) == 0 { + return n, io.EOF + } else { + r.reading = false + } + } + return n, nil +} + +func (r *replayingConn) Write(b []byte) (n int, err error) { + r.Lock() + defer r.Unlock() + + if r.reading { + r.t.Errorf("expected read, got write") + return 0, fmt.Errorf("recording expected read, got write") + } + + if !bytes.HasPrefix(r.flows[0], b) { + r.t.Errorf("write mismatch: expected %x, got %x", r.flows[0], b) + return 0, fmt.Errorf("write mismatch") + } + r.flows[0] = r.flows[0][len(b):] + if len(r.flows[0]) == 0 { + r.flows = r.flows[1:] + r.reading = true + } + return len(b), nil +} + +func (r *replayingConn) Close() error { + r.Lock() + defer r.Unlock() + + if len(r.flows) > 0 { + r.t.Errorf("closed with unfinished flows") + return fmt.Errorf("unexpected close") + } + return nil +} + +func (r *replayingConn) LocalAddr() net.Addr { return nil } +func (r *replayingConn) RemoteAddr() net.Addr { return nil } +func (r *replayingConn) SetDeadline(t time.Time) error { return nil } +func (r *replayingConn) SetReadDeadline(t time.Time) error { return nil } +func (r *replayingConn) SetWriteDeadline(t time.Time) error { return nil } + // tempFile creates a temp file containing contents and returns its path. func tempFile(contents string) string { file, err := os.CreateTemp("", "go-tls-test") From 8b177082b2b3c857ec7bcb63891c1a1c24a6175e Mon Sep 17 00:00:00 2001 From: Damien Neil Date: Mon, 24 Jun 2024 10:01:47 -0700 Subject: [PATCH 35/39] crypto/tls: apply QUIC session event flag to QUICResumeSession events Go 1.23 adds two new events to QUICConns: QUICStoreSessionEvent and QUICResumeSessionEvent. We added a QUICConfig.EnableStoreSessionEvent flag to control whether the store-session event is provided or not, because receiving this event requires additional action from the caller: the session must be explicitly stored with QUICConn.StoreSession. We did not add a control for whether the resume-session event is provided, because this event requires no action and the caller is expected to ignore unknown events. However, we never documented the expectation that callers ignore unknown events, and quic-go produces an error when receiving an unexpected event. So change the EnableStoreSessionEvent flag to apply to both new events. Fixes #68124 For #63691 Change-Id: I84af487e52b3815f7b648e09884608f8915cd645 Reviewed-on: https://go-review.googlesource.com/c/go/+/594475 Reviewed-by: Marten Seemann LUCI-TryBot-Result: Go LUCI Reviewed-by: Roland Shoemaker --- handshake_client.go | 4 +- handshake_client_tls13.go | 2 +- handshake_server_tls13.go | 2 +- quic.go | 16 ++-- quic_test.go | 156 +++++++++++++++++++++----------------- 5 files changed, 98 insertions(+), 82 deletions(-) diff --git a/handshake_client.go b/handshake_client.go index 553d2dd..5025657 100644 --- a/handshake_client.go +++ b/handshake_client.go @@ -478,7 +478,9 @@ func (c *Conn) loadSession(hello *clientHelloMsg) ( } if c.quic != nil { - c.quicResumeSession(session) + if c.quic.enableSessionEvents { + c.quicResumeSession(session) + } // For 0-RTT, the cipher suite has to match exactly, and we need to be // offering the same ALPN. diff --git a/handshake_client_tls13.go b/handshake_client_tls13.go index 6744e71..db5e35d 100644 --- a/handshake_client_tls13.go +++ b/handshake_client_tls13.go @@ -900,7 +900,7 @@ func (c *Conn) handleNewSessionTicket(msg *newSessionTicketMsgTLS13) error { session.ageAdd = msg.ageAdd session.EarlyData = c.quic != nil && msg.maxEarlyData == 0xffffffff // RFC 9001, Section 4.6.1 session.ticket = msg.label - if c.quic != nil && c.quic.enableStoreSessionEvent { + if c.quic != nil && c.quic.enableSessionEvents { c.quicStoreSession(session) return nil } diff --git a/handshake_server_tls13.go b/handshake_server_tls13.go index f24c267..503a732 100644 --- a/handshake_server_tls13.go +++ b/handshake_server_tls13.go @@ -377,7 +377,7 @@ func (hs *serverHandshakeStateTLS13) checkForResumption() error { continue } - if c.quic != nil { + if c.quic != nil && c.quic.enableSessionEvents { if err := c.quicResumeSession(sessionState); err != nil { return err } diff --git a/quic.go b/quic.go index 8e722c6..9dd6168 100644 --- a/quic.go +++ b/quic.go @@ -50,12 +50,12 @@ type QUICConn struct { type QUICConfig struct { TLSConfig *Config - // EnableStoreSessionEvent may be set to true to enable the - // [QUICStoreSession] event for client connections. + // EnableSessionEvents may be set to true to enable the + // [QUICStoreSession] and [QUICResumeSession] events for client connections. // When this event is enabled, sessions are not automatically // stored in the client session cache. // The application should use [QUICConn.StoreSession] to store sessions. - EnableStoreSessionEvent bool + EnableSessionEvents bool } // A QUICEventKind is a type of operation on a QUIC connection. @@ -113,7 +113,7 @@ const ( // QUICStoreSession indicates that the server has provided state permitting // the client to resume the session. // [QUICEvent.SessionState] is set. - // The application should use [QUICConn.Store] session to store the [SessionState]. + // The application should use [QUICConn.StoreSession] session to store the [SessionState]. // The application may modify the [SessionState] before storing it. // This event only occurs on client connections. QUICStoreSession @@ -165,7 +165,7 @@ type quicState struct { transportParams []byte // to send to the peer - enableStoreSessionEvent bool + enableSessionEvents bool } // QUICClient returns a new TLS client side connection using QUICTransport as the @@ -186,9 +186,9 @@ func QUICServer(config *QUICConfig) *QUICConn { func newQUICConn(conn *Conn, config *QUICConfig) *QUICConn { conn.quic = &quicState{ - signalc: make(chan struct{}), - blockedc: make(chan struct{}), - enableStoreSessionEvent: config.EnableStoreSessionEvent, + signalc: make(chan struct{}), + blockedc: make(chan struct{}), + enableSessionEvents: config.EnableSessionEvents, } conn.quic.events = conn.quic.eventArr[:0] return &QUICConn{ diff --git a/quic_test.go b/quic_test.go index 5a6f66e..1bb2e55 100644 --- a/quic_test.go +++ b/quic_test.go @@ -24,22 +24,22 @@ type testQUICConn struct { complete bool } -func newTestQUICClient(t *testing.T, config *Config) *testQUICConn { - q := &testQUICConn{t: t} - q.conn = QUICClient(&QUICConfig{ - TLSConfig: config, - }) +func newTestQUICClient(t *testing.T, config *QUICConfig) *testQUICConn { + q := &testQUICConn{ + t: t, + conn: QUICClient(config), + } t.Cleanup(func() { q.conn.Close() }) return q } -func newTestQUICServer(t *testing.T, config *Config) *testQUICConn { - q := &testQUICConn{t: t} - q.conn = QUICServer(&QUICConfig{ - TLSConfig: config, - }) +func newTestQUICServer(t *testing.T, config *QUICConfig) *testQUICConn { + q := &testQUICConn{ + t: t, + conn: QUICServer(config), + } t.Cleanup(func() { q.conn.Close() }) @@ -140,6 +140,11 @@ func runTestQUICConnection(ctx context.Context, cli, srv *testQUICConn, onEvent return err } } + case QUICStoreSession: + if a != cli { + return errors.New("unexpected QUICStoreSession event received by server") + } + a.conn.StoreSession(e.SessionState) case QUICResumeSession: if a.onResumeSession != nil { a.onResumeSession(e.SessionState) @@ -154,8 +159,8 @@ func runTestQUICConnection(ctx context.Context, cli, srv *testQUICConn, onEvent } func TestQUICConnection(t *testing.T) { - config := testConfig.Clone() - config.MinVersion = VersionTLS13 + config := &QUICConfig{TLSConfig: testConfig.Clone()} + config.TLSConfig.MinVersion = VersionTLS13 cli := newTestQUICClient(t, config) cli.conn.SetTransportParameters(nil) @@ -196,13 +201,13 @@ func TestQUICConnection(t *testing.T) { } func TestQUICSessionResumption(t *testing.T) { - clientConfig := testConfig.Clone() - clientConfig.MinVersion = VersionTLS13 - clientConfig.ClientSessionCache = NewLRUClientSessionCache(1) - clientConfig.ServerName = "example.go.dev" + clientConfig := &QUICConfig{TLSConfig: testConfig.Clone()} + clientConfig.TLSConfig.MinVersion = VersionTLS13 + clientConfig.TLSConfig.ClientSessionCache = NewLRUClientSessionCache(1) + clientConfig.TLSConfig.ServerName = "example.go.dev" - serverConfig := testConfig.Clone() - serverConfig.MinVersion = VersionTLS13 + serverConfig := &QUICConfig{TLSConfig: testConfig.Clone()} + serverConfig.TLSConfig.MinVersion = VersionTLS13 cli := newTestQUICClient(t, clientConfig) cli.conn.SetTransportParameters(nil) @@ -228,13 +233,13 @@ func TestQUICSessionResumption(t *testing.T) { } func TestQUICFragmentaryData(t *testing.T) { - clientConfig := testConfig.Clone() - clientConfig.MinVersion = VersionTLS13 - clientConfig.ClientSessionCache = NewLRUClientSessionCache(1) - clientConfig.ServerName = "example.go.dev" + clientConfig := &QUICConfig{TLSConfig: testConfig.Clone()} + clientConfig.TLSConfig.MinVersion = VersionTLS13 + clientConfig.TLSConfig.ClientSessionCache = NewLRUClientSessionCache(1) + clientConfig.TLSConfig.ServerName = "example.go.dev" - serverConfig := testConfig.Clone() - serverConfig.MinVersion = VersionTLS13 + serverConfig := &QUICConfig{TLSConfig: testConfig.Clone()} + serverConfig.TLSConfig.MinVersion = VersionTLS13 cli := newTestQUICClient(t, clientConfig) cli.conn.SetTransportParameters(nil) @@ -260,8 +265,8 @@ func TestQUICFragmentaryData(t *testing.T) { func TestQUICPostHandshakeClientAuthentication(t *testing.T) { // RFC 9001, Section 4.4. - config := testConfig.Clone() - config.MinVersion = VersionTLS13 + config := &QUICConfig{TLSConfig: testConfig.Clone()} + config.TLSConfig.MinVersion = VersionTLS13 cli := newTestQUICClient(t, config) cli.conn.SetTransportParameters(nil) srv := newTestQUICServer(t, config) @@ -288,8 +293,8 @@ func TestQUICPostHandshakeClientAuthentication(t *testing.T) { func TestQUICPostHandshakeKeyUpdate(t *testing.T) { // RFC 9001, Section 6. - config := testConfig.Clone() - config.MinVersion = VersionTLS13 + config := &QUICConfig{TLSConfig: testConfig.Clone()} + config.TLSConfig.MinVersion = VersionTLS13 cli := newTestQUICClient(t, config) cli.conn.SetTransportParameters(nil) srv := newTestQUICServer(t, config) @@ -312,8 +317,8 @@ func TestQUICPostHandshakeKeyUpdate(t *testing.T) { } func TestQUICPostHandshakeMessageTooLarge(t *testing.T) { - config := testConfig.Clone() - config.MinVersion = VersionTLS13 + config := &QUICConfig{TLSConfig: testConfig.Clone()} + config.TLSConfig.MinVersion = VersionTLS13 cli := newTestQUICClient(t, config) cli.conn.SetTransportParameters(nil) srv := newTestQUICServer(t, config) @@ -334,13 +339,13 @@ func TestQUICPostHandshakeMessageTooLarge(t *testing.T) { } func TestQUICHandshakeError(t *testing.T) { - clientConfig := testConfig.Clone() - clientConfig.MinVersion = VersionTLS13 - clientConfig.InsecureSkipVerify = false - clientConfig.ServerName = "name" + clientConfig := &QUICConfig{TLSConfig: testConfig.Clone()} + clientConfig.TLSConfig.MinVersion = VersionTLS13 + clientConfig.TLSConfig.InsecureSkipVerify = false + clientConfig.TLSConfig.ServerName = "name" - serverConfig := testConfig.Clone() - serverConfig.MinVersion = VersionTLS13 + serverConfig := &QUICConfig{TLSConfig: testConfig.Clone()} + serverConfig.TLSConfig.MinVersion = VersionTLS13 cli := newTestQUICClient(t, clientConfig) cli.conn.SetTransportParameters(nil) @@ -360,9 +365,9 @@ func TestQUICHandshakeError(t *testing.T) { // and that it reports the application protocol as soon as it has been // negotiated. func TestQUICConnectionState(t *testing.T) { - config := testConfig.Clone() - config.MinVersion = VersionTLS13 - config.NextProtos = []string{"h3"} + config := &QUICConfig{TLSConfig: testConfig.Clone()} + config.TLSConfig.MinVersion = VersionTLS13 + config.TLSConfig.NextProtos = []string{"h3"} cli := newTestQUICClient(t, config) cli.conn.SetTransportParameters(nil) srv := newTestQUICServer(t, config) @@ -391,10 +396,10 @@ func TestQUICStartContextPropagation(t *testing.T) { const key = "key" const value = "value" ctx := context.WithValue(context.Background(), key, value) - config := testConfig.Clone() - config.MinVersion = VersionTLS13 + config := &QUICConfig{TLSConfig: testConfig.Clone()} + config.TLSConfig.MinVersion = VersionTLS13 calls := 0 - config.GetConfigForClient = func(info *ClientHelloInfo) (*Config, error) { + config.TLSConfig.GetConfigForClient = func(info *ClientHelloInfo) (*Config, error) { calls++ got, _ := info.Context().Value(key).(string) if got != value { @@ -415,13 +420,13 @@ func TestQUICStartContextPropagation(t *testing.T) { } func TestQUICDelayedTransportParameters(t *testing.T) { - clientConfig := testConfig.Clone() - clientConfig.MinVersion = VersionTLS13 - clientConfig.ClientSessionCache = NewLRUClientSessionCache(1) - clientConfig.ServerName = "example.go.dev" + clientConfig := &QUICConfig{TLSConfig: testConfig.Clone()} + clientConfig.TLSConfig.MinVersion = VersionTLS13 + clientConfig.TLSConfig.ClientSessionCache = NewLRUClientSessionCache(1) + clientConfig.TLSConfig.ServerName = "example.go.dev" - serverConfig := testConfig.Clone() - serverConfig.MinVersion = VersionTLS13 + serverConfig := &QUICConfig{TLSConfig: testConfig.Clone()} + serverConfig.TLSConfig.MinVersion = VersionTLS13 cliParams := "client params" srvParams := "server params" @@ -449,8 +454,8 @@ func TestQUICDelayedTransportParameters(t *testing.T) { } func TestQUICEmptyTransportParameters(t *testing.T) { - config := testConfig.Clone() - config.MinVersion = VersionTLS13 + config := &QUICConfig{TLSConfig: testConfig.Clone()} + config.TLSConfig.MinVersion = VersionTLS13 cli := newTestQUICClient(t, config) cli.conn.SetTransportParameters(nil) @@ -475,8 +480,8 @@ func TestQUICEmptyTransportParameters(t *testing.T) { } func TestQUICCanceledWaitingForData(t *testing.T) { - config := testConfig.Clone() - config.MinVersion = VersionTLS13 + config := &QUICConfig{TLSConfig: testConfig.Clone()} + config.TLSConfig.MinVersion = VersionTLS13 cli := newTestQUICClient(t, config) cli.conn.SetTransportParameters(nil) cli.conn.Start(context.Background()) @@ -489,8 +494,8 @@ func TestQUICCanceledWaitingForData(t *testing.T) { } func TestQUICCanceledWaitingForTransportParams(t *testing.T) { - config := testConfig.Clone() - config.MinVersion = VersionTLS13 + config := &QUICConfig{TLSConfig: testConfig.Clone()} + config.TLSConfig.MinVersion = VersionTLS13 cli := newTestQUICClient(t, config) cli.conn.Start(context.Background()) for cli.conn.NextEvent().Kind != QUICTransportParametersRequired { @@ -502,15 +507,15 @@ func TestQUICCanceledWaitingForTransportParams(t *testing.T) { } func TestQUICEarlyData(t *testing.T) { - clientConfig := testConfig.Clone() - clientConfig.MinVersion = VersionTLS13 - clientConfig.ClientSessionCache = NewLRUClientSessionCache(1) - clientConfig.ServerName = "example.go.dev" - clientConfig.NextProtos = []string{"h3"} + clientConfig := &QUICConfig{TLSConfig: testConfig.Clone()} + clientConfig.TLSConfig.MinVersion = VersionTLS13 + clientConfig.TLSConfig.ClientSessionCache = NewLRUClientSessionCache(1) + clientConfig.TLSConfig.ServerName = "example.go.dev" + clientConfig.TLSConfig.NextProtos = []string{"h3"} - serverConfig := testConfig.Clone() - serverConfig.MinVersion = VersionTLS13 - serverConfig.NextProtos = []string{"h3"} + serverConfig := &QUICConfig{TLSConfig: testConfig.Clone()} + serverConfig.TLSConfig.MinVersion = VersionTLS13 + serverConfig.TLSConfig.NextProtos = []string{"h3"} cli := newTestQUICClient(t, clientConfig) cli.conn.SetTransportParameters(nil) @@ -528,7 +533,14 @@ func TestQUICEarlyData(t *testing.T) { cli2.conn.SetTransportParameters(nil) srv2 := newTestQUICServer(t, serverConfig) srv2.conn.SetTransportParameters(nil) - if err := runTestQUICConnection(context.Background(), cli2, srv2, nil); err != nil { + onEvent := func(e QUICEvent, src, dst *testQUICConn) bool { + switch e.Kind { + case QUICStoreSession, QUICResumeSession: + t.Errorf("with EnableSessionEvents=false, got unexpected event %v", e.Kind) + } + return false + } + if err := runTestQUICConnection(context.Background(), cli2, srv2, onEvent); err != nil { t.Fatalf("error during second connection handshake: %v", err) } if !cli2.conn.ConnectionState().DidResume { @@ -557,15 +569,17 @@ func TestQUICEarlyDataDeclined(t *testing.T) { } func testQUICEarlyDataDeclined(t *testing.T, server bool) { - clientConfig := testConfig.Clone() - clientConfig.MinVersion = VersionTLS13 - clientConfig.ClientSessionCache = NewLRUClientSessionCache(1) - clientConfig.ServerName = "example.go.dev" - clientConfig.NextProtos = []string{"h3"} + clientConfig := &QUICConfig{TLSConfig: testConfig.Clone()} + clientConfig.EnableSessionEvents = true + clientConfig.TLSConfig.MinVersion = VersionTLS13 + clientConfig.TLSConfig.ClientSessionCache = NewLRUClientSessionCache(1) + clientConfig.TLSConfig.ServerName = "example.go.dev" + clientConfig.TLSConfig.NextProtos = []string{"h3"} - serverConfig := testConfig.Clone() - serverConfig.MinVersion = VersionTLS13 - serverConfig.NextProtos = []string{"h3"} + serverConfig := &QUICConfig{TLSConfig: testConfig.Clone()} + serverConfig.EnableSessionEvents = true + serverConfig.TLSConfig.MinVersion = VersionTLS13 + serverConfig.TLSConfig.NextProtos = []string{"h3"} cli := newTestQUICClient(t, clientConfig) cli.conn.SetTransportParameters(nil) From dc96744fa990096827013b1bfc7ebbff751b9f13 Mon Sep 17 00:00:00 2001 From: Clide Stefani Date: Tue, 11 Jun 2024 14:42:13 -0400 Subject: [PATCH 36/39] crypto/tls: add support for -reject-alpn and -decline-alpn flags to bogo_shim_test The existing implementation of bogo_shim_test does not support tests which use the reject-alpn or the decline-alpn flag. This change adds support for these flags in bogo_shim_test. Updates #51434 Updates #46310 Cq-Include-Trybots: luci.golang.try:gotip-linux-amd64-longtest Change-Id: I3ff23ff4edd8f4c6c37ee6c9f2ee4689066c4e00 Reviewed-on: https://go-review.googlesource.com/c/go/+/592198 Reviewed-by: Roland Shoemaker Reviewed-by: David Chase Auto-Submit: Roland Shoemaker LUCI-TryBot-Result: Go LUCI --- bogo_shim_test.go | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/bogo_shim_test.go b/bogo_shim_test.go index 2d8100d..38087d2 100644 --- a/bogo_shim_test.go +++ b/bogo_shim_test.go @@ -75,6 +75,8 @@ var ( advertiseALPN = flag.String("advertise-alpn", "", "") expectALPN = flag.String("expect-alpn", "", "") + rejectALPN = flag.Bool("reject-alpn", false, "") + declineALPN = flag.Bool("decline-alpn", false, "") hostName = flag.String("host-name", "", "") @@ -126,6 +128,14 @@ func bogoShim() { } } + if *rejectALPN { + cfg.NextProtos = []string{"unnegotiableprotocol"} + } + + if *declineALPN { + cfg.NextProtos = []string{} + } + if *hostName != "" { cfg.ServerName = *hostName } @@ -256,6 +266,9 @@ func bogoShim() { if *expectVersion != 0 && cs.Version != uint16(*expectVersion) { log.Fatalf("expected ssl version %q, got %q", uint16(*expectVersion), cs.Version) } + if *declineALPN && cs.NegotiatedProtocol != "" { + log.Fatal("unexpected ALPN protocol") + } if *expectECHAccepted && !cs.ECHAccepted { log.Fatal("expected ECH to be accepted, but connection state shows it was not") } else if i == 0 && *onInitialExpectECHAccepted && !cs.ECHAccepted { From 539bd295cd7b199c907b0bbb74d2c5a3d6e0378d Mon Sep 17 00:00:00 2001 From: Clide Stefani Date: Tue, 25 Jun 2024 11:46:39 -0400 Subject: [PATCH 37/39] crypto/tls: add support for -expect-no-hrr to bogo_shim_test The existing implementation of bogo_shim_test does not support tests that use the expect-no-hrr flag. This change adds support for this flag. Updates #51434 Change-Id: Iadb38fc2262783cab144a7b52904d0443e7fc2c2 Reviewed-on: https://go-review.googlesource.com/c/go/+/594835 LUCI-TryBot-Result: Go LUCI Reviewed-by: Roland Shoemaker Reviewed-by: Russell Webb Reviewed-by: Carlos Amedee Auto-Submit: Roland Shoemaker --- bogo_shim_test.go | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/bogo_shim_test.go b/bogo_shim_test.go index 38087d2..f481a5a 100644 --- a/bogo_shim_test.go +++ b/bogo_shim_test.go @@ -54,6 +54,7 @@ var ( echConfigListB64 = flag.String("ech-config-list", "", "") expectECHAccepted = flag.Bool("expect-ech-accept", false, "") expectHRR = flag.Bool("expect-hrr", false, "") + expectNoHRR = flag.Bool("expect-no-hrr", false, "") expectedECHRetryConfigs = flag.String("expect-ech-retry-configs", "", "") expectNoECHRetryConfigs = flag.Bool("expect-no-ech-retry-configs", false, "") onInitialExpectECHAccepted = flag.Bool("on-initial-expect-ech-accept", false, "") @@ -283,6 +284,10 @@ func bogoShim() { log.Fatal("expected HRR but did not do it") } + if *expectNoHRR && cs.testingOnlyDidHRR { + log.Fatal("expected no HRR but did do it") + } + if *expectSessionMiss && cs.DidResume { log.Fatal("unexpected session resumption") } From 6c08cae23bb83a5a41cf45d05dd8710d1b61ce3c Mon Sep 17 00:00:00 2001 From: Clide Stefani Date: Wed, 26 Jun 2024 16:29:01 -0400 Subject: [PATCH 38/39] crypto/tls: add exclude tls flags to bogo_shim_test The existing implementation of bogo_shim_test does not support tests that use the -no-tls1, -no-tls11, or -no-tls12 flags. This change adds support for these flags. Updates #51434 Change-Id: I43eaea9f5ec6da6811b150630a7dde24d108017e Reviewed-on: https://go-review.googlesource.com/c/go/+/595775 Auto-Submit: Roland Shoemaker Reviewed-by: Russell Webb LUCI-TryBot-Result: Go LUCI Reviewed-by: Cherry Mui Reviewed-by: Roland Shoemaker --- bogo_shim_test.go | 26 +++++++++++++++++++++++++- 1 file changed, 25 insertions(+), 1 deletion(-) diff --git a/bogo_shim_test.go b/bogo_shim_test.go index f481a5a..ce01852 100644 --- a/bogo_shim_test.go +++ b/bogo_shim_test.go @@ -37,6 +37,9 @@ var ( maxVersion = flag.Int("max-version", VersionTLS13, "") expectVersion = flag.Int("expect-version", 0, "") + noTLS1 = flag.Bool("no-tls1", false, "") + noTLS11 = flag.Bool("no-tls11", false, "") + noTLS12 = flag.Bool("no-tls12", false, "") noTLS13 = flag.Bool("no-tls13", false, "") requireAnyClientCertificate = flag.Bool("require-any-client-certificate", false, "") @@ -116,8 +119,29 @@ func bogoShim() { ClientSessionCache: NewLRUClientSessionCache(0), } - if *noTLS13 && cfg.MaxVersion == VersionTLS13 { + + if *noTLS1 { + cfg.MinVersion = VersionTLS11 + if *noTLS11 { + cfg.MinVersion = VersionTLS12 + if *noTLS12 { + cfg.MinVersion = VersionTLS13 + if *noTLS13 { + log.Fatalf("no supported versions enabled") + } + } + } + } else if *noTLS13 { cfg.MaxVersion = VersionTLS12 + if *noTLS12 { + cfg.MaxVersion = VersionTLS11 + if *noTLS11 { + cfg.MaxVersion = VersionTLS10 + if *noTLS1 { + log.Fatalf("no supported versions enabled") + } + } + } } if *advertiseALPN != "" { From 6b21c9a4927aa494baa0ae5cf9a87425193e853a Mon Sep 17 00:00:00 2001 From: Filippo Valsorda Date: Thu, 1 Aug 2024 23:41:13 +0200 Subject: [PATCH 39/39] [release-branch.go1.23] crypto/tls: fix testHandshake close flakes The flakes were introduced by me in CL 586655. It's unclear why only FreeBSD seems affected, maybe other TCP stacks handle sending on a half-closed connection differently, or aren't as quick to propagate the RST over localhost. Updates #68155 Change-Id: I32a1b474a7d6531dbab93910c23568b867629e8c Reviewed-on: https://go-review.googlesource.com/c/go/+/602635 LUCI-TryBot-Result: Go LUCI Reviewed-by: Cherry Mui Run-TryBot: Filippo Valsorda TryBot-Result: Gopher Robot Auto-Submit: Filippo Valsorda Reviewed-by: Roland Shoemaker --- handshake_test.go | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/handshake_test.go b/handshake_test.go index bc3d23d..41c2643 100644 --- a/handshake_test.go +++ b/handshake_test.go @@ -491,9 +491,10 @@ func testHandshake(t *testing.T, clientConfig, serverConfig *Config) (serverStat if got := string(buf); got != sentinel { t.Errorf("read %q from TLS connection, but expected %q", got, sentinel) } - if err := cli.Close(); err != nil { - t.Errorf("failed to call cli.Close: %v", err) - } + // We discard the error because after ReadAll returns the server must + // have already closed the connection. Sending data (the closeNotify + // alert) can cause a reset, that will make Close return an error. + cli.Close() }() server := Server(s, serverConfig) err = server.Handshake()