vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.0 Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=33)
-   -   IP ban from registration only (https://vborg.vbsupport.ru/showthread.php?t=64034)

Hoth 04-17-2004 10:00 PM

IP ban from registration only
 
The problem with IP bans is of course their tendency to lock out innocent posters with the same ISP... or in some cases, even innocent posters using the same computer as the guilty. For my purposes, I prefer to have IP bans only block registrations, and not block people from viewing/posting -- if I didn't want someone posting, I'd have banned their username in the normal way already. By having it only block registrations I merely lose a few potential new people who could've otherwise registered, but don't have the more serious problem of locking out valued existing posters and making them think they've done something bad.

This can be done with a couple very minor file edits:

Open includes/functions.php and find

Code:

function verify_ip_ban()
Replace with
Code:

function verify_ip_ban($registering = 'no')
Then find
Code:

        global $vboptions, $session;
and replace with
Code:

        global $vboptions, $session;
    if ($registering == 'no') return false;

Open register.php and find
Code:

if (empty($_REQUEST['do']) AND empty($_REQUEST['a']))
Replace it with
Code:

verify_ip_ban('yes');
if (empty($_REQUEST['do']) AND empty($_REQUEST['a']))

I've IP banned myself to test this. It let me post, but when I logged out and tried to register a new account it told me my IP was banned. Works in 3.00 RC 3, presumably there wouldn't be any changes to these lines in 3.00 final.

Red Blaze 04-19-2004 03:31 AM

Nice, I'll add this. :)

bluecat 04-19-2004 08:06 PM

Thank you!!!

mikellogg 01-19-2005 01:30 PM

Thank you Hoth!

This is just the hack that I needed.

My site was being used as a general chat by a group that worked at the same place as a valued forum member. This way, I can ban them and keep him!

glenvw 01-30-2005 04:51 PM

This looks good but can you tell me if it still will prevent people from registering from the big ISPs like AOL, Juno, etc?

Koutaru 03-27-2005 09:42 PM

Definately trying this one :)

007 06-02-2005 09:32 PM

Could this be modified to not allow duplicate registrations per IP address? I have had a problem with members creating multiple accounts lately. :( I'm sure others have this same problem too..

Kirk Y 09-04-2005 05:48 PM

I urgently need this for vB 3.5.0 RC2. Would anyone port this for me, I would be very appreciative.

Q-v-n-s-Q 09-16-2005 09:42 PM

well when u're use proxies, you still could register, i think you should fix it or update it, anyway this is cool hack


All times are GMT. The time now is 08:39 AM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01101 seconds
  • Memory Usage 1,722KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (6)bbcode_code_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (9)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.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/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.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
  • printthread_start
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete