0

I used this Tony Hirst blog to capture the required data to scrape a website. But I am only able to extract response for the last one of the flow but there are actually multiple response bodies in the log file. How to tweak the code to write all the responses in the json created instead of only one?

alias micheal
  • 121
  • 1
  • 1
  • 5

1 Answers1

0

An easy way would be to write an addon that prints out what you are interested in:

def response(flow):
    print(flow.response.text)

You can then run this with mitmdump -r flows.mitm -s printjson.py flowfilter.

Maximilian Hils
  • 6,309
  • 3
  • 27
  • 46