Merge pull request #2333 from eladyn/proxy_proxyDNS_fix

enable proxyDNS only for supported proxies (SOCKS4/5)
This commit is contained in:
Andrea Marchesini 2022-04-25 19:52:48 +02:00 committed by GitHub
commit d4e9502e94
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -197,12 +197,17 @@ window.assignManager = {
return {}; return {};
} }
// proxyDNS only works for SOCKS proxies
if (["socks", "socks4"].includes(result.proxy.type)) {
result.proxy.proxyDNS = true;
}
if (!result.proxy.mozProxyEnabled) { if (!result.proxy.mozProxyEnabled) {
return { ...result.proxy, proxyDNS: true }; return result.proxy;
} }
// Let's add the isolation key. // Let's add the isolation key.
return [{ ...result.proxy, connectionIsolationKey: "" + MozillaVPN_Background.isolationKey, proxyDNS: true }]; return [{ ...result.proxy, connectionIsolationKey: "" + MozillaVPN_Background.isolationKey }];
}, },
// Before a request is handled by the browser we decide if we should // Before a request is handled by the browser we decide if we should