Chat spam, prefixes, instant-chat abuse

What do you want to see in Armagetron soon? Any new feature ideas? Let's ponder these ground breaking ideas...
Post Reply
User avatar
dlh
Formerly That OS X Guy
Posts: 2035
Joined: Fri Jan 02, 2004 12:05 am
Contact:

Chat spam, prefixes, instant-chat abuse

Post by dlh »

I've created a branch with some new spam checks. Some players are abusing the instant-chat “\” feature. They use this feature to always start their message with a color code, or some prefix text (usually a clan-tag).

0.2.8-armagetronad-newspam deals with this issue. Messages found to have a common prefix are now treated as spam. You won't get spam-silenced, rather your message will not get sent.
  • Only public chat messages are checked.
  • If you send a public chat message directed towards a user, it will not checked. For example:
    game chat wrote:me: Player 1: are you the real Player 1?
    Player 1: yes.
    me: Player 1: LOL!
  • Prefixes that begin with a color code or contain several color codes are more likely to be treated as spam, than as with the same text with no colors.
  • Longer prefixes are also more likely to be treated as spam.
The default settings should work well. They're in settings_dedicated.cfg. I haven't done any testing on a live-server with many players, but I think all legitimate messages will get through.
User avatar
Z-Man
God & Project Admin
Posts: 11585
Joined: Sun Jan 23, 2005 6:01 pm
Location: Cologne
Contact:

Post by Z-Man »

Splendid. I'll test this on Bugfarm Sumo, and if all goes well for a while, I'd have no objections against merging it for 0.2.8.3.
AI Teâm
Core Dumper
Posts: 106
Joined: Sun Nov 02, 2008 8:38 pm
Location: Munich

Post by AI Teâm »

Thats rly bad z-man , cuz on all your servers i cannot write anything!!
User avatar
Z-Man
God & Project Admin
Posts: 11585
Joined: Sun Jan 23, 2005 6:01 pm
Location: Cologne
Contact:

Post by Z-Man »

Proof it works :)

(Plus, can't be. The code is only active on Elimination Sumo.)

In case it got lost on IRC, it's still possible to get single letter prefixes blocked. Just say
pa
pb
pc
pd
pe
pf
and so on. I think pf will already get blocked then. Do blocked prefixes ever get unblocked? ( <- too lazy to look into the code for that.)
User avatar
dlh
Formerly That OS X Guy
Posts: 2035
Joined: Fri Jan 02, 2004 12:05 am
Contact:

Post by dlh »

Single letter prefixes are not blocked anymore. With a two letter prefix, 6 messages will get through. The 7th will be blocked.

Known prefixes also time-out now.
User avatar
dlh
Formerly That OS X Guy
Posts: 2035
Joined: Fri Jan 02, 2004 12:05 am
Contact:

Post by dlh »

wrtlprnft kindly gave me his Fortress Café log files. I parsed the chat from them into a xml file, and added a test-case to the branch. The xml file is (of course) missing color-codes. I'll update with a link to it if he gives me permission to release it.

The attached file is the result of the test. There were very very few false positives. Some messages directed towards another player were picked up as spam in the test, but this was because the way the test was run. Those won't be picked up as prefix-spam in the game.

A few cases of "hey " got picked up as spam. Here is an example:

Code: Select all

        <Said time="961651871">hey g5</Said>
        <Said time="961651877">hey CTºAdy-Lucifer </Said>
        <Said time="961651879">hey CT_emmy </Said>
        <Said time="961651882">hey madmax </Said>
        <Said time="961651885">hey ~|DS|~|Alien|~ </Said>
        <Said time="961651907">hey ~|DS|~ Judders, Lackadaisical </Said>
I think it is acceptable to block that, and it difficult not to and still catch other prefix-spam.

Code: Select all

Statistics:
	Number of sessions tested: 17242
	Number of chats: 305136
	Number of chats let through: 302860
	Number of chats blocked: 2276
	Number of chat prefixes found: 657
Attachments
prefix-spam-test.txt.bz2
Really is a bz2 file.
(3.74 KiB) Downloaded 115 times
User avatar
sinewav
Graphic Artist
Posts: 6413
Joined: Wed Jan 23, 2008 3:37 am
Contact:

Post by sinewav »

I can't wait for this. The amount of colored chat is completely out of control. I usually have to silence 50% of the players in any given server. I wish FILTER_COLOR_STRINGS worked in a way where the regular chat color is added back before output to the console.
User avatar
Z-Man
God & Project Admin
Posts: 11585
Joined: Sun Jan 23, 2005 6:01 pm
Location: Cologne
Contact:

Post by Z-Man »

Code: Select all

        <Said time="961651871">hey g5</Said>
        <Said time="961651877">hey CTºAdy-Lucifer </Said>
        <Said time="961651879">hey CT_emmy </Said>
        <Said time="961651882">hey madmax </Said>
        <Said time="961651885">hey ~|DS|~|Alien|~ </Said>
        <Said time="961651907">hey ~|DS|~ Judders, Lackadaisical </Said>
Are those times seconds? Then yes, it's an annoying amount of heys that's tolerable to block. I'll double check that the code can be completely disabled and merge it.
User avatar
dlh
Formerly That OS X Guy
Posts: 2035
Joined: Fri Jan 02, 2004 12:05 am
Contact:

Post by dlh »

Yes those are seconds—the heys were all done is span of ~30 seconds.

The windows project needs an update to add the eChat.{h, cpp} files.
User avatar
Z-Man
God & Project Admin
Posts: 11585
Joined: Sun Jan 23, 2005 6:01 pm
Location: Cologne
Contact:

Post by Z-Man »

I'll do that on occasion, and the translation of the new doc strings as well. Are the detailed config options undocumented on purpose?

I disabled the test subdirectory, it doesn't work for me, and shouldn't get touched on a regular build anyway. Plus, as you noticed, it's an ugly solution :) We should think of something better on the trunk, possibly after we decide what to do with epsy's CMAKE effort.
User avatar
dlh
Formerly That OS X Guy
Posts: 2035
Joined: Fri Jan 02, 2004 12:05 am
Contact:

Post by dlh »

The detailed config options are only exposed on DEBUG builds. Should I enable them for all builds?
User avatar
Z-Man
God & Project Admin
Posts: 11585
Joined: Sun Jan 23, 2005 6:01 pm
Location: Cologne
Contact:

Post by Z-Man »

I'd say so; it can't hurt, and we may want to publish fine tuned settings later. Like the smartcam finetuning settings, they don't need to be documented (but should be explicitly undocumented).
User avatar
rumpole
On Lightcycle Grid
Posts: 43
Joined: Sat Mar 14, 2009 2:52 am

Post by rumpole »

what exactly is wrong with clan or color prefixes ?
Writing code is easy. Finishing is hard.
User avatar
Z-Man
God & Project Admin
Posts: 11585
Joined: Sun Jan 23, 2005 6:01 pm
Location: Cologne
Contact:

Post by Z-Man »

They both distract from the actual chat message. I personally just apply my usual technique of passively ignoring them, which is especially easy for color code spammers; my eyes are conditioned to only read yellow text as chat (unless in team play, where red also works) and the rest as blurby server messages. But then people are surprised when they realize I didn't pay attention to what they are saying for the last fifteen minutes, and this feature protects them :)
Post Reply