This is the new home of the egghelp.org community forum.
All data has been migrated (including user logins/passwords) to a new phpBB version.


For more information, see this announcement post. Click the X in the top right-corner of this box to dismiss this message.

nickserv on ircx

Old posts that have not been replied to for several years.
Locked
b
b_raven
Voice
Posts: 6
Joined: Tue Jul 20, 2004 1:43 am

nickserv on ircx

Post by b_raven »

Hi. I recently migrated to Linux and therefore need to switch my bot to eggdrop.
There is one last problem before the bot can be put in use, a nickserv autoidenting script.
The problem is that IRCX doesn't have a physical representation of the services, so none of the nickserv scripts I've looked at can be used.
Was wondering if someone could help me.
IRCX sends the following _512_ raw to the client
$nick Authorization required to use Registered Nickname $nick
(where $nick is the nick of the user)
need the bot to reply to that with "/pass password"
Hope someone are willing to help.
User avatar
awyeah
Revered One
Posts: 1580
Joined: Mon Apr 26, 2004 2:37 am
Location: Switzerland
Contact:

Post by awyeah »

This is very easy. Make a bind to trigger on raw 512.

Then make a procedure to follow up that bind, also string matching the text, via some conditions with a putserv in the end to send the password to the server to identify the nick.
·­awyeah·

==================================
Facebook: jawad@idsia.ch (Jay Dee)
PS: Guys, I don't accept script helps or requests personally anymore.
==================================
b
b_raven
Voice
Posts: 6
Joined: Tue Jul 20, 2004 1:43 am

Post by b_raven »

hmmm.... would be helpful if I knew how to match the raw to the string I'm looking for.
Don't know the valid operators for if in TCL and iif wildcards are allowed (and if yes, which)...
*sounds the noob alarm* :oops:
User avatar
awyeah
Revered One
Posts: 1580
Joined: Mon Apr 26, 2004 2:37 am
Location: Switzerland
Contact:

Post by awyeah »

Well for that I would need the output displayed by the raw when it asks for nick identification.

You mentioned something like this:
$nick Authorization required to use Registered Nickname $nick

So if it's like this you can try a string match:

Code: Select all

if {([string match -nocase "*Authorization required to use Registered Nickname*" $text])} { putserv "PASS <bots password here>" }
Something, like this should work.
·­awyeah·

==================================
Facebook: jawad@idsia.ch (Jay Dee)
PS: Guys, I don't accept script helps or requests personally anymore.
==================================
b
b_raven
Voice
Posts: 6
Joined: Tue Jul 20, 2004 1:43 am

Post by b_raven »

Thanks a lot for the help :)
*gets to work*
User avatar
awyeah
Revered One
Posts: 1580
Joined: Mon Apr 26, 2004 2:37 am
Location: Switzerland
Contact:

Post by awyeah »

Here try this.

You can try the way I have done below in the code or try using wildcards between the text, or even try matching seperate words in the raw output string using lindex $arg, bla bla.

Code: Select all

#Set the text matching procedure for the raw.
set rawmatch "*Authorization required to use Registered Nickname*"

#Set your bots nick password here.
set nickpass "iamelite"

bind raw - 512 identify:nick

proc identify:nick {from key arg} { 
 global rawmatch nickpass
  if {([string match -nocase $rawmatch $arg])} { 
  putquick "PASS $nickpass" -next
  }
}
Try, this it should work.

Another alternative solution is to, identify the bot's nick
password on connection to the server. For that you simply
need to bind EVNT, with the parameter init-server.

I don't think I need give you that init-server code on bind
evnt, as there are atleast 100 or more topics in this forum
regarding that, both in the tcl and eggdrops section, so just
search it.
·­awyeah·

==================================
Facebook: jawad@idsia.ch (Jay Dee)
PS: Guys, I don't accept script helps or requests personally anymore.
==================================
Locked