Feature: Multiple IPs for each Torguard server

- Fallback on IP from configuration file if DNS resolution fails
- Download both TCP and UDP zip files to detect support for each
- Filter servers by supported network protocol
-
This commit is contained in:
Quentin McGaw
2021-05-10 01:48:52 +00:00
parent eff65dce00
commit 95b0fb81d6
9 changed files with 248 additions and 119 deletions

View File

@@ -222,7 +222,8 @@ func (u *updater) updateSurfshark(ctx context.Context) (err error) {
func (u *updater) updateTorguard(ctx context.Context) (err error) {
minServers := getMinServers(len(u.servers.Torguard.Servers))
servers, warnings, err := torguard.GetServers(ctx, u.unzipper, minServers)
servers, warnings, err := torguard.GetServers(
ctx, u.unzipper, u.presolver, minServers)
if u.options.CLI {
for _, warning := range warnings {
u.logger.Warn("Torguard: %s", warning)