View Full Version : Administrative and Maintenance Tools - Proxy to Real IP Conversion
Nirjonadda
01-03-2015, 12:02 PM
@Paul M, Why not you add this Features for vB 4.2.3 By default?
ozzy47
01-03-2015, 12:14 PM
Well, if I had to take a guess, I would say because there is no further development planned for vB4, other than PHP compatibility issues, security updates and possibly bug fixes.
"vBulletin 4 does not receive active development any longer, as it is not the current product."
What that means is that we're not actively developing it...features aren't being added, the product is not "in development" in the way that vB5 is.
That's not the same as no security fixes, and it's not the same as updating it for php version compatibility.
Paul M
01-03-2015, 05:20 PM
@Paul M, Why not you add this Features for vB 4.2.3 By default?
Actually, you have sort of been able to do it in any version of 4.2.x, as long as Cloudfare were connecting to you via specific (known) IPs.
You do it by setting the proxy definitions in your config.php file ;
$config['Misc']['proxyiplist'] = '192.168.10.20, 192.168.20.30';
$config['Misc']['proxyipheader'] = 'HTTP_CF_CONNECTING_IP';
Where 192.168.10.20 & 192.168.20.30 is the Clouldfare IPs.
Unfortunately, Cloudfare uses many IPs, which limited the usefulness of this unless you defined a big list (not a good idea performance wise).
However, in 4.2.3 you can actually specify this ;
$config['Misc']['proxyiplist'] = 'all';
$config['Misc']['proxyipheader'] = 'HTTP_CF_CONNECTING_IP';
Which means vB will trust any IP it gets the Cloudfare supplied data from, eliminating the need for the edit above and a long list of specific IPs.
Nirjonadda
01-03-2015, 05:34 PM
@Paul M, I am Talking about the adding Features for vB 4.2.3 By default Proxy to Real IP Conversion Work without Installs the Mod.
Paul M
01-03-2015, 06:53 PM
I'm afraid that nothing more than what already exists will be added to vB4 core.
ozzy47
01-03-2015, 07:59 PM
^^ as I said in post #252. :)
Nirjonadda
01-04-2015, 02:13 PM
Admin CP still show me Installed Version: 4.2.0.0
ozzy47
01-04-2015, 02:18 PM
You can ignore that, all 4.2.0.1 has change is, 4.2.0.1 Includes updated instructions for Cloudfare.
Paul M
01-04-2015, 02:29 PM
Admin CP still show me Installed Version: 4.2.0.0
Ugh, I updated the version number in the wrong place. Corrected.
ozzy47
01-04-2015, 02:32 PM
I do that all the time Paul. :p
joeychgo
01-05-2015, 05:02 PM
anyone try to remove this? It messed up my forum when I did...
Hex_legend
01-16-2015, 04:35 PM
anyone try to remove this? It messed up my forum when I did...
I was about to try this mod, but your post kinda scared me!
Anybody else with problems after the uninstallation?
CharlieDelta
01-16-2015, 06:46 PM
I have never had a problem with any of Paul's mods and even if there was he would fix it immediately.
I use this mod and am not worried one bit.
Paul M
01-16-2015, 10:35 PM
Anybody else with problems after the uninstallation?
Not if you uninstall it correctly.
asabet
01-19-2015, 01:27 AM
I tried this mod both with and without the following edits, and I couldn't get it to work with Pagespeed service. Don't know whether it's got to do with Litespeed webserver or something else, but I had to remove Pagespeed service from my sites.
We fixed it ourselves by editing the class_core.php bit:
// Detect ALL.
if ($registry->ipaddress == $registry->alt_ip)
{
define('PROXYIP','');
}
else
{
$proxy = true;
define('PROXYIP',$registry->ipaddress);
}
if ($proxy)
{
define('ALT_IP', $this->ipaddress);
define('IPADDRESS', $_SERVER['HTTP_X_FORWARDED_FOR']);
}
else
{
define('IPADDRESS', $_SERVER['HTTP_X_FORWARDED_FOR']);
define('ALT_IP', $this->alt_ip);
}
Now the proxy details aren't written properly, but that's not that important for me. At least I see the real IP addresses now.
Vintum
01-20-2015, 06:10 PM
I followed all the steps for cloudflare, but I'm still getting Cloudflare IPs. Have they changed things again?
bshield
01-23-2015, 04:43 AM
I followed all the steps for cloudflare, but I'm still getting Cloudflare IPs. Have they changed things again?
I just followed the steps exactly but the Cludflare IP's still show up when users are loggged in. Any advise?
WrecklessRZ
02-12-2015, 05:55 PM
Ugh, I updated the version number in the wrong place. Corrected.
I believe I installed it correctly and made all the correct edits, but it still seems to be showing the CloudFlare IPs. I followed the instructions exactly, and I'm still having issues.
Any help?
Arjang121
02-13-2015, 08:42 PM
I followed all the steps for cloudflare, but I'm still getting Cloudflare IPs. Have they changed things again?
I just followed the steps exactly but the Cludflare IP's still show up when users are loggged in. Any advise?
I believe I installed it correctly and made all the correct edits, but it still seems to be showing the CloudFlare IPs. I followed the instructions exactly, and I'm still having issues.
Any help?
Same goes for me. I've followed the 4 steps of the instructions and I am seeing no change to the post IP page and the IP button never seems to turn red, as if the plugin is not even installed.
Edited the class_core.php in includes. vB 4.2.2 patch level 4.
Any help would be appreciated. Thanks.
Paul M
02-14-2015, 07:54 PM
Sorry but I do not use cloudfare, my guess would be they changed something again.
bshield
02-27-2015, 03:59 PM
if anyone figured it out please share...thanks
hsoen
03-01-2015, 03:06 AM
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.
I am using this mod with Cloudflare, and it works well.
Below is the result which shows proxy IP is from Cloudflare, and real IP of your forum visitor.
vBulletin Message
The Real IP Address is: 183.90.37.93
The Real IP Host is: 183.90.37.93
The Proxy Server IP Address is: 103.31.5.77
The Proxy Host is: 103.31.5.77
Nirjonadda
04-13-2015, 03:33 PM
Any update instructions for google pagespeed : mod_pagespeed?
Duckface
04-15-2015, 12:49 AM
The image in the postbit isn't showing :S, I definitely put the image in the correct directory too!
fionix
06-08-2015, 08:41 AM
Is there any solution for Vbuleltin 5.1.7 please?
Paul M
06-08-2015, 10:00 AM
Sorry, atm, there is not.
There is the possibility that the functionality currently included in 4.2.3 will be included in 5.1.9.
Alan_SP
11-13-2015, 04:54 PM
For me CloudFlare didn't worked using given instructions, so I made one more change, first one found on CloudFlare's support: https://support.cloudflare.com/hc/en-us/articles/200170856-How-do-I-restore-original-visitor-IP-with-vBulletin-
Find:
function fetch_ip()
{
return $_SERVER['REMOTE_ADDR'];
}
Replace with:
function fetch_ip()
{
if(isset($_SERVER['HTTP_CF_CONNECTING_IP']))
{
return $_SERVER['HTTP_CF_CONNECTING_IP'];
}
return $_SERVER['REMOTE_ADDR'];
}
Now I see real IP address user uses, but I still can't see proxy and real IP address, including red IP icon. For some reason, it looks like this mod doesn't work for me on different servers.
But at least I now can see real IP address.
the one
11-17-2015, 11:09 AM
I know this is completely my fault i just need some guidance from you kind coders,members
Ok so i have installed this and tested it with a test member qwerty using numerous proxies and posted some posts.I was on another computer signed in as admin and was hoping that qwerty would show up red and i would be able to check real ip etc.I couldnt even see the red ip icon that i have uploaded correctly.
So could it be down to this.I read the text file and it said this below
Step 1.
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);
}
So i did that in my class core file and it look like this below.I have highlighted what they said to put above it
// Detect ALL.
if ($registry->ipaddress == $registry->alt_ip)
{
define('PROXYIP','');
}
else
{
$proxy = true;
define('PROXYIP',$registry->ipaddress);
}
if ($proxy)
{
define('ALT_IP', $this->ipaddress);
define('IPADDRESS', $this->alt_ip);
}
So is that code correct im having a https://vborg.vbsupport.ru/external/2015/11/1.gif moment lol or do you need to turn it on somewhere in settings
Once again thanks
ForceHSS
11-17-2015, 03:37 PM
I know this is completely my fault i just need some guidance from you kind coders,members
Ok so i have installed this and tested it with a test member qwerty using numerous proxies and posted some posts.I was on another computer signed in as admin and was hoping that qwerty would show up red and i would be able to check real ip etc.I couldnt even see the red ip icon that i have uploaded correctly.
So could it be down to this.I read the text file and it said this below
Step 1.
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);
}
So i did that in my class core file and it look like this below.I have highlighted what they said to put above it
// Detect ALL.
if ($registry->ipaddress == $registry->alt_ip)
{
define('PROXYIP','');
}
else
{
$proxy = true;
define('PROXYIP',$registry->ipaddress);
}
if ($proxy)
{
define('ALT_IP', $this->ipaddress);
define('IPADDRESS', $this->alt_ip);
}
So is that code correct im having a https://vborg.vbsupport.ru/external/2015/11/1.gif moment lol or do you need to turn it on somewhere in settings
Once again thanks
What are you using to edit the file with
// Detect ALL.
if ($registry->ipaddress == $registry->alt_ip)
{
define('PROXYIP','');
}
else
{
$proxy = true;
define('PROXYIP',$registry->ipaddress);
}
if ($proxy)
{
define('ALT_IP', $this->ipaddress);
define('IPADDRESS', $this->alt_ip);
}
else
{
define('IPADDRESS', $this->ipaddress);
define('ALT_IP', $this->alt_ip);
}
the one
11-17-2015, 05:00 PM
What are you using to edit the file with
// Detect ALL.
if ($registry->ipaddress == $registry->alt_ip)
{
define('PROXYIP','');
}
else
{
$proxy = true;
define('PROXYIP',$registry->ipaddress);
}
if ($proxy)
{
define('ALT_IP', $this->ipaddress);
define('IPADDRESS', $this->alt_ip);
}
else
{
define('IPADDRESS', $this->ipaddress);
define('ALT_IP', $this->alt_ip);
}
I just copied and pasted the code into my class core php file.I have also noticed that when i click on code edit for the class core php file its taking forever to load
ForceHSS
11-17-2015, 07:00 PM
I just copied and pasted the code into my class core php file.I have also noticed that when i click on code edit for the class core php file its taking forever to load
use notepad++ to edit your files
the one
11-18-2015, 07:14 AM
use notepad++ to edit your files
I will pm you i am not sure what to do.
I must sound like a right idiot but i always mess my forum up when i attempt to do anything lol.
vBulletin® v3.8.12 by vBS, Copyright ©2000-2025, vBulletin Solutions Inc.