Continue handling HTTP flows if flow logging fails
If flow beautification for display throws then we don't want to bypass other handling of the flow. This fixes a login failure due to SL's login XML-RPC endpoint returning a Content-Type of "application/llsd+xml/r/n" when it's actually "application/xml".
This commit is contained in:
@@ -212,7 +212,10 @@ class MITMProxyEventManager:
|
||||
def _handle_response(self, flow: HippoHTTPFlow):
|
||||
message_logger = self.session_manager.message_logger
|
||||
if message_logger:
|
||||
message_logger.log_http_response(flow)
|
||||
try:
|
||||
message_logger.log_http_response(flow)
|
||||
except:
|
||||
logging.exception("Failed while logging HTTP flow")
|
||||
|
||||
# Don't process responses for requests or responses injected by the proxy.
|
||||
# We already processed it, it came from us!
|
||||
|
||||
Reference in New Issue
Block a user