@@ -166,29 +166,40 @@ static const char *get_query_tcp(int port, unsigned int *len)
166166 "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00"
167167 "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00"
168168 ;
169- // This handshake claims support for DHE + AES-128 and AES-256 either in CBC
170- // or GCM mode, as well as SHA256 and SHA1 for signatures so it should work
169+ // This handshake claims support for (EC-) DHE + AES-128 or AES-256 + CBC
170+ // or GCM mode, and SHA256 or SHA1 for signatures so it should work
171171 // with modern as well as older server configs.
172172 static const char tls [] =
173173 "\x16" // Handshake (22)
174174 "\x03\x03" // TLS 1.2
175- "\x00\x3f " // Length
175+ "\x00\x63 " // Length
176176 "\x01" // Client Hello (1)
177- "\x00\x00\x3b " // Length
177+ "\x00\x00\x5f " // Length
178178 "\x03\x03" // TLS 1.2
179179
180180 // Random
181181 "\x55\xaa\x55\xaa\x55\xaa\x55\xaa\x55\xaa\x55\xaa\x55\xaa\x55\xaa"
182182 "\x55\xaa\x55\xaa\x55\xaa\x55\xaa\x55\xaa\x55\xaa\x55\xaa\x55\xaa"
183183
184184 "\x00" // Session ID length
185- "\x00\x08" // Cipher Suites length (= 8)
186- "\x00\x9e\x00\x9f\x00\x33\x00\x39"
185+ "\x00\x10" // Cipher Suites length (= 16)
186+ "\xc0\x2b\xc0\x2c\xc0\x09\xc0\x0a" // ECDHE+ECDSA
187+ "\xc0\x2f\xc0\x30\xc0\x13\xc0\x14" // ECDHE+RSA
188+ "\x00\x9e\x00\x9f\x00\x33\x00\x39" // DHE+RSA
187189 "\x01\x00" // Null Compression
188- "\x00\x0a " // Extensions length (= 10 )
190+ "\x00\x1e " // Extensions length (= 30 )
189191
190- // Signature Algorithms
191- "\x00\x0d\x00\x06\x00\x04\x04\x01\x02\x01"
192+ "\x00\x0a" // Extension: supported_groups
193+ "\x00\x06\x00\x04" // Length fields
194+ "\x00\x19\x00\x17"
195+
196+ "\x00\x0b" // Extension: ec_point_formats
197+ "\x00\x02\x01" // Length fields
198+ "\x00"
199+
200+ "\x00\x0d" // Extension: signature_algorithms
201+ "\x00\x0a\x00\x08" // Length fields
202+ "\x04\x01\x02\x01\x04\x03\x06\x03"
192203 ;
193204
194205 switch (port ) {
0 commit comments