vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   Modification Requests/Questions (Unpaid) (https://vborg.vbsupport.ru/forumdisplay.php?f=112)
-   -   Moderate user if hostaddress = whatever (https://vborg.vbsupport.ru/showthread.php?t=38112)

GeorgeofCS 05-01-2002 10:21 AM

Moderate user if hostaddress = whatever
 
Ok I've been having a problem with a troll he knows he's being banned, being ignored, etc. So he's using surfola.com's program to hide his IP I'm wanting to know is it possible to make a hack that will either prevent registering or moderate users that come from the a certain host address. Because I know in the (".gethostbyaddr($ip[ipaddress]).") piece it says he's from surfola. It might be helpful in tracking down the real bad trolls.
I've tried pretty much everything else to keep him banned, but so far this is the only way I can think of.

Admin 05-01-2002 10:25 AM

You can edit newreply.php and newthread.php and replace this:
Code:

  // auto bypass queueing for admins/mods
  if (ismoderator($foruminfo[forumid])) {
    $visible=1;
  }

With this:
Code:

  // auto bypass queueing for admins/mods
  if (ismoderator($foruminfo[forumid])) {
    $visible=1;
  } elseif (whatever) {
    $visible = 0;
  }

I don't know if you're checking his IP address of hostname, so just use what you want instead of whatever.

GeorgeofCS 05-01-2002 11:00 AM

but just curious on the piece that you'd add for say.


if hostaddress contains surfola.com put into query

it would be

if (gethostbyaddr($ip[ipaddress]=surfola.com)

or would you need to add something to say if it contains surfola.com.
I'm still better at the ifs and elses stuff. Still learning thewhatnots :)

Admin 05-01-2002 11:25 AM

Code:

if (strstr(gethostbyaddr($ipaddress), 'surfola.com')) {

GeorgeofCS 05-01-2002 09:03 PM

Thanks firefly It works like a charm :)


All times are GMT. The time now is 07:47 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.00970 seconds
  • Memory Usage 1,715KB
  • 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
  • (3)bbcode_code_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (5)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