J
J
JSmileMan2016-04-24 13:13:38
linux
JSmileMan, 2016-04-24 13:13:38

How to use different proxies for different sites on Linux?

Hello.
There is a debian-server to which I connect from Windows through OpenVPN. I want to make sure that different proxies are used for different sites.
Example:
A request from Windows to 1.1.1.1 goes through a tunnel to Debian, where it is forwarded to Proxy1, and from there to site 1.1.1.1 and back.
A request from Windows to 2.2.2.2 goes through a tunnel to Debian, where it is forwarded to Proxy2, and from there to site 2.2.2.2 and back.
Let the list of sites and the list of proxies be limited, and it is also possible to use a static link Site - Proxy (that is, you can go to one site from the same proxy).
How can this be organized?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
V
Vladimir Dubrovin, 2016-04-24
@JSmileMan

There are two ways:
1. Through the proxy auto-configuration file (PAC-file)
findproxyforurl.com/example-pac-file
, it is registered in the browser properties, no additional plugins are required.
2. Install a local proxy that will redirect traffic to the parent according to the specified rules. For example, for 3proxy the configuration is:
internal 127.0.0.1
auth iponly
allow * * 1.1.1.1
parent 1000 http proxy1 port1
allow * * 2.2.2.2
parent 1000 http proxy2 port2

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question