simpleobfs

package
v0.2.18 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 13, 2023 License: AGPL-3.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewHTTPObfs

func NewHTTPObfs(conn net.Conn, host string, port string, path string) net.Conn

NewHTTPObfs return a HTTPObfs

func NewTLSObfs

func NewTLSObfs(conn net.Conn, server string) net.Conn

NewTLSObfs return a SimpleObfs

Types

type HTTPObfs

type HTTPObfs struct {
	net.Conn
	// contains filtered or unexported fields
}

HTTPObfs is shadowsocks http simple-obfs implementation

func (*HTTPObfs) Read

func (ho *HTTPObfs) Read(b []byte) (int, error)

func (*HTTPObfs) Write

func (ho *HTTPObfs) Write(b []byte) (int, error)

type ObfsType

type ObfsType int
const (
	HTTP ObfsType = iota
	TLS
)

type SimpleObfs

type SimpleObfs struct {
	// contains filtered or unexported fields
}

SimpleObfs is a base http-obfs struct

func NewSimpleObfs

func NewSimpleObfs(s string, d proxy.Dialer) (*SimpleObfs, error)

NewSimpleobfs returns a simpleobfs proxy.

func (*SimpleObfs) Dial

func (s *SimpleObfs) Dial(network, addr string) (c net.Conn, err error)

Dial connects to the address addr on the network net via the proxy.

type TLSObfs

type TLSObfs struct {
	net.Conn
	// contains filtered or unexported fields
}

TLSObfs is shadowsocks tls simple-obfs implementation

func (*TLSObfs) Read

func (to *TLSObfs) Read(b []byte) (int, error)

func (*TLSObfs) Write

func (to *TLSObfs) Write(b []byte) (int, error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL