Versions in this module Expand all Collapse all v0 v0.2.0 Aug 25, 2026 Changes in this version type Option + func WithAllowedPorts(ports ...uint16) Option + func WithBlockedPrefixes(prefixes ...netip.Prefix) Option + type PortBlockedError struct + Host string + Port uint16 + func (e *PortBlockedError) Error() string v0.1.0 Aug 20, 2026 Changes in this version + func CheckAddr(addr netip.Addr, opts ...Option) error + func CheckSameOriginRedirect(req *http.Request, via []*http.Request) error + func NewDialContext(base ContextDialer, opts ...Option) func(ctx context.Context, network, addr string) (net.Conn, error) + func NewHTTPClient(base *http.Client, opts ...Option) *http.Client + func NewTransport(base *http.Transport, opts ...Option) *http.Transport + func ParseAllowedPrefix(raw string) (netip.Prefix, error) + func ParseNAT64Prefix(raw string) (netip.Prefix, error) + type BlockedError struct + Addr netip.Addr + Host string + func (e *BlockedError) Error() string + type ContextDialer interface + DialContext func(ctx context.Context, network, addr string) (net.Conn, error) + type Option func(*config) + func WithAllowedPrefixes(prefixes ...netip.Prefix) Option + func WithNAT64Prefixes(prefixes ...netip.Prefix) Option + func WithRedirectPolicy(policy RedirectPolicy) Option + type RedirectPolicy int + const RedirectDeny + const RedirectGuarded + const RedirectSameOrigin