Score:0

Selective forward proxy for testing

ch flag

I have a very specific testing situation where I want to use a forward proxy like so:

Client -> Forward Proxy 1 -> Forward Proxy 2 (WireMock)
                         |
                          -> Internet

Forward Proxy 1 would be responsible for forwarding requests for a whitelist of (destination) hosts to Forward Proxy 2 (WireMock), which may send back a mock response or may proxy further to the client's intended destination host. All other (non-whitelisted) requests should be proxied directly to the client's intended destination host by Forward Proxy 1.

The solution must support HTTPS requests. For the WireMock path, WireMock is acting as a MITM and generating self-signed SSL responses sometimes (which the clients are set up to trust, but I don't know if this is relevant for Forward Proxy 1). This solution needs to be available as a docker image, should be as lightweight as possible, and does not need to be particularly performant.

I've tried figuring out how to configure nginx, Squid, HAProxy like this, but no luck so far. Any pointers on how to attack this?

Thanks!

Michael Hampton avatar
cz flag
First, you need to choose the proxy software. Use software that was actually designed for forward proxying, such as squid. Then, you need to configure it. If you run into a problem and need help, you can ask _specific_ questions about it.
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.