Documentation ¶
Index ¶
- Variables
- func GetLocalIPv4() []string
- func GetRequestURLString(req *http.Request) string
- func HTTPProxyConnect(proxyURL *url.URL, c net.Conn, addr string) error
- func HTTPProxyDial(proxyURL string, addr string, timeout time.Duration) (net.Conn, error)
- func IPv42Int(ip string) (int64, error)
- func IsPrivateIP(ip string) bool
- func IsTimeoutError(err error) bool
- func Long2IPv4(i uint64) string
- func PKCS7Pad(buf *bytes.Buffer, blen int)
- func PKCS7Unpad(in []byte) []byte
- func PrepareRegexp(rule string) (*regexp.Regexp, error)
- func RandAsciiString(n int) string
- func RandBetween(min, max int) int
- func ReadWithoutComment(file string, commentPrefix string) ([]byte, error)
- func Socks5ProxyConnect(proxyURL *url.URL, conn net.Conn, addr string) error
- func Socks5ProxyDial(proxyURL string, addr string, timeout time.Duration) (net.Conn, error)
- func TLSParseSNI(data []byte) (string, error)
- func TLSReplaceSNI(data []byte, sni string) ([]byte, string, error)
- func WildcardMatch(text string, pattern string) bool
- type BufferChunkReader
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrNoSNI = errors.New("No SNI in protocol")
View Source
var ErrTLSClientHello = errors.New("Invalid tls client hello")
View Source
var ErrTLSIncomplete = errors.New("TLS header incomplete")
Functions ¶
func GetLocalIPv4 ¶
func GetLocalIPv4() []string
func GetRequestURLString ¶
func HTTPProxyConnect ¶ added in v0.26.0
func HTTPProxyDial ¶ added in v0.26.0
func IsPrivateIP ¶
func IsTimeoutError ¶ added in v0.26.0
func PKCS7Unpad ¶
Returns slice of the original data without padding.
func RandAsciiString ¶
func RandBetween ¶
func ReadWithoutComment ¶
func Socks5ProxyConnect ¶ added in v0.26.0
func Socks5ProxyDial ¶ added in v0.26.0
func TLSParseSNI ¶
func WildcardMatch ¶
Types ¶
Click to show internal directories.
Click to hide internal directories.