![]() |
If you are installing 4.2.0.0 version, you need to add below step 1 (from 4.1.0.8) in addition to step 2 (from 4.2.0.0).
----------------------------------------------------------------------------------------------------------- Step 1 (THIS STEP IS NOT REQUIRED IN vBulletin 4.1.7 - IT *IS* REQUIRED IN ALL OTHER VERSIONS, INCLUDING 4.1.8 ONWARDS). In class_core.php ; Find ; // fetch client IP address $registry->ipaddress = $this->fetch_ip(); define('IPADDRESS', $registry->ipaddress); // attempt to fetch IP address from behind proxies - useful, but don't rely on it... $registry->alt_ip = $this->fetch_alt_ip(); define('ALT_IP', $registry->alt_ip); Replace with ; // Paul M - Get ip addresses. $registry->ipaddress = $this->fetch_ip(); $registry->alt_ip = $this->fetch_alt_ip(); // Check that alt_ip is valid address, reset to original if not. if (preg_match("#\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}#" , $registry->alt_ip, $iplist)) { $registry->alt_ip = $iplist[0]; } else { $registry->alt_ip = $registry->ipaddress; } // Set ip constants. if ($registry->ipaddress == $registry->alt_ip) { define('PROXYIP',''); define('ALT_IP',$registry->alt_ip); define('IPADDRESS',$registry->ipaddress); } else { define('ALT_IP',$registry->alt_ip); define('IPADDRESS',$registry->alt_ip); define('PROXYIP',$registry->ipaddress); $registry->ipaddress = $registry->alt_ip; } ----------------------------------------------------------------------------------------------------------- Step 2. In class_core.php ; Find ; if ($proxy) { define('ALT_IP', $this->ipaddress); define('IPADDRESS', $this->alt_ip); } Insert above it ; // Detect ALL. if ($registry->ipaddress == $registry->alt_ip) { define('PROXYIP',''); } else { $proxy = true; define('PROXYIP',$registry->ipaddress); } ----------------------------------------------------------------------------------------------------------- |
This mod does not work. I'm attempting to use it with Cloudflare (at Cloudflare's recommendation), and I'm still only seeing Cloudflare IP addresses within vBulletin.
|
Quote:
|
Quote:
|
Quote:
|
Quote:
It will no longer work with Cloudfare because they changed their system to use a custom http variable called HTTP_CF_CONNECTING_IP, instead of the standard HTTP_X_FORWARDED_FOR. |
Thanks for clarifying the situation, Paul. Cloudflare needs to stop directing people to this mod, because they are causing a lot of unnecessary confusion.
|
Will this work for vB 4.1.4 ?
|
As stated in the first post.
For vBulletin 4.1.0 Onwards |
Quote:
In addition to the install instructions provided, just do this ; Code:
In class_core.php ; No need to perform their option 2 then. I've included this in the instructions for v4.2.0.1 |
All times are GMT. The time now is 01:52 PM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|