| View previous topic :: View next topic |
| Author |
Message |
nml375 Revered One
Joined: 04 Aug 2006 Posts: 2857
|
Posted: Tue Nov 20, 2007 11:18 am Post subject: |
|
|
Managed to sneak in a tiny typo. Fixed now. _________________ NML_375, idling at #eggdrop@IrcNET |
|
| Back to top |
|
 |
Sydneybabe Op
Joined: 27 Apr 2007 Posts: 106 Location: Philippines
|
Posted: Thu Nov 22, 2007 9:52 am Post subject: |
|
|
hi nml375 i load the script and restart and then try it and this is appear on partyline:
<Bot> [08:46] Recieved chanserv-notice "[VERBOSE] SopUser!~usa@dal.net => akick #channel add *!*@test.com1" from "ChanServ!service@dal.net" to "@#channel"
<Bot> [08:46] Recieved chanserv-notice "SopUser has SOp access to #channel. Reason: Identification to the nickname SopUser. Channel Frozen: NO" from "ChanServ!service@dal.net" to "Bot"
<Bot> [08:46] -ChanServ (service@dal.net)- SopUser has SOp access to #channel. Reason: Identification to the nickname SopUser. Channel Frozen: NO
...the sop eggdrop Bot still doesn't remove the akick issued by the sop SopUser :/ |
|
| Back to top |
|
 |
nml375 Revered One
Joined: 04 Aug 2006 Posts: 2857
|
Posted: Thu Nov 22, 2007 10:19 am Post subject: |
|
|
Had to add the banmask to the queue-list, which broke matching in "stage 2". Changed to use an array now. _________________ NML_375, idling at #eggdrop@IrcNET |
|
| Back to top |
|
 |
Sydneybabe Op
Joined: 27 Apr 2007 Posts: 106 Location: Philippines
|
Posted: Fri Nov 23, 2007 9:03 am Post subject: |
|
|
hi nml375 i load the script and this is what appear on putty:
[07:59] can't unset "akick:queue": no such variable
while executing
"unset akick:queue "
(file "scripts/noakick.tcl" line 3)
invoked from within
"source scripts/noakick.tcl"
(file "eggdrop.conf" line 480)
[07:59] * CONFIG FILE NOT LOADED (NOT FOUND, OR ERROR) |
|
| Back to top |
|
 |
nml375 Revered One
Joined: 04 Aug 2006 Posts: 2857
|
Posted: Fri Nov 23, 2007 2:21 pm Post subject: |
|
|
Sorry, should've caught that line I suppose... updating code shorly.
Thanks for your patience sofar, somewhat limited possibilities for debugging as I don't use dalnet or chanserv-services myself. _________________ NML_375, idling at #eggdrop@IrcNET |
|
| Back to top |
|
 |
Sydneybabe Op
Joined: 27 Apr 2007 Posts: 106 Location: Philippines
|
Posted: Fri Nov 23, 2007 4:03 pm Post subject: |
|
|
hi nml375 i load the script and this is what appear on partyline:
<Bot> [14:56] Recieved chanserv-notice "[VERBOSE] SopUser!~usa@dalnet => akick #channel add *!*@i.am.a.1337.bsdguru.us" from "ChanServ!service@dal.net" to "@#channel"
<Bot> [14:56] Recieved chanserv-notice "SopUser has SOp access to #channel. Reason: Identification to the nickname SopUser. Channel Frozen: NO" from "ChanServ!service@dal.net" to "Bot"
<Bot> [14:56] -ChanServ (service@dal.net)- SopUser has SOp access to #channel. Reason: Identification to the nickname SopUser. Channel Frozen: NO
.. still sop Bot not deleting the akick issued by sop SopUser :/ |
|
| Back to top |
|
 |
nml375 Revered One
Joined: 04 Aug 2006 Posts: 2857
|
Posted: Fri Nov 23, 2007 4:49 pm Post subject: |
|
|
Posting a separate version here with some extended debugging.
| Code: | bind notc - {[VERBOSE]* => akick * add *} check:akick
bind notc - {* has * access to * Reason:*} check:why
catch {unset akick:queue}
proc check:akick {nick host hand text {dest ""}} {
putlog "Recieved chanserv-notice \"$text\" from \"$nick!$host\" to \"$dest\""
if {$dest == "" || [isbotnick $dest] || ![string equal -nocase "chanserv!service@dal.net" "$nick!$host"]} {
putlog "Possible forged ChanServ. Ignoring..."
return
}
if {[regexp -- {^\[VERBOSE\] (.+?)!(.+?) => akick (.+?) add (.+?)$} [stripcodes bcruag $text] match tnick thost tchan tmask] && ![isbotnick $tnick]} {
putlog "Data extracted: $tnick $thost $tchan $tmask"
set ::akick:queue([list [string tolower $tchan] [string tolower $tnick]]) $tmask
putlog "Sending: CHANSERV WHY $tchan $tnick"
putserv "CHANSERV WHY $tchan $tnick"
}
}
proc check:why {nick host hand text {dest ""}} {
putlog "Recieved chanserv-notice \"$text\" from \"$nick!$host\" to \"$dest\""
if {![string equal -nocase "chanserv!service@dal.net" "$nick!$host"]} {
putlog "Possible forged ChanServ. Ignoring..."
return
}
if {$dest == "" || [isbotnick $dest]} {
putlog "Origin appears authentic, continuing..."
if {[regexp -- {^(.+?) has (SOp|AOp) access to (.+?)\. +Reason: Identification to the nickname (.+?)\. Channel Frozen: (YES|NO)$} [stripcodes bcruag $text] match tnick tacc tchan trnick tfrozen]} {
putlog "Data extracted: $tnick $tacc $tchan $trnick $tfrozen"
if {[info exists ::akick:queue] && [info exists ::akick:queue([list [string tolower $tchan] [string tolower $tnick]])]} {
putlog "Sending: CHANSERV AKICK $tchan DEL [set ::akick:queue([list [string tolower $tchan] [string tolower $tnick]])]"
putserv "CHANSERV AKICK $tchan DEL [set ::akick:queue([list [string tolower $tchan] [string tolower $tnick]])]"
puthelp "PRIVMSG $tnick :Only Founder may add AKICK's to $tchan"
unset ::akick:queue([list [string tolower $tchan] [string tolower $tnick]])
} {
putlog "Did not find scheduled check. Ignoring (Status: [info exists ::akick:queue] [info exists ::akick:queue([list [string tolower $tchan] [string tolower $tnick]])]"
}
}
}
}
|
Edit:
Escaping literal dots (.) in the regular expression.
Edit:
Now matching multiple spaces after the channelname. _________________ NML_375, idling at #eggdrop@IrcNET
Last edited by nml375 on Fri Dec 07, 2007 1:58 pm; edited 3 times in total |
|
| Back to top |
|
 |
Sydneybabe Op
Joined: 27 Apr 2007 Posts: 106 Location: Philippines
|
Posted: Tue Nov 27, 2007 10:43 pm Post subject: |
|
|
hi nml375 i load the script and this is what appear on partyline:
<Bot> [21:37] Recieved chanserv-notice "[VERBOSE] SopUser!~x@203.111.234.24 => akick #channel add *!*@test.com" from "ChanServ!service@dal.net" to "@#channel"
<Bot> [21:37] Data extracted: HackServ ~x@203.111.234.24 #channel *!*@test.com
<Bot> [21:37] Sending: CHANSERV WHY #channel SopUser
<Bot> [21:37] Recieved chanserv-notice "SopUser has SOp access to #channel. Reason: Identification to the nickname SopUser. Channel Frozen: NO" from "ChanServ!service@dal.net" to "Bot"
<Bot> [21:37] Origin appears authentic, continuing...
<Bot> [21:37] Data extracted: SopUser SOp #channel. SopUser NO
<Bot> [21:37] Did not find scheduled check. Ignoring (Status: 1 0
<Bot> [21:37] -ChanServ (service@dal.net)- SopUser has SOp access to #channel. Reason: Identification to the nickname SopUser. Channel Frozen: NO |
|
| Back to top |
|
 |
nml375 Revered One
Joined: 04 Aug 2006 Posts: 2857
|
Posted: Wed Nov 28, 2007 6:51 am Post subject: |
|
|
Unfortunately, obfuscating "HackServ" makes it somewhat hard to pin this down. _________________ NML_375, idling at #eggdrop@IrcNET |
|
| Back to top |
|
 |
Sydneybabe Op
Joined: 27 Apr 2007 Posts: 106 Location: Philippines
|
Posted: Wed Nov 28, 2007 9:31 am Post subject: |
|
|
| hi nml375 HackServ anyway is only a nick and no access to Dalnet Services it's just i forgot to edit that nick HackServ change to SopUser. |
|
| Back to top |
|
 |
nml375 Revered One
Joined: 04 Aug 2006 Posts: 2857
|
Posted: Wed Nov 28, 2007 9:40 am Post subject: |
|
|
That I've figured aswell..
But by obfuscating it, it makes it difficult to figure out why this check fails:
| Code: | | if {[info exists ::akick:queue] && [info exists ::akick:queue([list [string tolower $tchan] [string tolower $tnick]])]} { |
Or, more speciffic, it seems "[list [string tolower $tchan] [string tolower [$tnick]]" yields different results in the two procs. _________________ NML_375, idling at #eggdrop@IrcNET |
|
| Back to top |
|
 |
Sydneybabe Op
Joined: 27 Apr 2007 Posts: 106 Location: Philippines
|
Posted: Wed Nov 28, 2007 10:36 pm Post subject: |
|
|
| how to solved it nml375 i don't have idea :/ |
|
| Back to top |
|
 |
nml375 Revered One
Joined: 04 Aug 2006 Posts: 2857
|
Posted: Thu Nov 29, 2007 8:49 am Post subject: |
|
|
The debugging was added to provide the information to see what and why it does'nt match properly. Unfortunately, the data you've posted has brought no light into the matter, and actually works just fine when I simulate it on one of my own eggies (triggering each proc manually with the data you've provided).
Without better debug-data, I can only conclude "Works for me". _________________ NML_375, idling at #eggdrop@IrcNET |
|
| Back to top |
|
 |
Sydneybabe Op
Joined: 27 Apr 2007 Posts: 106 Location: Philippines
|
Posted: Mon Dec 03, 2007 2:42 am Post subject: |
|
|
hi nml375 i load the script and restart the bot and this is what appear on partyline:
<Tashwini> [01:32] Recieved chanserv-notice "[VERBOSE] maLd|tang`masung|t!~grace@d193-69-36.home3.cgocable.net => akick #anthony add *!*@test.com" from "ChanServ!service@dal.net" to "@#anthony"
<Tashwini> [01:32] Data extracted: maLd|tang`masung|t ~grace@d193-69-36.home3.cgocable.net #anthony *!*@test.com
<Tashwini> [01:32] Sending: CHANSERV WHY #anthony maLd|tang`masung|t
<Tashwini> [01:32] Recieved chanserv-notice "maLd|tang`masung|t has SOp access to #anthony. Reason: Identification to the nickname maLd|tang`masung|t. Channel Frozen: NO" from "ChanServ!service@dal.net" to "Tashwini"
<Tashwini> [01:32] Origin appears authentic, continuing...
<Tashwini> [01:32] Data extracted: maLd|tang`masung|t SOp #anthony. maLd|tang`masung|t NO
<Tashwini> [01:32] Did not find scheduled check. Ignoring (Status: 1 0
<Tashwini> [01:32] -ChanServ (service@dal.net)- maLd|tang`masung|t has SOp access to #anthony. Reason: Identification to the nickname maLd|tang`masung|t. Channel Frozen: NO
..still the sop bot Tashwini not removing the akick issued by a sop user maLd|tang`masung|t :/ |
|
| Back to top |
|
 |
nml375 Revered One
Joined: 04 Aug 2006 Posts: 2857
|
Posted: Mon Dec 03, 2007 7:22 am Post subject: |
|
|
Problem located, forgot to escape a . in one of the regular expressions. Updating posts shortly.. _________________ NML_375, idling at #eggdrop@IrcNET |
|
| Back to top |
|
 |
|