Versions in this module Expand all Collapse all v0 v0.0.7 Mar 15, 2020 v0.0.6 Mar 15, 2020 Changes in this version + const CacheTime + const MappingDuration + var DefaultTimeout = nat.DefaultTimeout + var ErrNoMapping = errors.New("mapping not established") + type Mapping interface + Close func() error + ExternalAddr func() (addr net.Addr, err error) + ExternalPort func() int + InternalPort func() int + NAT func() *NAT + Protocol func() string + type NAT struct + func DiscoverNAT(ctx context.Context, timeout time.Duration) (*NAT, error) + func (nat *NAT) Close() error + func (nat *NAT) Mappings() []Mapping + func (nat *NAT) NewMapping(protocol string, port int) (Mapping, error)