代理自动配置脚本

ie
file://d:/PersonalSet/agent.pac
火狐
file:///d:/PersonalSet/agent.pac

function FindProxyForURL(url, host)
{

if (isPlainHostName(host))
{
     return "DIRECT";
}

if (isInNet(host, "10.0.0.0", "255.0.0.0"))
{
     return "DIRECT";
}

if (shExpMatch(host,"*.company.com"))
{
    return "DIRECT";
}

// if (isResolvable(host))
// {
// return "DIRECT";
// }

     return "PROXY proxy.com:8080";
}

posted @ 2014-06-15 13:52  dzqabc  阅读(1668)  评论(0编辑  收藏  举报