Передача правильного IP клиента апачу с mod_rpaf

Vladimir Larionov incognito at opencom.ru
Tue Nov 6 11:29:16 MSK 2007



as at nn.ru пишет:
> Hi All
> Поможите в такой теме:
> есть сервер1 с внешней IP , если nginx приходят запросы то локальным
> апачам запущенным на этом сервере1 передается правильная айпишка
> клиента, хочется задействовать апачи с других серверов(2,3), по
> локальному интерфейсу, но для них не получается пробросить реальный
> адрес клиента и .htaccess из этого "не правильно себя ведет" и в логах
> апачей видим только локальный адрес интерфейса сервера1, а хотелось бы
> адрес клиента, подскажите как правильно настроить nginx или апач с
> realip или rpaf

	http://stderr.net/apache/rpaf/
Module configuration is pretty simple, there are only two directives to 
set; RPAFenable and RPAFproxy_ips. With the later you can define which 
IP's are your frontend proxies that sends the correct X-Forwarded-For 
headers. If you do not use the RPAFproxy_ips directive then the module 
will not change the remote address of the incoming connection at any 
time. RPAFsethostname will, when enabled, take the incoming X-Host 
header and update the virtualhost settings accordingly.

# if DSO load module first:
LoadModule rpaf_module libexec/apache2/mod_rpaf-2.0.so

RPAFenable On
RPAFsethostname On
RPAFproxy_ips 127.0.0.1 10.0.0.1 ...

	В случае с realip, подозреваю, директива будет
RealIP  localhost 192.168.1.1 ...


-- 
WRB, LVP-RIPE INCOGNITO-RIPN





More information about the nginx-ru mailing list