Deskpro has a proxy mode which tells it to trust IP addresses forwarded in HTTP headers.
You should enable proxy mode in these cases:
- Your network configuration requires that you access Deskpro through proxy servers.
- You are running Deskpro on multiple load-balanced nodes to increase availability.
To enable proxy mode, in the Deskpro config.php
edit the following line:
$DP_CONFIG['trust_proxy_data'] = false;
copy
You must specify the IP addresses or address ranges of trusted proxies using CIDR notation:
$DP_CONFIG['trust_proxy_data'] = array(
'192.168.1.83', // whitelist this specific IP
'192.168.0.0/24' // whitelist this range (192.168.0.0 - 255)
'@/etc/proxy_list.php', // read addresses from file (as PHP array)
);
copy
If this is not configured correctly, it may appear that all users have the same IP address (the address of the proxy server).
For Deskpro to function properly, the servers it interacts with must be sending proper headers with each request:
- X-Forwarded-For: The IP address of the user.
- X-Forwarded-Host: The real hostname the user requested.
- X-Forwarded-Port: The real port the user requested (usually 80 or 443 for SSL)
- X-Forwarded-Proto: The protocol (HTTP or HTTPS) of the user request
Bitte loggen Sie sich ein oder melden Sie sich an, um einen Kommentar zu hinterlassen.