I came across this today:
The newer one, "tls/1", sorts the extensions into lexicographic order, to compensate for the randomization of those fields introduced by some TLS clients.
https://github.com/cisco/mercury/blob/main/doc/npf.md#tls
which is concerning. some servers, such as android.googleapis.com, are sensitive to the extension order. This is not theoretical. for example, using these extensions:
&RenegotiationInfoExtension{},
&SNIExtension{},
&UtlsExtendedMasterSecretExtension{},
&SessionTicketExtension{},
&SignatureAlgorithmsExtension{},
&StatusRequestExtension{},
&ALPNExtension{},
&SupportedPointsExtension{},
&SupportedCurvesExtension{},
I get this result:
if I swap the first two, I get this:
So if extensions are sorted, then an NPF cannot be used to reconstruct the original client hello, which would make it useless for actually making network requests. So imagine this conversation:
A: hello I cannot connect to this server, can anyone help?
B: sure just use tls/1...
A: it doesn't work...
B: ...
Also, this is confusing:
The "tls/1" fingerprint format is
"tls/1" (TLS_Version) (TLS_Ciphersuite) [ QUIC_Extension* ]
and the older "tls" fingerprint format is
"tls/" (TLS_Version) (TLS_Ciphersuite) ((TLS_Extension)*)
supposedly tls/1 sorts the extensions, but it also lists QUIC_Extension. does that mean only QUIC hellos can be sorted?
I came across this today:
https://github.com/cisco/mercury/blob/main/doc/npf.md#tls
which is concerning. some servers, such as
android.googleapis.com, are sensitive to the extension order. This is not theoretical. for example, using these extensions:I get this result:
if I swap the first two, I get this:
So if extensions are sorted, then an NPF cannot be used to reconstruct the original client hello, which would make it useless for actually making network requests. So imagine this conversation:
Also, this is confusing:
supposedly
tls/1sorts the extensions, but it also listsQUIC_Extension. does that mean only QUIC hellos can be sorted?