Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ShadowsocksReader ¶
ShadowsocksReader is an io.Reader that also implements io.WriterTo to allow for piping the data without extra allocations and copies.
func NewShadowsocksReader ¶
func NewShadowsocksReader(reader io.Reader, ssCipher shadowaead.Cipher) ShadowsocksReader
NewShadowsocksReader creates a Reader that decrypts the given Reader using the shadowsocks protocol with the given shadowsocks cipher.
type ShadowsocksWriter ¶
type ShadowsocksWriter interface {
io.Writer
io.ReaderFrom
}
ShadowsocksWriter is an io.Writer that also implements io.ReaderFrom to allow for piping the data without extra allocations and copies.
func NewShadowsocksWriter ¶
func NewShadowsocksWriter(writer io.Writer, ssCipher shadowaead.Cipher) ShadowsocksWriter
NewShadowsocksWriter creates a Writer that encrypts the given Writer using the shadowsocks protocol with the given shadowsocks cipher.
type TCPService ¶
type TCPService interface {
Start()
Stop() error
}
func NewTCPService ¶
func NewTCPService(listener *net.TCPListener, ciphers *map[string]shadowaead.Cipher, m metrics.ShadowsocksMetrics) TCPService
type UDPService ¶
type UDPService interface {
Start()
Stop() error
}
func NewUDPService ¶
func NewUDPService(clientConn net.PacketConn, natTimeout time.Duration, ciphers *map[string]shadowaead.Cipher, m metrics.ShadowsocksMetrics) UDPService
Click to show internal directories.
Click to hide internal directories.