Karl Dahlke <[email protected]> writes: > Can you specify proxy exceptions within curl?
Nope. This will be a fun can of worms. In corporate settings, the proxy you use may depends on the URL you're trying to fetch. See http://en.wikipedia.org/wiki/Proxy_auto-config It's going to be more complicated than just supporting exceptions. Here's a long quote from that article: <quote> Computer {operating systems} (e.g., {Microsoft Windows} {Mac OS X} {Linux}) require a number of settings to communicate over the {Internet}. These settings are typically obtained from an {Internet Service Provider} (ISP). Either anonymous (proxy to use a {proxy server}) or real settings may be used to establish a network connection. The PAC File{edit} The Proxy auto-config file format was originally designed by {Netscape} in 1996 for the {Netscape Navigator 2.0}^{[1]} and is a {text file} that defines at least one JavaScript function, FindProxyForURL(url, host), with two arguments: url is the URL of the object and host is the host-name derived from that URL. By convention, the PAC file is normally named proxy.pac. The {WPAD standard} uses wpad.dat. To use it, a PAC file is published to a {HTTP server}, and client user agents are instructed to use it, either by entering the URL in the proxy connection settings of the browser or through the use of the WPAD protocol. A very simple example of a PAC file is: function FindProxyForURL(url, host) { return "PROXY proxy.example.com:8080; DIRECT"; } This function instructs the browser to retrieve all pages through the proxy on {port} 8080 of the server proxy.example.com. Should this proxy fail to respond, the browser contacts the Web-site directly, without using a proxy. The latter may fail if {firewalls}, or other intermediary network devices, reject requests from sources other than the proxy; a common configuration in corporate networks. A more complicated example demonstrates some available JavaScript functions to be used in the FindProxyForURL function: function FindProxyForURL(url, host) { // our local URLs from the domains below example.com don't need a proxy: if (shExpMatch(host, "*.example.com")) { return "DIRECT"; } // URLs within this network are accessed through // port 8080 on fastproxy.example.com: if (isInNet(host, "10.0.0.0", "255.255.248.0")) { return "PROXY fastproxy.example.com:8080"; } // All other requests go through port 8080 of proxy.example.com. // should that fail to respond, go directly to the WWW: return "PROXY proxy.example.com:8080; DIRECT"; } </quote> Yeah, I had to deal with this stuff when I worked for $big_company. For all intents and purposes, edbrowse was completely unusable on that network. -- Chris _______________________________________________ Edbrowse-dev mailing list [email protected] http://lists.the-brannons.com/mailman/listinfo/edbrowse-dev
