function FindProxyForURL(url, host) { // If the hostname matches, send direct. if (dnsDomainIs(host, "(*.4lpi.pvt|4lpi.pvt)") || shExpMatch(host, "(*.4lpi.pvt|4lpi.pvt|*.4lpi.com|4lpi.com)")) return "DIRECT"; // If the requested website is hosted within the internal network, send direct. if (isPlainHostName(host) || shExpMatch(host, "(*.local|*.pvt)") || isInNet(dnsResolve(host), "10.0.0.0", "255.0.0.0") || isInNet(dnsResolve(host), "172.16.0.0", "255.240.0.0") || isInNet(dnsResolve(host), "192.168.0.0", "255.255.0.0") || isInNet(dnsResolve(host), "127.0.0.0", "255.255.255.0")) return "DIRECT"; if (shExpMatch(host, "(litle.com|*.litle.com)") || shExpMatch(host, "(vantiv.com|*.vantiv.com)")) return "PROXY 192.168.100.80:3128"; if (shExpMatch(host, "(kaspersky.com|*.kaspersky.com)")) return "DIRECT"; // if (shExpMatch(host, "(microsoft.com|*.microsoft.com)")) return "DIRECT"; // if (shExpMatch(host, "(windowsupdate.com|*.windowsupdate.com)")) return "DIRECT"; if (url.substring(0, 6) == "https:") return "DIRECT"; // DEFAULT RULE: All other traffic, use below proxies, in fail-over order. return "PROXY 192.168.100.80:3128; PROXY 192.168.2.2:3128; DIRECT"; }