Skip to content

Sanity check for clienthello #1535

@drwetter

Description

@drwetter

While converting run_ticketbleed() to a different socket sending function which omits the leading x in each bytes I thought: Well, as we don't have a unit test for ticketbleed (and I couldn't find a vulnerable server anymore either) .... as a baseline it makes sense to compare the handshakes in debug mode before + after the change whether they match. Then I stumbled over a malformatted client hello:

sending client hello... 
"\x16\x03\x01\xx01\xxf6\x01\x00\xx01\xxf2\x03\x03\xee\xee\x5b\x90\x9d\x9b\x72
[..]
xx7a\xx76\xxcb\xxeb\xxf9\xx80\xx83\xx16\xx0c\xx8d\xx83\x00\x0f\x00\x01\x01"
reading server hello (ticketbleed reply)... 

Note the double x-es.

This would probably not have been discovered otherwise. This particular clienthello is THE check for it. In this case the server reply was empty (means also in a use case scenario not vulnerable).

So what I was thinking on is extending socksend_clienthello() to include a (debug) function which checks whether all he bytes which will be send over the wire are formatted like

1: backslash
2: x
3: 0-9,a-f
4: 0-9,a-f

If we run that in a (to be defined) debug mode we also can use a unit test for shed some light on those kind of problems which otherwise would be hard to discover.

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions