revshell / collective-intelligence-framework

Automatically exported from code.google.com/p/collective-intelligence-framework
0 stars 0 forks source link

python-cif: proxy support #116

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
http://httplib2.googlecode.com/hg/doc/html/libhttplib2.html#httplib2.ProxyInfo

patch sorta looks like:

@@ -64,7 +74,12 @@
             else:
                 queryString += '&' + str(p) + '=' + params[p]

-        resp,ret = 
httplib2.Http(disable_ssl_certificate_validation=self.no_verify_tls).request(s+q
ueryString)
+        p = None
+        #if self.proxy_host:
+        #    proxyport = self.proxy_port
+        #    p = httplib2.ProxyInfo(proxy_type=socks.PROXY_TYPE_SOCKS5, 
proxy_host=self.proxy_host, proxy_port = self.proxy_port)
+
+        resp,ret = httplib2.Http(proxy_info = 
p,disable_ssl_certificate_validation=self.no_verify_tls).request(s+queryString)
         ret = json.loads(ret)

missing something still though.

Original issue reported on code.google.com by saxjazm...@gmail.com on 26 Oct 2011 at 7:39

GoogleCodeExporter commented 9 years ago
$ vi ~/.cif
[client]
host = ...
apikey = ...
proxy_host = localhost
proxy_port = 8080
proxy_type = SOCKS5

where proxy_type can be anything from:

http://socksipy.sourceforge.net/

PROXY_TYPE_HTTP -- HTTP
PROXY_TYPE_SOCKS5 -- SOCKS5

ref: 
http://code.google.com/p/collective-intelligence-framework/source/detail?r=1132

Original comment by saxjazm...@gmail.com on 27 Oct 2011 at 11:25

GoogleCodeExporter commented 9 years ago

Original comment by saxjazm...@gmail.com on 27 Oct 2011 at 11:25

GoogleCodeExporter commented 9 years ago
will be fixed in 
http://code.google.com/p/collective-intelligence-framework/issues/detail?id=82

Original comment by saxjazm...@gmail.com on 6 Jan 2012 at 12:13

GoogleCodeExporter commented 9 years ago

Original comment by saxjazm...@gmail.com on 6 Jan 2012 at 12:13