| View previous topic :: View next topic |
| Author |
Message |
user

Joined: 18 Mar 2003 Posts: 1452 Location: Norway
|
Posted: Mon Jul 21, 2003 5:26 pm Post subject: |
|
|
| Sir_Fz wrote: | | yeah, that's not a bad idea. but still there are some nicks that are not in a dictionary (as have no meaning), so it might be more messy than the regexp mentioned. |
That's the beauty of my method (I think/hope), because even if they're not real words most nicks SOUND like real words. Except strange nicks like where a number becomes a couple of chars in a word etc...but these could be translated to chars with a 'string map' before the soundex is made (in most cases) and the rest would be allowed to re-enter through the /msg command |
|
| Back to top |
|
 |
Sir_Fz Revered One

Joined: 27 Apr 2003 Posts: 3793 Location: Lebanon
|
Posted: Mon Jul 21, 2003 5:32 pm Post subject: |
|
|
yeah ur right, It might be a good idea for a script. also we might add a system that if 5 nicknames of this kind join in a certain period of time the bot locks the chan...
like the bogus username join. _________________ Follow me on GitHub
- Opposing
Public Tcl scripts |
|
| Back to top |
|
 |
z_one Master

Joined: 14 Jan 2002 Posts: 269 Location: Canada
|
Posted: Tue Jul 22, 2003 1:11 pm Post subject: |
|
|
Isn't the "y" a vowel ?
There are 6 vowels: a, e, o, u, i and y
As I understand, your code is supposed to look for all vowels because spam nicks (as your code assumes but it's not necessarily always the case) are made up of consonants.
For example the nick: wdvghhn
Anyway it's really up to you whether you decide to include the "y" or not. |
|
| Back to top |
|
 |
Papillon Owner

Joined: 15 Feb 2002 Posts: 724 Location: *.no
|
Posted: Tue Jul 22, 2003 3:03 pm Post subject: |
|
|
did anyone test those regular expressions? _________________ Elen sila lúmenn' omentielvo |
|
| Back to top |
|
 |
Sir_Fz Revered One

Joined: 27 Apr 2003 Posts: 3793 Location: Lebanon
|
Posted: Tue Jul 22, 2003 3:41 pm Post subject: |
|
|
yeah I did.
Its actualy pretty good. although there are 1 or 2 innoscent users being kicked every hour. but it also bans flooders using random nicks. so it would be better if someone can give a way to lock the channel if 3 nicks join together in X seconds.
Z_one: well its not about vowels, the code I gave doesn't include y in it. (I'm not the one who coded it) _________________ Follow me on GitHub
- Opposing
Public Tcl scripts |
|
| Back to top |
|
 |
Papillon Owner

Joined: 15 Feb 2002 Posts: 724 Location: *.no
|
Posted: Tue Jul 22, 2003 4:10 pm Post subject: |
|
|
hmmm..
| Code: | | regexp {^[^aeiou_^-`]+$} $nick | return 1 even if - is in the nick
| Code: | | regexp {[^0-9]?$} $nick | return 1 no mather what
try changing the if-test to
| Code: | if {[regexp {^[^aeiou_^`-]+$} $nick] \
&& [regexp {^[^0-9]+$} $nick] \
&& ([string length $nick] > 3)} {...} |
_________________ Elen sila lúmenn' omentielvo |
|
| Back to top |
|
 |
Sir_Fz Revered One

Joined: 27 Apr 2003 Posts: 3793 Location: Lebanon
|
|
| Back to top |
|
 |
Sir_Fz Revered One

Joined: 27 Apr 2003 Posts: 3793 Location: Lebanon
|
Posted: Wed Jul 23, 2003 2:25 am Post subject: |
|
|
I haven't noticed anything different.
but I noticed that using this regexp it kicks user with a nick all CAPS. like for example if user "SIRFZ" joins, it gets kicked. what's the reason ? (Note that this is not a change after Papillon modified the code, it also happened when using TsT's code.) _________________ Follow me on GitHub
- Opposing
Public Tcl scripts |
|
| Back to top |
|
 |
Papillon Owner

Joined: 15 Feb 2002 Posts: 724 Location: *.no
|
Posted: Wed Jul 23, 2003 3:46 am Post subject: |
|
|
well, that's easily fixed, just add -nocase as option to the first regexp... like this: | Code: | | regexp -nocase -- {^[^aeiou_^`-]+$} $nick |
_________________ Elen sila lúmenn' omentielvo |
|
| Back to top |
|
 |
Sir_Fz Revered One

Joined: 27 Apr 2003 Posts: 3793 Location: Lebanon
|
|
| Back to top |
|
 |
Sir_Fz Revered One

Joined: 27 Apr 2003 Posts: 3793 Location: Lebanon
|
Posted: Thu Jul 24, 2003 6:32 pm Post subject: |
|
|
is there a way to add "\" into the regexp ? cuz some nicks have \, most of them are bot
like regexp -nocase -- {^[^aeiou_\^`-]+$} $nick (but i know that slashes are used to separate, so how to do it ?) _________________ Follow me on GitHub
- Opposing
Public Tcl scripts |
|
| Back to top |
|
 |
Papillon Owner

Joined: 15 Feb 2002 Posts: 724 Location: *.no
|
Posted: Fri Jul 25, 2003 4:33 am Post subject: |
|
|
just escape it with another \
| Code: | | regexp -nocase -- {^[^aeiou\\_^`-]+$} $nick |
_________________ Elen sila lúmenn' omentielvo |
|
| Back to top |
|
 |
Sir_Fz Revered One

Joined: 27 Apr 2003 Posts: 3793 Location: Lebanon
|
|
| Back to top |
|
 |
Sir_Fz Revered One

Joined: 27 Apr 2003 Posts: 3793 Location: Lebanon
|
Posted: Fri Jul 25, 2003 5:28 pm Post subject: |
|
|
well , last request.
how can u make it also check for random idents like these ? _________________ Follow me on GitHub
- Opposing
Public Tcl scripts |
|
| Back to top |
|
 |
Papillon Owner

Joined: 15 Feb 2002 Posts: 724 Location: *.no
|
Posted: Fri Jul 25, 2003 5:55 pm Post subject: |
|
|
do a whois when the user/bot joins. Then catch the whois-reply with bind raw and just add the same if-check in there... when you have pulled out the ident from all the input ofcourse  _________________ Elen sila lúmenn' omentielvo |
|
| Back to top |
|
 |
|