Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /**
- The original template was created by Sam Gleske
- This author and license block must stay intact for use even if this script is
- modified!
- License:
- This file falls under the MIT Licence
- http://www.opensource.org/licenses/mit-license.php
- Take responsibility for your own actions.
- Generated using Python and predefined proxy lists!
- http://sourceforge.net/projects/webtechtools/files/Proxy%20wpad.dat%20Generator/
- You are not authorized to use this proxy configuration for illegal purposes.
- This file follows the Netscape WPAD standard. Please read the documentation
- after the configuration options for additional warnings and tips information.
- **/
- /*
- * Configuration Options
- */
- //Enables console logging (true/false, default true)
- var ENABLE_LOGGING=true;
- //Enable friendly excludes (true/false, default true)
- //If a request matches an exclude then it will create a direct connection rather than proxy
- //This option must be disabled for user defined excludes to work
- var ENABLE_EXCLUDES=true;
- //User defined Protocol excludes (array)
- var protocol_excludes=[];
- //User defined IP excludes (array)
- var ip_excludes=[];
- //User defined Domain excludes (array)
- var domain_excludes=[];
- //Enable predefined proxy list (true/false, default true)
- //This option must be disabled for the user defined proxy list
- var ENABLE_PREDEFINED_PROXY_LIST=true;
- //User defined proxy list (array)
- var proxylist=[];
- /*
- * End of Configuration Options
- */
- /************************************************************************************
- WARNINGS, INFORMATION, AND ADDITIONAL DOCUMENTATION
- *************************************************************************************
- It is highly recommended that you keep this documentation block if you modify
- this file.
- DO NOT, I repeat, DO NOT log into web portals where financial or personal
- information is at risk using an anonymous/3rd party proxy. It is possible that
- an anonymous proxy is set up to record all traffic and to mine usernames and
- passwords for websites. Monitoring insecure authentication or cookies are just a
- few of many methods to achieve this. I have set up some rules which will help
- minimize the effect of this but it is still recommended to disable this proxy
- whenever handling such information. This is not a flaw of this software or
- wpad.dat but more the nature of an anonymous proxy.
- Public Proxies and the Law
- According to U.S. law, 18 U.S.C. Section 1030 (Fraud and Related Activity in
- Connection with Computers) applies only when anyone who knowingly accesses a
- computer without authorization or has knowingly exceeds his authorized access on
- that computer. Because an opened proxy, by default, allows connections and use of
- the service by anyone in the WWW, its administrator has essentially authorized
- everyone to use the proxy. Therefore browsing the web, via anonymous proxies, is
- not illegal.
- This software is geared towards advanced end users and security professionals. By
- using this software you agree to the MIT license which governs any unlicensed
- software or files related to this file.
- What is wpad.dat?
- wpad.dat is a Web Proxy Automatic Detection (WPAD) file. Your browser selects a
- proxy based on the pre-defined rules specified in the wpad.dat file. The language
- is JavaScript for wpad.dat.
- Pros/Cons of proxying using my wpad.dat method?
- Pros:
- * Your IP address is constantly changing from the perspective of the web
- server making you impossible to track.
- * There are pre-defined rules which help to protect your information if you
- accidently forget to turn off this proxy method while browsing websites
- where financial or personal information are at risk.
- * If a website is using an encrypted connection then it does not go through
- any anonymous proxy. PLEASE NOTE if you opt out of my predefined rules
- then this is no longer the case.
- Cons:
- * Your browsing speed is slightly diminished because you are visiting
- websites via a proxy.
- * Your browsing habits and information are not guarunteed to be protected
- from the anonymous proxy if by some happance this file is misconfigured.
- *************************************************************************************
- End of Documentation
- *************************************************************************************/
- //////////////// No need to edit beyond this point ///////////////
- //Custom defined functions for cleaner processing
- function exclude(source,rules)
- {
- try
- {
- for(var i=0;i<rules.length;i++)
- if(shExpMatch( source, rules[i]))
- return true;
- return false;
- }
- catch(e)
- {
- if(ENABLE_LOGGING)
- alert("An exception has been encountered!\n" + source + "\n" + rules);
- return false;
- }
- }
- //Initialization Function
- function FindProxyForURL(url, host)
- {
- //These are my personal excludes just in case I accidently go to a login site with this proxy enabled
- if(ENABLE_EXCLUDES)
- {
- ip_excludes=[
- "10.*", //private address range
- "172.*", //private address range
- "192.*", //private address range
- "127.*", //loopback or localhost
- "144.118.*", //Drexel University
- "74.125.*", //Google
- "67.195.*", //Yahoo Inc
- "170.201.*", //PNC Bank
- "66.95.*", //United Bank
- "12.*", //AT&T WorldNet Services (covers AES and other banking websites)
- "164.109.*" //Digex, Incorporated. (Covers PECO and Exelon Corp)
- ];
- domain_excludes=[
- "*accuweather.com",
- "*mozdev.org",
- "*mozilla.org",
- "*bankofamerica.com",
- "*campusfood.com",
- "*chase.com*",
- "*clubbleach.org",
- "*crunchyroll.com",
- "*dccc.edu*",
- "*domaintools.com",
- "*ea.com",
- "*ebay.com",
- "*ebayrtm.com",
- "*ebaystatic.com",
- "*expedia.com",
- "*experts-exchange.com",
- "*facebook.com",
- "*fbcdn.net",
- "*flagfox.net",
- "*fsdn.com",
- "*godaddy.com",
- "www.google.*", //Needed for when Google randomly decides to load files from another country like www.google.ca or www.google.com.ph
- "*.gov",
- "*geotrust.com",
- "*ingdirect.com",
- "*ittoolbox.com",
- "*live.com",
- "*logmein.com",
- "*mqcdn.com",
- "*msn.com",
- "*newegg.ca",
- "*newegg.com",
- "*neweggimages.com",
- "*passport.com",
- "*passport.net",
- "*passportimages.com",
- "*paypal.com",
- "*paypalobjects.com",
- "*register.com",
- "*sf.net",
- "*sourceforge.net",
- "*steampowered.com",
- "*thawte.com",
- "*verisign.com",
- "*yahoo.com",
- "*whois.net"
- ];
- protocol_excludes=[
- "about:*",
- "aim:*",
- "chrome:*",
- "file:*",
- "https:*",
- "sftp:*",
- "socks:*",
- "steam:*",
- "telnet:*"
- ];
- };
- //Run exclude rules for protocols, domain names, and ip addresses
- if(exclude(url.toLowerCase(),protocol_excludes))
- {
- if(ENABLE_LOGGING)
- alert("Exclude rule triggered: protocol\n" + url);
- return "DIRECT";
- };
- if(exclude(dnsResolve(host),ip_excludes))
- {
- if(ENABLE_LOGGING)
- alert("Exclude rule triggered: ip\n" + dnsResolve(host));
- return "DIRECT";
- };
- if(exclude(host.toLowerCase(),domain_excludes))
- {
- if(ENABLE_LOGGING)
- alert("Exclude rule triggered: domain\n" + dnsResolve(host) + "\n" + host);
- return "DIRECT";
- };
- //Pre-defined proxy list
- if(ENABLE_PREDEFINED_PROXY_LIST)
- {
- proxylist=[
- "91.209.24.4:3128",
- "91.209.24.3:3128",
- "222.124.189.93:8080",
- "192.99.169.33:80",
- "202.166.218.136:8080",
- "193.60.133.147:80",
- "190.152.167.163:3128",
- "36.75.212.171:8080",
- "190.92.49.203:8080",
- "118.193.134.80:3128",
- "120.237.3.227:80",
- "176.35.226.195:3128",
- "210.75.14.157:80",
- "116.213.211.130:80",
- "190.29.24.23:8080",
- "23.102.160.68:3128",
- "190.102.17.84:80",
- "211.162.39.98:80",
- "201.18.145.149:3128",
- "188.120.254.160:3128",
- "58.26.17.167:8080",
- "79.136.250.37:3128",
- "111.7.128.135:8080",
- "207.223.117.198:3128",
- "115.114.148.71:80",
- "58.254.132.87:80",
- "183.221.247.122:80",
- "202.152.196.141:8080",
- "200.86.217.67:3128",
- "189.1.97.44:3128",
- "106.185.26.65:3128",
- "190.167.198.157:8080",
- "36.75.215.86:80",
- "111.7.128.132:8080",
- "153.120.25.103:80",
- "187.53.61.43:8080",
- "111.11.184.103:80",
- "183.57.78.93:80",
- "193.36.34.10:3128",
- "118.98.73.122:80",
- "202.21.181.110:3128",
- "218.213.227.186:8080",
- "65.19.227.253:8080",
- "93.76.255.80:8080",
- "185.14.251.242:8080",
- "177.99.164.167:8080",
- "118.26.224.160:80",
- "61.247.188.66:8080",
- "200.199.73.189:3128",
- "180.153.32.9:8080",
- "111.26.20.75:8080",
- "117.121.21.222:80",
- "61.7.231.139:3128",
- "116.218.129.154:8080",
- "152.26.7.16:8080",
- "77.89.244.102:80",
- "186.103.171.76:3128",
- "218.204.131.250:3128",
- "203.81.93.38:8080",
- "212.68.51.58:80",
- "78.38.101.2:8080",
- "210.101.131.232:8080",
- "103.10.61.3:8080",
- "118.96.58.82:8080",
- "202.106.16.36:3128",
- "203.144.170.99:3128",
- "36.79.179.74:3128",
- "111.11.184.83:80",
- "202.118.10.101:8080",
- "176.108.100.229:8080",
- "183.207.229.137:80",
- "111.11.184.45:80",
- "223.197.55.81:8080"
- ];
- };
- //Generate a random index for the proxy list
- try
- {
- var index=-1;
- while(index<0)
- index=Math.ceil(proxylist.length*Math.random())-1;
- if(proxylist.length)
- {
- if(ENABLE_LOGGING)
- alert("Rule not triggered!\n" + dnsResolve(host) + "\n" + host.toLowerCase() + "\n" + url.toLowerCase() + "\nUsing Proxy: " + proxylist[index]);
- return "PROXY "+proxylist[index];
- }
- else
- return "DIRECT";
- }
- catch(e)
- {
- if(ENABLE_LOGGING)
- alert("An exception has been encountered!\n" + proxylist);
- return "DIRECT";
- };
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement