Search code examples
windowsfirefoxproxypac

Can I serve a wpad.dat file that tells the requesting system that there are no proxy settings?


I run a company webserver that seems to get hit constantly with wpad.dat requests. It fills up my error logs with 404 not found errors. I had considered ignoring the wpad.dat requests in the config, but upon further inspection it seems that some systems try to get this file every couple seconds at times. Some try several times a minute ongoing for days.

Can I create a wpad.dat file that I can serve to these systems to tell them there are no proxy settings so they can stop hammering the server with requests? I know the idea of the wpad.dat file is to provide auto-detected proxy settings. We only seem to have this issue with users logged into our VPN. Their web browsers just sit there and hammer the server with requests. I'd like to give them what they want. Any suggestions?


Solution

  • Serving this file seems to tell the connected system that there is no proxy info and to connect directly.

     function FindProxyForURL(url, host) {
       return "DIRECT";
     }