MyBB Community Forums

Full Version: Show visiters IPs instead of cloudflares.
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
I'm running nginx and I run all of my traffic through cloudflare (via whitelisting)

# https://www.cloudflare.com/ips
# IPv4
allow 103.21.244.0/22;
allow 103.22.200.0/22;
allow 103.31.4.0/22;
allow 104.16.0.0/12;
allow 108.162.192.0/18;
allow 131.0.72.0/22;
allow 141.101.64.0/18;
allow 162.158.0.0/15;
allow 172.64.0.0/13;
allow 173.245.48.0/20;
allow 188.114.96.0/20;
allow 190.93.240.0/20;
allow 197.234.240.0/22;
allow 198.41.128.0/17;
allow 199.27.128.0/21;

# IPV6
allow 2400:cb00::/32;
allow 2405:8100::/32;
allow 2405:b500::/32;
allow 2606:4700::/32;
allow 2803:f800::/32;
allow 2c0f:f248::/32;
allow 2a06:98c0::/29;

How do I restore the REAL visitors IP?

(I've referred to the listings on this page however they don't work (plus the mybb tutorial is out of date))
Go to
Admin CP > Configuration > Server and Optimization Options > Scrutinize User's IP address? > Yes

https://support.cloudflare.com/hc/en-us/...yBB-forums-
You can access your visitors IP via the server variable $_SERVER["HTTP_CF_CONNECTING_IP"]