Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 2.x > vBulletin 2.x Beta Releases
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
Details »»

Version: 1.00, by intellected intellected is offline
Developer Last Online: Apr 2002 Show Printable Version Email this Page

Version: 2.2.x Rating:
Released: 02-21-2002 Last Update: Never Installs: 9
Is in Beta Stage  
No support by the author.

UPDATED!!! AGAIN!

This is a more effective solution than the standard "ban", and is meant to be used for very annoying troublemakers that keeps re-registering once banned. Anyway - once a user is placed under the "Hellban", the following happens:

1. Every 3:d time the user tries to load a page, he is greeted with a fake "500 Internal Server Error" message.

2. Nobody but moderators and the user himself can see his posts. He is, essentially, under a site-wide ignore.

This may not be a 100% fail-safe solution, but a lot of the morons will hopefully get tired and go away.

Here is how it's done:

1. Run the following query on your database:

INSERT INTO usergroup VALUES("666","Hellban","","0","1","1","1","1","0", "1","0","0","0","1","1","1","1","0","0","1","1","1 ","0","0","1","0","0","0","0","0","0","0","0","1") ;
ALTER TABLE post ADD hellban INT UNSIGNED;
ALTER TABLE thread ADD hellban INT UNSIGNED;

2. Add this at the bottom of you global.php
PHP Code:
if ($bbuserinfo[usergroupid] == 666) {
  
  
$randnum mt_rand(1,3);
  if (
$randnum == 1) {
    
header("HTTP/1.0 500 Internal Server Error");
    exit;
  }   


3. Find this in newreply.php:
PHP Code:
$DB_site->query("INSERT INTO post (postid,threadid,title,username,userid,dateline,attachmentid,pagetext,allowsmilie,showsignature,ipaddress,iconid,visible) VALUES (NULL,'$threadid','".addslashes(htmlspecialchars($title))."','".addslashes(htmlspecialchars($postusername))."','$bbuserinfo[userid]','".time()."','$attachmentid','".addslashes($message)."','$allowsmilie','$signature','$ipaddress','$iconid','$visible')"); 
REPLACE it with this:

PHP Code:
if ($bbuserinfo[usergroup] == 666) {
  
$DB_site->query("INSERT INTO post (postid,threadid,title,username,userid,dateline,attachmentid,pagetext,allowsmilie,showsignature,ipaddress,iconid,visible,hellban) VALUES (NULL,'$threadid','".addslashes(htmlspecialchars($title))."','".addslashes(htmlspecialchars($postusername))."','$bbuserinfo[userid]','".time()."','$attachmentid','".addslashes($message)."','$allowsmilie','$signature','$ipaddress','$iconid','$visible','$bbuserinfo[userid]')");
} else {
  
$DB_site->query("INSERT INTO post (postid,threadid,title,username,userid,dateline,attachmentid,pagetext,allowsmilie,showsignature,ipaddress,iconid,visible) VALUES (NULL,'$threadid','".addslashes(htmlspecialchars($title))."','".addslashes(htmlspecialchars($postusername))."','$bbuserinfo[userid]','".time()."','$attachmentid','".addslashes($message)."','$allowsmilie','$signature','$ipaddress','$iconid','$visible')");

4. find this in newthread.php

PHP Code:
$DB_site->query("INSERT INTO thread (threadid,title,lastpost,forumid,open,replycount,postusername,postuserid,lastposter,dateline,iconid,visible,attach) VALUES (NULL,'".addslashes(htmlspecialchars($subject))."','".time()."','$forumid','1','0','".addslashes($postusername)."','$bbuserinfo[userid]','".addslashes($postusername)."','".time()."','$iconid','$visible','$attachcount')"); 
PHP Code:
if ($bbuserinfo[usergroup] == 666) {
  
$DB_site->query("INSERT INTO thread (threadid,title,lastpost,forumid,open,replycount,postusername,postuserid,lastposter,dateline,iconid,visible,attach,hellban) VALUES (NULL,'".addslashes(htmlspecialchars($subject))."','".time()."','$forumid','1','0','".addslashes($postusername)."','$bbuserinfo[userid]','".addslashes($postusername)."','".time()."','$iconid','$visible','$attachcount','$bbuserinfo[userid]')");
} else {
  
$DB_site->query("INSERT INTO thread (threadid,title,lastpost,forumid,open,replycount,postusername,postuserid,lastposter,dateline,iconid,visible,attach) VALUES (NULL,'".addslashes(htmlspecialchars($subject))."','".time()."','$forumid','1','0','".addslashes($postusername)."','$bbuserinfo[userid]','".addslashes($postusername)."','".time()."','$iconid','$visible','$attachcount')"); 

in that file, also find this:

PHP Code:
$DB_site->query("INSERT INTO post (postid,threadid,title,username,userid,dateline,attachmentid,pagetext,allowsmilie,showsignature,ipaddress,iconid,visible) VALUES (NULL,'$threadid','".addslashes(htmlspecialchars($subject))."','".addslashes($postusername)."','$bbuserinfo[userid]','".time()."','$attachmentid','".addslashes($message)."','$allowsmilie','$signature','$ipaddress','$iconid','1')"); 
PHP Code:
if ($bbuserinfo[usergroup] == 666) {
  
$DB_site->query("INSERT INTO post (postid,threadid,title,username,userid,dateline,attachmentid,pagetext,allowsmilie,showsignature,ipaddress,iconid,visible,hellban) VALUES (NULL,'$threadid','".addslashes(htmlspecialchars($subject))."','".addslashes($postusername)."','$bbuserinfo[userid]','".time()."','$attachmentid','".addslashes($message)."','$allowsmilie','$signature','$ipaddress','$iconid','1','$bbuserinfo[userid]')");
} else {
  
$DB_site->query("INSERT INTO post (postid,threadid,title,username,userid,dateline,attachmentid,pagetext,allowsmilie,showsignature,ipaddress,iconid,visible) VALUES (NULL,'$threadid','".addslashes(htmlspecialchars($subject))."','".addslashes($postusername)."','$bbuserinfo[userid]','".time()."','$attachmentid','".addslashes($message)."','$allowsmilie','$signature','$ipaddress','$iconid','1')");

After that, find this:

PHP Code:
if ($visible==1) {
        
$DB_site->query("UPDATE forum SET replycount=replycount+1,threadcount=threadcount+1,lastpost='".time()."',lastposter='".addslashes($postusername)."' WHERE forumid IN ($foruminfo[parentlist])");

and replace with this:

PHP Code:
if ($visible==&& $bbuserinfo[usergroup] != 666) {
  
$DB_site->query("UPDATE forum SET replycount=replycount+1,threadcount=threadcount+1,lastpost='".time()."',lastposter='".addslashes($postusername)."' WHERE forumid IN ($foruminfo[parentlist])");

I showthread.php, find this:
PHP Code:
  $getpostids=$DB_site->query(
    SELECT post.postid FROM post
    WHERE post.threadid='
$threadid' AND post.visible=1 
    ORDER BY dateline 
$postorder LIMIT ".($limitlower-1).",$perpage 
  "
); 
Replace with this:

PHP Code:
if ($bbuserinfo[usergroupid] == 666 || ismoderator($forumid)) {
  
  
$getpostids=$DB_site->query(
    SELECT post.postid FROM post
    WHERE post.threadid='
$threadid' AND post.visible=1 AND post.hellban = '$bbuserinfo[userid]'
    ORDER BY dateline 
$postorder LIMIT ".($limitlower-1).",$perpage 
  "
);  
  
} else {

$getpostids=$DB_site->query(
    SELECT post.postid FROM post
    WHERE post.threadid='
$threadid' AND post.visible=1 AND post.hellban = NULL
    ORDER BY dateline 
$postorder LIMIT ".($limitlower-1).",$perpage 
"
);


in forumdisplay.php, find this:

PHP Code:
    $getthreadids=$DB_site->query("
    SELECT
    "
.iif($sortfield=="voteavg",$votequery,"")."
        thread.threadid
    FROM thread
    WHERE thread.forumid = 
$foruminfo[forumid]
        AND thread.sticky=0
        AND thread.visible=1
    
$datecut
    
$limitothers
      ORDER BY sticky DESC, 
$sortfield $sqlsortorder
      LIMIT "
.($sel_limitlower-1).",$perpage"); 
Replace that with this:

PHP Code:
if ($bbuserinfo[usergroup] == 666) {
  
$getthreadids=$DB_site->query("
    SELECT
    "
.iif($sortfield=="voteavg",$votequery,"")."
        thread.threadid
    FROM thread
    WHERE thread.forumid = 
$foruminfo[forumid]
        AND thread.sticky=0
        AND thread.visible=1
        AND thread.hellban = NULL
        AND thread.hellban = '
$bbuserinfo[userid]'
    
$datecut
    
$limitothers
      ORDER BY sticky DESC, 
$sortfield $sqlsortorder
      LIMIT "
.($sel_limitlower-1).",$perpage");
      
} else {
  
    
$getthreadids=$DB_site->query("
    SELECT
    "
.iif($sortfield=="voteavg",$votequery,"")."
        thread.threadid
    FROM thread
    WHERE thread.forumid = 
$foruminfo[forumid]
        AND thread.sticky=0
        AND thread.visible=1
    
$datecut
    
$limitothers
      ORDER BY sticky DESC, 
$sortfield $sqlsortorder
      LIMIT "
.($sel_limitlower-1).",$perpage");
  

Now, whenever you want to get rid of a user, simply set him or her to usergroup Hellban.

Show Your Support

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

Comments
  #12  
Old 02-24-2002, 11:20 AM
intellected intellected is offline
 
Join Date: Dec 2001
Posts: 21
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Updated with modifications!

[edit] Also, dear admins of this board - you might like to modify the PHP-code template so that the tables are left-aligned and dont look like ****
Reply With Quote
  #13  
Old 02-24-2002, 09:46 PM
Rick Rick is offline
 
Join Date: Nov 2001
Location: Wittmann, AZ
Posts: 98
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I got this error when I tried to run the query.

SQL-query:

INSERT INTO usergroup VALUES(\"666\",\"Hellban\",\"\",\"0\",\"1\",\"1\", \"1\",\"1\",\"0\",\"1\",\"0\", \"0\",\"0\",\"1\",\"1\",\"1\",\"1\",\"0\",\"0\",\" 1\",\"1\",\"1\",\"0\",\"0\",\" 1\",\"0\",\"0\",\"0\",\"0\",\"0\",\"0\",\"0\",\"0\ ",\"1\");
ALTER TABLE post ADD hellban INT UNSIGNED;
ALTER TABLE thread ADD hellban INT UNSIGNED;

MySQL said: Column count doesn't match value count at row 1
Reply With Quote
  #14  
Old 02-24-2002, 11:41 PM
supreemball supreemball is offline
 
Join Date: Nov 2001
Location: houston, tx
Posts: 47
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

me too, rick.
Reply With Quote
  #15  
Old 02-25-2002, 01:19 AM
intellected intellected is offline
 
Join Date: Dec 2001
Posts: 21
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally posted by supreemball
me too, rick.
How very wierd - the query is the exact same that I used when inserting it. Anyway, it's not really complicated to circumvent:

Just create a new usergroup, and then go into phpmyadmin and change the groupid to 666.
Reply With Quote
  #16  
Old 02-25-2002, 02:45 AM
hagi hagi is offline
 
Join Date: Jan 2002
Location: Chi-town
Posts: 32
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally posted by intellected

How very wierd - the query is the exact same that I used when inserting it. Anyway, it's not really complicated to circumvent:

Just create a new usergroup, and then go into phpmyadmin and change the groupid to 666.
i dont have phpmyadmin. i actually didnt know how to run query's until i got that hack for the vbb admin cp. is their any other query i can run to make it work, cause i got the same problems as others and clueless on this. btw, sounds like a good hack.
Reply With Quote
  #17  
Old 02-25-2002, 02:56 AM
intellected intellected is offline
 
Join Date: Dec 2001
Posts: 21
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally posted by hagi


i dont have phpmyadmin. i actually didnt know how to run query's until i got that hack for the vbb admin cp. is their any other query i can run to make it work, cause i got the same problems as others and clueless on this. btw, sounds like a good hack.
Seriously man, this is indeed the EXACT query I use:

Code:
INSERT INTO usergroup VALUES("666","Ultimate ban","","0","1","1","1","1","0","1","0","0","0","1","1","1","1","0","0","1","1","1","0","0","1","0","0","0","0","0","0","0","0","1");
And it works flawlessly on vB 2.2.2. I have no idea why it doesn't work for you. Anyone got any ideas?
Reply With Quote
  #18  
Old 02-25-2002, 03:34 AM
hagi hagi is offline
 
Join Date: Jan 2002
Location: Chi-town
Posts: 32
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

its funny, mine just worked now without me doing anything. well, thanks for the help
Reply With Quote
  #19  
Old 02-25-2002, 09:14 PM
Rick Rick is offline
 
Join Date: Nov 2001
Location: Wittmann, AZ
Posts: 98
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Still no good for me :-(
Reply With Quote
  #20  
Old 02-26-2002, 01:05 AM
hagi hagi is offline
 
Join Date: Jan 2002
Location: Chi-town
Posts: 32
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

i got the query to work, but the hack itself wont work for some reason
Reply With Quote
  #21  
Old 03-02-2002, 07:15 AM
Neo's Avatar
Neo Neo is offline
 
Join Date: Oct 2001
Location: Anywhere
Posts: 1,817
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

props to you. nice hack.
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 11:17 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.04844 seconds
  • Memory Usage 2,391KB
  • 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
  • (13)bbcode_php
  • (3)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (3)pagenav_pagelink
  • (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