Search code examples
pythonmacosproxybrowsermob

How does one configure a proxy upstream of browsermob on osx?


I'm looking to configure an upstream proxy for browsermob, preferably programmatically from within a python or shell script.

It doesn't look like the python bindings for browsermob include an upstream-proxy configuration command or method. Is there another method I can use?


Solution

  • The python bindings do actually allow you to configure an upstream proxy. When creating a proxy using create_proxy, you can set the value of httpProxy to the IP address and port of the upstream proxy (see the params parameter on create_proxy for details).