Decrypt Traffic Route to Squid then Encrypt Back?


#1

Hello i’m working on a project to cache HTTPS connection via squid server, so i’m wondering if i can route the decrypted HTTPS traffic to squid server so he logs it then i route back the traffic from squid server to mitm server to encrypt it back and send it to facebook/google Graph:

Internet <—> MITMPROXY <====> Squid Server <====> MITMPROXY <----> User.

Thank you! if you got another suggestion please tell me!


#2

im not sure how you would go about doing this but you might wish to look at this file for ideas https://github.com/mitmproxy/mitmproxy/blob/master/examples/simple/redirect_requests.py