Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
Reason string
IPAddr string
IPPort string
VPNAddress string
CommonName string
SessionID string
SessionState string
IvSSO string
KID uint64
CID uint64
UsernameIsDefined int
}
func NewClient ¶
NewClient parses a multi-line message from the OpenVPN management interface and returns the extracted information. The message contains several `>CLIENT:` records separated by CRLF. Each line is inspected to collect the connection reason with its CID/KID and to read environment variables such as untrusted IP address, port and session identifiers. Unsupported or empty environment lines are ignored. If no valid reason line is found, ErrParseErrorClientReason is returned.
Click to show internal directories.
Click to hide internal directories.