@@ -56,6 +56,18 @@ func (s *SurfsharkServer) String() string {
|
||||
return fmt.Sprintf("{Region: %q, IPs: %s}", s.Region, goStringifyIPs(s.IPs))
|
||||
}
|
||||
|
||||
type TorguardServer struct {
|
||||
Country string `json:"country"`
|
||||
City string `json:"city"`
|
||||
Hostname string `json:"hostname"`
|
||||
IP net.IP `json:"ip"`
|
||||
}
|
||||
|
||||
func (s *TorguardServer) String() string {
|
||||
return fmt.Sprintf("{Country: %q, City: %q, Hostname: %q, IP: %s}",
|
||||
s.Country, s.City, s.Hostname, goStringifyIP(s.IP))
|
||||
}
|
||||
|
||||
type CyberghostServer struct {
|
||||
Region string `json:"region"`
|
||||
Group string `json:"group"`
|
||||
|
||||
@@ -9,6 +9,7 @@ type AllServers struct {
|
||||
Privado PrivadoServers `json:"privado"`
|
||||
Purevpn PurevpnServers `json:"purevpn"`
|
||||
Surfshark SurfsharkServers `json:"surfshark"`
|
||||
Torguard TorguardServers `json:"torguard"`
|
||||
Vyprvpn VyprvpnServers `json:"vyprvpn"`
|
||||
Windscribe WindscribeServers `json:"windscribe"`
|
||||
}
|
||||
@@ -21,6 +22,7 @@ func (a *AllServers) Count() int {
|
||||
len(a.Privado.Servers) +
|
||||
len(a.Purevpn.Servers) +
|
||||
len(a.Surfshark.Servers) +
|
||||
len(a.Torguard.Servers) +
|
||||
len(a.Vyprvpn.Servers) +
|
||||
len(a.Windscribe.Servers)
|
||||
}
|
||||
@@ -60,6 +62,11 @@ type SurfsharkServers struct {
|
||||
Timestamp int64 `json:"timestamp"`
|
||||
Servers []SurfsharkServer `json:"servers"`
|
||||
}
|
||||
type TorguardServers struct {
|
||||
Version uint16 `json:"version"`
|
||||
Timestamp int64 `json:"timestamp"`
|
||||
Servers []TorguardServer `json:"servers"`
|
||||
}
|
||||
type VyprvpnServers struct {
|
||||
Version uint16 `json:"version"`
|
||||
Timestamp int64 `json:"timestamp"`
|
||||
|
||||
Reference in New Issue
Block a user