Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct { Name configvalues.Hostname `json:"name"` Endpoint configvalues.UDPAddr `json:"endpoint"` IP configvalues.IP `json:"ip"` Private PrivateKey `json:"private"` Public PublicKey `json:"public"` // contains filtered or unexported fields }
Client is a basic wireguard client.
func (*Client) CaddyModule ¶
func (*Client) CaddyModule() caddy.ModuleInfo
func (*Client) UnmarshalCaddyfile ¶
UnmarshalCaddyfile unmarshals a config in caddyfile form.
{ point-c { wgclient <name> { ip <tunnel ip> endpoint <server address/ip> private <client private key> public <server public key> shared <shared key> } }
type PresharedKey ¶
type PresharedKey = configvalues.CaddyTextUnmarshaler[wgapi.PresharedKey, valueKey[wgapi.PresharedKey], *valueKey[wgapi.PresharedKey]]
PresharedKey is a wireguard preshared key in base64 format.
type PrivateKey ¶
type PrivateKey = configvalues.CaddyTextUnmarshaler[wgapi.PrivateKey, valueKey[wgapi.PrivateKey], *valueKey[wgapi.PrivateKey]]
PrivateKey is a wireguard private key in base64 format.
type PublicKey ¶
type PublicKey = configvalues.CaddyTextUnmarshaler[wgapi.PublicKey, valueKey[wgapi.PublicKey], *valueKey[wgapi.PublicKey]]
PublicKey is a wireguard public key in base64 format.
type Server ¶
type Server struct { Name configvalues.Hostname `json:"hostname"` IP configvalues.IP `json:"ip"` ListenPort configvalues.Port `json:"listen-port"` Private PrivateKey `json:"private"` Peers []*ServerPeer `json:"peers"` // contains filtered or unexported fields }
Server is a basic wireguard server.
func (*Server) CaddyModule ¶
func (*Server) CaddyModule() caddy.ModuleInfo
func (*Server) UnmarshalCaddyfile ¶
UnmarshalCaddyfile unmarshals a config in caddyfile form.
{ point-c { wgserver <name> { ip <server ip> port <server port to listen on> private <server private key> peer <name> { ip <client ip> public <client public key> shared <shared key> } } }
type ServerPeer ¶
type ServerPeer struct { Name configvalues.Hostname `json:"hostname"` Public PublicKey `json:"public"` IP configvalues.IP `json:"ip"` }
Server is a basic wireguard server.
Click to show internal directories.
Click to hide internal directories.