aboutsummaryrefslogtreecommitdiffstats
path: root/libmproxy/proxy/server.py
diff options
context:
space:
mode:
authorMaximilian Hils <git@maximilianhils.com>2014-05-21 01:16:22 +0200
committerMaximilian Hils <git@maximilianhils.com>2014-05-21 01:16:22 +0200
commitdecb6f998a1b3e257a1b6dc1dbae57e3c95b5059 (patch)
tree920fb29d27d778371dc86ea7c2ed784b659bc2f0 /libmproxy/proxy/server.py
parent00fd243810954b1ea7c108482513a7e92f2e8000 (diff)
downloadmitmproxy-decb6f998a1b3e257a1b6dc1dbae57e3c95b5059.tar.gz
mitmproxy-decb6f998a1b3e257a1b6dc1dbae57e3c95b5059.tar.bz2
mitmproxy-decb6f998a1b3e257a1b6dc1dbae57e3c95b5059.zip
add support for certificate chains, refs #174
Diffstat (limited to 'libmproxy/proxy/server.py')
-rw-r--r--libmproxy/proxy/server.py8
1 files changed, 5 insertions, 3 deletions
diff --git a/libmproxy/proxy/server.py b/libmproxy/proxy/server.py
index 1820c881..741e5f93 100644
--- a/libmproxy/proxy/server.py
+++ b/libmproxy/proxy/server.py
@@ -197,7 +197,8 @@ class ConnectionHandler:
cert, key,
handle_sni=self.handle_sni,
cipher_list=self.config.ciphers,
- dhparams=self.config.certstore.dhparams
+ dhparams=self.config.certstore.dhparams,
+ ca_file=self.config.ca_file
)
def server_reconnect(self, no_ssl=False):
@@ -260,11 +261,12 @@ class ConnectionHandler:
cert, key,
method=SSL.TLSv1_METHOD,
cipher_list=self.config.ciphers,
- dhparams=self.config.certstore.dhparams
+ dhparams=self.config.certstore.dhparams,
+ ca_file=self.config.ca_file
)
connection.set_context(new_context)
# An unhandled exception in this method will core dump PyOpenSSL, so
# make dang sure it doesn't happen.
- except Exception, e: # pragma: no cover
+ except Exception: # pragma: no cover
import traceback
self.log("Error in handle_sni:\r\n" + traceback.format_exc(), "error") \ No newline at end of file