Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func InitServer ¶
InitializeServer creates the directories and files necessary to operate the server, including the key and certificate files.
Types ¶
type ClientConfig ¶
type ClientConfig struct { ConnectAddr string // Standard format: <address>:<port> Secret string // Shared secret key. }
A ClientConfig represents the configuration file for a tunnel client, stored on the server.
func (*ClientConfig) Load ¶
func (cc *ClientConfig) Load(path string) error
Load loads client configuration from the given file.
func (ClientConfig) Save ¶
func (cc ClientConfig) Save(path string) error
Save stores the client configuration into the given file.
type TunnelConfig ¶
type TunnelConfig struct { Host string // The host address: <address>:<port> Port int32 // The local port to listen on. Pwd string // The shared secret. CaCert []byte // The CA certificate. }
A TunnelConfig represents the configuration of a tunnel from the client's perspective.
func (*TunnelConfig) Load ¶
func (tc *TunnelConfig) Load(path string) error
Load loads the tunnel configuration from the given file.
func (TunnelConfig) Save ¶
func (tc TunnelConfig) Save(path string) error
Save stores the tunnel configuration into the given file.
Source Files ¶
Click to show internal directories.
Click to hide internal directories.