Raised This Month: $12 Target: $400
 3% 

Spam Blocker v3.6


Post New Thread Reply   
 
Thread Tools Display Modes
Plugin Info:     Modification:   ALL        Category:   Server Management        Approver:   Exolent[jNr] (178)
TeoNoman
Senior Member
Join Date: Jun 2008
Old 02-22-2009 , 09:35   Spam Blocker v3.6
Reply With Quote #1

Spam Blocker v3.6

Description:
Monitoring my servers I noticed that a lot of players post ads in chat like "Want buy server? Call .... or visit cant_remember_site_address.co.il". Maybe this is some kind of adware, or maybe it's just an advertising campaign, I don't care. At first I banned them manually. Then I've got enough of that shi-- and wrote this plugin.

So. This plugin can hide ads message and warn/kick/ban (either usual way or amxbans way) the spammer. This plugin detects AMXBans or Advanced Bans (if it's loaded) and uses it's ban method. Also you can set a whitelist (only for ban.ini and kick.ini).

The plugin has three powerful features:
— Just hide messages (I use this feature for hiding messages like changerace, /rank etc.)
— Kick spammers
— Warn spammers
— Ban spammers (there are separate files for messages that cause in kick, ban or hide)

Also the plugin supports immunity flags — by default q (ADMIN_LEVEL_E).

CVAR list:
  • spam_blocker_active [0, 1, default 1] — enables or disables the plugin.
  • spam_bantime [1440 by default (one day)] — I spose everyone understood what does this cvar mean.
  • spam_check_nick [0, 1, default 1] — enables or disables nick-spam checking.
  • spam_detect_ip [0 by default] — if this set to 1 the plugin will perform needed action with any player which post any IPs to chat (but I'm still not sure that this feature is needed indeed).
  • spam_ip_mode [1, 2, 3, default 3] — what plugin is supposed to do when he found IP (of course, if IP detection is on). 1 — hide ad message. 2 — hide message and kick spamer. 3 — hide message and ban spamer.
  • spam_log_hides [0, 1, default 0] — log messages hides (only strings from file hide.ini). I made this feature because I set up a huge list of War3FT chat messages that I don't want to be shown in chat, so logging each hide of message like "tome" is some kinda strange
  • spam_warning [0, 1, default 1] — enables or disables the regular warning.
  • spam_notify_admins [0, 1, 2, default 2] — if 2 it will notify admins about all warnings, kicks and bans thru admin chat. If 1 it will notify admins about only warning (for example if somebody tries to spam anyway admin can ban him manually). If 0 no reports are sent.
  • spam_ban_mode [1, 2, default 1] — if your server is non-steam set 2 (thus plugin will ban/kick thru IP), if you got a steam-server set 1 (and the plugin will ban/kick thru SteamID).

Manual installation:
— Upload spam_blocker.amxx to your plugins directory.
— Add this plugin to the end of your plugins.ini.
— Create a folder "spam_blocker" in configs directory.
— Create files hide.ini, kick.ini, ban.ini, warn.ini, whitelist.ini and config.cfg.
— Set up a list of string in .ini files (examples: 1, 2).
— Set cvars in config.cfg.
— ???
— PROFIT!

Fast installation:
— Download & unzip attached archive to your mod folder (e. g. cstrike)
— Download attached spam_blocker.amxx and put it to your plugins folder.
— Edit hide.ini, kick.ini, ban.ini, warn.ini, whitelist.ini and config.cfg if needed.
— Add spam_blocker.amxx to the end of your plugins.ini file.
— Have fun!

Changelog:
Quote:
  • v1.0 — second stable release (I lost source code of the first release)
  • v1.1 — performance improved
  • v1.1.1 — even more optimized! Also removed debug messages
  • v1.2 — added spam_blocker.ini file
  • v1.2.1 — minor fix of major bug
  • v2.0 — almost all code has been totally rewritten, so productivity is to be very nice now.
  • v2.1 — added AMXBans autodetection
  • v2.2 — any IP detection
  • v2.3 — major optimization
  • v2.3.1 — a little regex-pattern optimization
  • v2.3.2 — minor changes
  • v2.3.3 — one more bug fix
  • v2.4 — plugin logs all hides/bans/kicks to AMX log
  • v3.0 — brand new version, a huge line of changes and fixes
  • v3.1 — added nick-checking and regular warning about spamming
  • v3.2 — major fixes, regular warning cvar
  • v3.3 — whitelist, a lot of fixes, new cvar spam_warning_message
  • v3.3.1 — renamed Spam Blocker folder to spam_blocker. When update the plugin from 3.3, don't forget to rename the folder!
  • v3.4 — added warn.ini; removed cvar spam_warning_message; when somebody gets kicked/banned/warned all online admins recieve report about that; new cvar spam_notify_admin; new cvar spam_ban_mode
  • v3.5 — lots of bugs fixed; plugin now supports Advanced Bans
  • v3.5.1 — a little fix
  • v3.5.2 — one more little fix
  • v3.6 — immunity flag
P. S. As you can see here (http://gg.zombified.ru/bans/ban_list.php) my plugin really works! If there are no active bans, you can try to search among expired bans by AUTOBAN reason.

P. P. S. As for me, I use this plugin in three ways:
1. Ban spamers (with ban.ini)
2. Kick abusers (with kick.ini)
3. Hide messages like "/rank" (with hide.ini)

P. P. P. S. Also I saw TF, HL and CZ severs, running this plugin. Please try this plugin at different mods and tell me!
Attached Files
File Type: zip spam_blocker_v3.6.zip (4.6 KB, 14416 views)
File Type: sma Get Plugin or Get Source (spam_blocker.sma - 15465 views - 6.7 KB)

Last edited by TeoNoman; 05-05-2009 at 00:53.
TeoNoman is offline
maplebest
BANNED
Join Date: May 2007
Location: Sweden, Sverige
Old 02-22-2009 , 09:38   Re: Spam Blocker
Reply With Quote #2

Nice, I hate all spammers that says such things. +karma
maplebest is offline
TeoNoman
Senior Member
Join Date: Jun 2008
Old 02-22-2009 , 09:41   Re: Spam Blocker
Reply With Quote #3

You're welcome, dude
__________________
My plugins:
Spam Blocker

My servers:
http://gg.zombified.ru
TeoNoman is offline
tuty
Veteran Member
Join Date: Jul 2008
Location: UK
Old 02-22-2009 , 09:44   Re: Spam Blocker
Reply With Quote #4

- use pcvars
- read_args (said, 127);
- get_user_authid (id,szAuthID, 31)
- you should check both say comands, i mean say and say_team
__________________
tuty is offline
Send a message via ICQ to tuty Send a message via AIM to tuty
maplebest
BANNED
Join Date: May 2007
Location: Sweden, Sverige
Old 02-22-2009 , 09:48   Re: Spam Blocker
Reply With Quote #5

"ToDo:
— A config file with deprecated strings
— AMXBans autodetection"

Do you mean you are going to make a cfg, so you can write what the users isn't allowed to type?
maplebest is offline
TeoNoman
Senior Member
Join Date: Jun 2008
Old 02-22-2009 , 09:51   Re: Spam Blocker
Reply With Quote #6

maplebest, yes.
tuty, thx, goin to fix.
__________________
My plugins:
Spam Blocker

My servers:
http://gg.zombified.ru
TeoNoman is offline
maplebest
BANNED
Join Date: May 2007
Location: Sweden, Sverige
Old 02-22-2009 , 09:55   Re: Spam Blocker
Reply With Quote #7

Okay, I see. I might add this to a server if I get one..
maplebest is offline
TeoNoman
Senior Member
Join Date: Jun 2008
Old 02-22-2009 , 10:00   Re: Spam Blocker
Reply With Quote #8

Do not hurry. I'm going to release v1.1 in a few minutes.
__________________
My plugins:
Spam Blocker

My servers:
http://gg.zombified.ru
TeoNoman is offline
Arkshine
AMX Mod X Plugin Approver
Join Date: Oct 2005
Old 02-22-2009 , 10:18   Re: Spam Blocker
Reply With Quote #9

You should not be that specific.

- It would be more interesting to be able to write via a file a list of text to block
- Use pcvar, it's faster.
- Use a switch() instead of if() if() etc.
Arkshine is offline
TeoNoman
Senior Member
Join Date: Jun 2008
Old 02-22-2009 , 10:26   Re: Spam Blocker v1.1.1
Reply With Quote #10

arkshine, moved to pcvars, moved to switch. But what do u mean about first suggestion? I didn't get it (sry, english is not my native lang).

tuty, what's wrong with read_args (said, 127) and get_user_authid (id,szAuthID, 31)?
__________________
My plugins:
Spam Blocker

My servers:
http://gg.zombified.ru
TeoNoman is offline
Reply


Thread Tools
Display Modes

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 -4. The time now is 22:11.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode