servers

package
v3.2.0 Latest Latest
Warning

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

Go to latest
Published: Aug 23, 2022 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AuthenticationMethod

type AuthenticationMethod func(username []byte, password []byte) error

type DialFunc

type DialFunc func(network, address string) (net.Conn, error)

type DialUDPFunc

type DialUDPFunc func(network string, localAddress, remoteAddress *net.UDPAddr) (*net.UDPConn, error)

type HTTPHandler

type HTTPHandler interface {
	Protocol
	http.Handler
}

type ListenFunc

type ListenFunc func(network, address string) (net.Listener, error)

type Protocol

type Protocol interface {
	Handle(net.Conn) error
	SetAuthenticationMethod(AuthenticationMethod)
	SetDial(dialFunc DialFunc)
	SetListen(listenFunc ListenFunc)
	SetListenAddress(address net.Addr)
	SetSniffers(incoming, outgoing io.Writer)
}

Directories

Path Synopsis
translation

Jump to

Keyboard shortcuts

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