utls/testdata/Client-TLSv13-ECDSA
Filippo Valsorda 5b79a7c982 crypto/tls: implement TLS 1.3 middlebox compatibility mode
Looks like the introduction of CCS records in the client second flight
gave time to s_server to send NewSessionTicket messages in between the
client application data and close_notify. There seems to be no way of
turning NewSessionTicket messages off, neither by not sending a
psk_key_exchange_modes extension, nor by command line flag.

Interleaving the client write like that tickled an issue akin to #18701:
on Windows, the client reaches Close() before the last record is drained
from the send buffer, the kernel notices and resets the connection,
cutting short the last flow. There is no good way of synchronizing this,
so we sleep for a RTT before calling close, like in CL 75210. Sigh.

Updates #9671

Change-Id: I44dc1cca17b373695b5a18c2741f218af2990bd1
Reviewed-on: https://go-review.googlesource.com/c/147419
Run-TryBot: Filippo Valsorda <filippo@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Adam Langley <agl@golang.org>
2018-11-12 20:43:06 +00:00

116 lines
8.7 KiB
Text

>>> Flow 1 (client to server)
00000000 16 03 01 00 f8 01 00 00 f4 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 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 32 cc a8 |.............2..|
00000050 cc a9 c0 2f c0 2b c0 30 c0 2c c0 27 c0 13 c0 23 |.../.+.0.,.'...#|
00000060 c0 09 c0 14 c0 0a 00 9c 00 9d 00 3c 00 2f 00 35 |...........<./.5|
00000070 c0 12 00 0a 00 05 c0 11 c0 07 13 01 13 03 13 02 |................|
00000080 01 00 00 79 00 05 00 05 01 00 00 00 00 00 0a 00 |...y............|
00000090 0a 00 08 00 1d 00 17 00 18 00 19 00 0b 00 02 01 |................|
000000a0 00 00 0d 00 18 00 16 08 04 08 05 08 06 04 01 04 |................|
000000b0 03 05 01 05 03 06 01 06 03 02 01 02 03 ff 01 00 |................|
000000c0 01 00 00 12 00 00 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 48 a3 75 25 ac |....z...v..H.u%.|
00000010 19 49 b6 e7 5a 9a c2 15 3e e3 a6 21 c0 f5 09 40 |.I..Z...>..!...@|
00000020 b7 ad fc 0c 39 1b 3c 44 36 13 9e 20 00 00 00 00 |....9.<D6.. ....|
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 01 00 00 |................|
00000050 2e 00 2b 00 02 03 04 00 33 00 24 00 1d 00 20 20 |..+.....3.$... |
00000060 db 3f 51 79 d2 24 e1 e1 a4 b6 f8 84 2d 25 27 ca |.?Qy.$......-%'.|
00000070 9a d2 5e cc 28 ac 5e 74 2a ea 1b 56 28 24 76 14 |..^.(.^t*..V($v.|
00000080 03 03 00 01 01 17 03 03 00 17 bc dd d4 00 24 28 |..............$(|
00000090 82 e2 0a 74 8f a6 06 9b 14 2d ca c1 90 6c 1c 8f |...t.....-...l..|
000000a0 7f 17 03 03 02 22 f9 8f 72 d6 f1 34 fa 90 0e 42 |....."..r..4...B|
000000b0 2d 2e a0 1d 9e 1f ce ee 79 af b6 b3 bd c2 6b 8f |-.......y.....k.|
000000c0 62 4c 5d 1c 1e 47 a7 77 97 ca 04 c5 16 f8 58 3a |bL]..G.w......X:|
000000d0 b7 33 15 bc 5f f0 13 7f 02 4d f2 80 95 84 6f 41 |.3.._....M....oA|
000000e0 df 03 c8 64 23 91 e5 8c e9 01 45 fe 8e 37 27 e0 |...d#.....E..7'.|
000000f0 47 83 43 a2 0f ef 3d eb 11 fb ba 52 2f 8e 43 97 |G.C...=....R/.C.|
00000100 1b fe 49 28 e7 ce 73 c4 3e 9d 18 9d 34 a4 b4 5e |..I(..s.>...4..^|
00000110 ee ec bf e3 75 fc 00 be b7 0e 80 f8 a2 db 90 a9 |....u...........|
00000120 62 74 35 c6 8e 36 55 68 4e 6c 94 b6 61 d7 d0 34 |bt5..6UhNl..a..4|
00000130 e8 83 ae c3 75 2d eb 35 95 d3 5f 28 3e 05 f3 ea |....u-.5.._(>...|
00000140 18 76 6b 6d b9 98 c0 d5 ea 6d 62 9b 15 d8 be 55 |.vkm.....mb....U|
00000150 8c f5 5a 3d 14 81 82 cc 8c 6c 34 2f e8 50 87 ef |..Z=.....l4/.P..|
00000160 c6 fe 92 39 e0 f4 6d ca d1 97 c9 df 81 6d dc 3f |...9..m......m.?|
00000170 6f 60 58 30 e1 c7 87 d0 fb 40 f6 ce 44 96 e9 19 |o`X0.....@..D...|
00000180 21 d3 3a 56 fd c1 60 22 96 f7 d9 07 30 15 40 f9 |!.:V..`"....0.@.|
00000190 b3 0c 9c cf f7 38 94 43 41 8a 76 92 4a 71 55 22 |.....8.CA.v.JqU"|
000001a0 8d ce 03 ed 97 98 54 0e 94 8c b7 a4 ee ce d6 60 |......T........`|
000001b0 5d a2 4e 9f ff e6 90 23 69 b1 a2 0e c5 e7 5b 58 |].N....#i.....[X|
000001c0 7b d1 13 ba f2 d3 ff 6a 48 ff 77 2d 61 05 4b 15 |{......jH.w-a.K.|
000001d0 cc 6f 52 4a 69 1c e2 38 b3 2a 96 ff 10 bb 55 02 |.oRJi..8.*....U.|
000001e0 50 e9 f2 09 92 66 cc 43 ea f4 4e ad aa 18 fc 9b |P....f.C..N.....|
000001f0 05 52 3b f1 44 3b 6e 25 47 cd 20 4d 69 86 8b 64 |.R;.D;n%G. Mi..d|
00000200 61 31 0a 03 92 0e 21 9d 67 d5 af 00 de 88 a4 f5 |a1....!.g.......|
00000210 3d 3e 45 0f f4 02 15 ae bf 45 76 80 0d 8d 7a 04 |=>E......Ev...z.|
00000220 58 d7 e5 5a 81 41 a9 04 7e aa 67 af 27 92 cf 51 |X..Z.A..~.g.'..Q|
00000230 13 c4 e6 84 2e 28 dc 53 c8 73 11 f9 f7 d9 28 ac |.....(.S.s....(.|
00000240 a6 00 af cb 38 bc f2 b7 1c 6d e8 21 f0 6e e5 35 |....8....m.!.n.5|
00000250 12 c0 a9 57 2f 87 39 bc a6 7a ab ab 04 02 48 e8 |...W/.9..z....H.|
00000260 13 a3 20 a4 c9 09 64 b2 2a 66 39 91 d7 3a 7a 41 |.. ...d.*f9..:zA|
00000270 1c a4 15 4e 84 d3 72 66 31 3a ba 7a b8 18 ee 0c |...N..rf1:.z....|
00000280 e2 17 1a 8f f7 af 38 49 e3 4d d7 ed be 7a 1e bd |......8I.M...z..|
00000290 ae 70 c1 fc 6a 09 05 29 bb fc 78 5b 8f a4 f7 81 |.p..j..)..x[....|
000002a0 34 fd ad 9b 22 87 67 15 0f ee d4 99 90 e7 af 4b |4...".g........K|
000002b0 14 bd af f3 ab 04 e0 d1 58 f5 34 b2 e1 ee 65 92 |........X.4...e.|
000002c0 80 05 68 c3 b2 6a bc 6d 17 03 03 00 a4 f4 d6 df |..h..j.m........|
000002d0 b6 61 6a c2 6c a6 25 f9 b2 95 8f 73 10 05 e2 63 |.aj.l.%....s...c|
000002e0 37 22 63 bd 50 af 18 0c 71 17 61 40 c9 a1 b1 6d |7"c.P...q.a@...m|
000002f0 d7 a6 2f c6 c2 46 9d 40 06 e3 30 04 e1 d9 97 c1 |../..F.@..0.....|
00000300 a8 6c ce 97 47 4e 9e 54 bc 8e 2c 77 e8 21 c3 0b |.l..GN.T..,w.!..|
00000310 8f 51 0c c2 8f 0d 64 b9 79 26 c0 33 07 e0 df 08 |.Q....d.y&.3....|
00000320 50 98 26 b1 2b 69 6a 5d b4 9c b7 4e 20 97 cc d9 |P.&.+ij]...N ...|
00000330 43 94 9f 4d 2b d1 72 24 a7 a8 3e 7d 9e 84 7a 98 |C..M+.r$..>}..z.|
00000340 23 64 7b b9 17 15 d6 27 80 6c 60 2d 38 c7 4d cd |#d{....'.l`-8.M.|
00000350 9a 87 d6 ab 31 8d 59 62 58 b4 11 f4 2e d5 81 10 |....1.YbX.......|
00000360 87 e5 58 3e 37 99 37 af 68 6f 11 cc 0b a2 f1 d1 |..X>7.7.ho......|
00000370 b0 17 03 03 00 35 be f6 19 d0 66 ec cd 14 d5 28 |.....5....f....(|
00000380 b8 bf 0d f4 37 5d 55 3d 2e 2c 1e 0c 62 0a 49 3e |....7]U=.,..b.I>|
00000390 df cf c2 dc 2c 27 df 54 64 67 8d 33 8b f0 b1 50 |....,'.Tdg.3...P|
000003a0 c5 dd fc 47 5c e7 58 5b 74 57 4b |...G\.X[tWK|
>>> Flow 3 (client to server)
00000000 14 03 03 00 01 01 17 03 03 00 35 2d 01 39 11 82 |..........5-.9..|
00000010 67 c7 e5 db 3f dd 18 c3 0b 0a 25 8a 24 2e e1 f4 |g...?.....%.$...|
00000020 5e a2 0f 8a 1c 70 83 26 d0 5d b1 8d cf c6 69 a9 |^....p.&.]....i.|
00000030 38 8c 14 22 74 4a 85 fe f5 86 e6 c2 07 44 bf 87 |8.."tJ.......D..|
00000040 17 03 03 00 17 a8 2f 45 46 d9 59 7e 5f 4c 9e 46 |....../EF.Y~_L.F|
00000050 09 e4 38 e1 e3 e3 5e ab 62 14 eb 2f |..8...^.b../|
>>> Flow 4 (server to client)
00000000 17 03 03 00 da 41 7f 38 18 5c d5 fc c7 ba 60 66 |.....A.8.\....`f|
00000010 d6 92 60 81 83 bc f3 35 ff 00 ef 4b 99 48 de 1c |..`....5...K.H..|
00000020 aa 1c f8 80 6d 59 48 30 83 03 ad fd e3 15 23 16 |....mYH0......#.|
00000030 aa c8 d7 71 58 df 65 fc 8c d3 77 56 f4 19 f2 5e |...qX.e...wV...^|
00000040 c2 d5 15 1b b7 9a 46 68 81 68 c6 2b be 81 f2 f5 |......Fh.h.+....|
00000050 5a 71 81 55 10 0f 09 9a 9a 9e c4 be 28 db fa 50 |Zq.U........(..P|
00000060 f6 fa 88 5b c6 63 35 77 8c d0 1b 4a 50 b8 42 6d |...[.c5w...JP.Bm|
00000070 5d f5 b7 5a 5e 73 0f 12 ba 86 92 44 23 bc 70 e1 |]..Z^s.....D#.p.|
00000080 3d f4 1b 20 87 e6 c2 89 43 2a 76 7f e3 8f 2c db |=.. ....C*v...,.|
00000090 86 31 4a 38 5b 5e 44 3e 6c 72 be 13 a5 77 d2 90 |.1J8[^D>lr...w..|
000000a0 95 80 35 c6 c9 1b 0e ea b8 0a 18 65 78 23 e4 0e |..5........ex#..|
000000b0 bc 67 86 5b 6a 77 32 66 f3 38 89 01 86 d3 c2 3e |.g.[jw2f.8.....>|
000000c0 93 70 57 11 07 1a be 26 3c 69 f8 8b 3b c3 4a 1c |.pW....&<i..;.J.|
000000d0 e5 bf 9c 48 20 6b 9c 91 eb ff 14 af 44 93 35 17 |...H k......D.5.|
000000e0 03 03 00 da 42 0b c1 73 60 66 cf c6 f1 25 bc d2 |....B..s`f...%..|
000000f0 da 72 0b 8d aa 32 82 35 70 3a e2 fa 4c 30 fd d4 |.r...2.5p:..L0..|
00000100 12 3c 29 a5 41 71 7e e9 3a 64 61 7d e6 c3 60 3f |.<).Aq~.:da}..`?|
00000110 d8 e3 db b4 f9 f6 59 02 96 e3 2a 2a d1 96 70 8e |......Y...**..p.|
00000120 98 ec a0 84 79 46 53 3c b1 0b a5 d8 78 6b 82 06 |....yFS<....xk..|
00000130 43 af 5a 5a 68 b6 4e 6d 30 eb 81 63 1a 2d 72 0a |C.ZZh.Nm0..c.-r.|
00000140 0e 2b 68 b4 20 12 77 ef 9b d6 c4 f0 4a 59 47 86 |.+h. .w.....JYG.|
00000150 05 59 9e 68 25 54 8d 72 04 bf 50 cf 44 0a fc 0c |.Y.h%T.r..P.D...|
00000160 6a bf af 26 08 7d e6 c4 3b 69 a5 7f f0 11 0c 7f |j..&.}..;i......|
00000170 87 bf 84 02 7b af 2e 03 35 c4 d3 36 aa da 4a e7 |....{...5..6..J.|
00000180 eb 77 23 bd 4d e6 df 08 2a 76 47 6b 7d 04 42 20 |.w#.M...*vGk}.B |
00000190 be 82 51 d3 af df 98 c1 6e 5d 21 da a0 da 7c 5c |..Q.....n]!...|\|
000001a0 29 ee 62 bb a3 aa f8 76 09 77 f4 5c 56 94 75 27 |).b....v.w.\V.u'|
000001b0 30 4a 60 18 e8 67 9f 7d 38 ec 34 6d 9c 0e |0J`..g.}8.4m..|
>>> Flow 5 (client to server)
00000000 17 03 03 00 13 d2 5d 20 07 4c 51 50 40 86 e8 36 |......] .LQP@..6|
00000010 59 ba c4 f6 13 ab 29 1f |Y.....).|