Manual:$wgUsePrivateIPs/pl
From Linux Web Expert
<translate> HTTP proxy (CDN) settings</translate>: $wgUsePrivateIPs | |
---|---|
Whether private X-Forwarded-For IPs should be accepted |
|
<translate> Introduced in version:</translate> | 1.14.0 (r43784) |
<translate> Removed in version:</translate> | <translate> still in use</translate> |
<translate> Allowed values:</translate> | (boolean) |
<translate> Default value:</translate> | false |
<translate> Other settings:</translate> <translate> Alphabetical</translate> | <translate> By function</translate> |
Szczegóły
Determines whether MediaWiki will trust an X-Forwarded-For (XFF) header specifying a private IP in requests from a trusted forwarding proxy.
If set to false
, private IP addresses in the XFF header will be ignored.
A trusted forwarding proxy is any proxy listed in either $wgCdnServers or $wgCdnServersNoPurge
.
Extensions can also mark proxies as trusted via the IsTrustedProxy
hook.
So if you have two traffic managers (Might be Zeus or F5) sending requests to your webservers, forwarding from an internal network, the config might be this:
$wgUsePrivateIPs = true;
$wgCdnServersNoPurge = array( '172.1.1.1', '172.1.1.2' );