Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CustomPaddingStyle ¶
CustomPaddingStyle is a function to use with TLS extension ID 21, padding. In order to ensure this TLS extension is always enabled, the function never returns 0 or false like the BoringPaddingStyle function in the uTLS library does. Returns a random number between 0 and 65,535 Adapted from https://github.com/refraction-networking/utls/blob/8e1e65eb22d21c635523a31ec2bcb8730991aaad/u_tls_extensions.go#L680 https://www.rfc-editor.org/rfc/rfc7685.html
func JA3toClientHello ¶
func JA3toClientHello(ja3 string) (*tls.ClientHelloSpec, error)
JA3toClientHello creates a ClientHelloSpec based on a JA3 string JA3 string format: SSLVersion,Cipher,SSLExtension,EllipticCurve,EllipticCurvePointFormat
func ParrotStringToClientHelloID ¶
func ParrotStringToClientHelloID(parrot string) (clientHello tls.ClientHelloID, err error)
ParrotStringToClientHelloID reads in a string that represents a uTLS ClientHelloID and returns the real ClientHelloID object https://github.com/refraction-networking/utls/blob/8e1e65eb22d21c635523a31ec2bcb8730991aaad/u_common.go#L150
Types ¶
type Transport ¶
type Transport struct {
// contains filtered or unexported fields
}
Transport is custom http.Transport that switches clients between HTTP/1.1 and HTTP2 depending on which protocol was negotiated during the TLS handshake. It is also used to create a http.Transport structure from a JA3 or parrot string
func NewTransportFromJA3 ¶
func NewTransportFromJA3(ja3 string, InsecureSkipVerify bool, proxy func(*http.Request) (*url.URL, error)) (*Transport, error)
NewTransportFromJA3 creates a new http.Transport object given an utls.Config
func NewTransportFromParrot ¶
func NewTransportFromParrot(parrot string, InsecureSkipVerify bool, proxy func(*http.Request) (*url.URL, error)) (*Transport, error)
NewTransportFromParrot takes in a string that represents a ClientHelloID to parrot a TLS connection that looks like an associated browser and returns a http transport structure