Documentation ¶
Index ¶
- func EncodeBase64ToHex(key string) (string, error)
- func NewVtunUDPForwarder(ctx context.Context, localBind netip.AddrPort, dest string, tnet *netstack.Net, ...) (netip.AddrPort, error)
- func ParseReserved(str string) ([3]byte, error)
- func RunScan(ctx context.Context, l *slog.Logger, opts ScanOptions) (result []ipscanner.IPInfo, err error)
- func StartProxy(ctx context.Context, l *slog.Logger, tnet *netstack.Net, ...) (netip.AddrPort, error)
- type Configuration
- type InterfaceConfig
- type PeerConfig
- type ScanOptions
- type VirtualTun
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func EncodeBase64ToHex ¶ added in v1.2.2
func NewVtunUDPForwarder ¶
func ParseReserved ¶ added in v1.2.2
Types ¶
type Configuration ¶
type Configuration struct { Interface *InterfaceConfig Peers []PeerConfig }
func ParseConfig ¶
func ParseConfig(path string) (*Configuration, error)
ParseConfig takes the path of a configuration file and parses it into Configuration
type InterfaceConfig ¶
func ParseInterface ¶
func ParseInterface(cfg *ini.File) (InterfaceConfig, error)
ParseInterface parses the [Interface] section
type PeerConfig ¶
type PeerConfig struct { PublicKey string Endpoint string KeepAlive int AllowedIPs []netip.Prefix Trick bool Reserved [3]byte }
func ParsePeers ¶
func ParsePeers(cfg *ini.File) ([]PeerConfig, error)
ParsePeers parses the [Peer] section and extract the information into `peers`
type ScanOptions ¶
Click to show internal directories.
Click to hide internal directories.