I'm trying configure an SRX router to automatically forward all traffic through a proxy server i have in the USA.
I have created a separate vlan and configured the proxy but not sure how i can route all traffic through this.
The aim of this task is create a test network which makes users appear in the location of the proxy server. (with the external ip address of the proxy)
Is this possible and how should i do this. Am i approaching this the right way?
Thanks
Best Answer
Here is how I usually do this on JunOS. It doesn't really matter that you're on an SRX, but keep in mind NAT rules still apply.
I recommend you do not put the proxy server on the same VLAN as the clients. It can make a nice routing loop.
Then, you apply that filter as a family inet filter to an interface, in your case a VLAN interface.
Keep in mind, my example only traps ports 80/443 over to the proxy, if you have other applications, or you want to do this for an entire subnet, in the filter you can match on source or destination IP address or just send everything.
If you want to send ALL traffic to the proxy server from that VLAN, use these lines: