Go Back   vb.org Archive > vBulletin 3 Discussion > vB3 General Discussions
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools Display Modes
  #1  
Old 11-10-2005, 04:01 PM
JJR512's Avatar
JJR512 JJR512 is offline
 
Join Date: Oct 2001
Location: Glen Burnie, MD, USA
Posts: 710
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default Need help fast: How to ban an IP except for specific members

A lot of people from where I work have registered and are starting flame wars and other bullshit. On the board it looks like we all come from the same IP. I could member-ban but they'll just re-register. If I IP-ban, though, then I can't post, and neither can a few other co-workers who aren't part of the problem. I assume I'll have to modifiy some code somewhere but am looking for some quick help on what, where, and how. Thanks!
Reply With Quote
  #2  
Old 11-10-2005, 06:38 PM
Marco van Herwaarden Marco van Herwaarden is offline
 
Join Date: Jul 2004
Posts: 25,415
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

No solution to this i guess. If IP-banned, you won't even get a login, so the board don't know who you are.
Reply With Quote
  #3  
Old 11-10-2005, 09:13 PM
silly rabbit silly rabbit is offline
 
Join Date: Oct 2005
Location: Atlanta/NYC
Posts: 92
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by JJR512
A lot of people from where I work have registered and are starting flame wars and other bullshit.
JJ, I am currently working on a custom 'work IP' permissions system based on the general IP ban but have nothing tested yet.

If ya need a 'nudge' look at Line#671 in global.php which calls the function verify_ip_ban() at line#551 in functions.php.

IPADDRESS is the system detected IP of person logging & $val is an element out of your 'banning list'. Would think it'd be a simple matter to test both IPADDRESS(your job IP) and the current forumid / user trying to log in.

Based On preferences, either return 'Ok' or let eval(standard_error . . .) do its work???

In my case if I BAN the work IP I'm looking to reassign anybody logging from a work set to a predetermined generic userid assigned a usergroup with restricted permissions.

Having done so, would I simply redirect back to 'index.php'??

Rabbit
Reply With Quote
  #4  
Old 11-10-2005, 09:17 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

Quote:
Originally Posted by silly rabbit
JIPADDRESS is the system detected IP of person logging & $val is an element out of your 'banning list'. Would think it'd be a simple matter to test both IPADDRESS(your job IP) and the current forumid / user trying to log in.
As I recall, the ip test is so early in the process that the user details are not known at that point.
Reply With Quote
  #5  
Old 11-10-2005, 09:35 PM
silly rabbit silly rabbit is offline
 
Join Date: Oct 2005
Location: Atlanta/NYC
Posts: 92
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Paul M
As I recall, the ip test is so early in the process . . .
If that is indeed the case then perhaps I am set - simply set userid(forumid??)

Look HERE

Either way I suspect this test is called repeatedly/constantly as .php progresses on it's merry way. Test the userids you do not want to 'pass thru' and eval() out and the rest you simply 'return' out(errr . . . in)!!

I Am NOT At The House And Need My FTP!!!
Can you 'break' from a 'foreach'??
Rabbit
Reply With Quote
  #6  
Old 11-11-2005, 09:58 AM
Marco van Herwaarden Marco van Herwaarden is offline
 
Join Date: Jul 2004
Posts: 25,415
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by silly rabbit
Can you 'break' from a 'foreach'??
You can use either 'continue' (will process the next item in the loop), or 'break' (will jump out of the loop.
Reply With Quote
Reply


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 08:38 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
  • Page Generation 0.03869 seconds
  • Memory Usage 2,205KB
  • Queries Executed 13 (?)
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)ad_showthread_firstpost
  • (1)ad_showthread_firstpost_sig
  • (1)ad_showthread_firstpost_start
  • (4)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)navbar_link
  • (120)option
  • (6)post_thanks_box
  • (6)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (6)post_thanks_postbit_info
  • (6)postbit
  • (6)postbit_onlinestatus
  • (6)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_postinfo_query
  • fetch_postinfo
  • 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
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete