utls: fork of crypto/tls for anti-censorship

73 views
Skip to first unread message

Sergey Frolov

unread,
Sep 30, 2017, 11:04:12 PM9/30/17
to Network Traffic Obfuscation
https://github.com/refraction-networking/utls

utls is a fork of Golang crypto/tls, designed for censorship circumvention tool development.
Main features include:
  • Fingerprinting resistance - can parrot several browsers*, and generate random tls handshakes.
  • Low-level access to handshake - write anything to ClientHello, read anything from the rest of handshake.
  • Fake Session Tickets** - nifty trick designed to skip whole round trip, together with some fingerprintable aspects of handshake.

Important implementation details:

  • Does not diverge from upstream - original crypto/tls files are left almost untouched, with most of new utls functionality being done in separate files, making the merge of upstream (and staying up to date) trivial.
  • Handshake is done by standard crypto/tls, relying on Golang maintainers for most of security; utls mostly just fills in the ClientHello. However, we did implement EMS, since it is an overwhelmingly popular extension, but still missing in crypto/tls.
* Parroting has a downside, that it forces us to send some stuff in ClientHello, that Golang doesn't support. Which means that if server in the wild echoes unsupported stuff back, connection will visibly break. In TapDance project we judged that it's extremely unlikely for censors to employ TLS ClientHello whitelist, so we are currently using randomized handshake instead, without any compatibility/parrot-is-dead risks. We may use randomizing + parroting later, iterating through our parroting options, until unblocked/working one is found.
** API for Fake Session Tickets may not be the most convenient, since I personally haven't used it yet. We can work out something better, PRs are welcome.

I hope we can work together on it to implement more features, keep fingerprints of browsers up to date and smash bugs together. Some anti-censorship tools are in the process of integrating utls. Feedback on this library is welcome!
Reply all
Reply to author
Forward
0 new messages