Go Back   vb.org Archive > vBulletin Modifications > Archive > Modification Graveyard

Reply
 
Thread Tools
Proxy to Real IP Conversion Details »»
Proxy to Real IP Conversion
Version: 2.25, by Paul M Paul M is offline
Developer Last Online: Nov 2023 Show Printable Version Email this Page

Category: Administrative and Maintenance Tools - Version: 3.6.x Rating:
Released: 07-01-2006 Last Update: 11-24-2006 Installs: 633
DB Changes Uses Plugins Auto-Templates
Code Changes Translations  
No support by the author.

This modification is no longer available or supported.

This hack makes the forum always use the members real ip when a proxy is detected, meaning that all existing ip functions should continue to work, basically ignoring the proxy server (other than recording it's presence).

i.e.

* The real ip (or host) is displayed in the who's online page.
* The real and proxy server ip's are accesible for each post, the button is red for members using a proxy server.
* The real ip is searchable in the admin/mod cp (but not the proxy ip).
* The real ip can be banned by admins.

etc etc ......

Note: Obviously this hack relies on the proxy server passing the correct http variables to allow detection.

If a proxy is detected, then a red ip icon is displayed instead of the standard one. This mod will also detect if the ipinfo hack is installed and adjust itself to call the ipinfo code.


History:

v2.20 : Updated for vb 3.6. IP Info detection added.
v2.21 : Dependancies updated for 3.6.0 Gold.
v2.22 : Updated for Version Checking.
v2.23 : Fixed bug causing wrong ip in WOL display.
v2.24 : Rewritten slightly to fix a minor issue with spiders.
v2.25 : Updated for changes in vB 3.6.4.


Remember that this modification involves changes to the class_core.php file - if you upgrade your vbulletin, you must reapply those changes.

Please do not post asking why this does not work with some proxy servers, the answer is already in the notes above, and also in Post #160.

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #392  
Old 09-05-2007, 07:11 PM
Alfa1's Avatar
Alfa1 Alfa1 is offline
 
Join Date: Dec 2005
Location: Netherlands
Posts: 3,537
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Most of my members now display a red button and when I check it out this is displayed:
"The Proxy Server IP Address is: PROXYIP"
This is even displayed for myself and I sure am not on a proxy. How can I fix this?
Reply With Quote
  #393  
Old 09-05-2007, 10:02 PM
Paul M's Avatar
Paul M Paul M is offline
 
Join Date: Sep 2004
Location: Nottingham, UK
Posts: 23,748
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

You fix it by doing the required file edits.
Reply With Quote
  #394  
Old 09-06-2007, 03:26 PM
Alfa1's Avatar
Alfa1 Alfa1 is offline
 
Join Date: Dec 2005
Location: Netherlands
Posts: 3,537
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

The file edits instructions do no longer match vb 3.6.8's class_core.php's content.

Step 3:
Find:
PHP Code:
        // define session constants
        
define('SESSION_IDHASH'md5($_SERVER['HTTP_USER_AGENT'] . vB_Session::fetch_substr_ip($registry->alt_ip))); // this should *never* change during a session
        
define('SESSION_HOST',   substr($registry->ipaddress015)); 
This is not there. What is there is:
PHP Code:
        // define session constants
        
define('SESSION_HOST',   substr($registry->ipaddress015)); 
I assume that this would need to be replaced. But since I am no coder and it seems more has been altered in class_core.php's content, I am not certain.
Reply With Quote
  #395  
Old 09-06-2007, 05:24 PM
Paul M's Avatar
Paul M Paul M is offline
 
Join Date: Sep 2004
Location: Nottingham, UK
Posts: 23,748
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

You need to re-read the instructions ;

Step 3 clearly states ;

Quote:
Step 3 (vB Versions 3.6.0 to 3.6.3 only).


Steps 4 & 5 state ;

Quote:
Step 4 (vB Versions 3.6.4 onwards only).

Step 5 (vB Versions 3.6.4 onwards only).
Reply With Quote
  #396  
Old 09-07-2007, 11:44 AM
Alfa1's Avatar
Alfa1 Alfa1 is offline
 
Join Date: Dec 2005
Location: Netherlands
Posts: 3,537
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I seem to have been working with an older version of the instructions. I have now applied the new instructions to vb 3.6.8, but this has not solved it. Do I need to wait for a cron job to be passed or is there something else I need to do?
Reply With Quote
  #397  
Old 09-07-2007, 03:59 PM
Paul M's Avatar
Paul M Paul M is offline
 
Join Date: Sep 2004
Location: Nottingham, UK
Posts: 23,748
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I'm not sure what you mean isn't solved. If you have done the file edits correctly then new posts posts will now contain the correct data. Old posts will not be updated.
Reply With Quote
  #398  
Old 09-07-2007, 04:14 PM
Alfa1's Avatar
Alfa1 Alfa1 is offline
 
Join Date: Dec 2005
Location: Netherlands
Posts: 3,537
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

That explains it. Thanks.
Reply With Quote
  #399  
Old 09-14-2007, 11:15 AM
dosadno dosadno is offline
 
Join Date: Dec 2006
Posts: 26
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I am having som problems on 3.6.8 version, I cant find the code in step 2. in the class_core.php, so I dont know where to put replacmen code given in the instructions? Help!!!

THNX in front!

Missing code:
Code:
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);
Reply With Quote
  #400  
Old 09-14-2007, 02:44 PM
Paul M's Avatar
Paul M Paul M is offline
 
Join Date: Sep 2004
Location: Nottingham, UK
Posts: 23,748
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

If you have the default class_core file for 3.6.8 then the code is there, perhaps your text editor is not searching properly, try just looking for "// fetch client IP address".
Reply With Quote
  #401  
Old 09-14-2007, 04:58 PM
CMGU CMGU is offline
 
Join Date: Mar 2007
Location: Central America
Posts: 213
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

nice thanks
Reply With Quote
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 02:01 PM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.08567 seconds
  • Memory Usage 2,313KB
  • Queries Executed 25 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)bbcode_code
  • (2)bbcode_php
  • (2)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (4)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (1)pagenav_pagelinkrel
  • (11)post_thanks_box
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (11)post_thanks_postbit_info
  • (10)postbit
  • (11)postbit_onlinestatus
  • (11)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete