Forum Discussion
mart_58302
Nimbostratus
Aug 15, 2008Serving wpad.dat with F5?
Hello.
Maybe wrong area, but I'm trying to find out, is it possible to use F5 himself as web server, to serve text based file like wpad.dat or cache.pac for clients?
How ...
mart_58302
Nimbostratus
Oct 16, 2008
It is possible to do this. Take a look at:
http://devcentral.f5.com/wiki/default.aspx/iRules/LTMMaintenancePage.html
...for an example. This particular iRule serves content directly from the LTM (in this case, a maintenance page) and shows how/where to put the text and uuencoded graphics.
Hmm, but can I do it with just iRule, as this http in one line and non easy editable is too complicated, actually the wpad.dat file is very simple javascript code like this:
function FindProxyForURL(url, host) {
if(shExpMatch(host, "*[^0123456789.]*") == false)
if( isInNet(host, "127.0.0.0", "255.0.0.0")
|| isInNet(host, "172.17.0.0", "255.255.0.0")
|| isInNet(host, "172.18.0.0", "255.255.0.0")
)
return "DIRECT";
else
return "PROXY proxygateway.internal:8080; DIRECT";
)
I found one one similar example - http://devcentral.f5.com/Wiki/default.aspx/iRules/LTMMaintenancePageLite.html but didn't figure how how to access access it from F5 with url like this - http://wpad.internal/wpad.dat
Recent Discussions
Related Content
DevCentral Quicklinks
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com
Discover DevCentral Connects
