I
I
Ivan Semenov2016-10-26 10:18:07
Apache HTTP Server
Ivan Semenov, 2016-10-26 10:18:07

How to hide all clients behind one IP?

Good afternoon!
I have been suffering for several days with the solution of one problem, its essence is this.
The student, having entered his personal account on the university website, in the library systems section, follows the link to the elibrary.ru website , while an authorization window pops up where he enters his credentials from the personal account (the same as from the personal account on the university website) . after that he gets to the site elibrary.ru but on this site he should be seen under a certain ip address and not under the one under which he sits in the internet. For all this, we have an Apache proxy server on centos on which Virtual Host with the address elibrary.elib.mydomain.ru

<VirtualHost *:80>
 ServerName elibrary.elib.mydomain.ru
 ServerAlias www.elibrary.elib.mydomain.ru
 LogLevel warn
 ErrorLog /var/log/httpd/elibrary.elib.mydomain.ru.error_log
 TransferLog /var/log/httpd/elibrary.elib.mydomain.ru.access_log

<Location ~ "/*">
 AuthName " "
 AuthType Basic
 AuthBasicProvider ldap
 AuthzLDAPAuthoritative off
 AuthLDAPBindDN "[email protected]"
 AuthLDAPBindPassword XXXXXXXXXXX
 AuthLDAPURL ldap://XXX.XXX.XXX.XXX:389/DC=mydomain,DC=ru?sAMAccountName?sub?(objectClass=*)
 AuthLDAPGroupAttributeIsDN off
 ErrorDocument 401 "Please use your AD username and password to login this site."
 require valid-user
</Location>
ProxyVia On
ProxyPass / http://elibrary.ru/ connectiontimeout=5 timeout=30
ProxyPassReverse / http://elibrary.ru/
#ProxyPreserveHost On
</VirtualHost>

In short, it will blow away which goes to the virtual host elibrary.elib.mydomain.ru and sits on it behind the ip address of the proxy server, and the site elibrary.ru is hidden behind the virtual host. Those. The student sits on the site under a single university and hides behind a single ip address.
Help me figure out why it doesn't work and how to make it easier.

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question