如果將這些代理伺服器用於網域與子網域:
*intranet1.com proxy.intranet.com:8080
intranet2.com proxy.intranet1.com:8080
相對應的 PAC 檔案是:
// Start of the PAC File function FindProxyForURL(url, host) { if (dnsDomainIs(host, ".intranet1.com")) { return "DIRECT"; } if (dnsDomainIs(host, ".intranet2.com")) { return "PROXY proxy.intranet1.com:8080"; } return "NULL"; } //End of the PAC File |