This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Proxy Auto Configuration

Hi guys,

I am currently playing around with this proxy auto configuration and currently i follow what that is mentioned in the "help" guide.

=======
function FindProxyForURL(url, host)
{ return "PROXY proxy.example.com:8080; DIRECT"; }
=======

i edited it to this below:

function FindProxyForURL(url, host)
{ return "PROXY 192.168.1.254:8080; gw.mygw.com"; }

========

edit:
I've gotten it to work.

Now another issue.
With this Proxy Auto Configuration enabled in my browser, I could not access the ASG Webadmin.

Any ideas?

Thank you.


This thread was automatically locked due to age.
Parents Reply Children
  • Here is the proxy.pac file i ended up deploying to several computers (with name changed of course)
    Some notes about the file:
    the *.toLowerCase() is to make sure that if someone types in server.COMPANY.local it is properly handled (DIRECT)
    the line "isPlainHostName(host)" makes it work with a sharepoint server (registered as a CNAME/alias in the DNS) that the astaro doesn't handle well.
    || is "or"
     in 'return "PROXY webfilter.company.local:800; DIRECT";' i used the FQDN so that the browser will pass kerberos and AD SSO will work properly.  Also, this file is used on laptops that require access to the internet when offsite, so the last DIRECT makes it connect to the internet if it cannot find the proxy in DNS. To prevent access offsite, i just remove that last DIRECT.  
    Hope this helps

    //-----------------------------------------------------------------------
    function FindProxyForURL(url, host)
    {
    url=url.toLowerCase();
    host=host.toLowerCase();
    //The following URLs will not be proxied
    if ( isPlainHostName(host)
    || dnsDomainIs(host, "companyintranet")
    || dnsDomainIs(host, ".company.local")
    || dnsDomainIs(host, "localhost")
    || isInNet(host, "192.168.0.0", "255.255.0.0")
    || isInNet(host, "127.0.0.0", "255.255.255.0")
    )
    return "DIRECT" ;
    else
    return "PROXY webfilter.company.local:800; DIRECT"; }
    //-----------------------------------------------------------------------

    Edit: Returning to the initial question of the webadmin, by creating the exception "|| isInNet(host, "192.168.0.0", "255.255.0.0")" if using the local IP address it will go straight to the webmin rather than trying to pass that through the proxy too.  Be sure to use a more restricted net/subnet combo if you can i.e.  "192.168.1.0", "255.255.255.0".