Documentation ¶
Overview ¶
Package internal contains the implementation of tlstool.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func SNISplitter ¶
SNISplitter splits input such that SNI is splitted across a bunch of different output buffers.
func Splitter3264rand ¶
Splitter3264rand splits the specified buffer at a random offset between 32 and 64 bytes. This is the methodology used by github.com/Jigsaw-Code/outline-go-tun2socks.
func Splitter84rest ¶
Splitter84rest segments the specified buffer into three sub-buffers containing respectively 8 bytes, 4 bytes, and the rest of the buffer. This segment technique has been described by Kevin Bock during the Internet Measurements Village 2020: https://youtu.be/ksojSRFLbBM?t=1140.
Types ¶
type Dialer ¶
Dialer creates net.Conn instances where (1) we delay writes if a delay is configured and (2) we split outgoing buffers if there is a configured splitter function.
func NewRandomSplitterDialer ¶
func NewRandomSplitterDialer(config DialerConfig) Dialer
NewRandomSplitterDialer creates a new dialer that splits the SNI like the fixed splitting schema used by outline. See github.com/Jigsaw-Code/outline-go-tun2socks.
func NewSNISplitterDialer ¶
func NewSNISplitterDialer(config DialerConfig) Dialer
NewSNISplitterDialer creates a new dialer that splits outgoing messages such that the SNI should end up being splitted into different TCP segments.
func NewThriceSplitterDialer ¶
func NewThriceSplitterDialer(config DialerConfig) Dialer
NewThriceSplitterDialer creates a new dialer that splits outgoing messages in three parts according to the circumvention technique described by Kevin Boch in the Internet Measurement Village 2020 <https://youtu.be/ksojSRFLbBM?t=1140>.
func NewVanillaDialer ¶
func NewVanillaDialer(config DialerConfig) Dialer
NewVanillaDialer creates a new vanilla dialer that does nothing and is used to establish a baseline.
type DialerConfig ¶
DialerConfig contains the config for creating a dialer
type SleeperWriter ¶
SleeperWriter is a net.Conn that optionally sleeps for the specified delay before posting each write.
type SplitterWriter ¶
SplitterWriter is a writer that splits every outgoing buffer according to the rules specified by the Splitter.
Caveat ¶
The TLS ClientHello may be retransmitted if the server is requesting us to restart the negotiation. Therefore, it is not safe to just run the splitting once. Since this code is meant to investigate TLS blocking, that's fine.