Skip to content

Commit

Permalink
The mitmproxy API seems to have changed and the syntax is now http.Re…
Browse files Browse the repository at this point in the history
…sponse.make
  • Loading branch information
himanshunikhare25 committed Mar 10, 2023
1 parent 890b0cb commit 30b2f65
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/main/resources/scripts/proxy.py
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,7 @@ def request(self, flow):
new_metadata = message_response[0]
new_body = message_response[1]

flow.response = http.HTTPResponse.make(
flow.response = http.Response.make(
new_metadata['status_code'],
new_body,
map(convert_headers_to_bytes, new_metadata['headers'])
Expand Down Expand Up @@ -198,7 +198,7 @@ def response(self, flow):

#print("Prepping response!")

flow.response = http.HTTPResponse.make(
flow.response = http.Response.make(
new_metadata['status_code'],
new_body,
map(convert_headers_to_bytes, new_metadata['headers'])
Expand Down

0 comments on commit 30b2f65

Please sign in to comment.