aboutsummaryrefslogtreecommitdiffstats
path: root/libmproxy/protocol/primitives.py
diff options
context:
space:
mode:
authorMaximilian Hils <git@maximilianhils.com>2014-08-08 02:45:24 +0200
committerMaximilian Hils <git@maximilianhils.com>2014-08-08 02:45:24 +0200
commita9e6121a08c745961992c9fd2b4e4593063192f5 (patch)
tree87ab6b3348f0030249555e16b2ac190b674f17ee /libmproxy/protocol/primitives.py
parentc01b294d8d7c070547b9eb981b6001581b33c7b4 (diff)
downloadmitmproxy-a9e6121a08c745961992c9fd2b4e4593063192f5.tar.gz
mitmproxy-a9e6121a08c745961992c9fd2b4e4593063192f5.tar.bz2
mitmproxy-a9e6121a08c745961992c9fd2b4e4593063192f5.zip
properly express state information on server connections, refs #315
Diffstat (limited to 'libmproxy/protocol/primitives.py')
-rw-r--r--libmproxy/protocol/primitives.py8
1 files changed, 8 insertions, 0 deletions
diff --git a/libmproxy/protocol/primitives.py b/libmproxy/protocol/primitives.py
index f3ecdab7..7b936f7f 100644
--- a/libmproxy/protocol/primitives.py
+++ b/libmproxy/protocol/primitives.py
@@ -148,6 +148,14 @@ class ProtocolHandler(object):
"""
raise NotImplementedError # pragma: nocover
+ def handle_server_reconnect(self, state):
+ """
+ This method gets called if a server connection needs to reconnect and there's a state associated
+ with the server connection (e.g. a previously-sent CONNECT request or a SOCKS proxy request).
+ This method gets called after the connection has been restablished but before SSL is established.
+ """
+ raise NotImplementedError # pragma: nocover
+
def handle_error(self, error):
"""
This method gets called should there be an uncaught exception during the connection.