Version: 1.00, by Zzed
Developer Last Online: Feb 2012
Version: 2.2.x
Rating:
Released: 04-16-2003
Last Update: Never
Installs: 12
No support by the author.
This is yet another way to ban a user from your board.
This hack is a little fun project I thought of given some of the recent events in my forums. We have had a few "trouble makers" on our board who got slammed pretty hard by the board moderators quite rightfully. And they got their fragile feelings hurt and posted threads stating that they never wanted to post on the board and so on so forth...
So I came up with the idea of the Farewell Hack, or as I call it the AutoBahn Hack. As the name suggests, the hack allows a person to automatically ban himself from the board. The unsuspecting victim will post a new thread and type some angry messages in there, and all of a sudden, he is not able to access the board. He has been banned. The hack posts a reply to the thread stating that the person is banend. The thread gets locked, and the person receives an Email notice informing him that he has been banned.
This is the reply given to the post:
Quote:
Your post indicates that you no longer wish to be a member of this site.
Your ID has been banned.
Contact the site administrators about reinstating your account.
Good bye.
The hack tries to identify certain phrases in the post by performing a series of regex matches and if it finds a match it deems that thread as a farewell thread.
The hack is quite simple. It adds a new .php file to your forums directory and requires a small change to newthread.php.
And yes, mods and admins are immune to this hack.
farewell.php can be slightly tweaked to work according to your board configuration.
The variable $bot_ip is set to 127.0.0.1. You can change it to the IP address of your board.
The variable $admin_uid is set to 1. You can set it to the user ID of anyone on your board.
In the $patterns array, replace "myboard.com" with the name of your board.
Feel free to add patterns of your own to the list. Be suer to follow the rules for regular expression mathces.
And pardon the little profanity in the list.
Show Your Support
This modification may not be copied, reproduced or published elsewhere without author's permission.
Today at 07:36 PM Zelda-King said this in Post #20 When I post only one word of a 'ban phrase' I get the attached error. Everything seems to still function normally, and the user isn't banned without saying the rest of it but I get the error come up briefly nevertheless.
For example, if a ban sentence is "I'm leaving" and I post the word 'leaving' in a different context, there's that error.
One word is enough to make the post require farewell.php. Isn't there a way of making it not do that unless all criteria are met for an autoban?
This is due to some regex syntax error in your list of patterns.
Email me the contents of your array and I'll give you back the corrected list.
I copied and pasted them in my farewell.php and I tried 2 different posts.
In the first one I said "I'm leaving" and the hack kicked in. And in the other one I said "blah blah leaving" and nothing happened. But I did not get any errors either. I am not sure why you are getting that error. Maybe you can tell me what exact phrase causes that error.
On a different note, you don't need various upper/lower case combination of words. The /i makes the regex case insensitive.
I am completely stumped. It is workig just fine on my site...
Let's try and narrow it down to the actual regex that causes this.
Find:
PHP Code:
while(($found == 0) and ($x < $entries)) {
And add this directly below it:
PHP Code:
echo "$patterns[x] \n";
This will list out all the patterns and you will see the error message right after the culprit. This way we can at least narrow it down to the actual pattern.