Show More
@@ -108,8 +108,13 b' class proxyhandler(urllib2.ProxyHandler)' | |||||
108 |
|
108 | |||
109 | def proxy_open(self, req, proxy, type_): |
|
109 | def proxy_open(self, req, proxy, type_): | |
110 | host = req.get_host().split(':')[0] |
|
110 | host = req.get_host().split(':')[0] | |
111 |
|
|
111 | for e in self.no_list: | |
112 | return None |
|
112 | if host == e: | |
|
113 | return None | |||
|
114 | if e.startswith('*.') and host.endswith(e[2:]): | |||
|
115 | return None | |||
|
116 | if e.startswith('.') and host.endswith(e[1:]): | |||
|
117 | return None | |||
113 |
|
118 | |||
114 | # work around a bug in Python < 2.4.2 |
|
119 | # work around a bug in Python < 2.4.2 | |
115 | # (it leaves a "\n" at the end of Proxy-authorization headers) |
|
120 | # (it leaves a "\n" at the end of Proxy-authorization headers) |
General Comments 0
You need to be logged in to leave comments.
Login now