add IPv6 info to report
This commit is contained in:
parent
f1e1a6838f
commit
38dd7c6d95
@ -20,9 +20,11 @@ type DsnetReport struct {
|
|||||||
// resolution. Informational only.
|
// resolution. Informational only.
|
||||||
Domain string
|
Domain string
|
||||||
IP net.IP
|
IP net.IP
|
||||||
|
IP6 net.IP
|
||||||
// IP network from which to allocate automatic sequential addresses
|
// IP network from which to allocate automatic sequential addresses
|
||||||
// Network is chosen randomly when not specified
|
// Network is chosen randomly when not specified
|
||||||
Network JSONIPNet
|
Network JSONIPNet
|
||||||
|
Network6 JSONIPNet
|
||||||
DNS net.IP
|
DNS net.IP
|
||||||
PeersOnline int
|
PeersOnline int
|
||||||
PeersTotal int
|
PeersTotal int
|
||||||
@ -88,6 +90,7 @@ func GenerateReport(dev *wgtypes.Device, conf *DsnetConfig, oldReport *DsnetRepo
|
|||||||
Description: peer.Description,
|
Description: peer.Description,
|
||||||
Added: peer.Added,
|
Added: peer.Added,
|
||||||
IP: peer.IP,
|
IP: peer.IP,
|
||||||
|
IP6: peer.IP6,
|
||||||
ExternalIP: externalIP,
|
ExternalIP: externalIP,
|
||||||
Networks: peer.Networks,
|
Networks: peer.Networks,
|
||||||
LastHandshakeTime: wgPeer.LastHandshakeTime,
|
LastHandshakeTime: wgPeer.LastHandshakeTime,
|
||||||
@ -104,7 +107,9 @@ func GenerateReport(dev *wgtypes.Device, conf *DsnetConfig, oldReport *DsnetRepo
|
|||||||
ListenPort: conf.ListenPort,
|
ListenPort: conf.ListenPort,
|
||||||
Domain: conf.Domain,
|
Domain: conf.Domain,
|
||||||
IP: conf.IP,
|
IP: conf.IP,
|
||||||
|
IP6: conf.IP6,
|
||||||
Network: conf.Network,
|
Network: conf.Network,
|
||||||
|
Network6: conf.Network6,
|
||||||
DNS: conf.DNS,
|
DNS: conf.DNS,
|
||||||
Peers: peerReports,
|
Peers: peerReports,
|
||||||
PeersOnline: peersOnline,
|
PeersOnline: peersOnline,
|
||||||
@ -159,6 +164,7 @@ type PeerReport struct {
|
|||||||
Added time.Time
|
Added time.Time
|
||||||
// Internal VPN IP address. Added to AllowedIPs in server config as a /32
|
// Internal VPN IP address. Added to AllowedIPs in server config as a /32
|
||||||
IP net.IP
|
IP net.IP
|
||||||
|
IP6 net.IP
|
||||||
// Last known external IP
|
// Last known external IP
|
||||||
ExternalIP net.IP
|
ExternalIP net.IP
|
||||||
// TODO ExternalIP support (Endpoint)
|
// TODO ExternalIP support (Endpoint)
|
||||||
|
Loading…
Reference in New Issue
Block a user