egghelp.org community Forum Index
[ egghelp.org home | forum home ]
egghelp.org community
Discussion of eggdrop bots, shell accounts and tcl scripts.
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

checking bad nick on connect

 
Post new topic   Reply to topic    egghelp.org community Forum Index -> Script Requests
View previous topic :: View next topic  
Author Message
milco
Voice


Joined: 21 Apr 2014
Posts: 1

PostPosted: Mon Apr 21, 2014 3:36 pm    Post subject: checking bad nick on connect Reply with quote

hi all i was looking for a tcl to check nicks on connect in a opered eggdrop
and match them with a list of badnicks possibly with regex and if there is a match to kill user rather than to have eggdrop check on channel joins
i have been looking for it for like ages it would help our bots a lot to prevent joining of bad nicks and not load it all on the ircd

im plan on using on a inspIRCD server

apreciated

thank you in advance
Back to top
View user's profile Send private message
Get_A_Fix
Master


Joined: 07 May 2005
Posts: 206
Location: New Zealand

PostPosted: Thu May 29, 2014 1:59 pm    Post subject: Reply with quote

Depending on how your snotices are piped, it can be relatively easy. You will have to play around with this code, to suit your exact arguments, but it should help you make the script you want. Read this.

Then, you'll want to use a list, like
Code:

set badnicks {
  "*thisnick*"
  "*badnick*"
  "*keep*"
  "*adding*"
  "*withthe*"
  "*wildcards*"
}


Then, in the codeblock/proc, you'd want something like

Code:

foreach checknick $::badnicks {
  if {[string match -nocase $checknick $nick]} {
    putquick "KILL $nick :You match a Bad Nickname. This is not Permitted on $::network. Please change your nickname to reconnect. (matching: $checknick)"
  }
}


Hope it works out.
_________________
We explore.. and you call us criminals. We seek after knowledge.. and you call us criminals. We exist without skin color, without nationality, without religious bias.. and you call us criminals.
Back to top
View user's profile Send private message AIM Address Yahoo Messenger MSN Messenger
Display posts from previous:   
Post new topic   Reply to topic    egghelp.org community Forum Index -> Script Requests All times are GMT - 4 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Forum hosting provided by Reverse.net

Powered by phpBB © 2001, 2005 phpBB Group
subGreen style by ktauber