Documentation
¶
Overview ¶
Package stun provides an embedded STUN server for NAT traversal discovery.
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrNoListeners = errors.New("stun: no listeners configured")
ErrNoListeners is returned by Listen when no UDP connections were provided.
View Source
var ErrServerClosed = errors.New("stun: server closed")
ErrServerClosed is returned by Listen when the server is shut down gracefully.
Functions ¶
This section is empty.
Types ¶
type Server ¶
type Server struct {
// contains filtered or unexported fields
}
Server implements a STUN server that responds to binding requests with the client's reflexive transport address.
func NewServer ¶
NewServer creates a new STUN server with the given UDP listeners. The caller is responsible for creating and providing the listeners. logLevel can be: panic, fatal, error, warn, info, debug, trace
Click to show internal directories.
Click to hide internal directories.