<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en-gb">
	<link rel="self" type="application/atom+xml" href="https://forum.eggheads.org/app.php/feed/topic/21153" />

	<title>egghelp/eggheads community</title>
	<subtitle>Discussion of eggdrop bots, shell accounts and tcl scripts.</subtitle>
	<link href="https://forum.eggheads.org/index.php" />
	<updated>2022-05-22T12:23:55-04:00</updated>

	<author><name><![CDATA[egghelp/eggheads community]]></name></author>
	<id>https://forum.eggheads.org/app.php/feed/topic/21153</id>

		<entry>
		<author><name><![CDATA[Spartan]]></name></author>
		<updated>2022-05-22T12:23:55-04:00</updated>

		<published>2022-05-22T12:23:55-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=111146#p111146</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=111146#p111146"/>
		<title type="html"><![CDATA[Hi]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=111146#p111146"><![CDATA[
Spike^^ ty again the scripts works great now and set mode channel and ban and kick in order also time ban and time mode is work great exact unset and unban all. <br><br>Spike^^ thx a lot a great fast script<br><div class="codebox"><p>Code: </p><pre><code>[19:20:44] * Joins: gudiya (zmiitx@D2B89372.23EF34A4.322F620B.IP)  [19:20:44] * Joins: kanha (bgich@D7FF18AC.ACDA578F.C64C234B.IP)  [19:20:44] * Joins: shree (kzyvoh@39CE9ADB.6A1EB3FD.C64C234B.IP)  [19:20:44] * Joins: coco (wlidc@2B559C8D.ACDA578F.C64C234B.IP)  [19:20:44] * Joins: pihu (kcelejr@8BF03232.C88719AD.322F620B.IP)  [19:20:45] * X sets mode: +bbbbb *!*@D2B89372.23EF34A4.322F620B.IP *!*@D7FF18AC.ACDA578F.C64C234B.IP *!*@39CE9ADB.6A1EB3FD.C64C234B.IP *!*@2B559C8D.ACDA578F.C64C234B.IP *!*@8BF03232.C88719AD.322F620B.IP[19:20:45] * gudiya was kicked from #test by X (Sorry, Try to connect via WEBIRC)[19:20:45] * kanha was kicked from #test by X (Sorry, Try to connect via WEBIRC)[19:20:45] * shree was kicked from #test by X (Sorry, Try to connect via WEBIRC)[19:20:45] * coco was kicked from #test by X (Sorry, Try to connect via WEBIRC)[19:20:45] * pihu was kicked from #test by X (Sorry, Try to connect via WEBIRC)[19:20:44] * Joins: gudiya (zmiitx@D2B89372.23EF34A4.322F620B.IP)[19:20:44] * Joins: kanha (bgich@D7FF18AC.ACDA578F.C64C234B.IP)[19:20:44] * Joins: shree (kzyvoh@39CE9ADB.6A1EB3FD.C64C234B.IP)[19:20:44] * Joins: coco (wlidc@2B559C8D.ACDA578F.C64C234B.IP) [19:20:44] * Joins: pihu (kcelejr@8BF03232.C88719AD.322F620B.IP)[19:20:45] * X sets mode: +bbbbb *!*@D2B89372.23EF34A4.322F620B.IP *!*@D7FF18AC.ACDA578F.C64C234B.IP *!*@39CE9ADB.6A1EB3FD.C64C234B.IP *!*@2B559C8D.ACDA578F.C64C234B.IP *!*@8BF03232.C88719AD.322F620B.IP[19:20:45] * gudiya was kicked from #test by X (Sorry, Try to connect via WEBIRC)[19:20:45] * kanha was kicked from #test by X (Sorry, Try to connect via WEBIRC)[19:20:45] * shree was kicked from #test by X (Sorry, Try to connect via WEBIRC)[19:20:45] * coco was kicked from #test by X (Sorry, Try to connect via WEBIRC)[19:20:45] * pihu was kicked from #test by X (Sorry, Try to connect via WEBIRC)[19:19:43] * Joins: kanha (bgich@D7FF18AC.ACDA578F.C64C234B.IP)[19:19:43] * Joins: pihu (kcelejr@8BF03232.C88719AD.322F620B.IP)[19:19:44] * X sets mode: +NR [19:19:44] * X sets mode: +bb *!*@D7FF18AC.ACDA578F.C64C234B.IP *!*@8BF03232.C88719AD.322F620B.IP[19:19:44] * kanha was kicked from #test by X (Sorry, Try to connect via WEBIRC)[19:19:44] * pihu was kicked from #test by X (Sorry, Try to connect via WEBIRC)[19:25:05] * Joins: gudiya (zmiitx@D2B89372.23EF34A4.322F620B.IP)[19:25:05] * Joins: coco (wlidc@2B559C8D.ACDA578F.C64C234B.IP) [19:25:05] * Joins: kanha (bgich@D7FF18AC.ACDA578F.C64C234B.IP)[19:25:05] * X sets mode: +E [19:25:06] * gudiya was kicked from #test by X (Sorry, Try to connect via WEBIRC)[19:25:06] * coco was kicked from #test by X (Sorry, Try to connect via WEBIRC)[19:25:06] * kanha was kicked from #test by X (Sorry, Try to connect via WEBIRC)[19:25:05] * Joins: gudiya (zmiitx@D2B89372.23EF34A4.322F620B.IP)[19:25:05] * Joins: coco (wlidc@2B559C8D.ACDA578F.C64C234B.IP)[19:25:05] * Joins: kanha (bgich@D7FF18AC.ACDA578F.C64C234B.IP)[19:25:05] * X sets mode: +E [19:25:06] * gudiya was kicked from #testing by X (Sorry, Try to connect via WEBIRC)[19:25:06] * coco was kicked from #testing by X (Sorry, Try to connect via WEBIRC)[19:25:06] * kanha was kicked from #testing by X (Sorry, Try to connect via WEBIRC)[19:25:44] * X sets mode: -bbbbb *!*@D2B89372.23EF34A4.322F620B.IP *!*@D7FF18AC.ACDA578F.C64C234B.IP *!*@39CE9ADB.6A1EB3FD.C64C234B.IP *!*@2B559C8D.ACDA578F.C64C234B.IP *!*@8BF03232.C88719AD.322F620B.IP[19:27:05] * X sets mode: -E</code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=12970">Spartan</a> — Sun May 22, 2022 12:23 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[SpiKe^^]]></name></author>
		<updated>2022-05-22T10:39:15-04:00</updated>

		<published>2022-05-22T10:39:15-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=111145#p111145</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=111145#p111145"/>
		<title type="html"><![CDATA[whos.tcl ver 0.2]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=111145#p111145"><![CDATA[
Spartan,<br><br>This version tries to address both of your issues with how the script is handling bans and kicks.<br>=&gt; Check out the 2 new custom queue settings!<br><br>Please test and see if this is better.<br><div class="codebox"><p>Code: </p><pre><code>####  whos.tcl ver 0.2  by SpiKe^^  (21May2022)  ####namespace eval whos {   variable whos##### begin settings ###### Channel(s) where bot to check on joins OR set to {*} for all channels#     Example:  set whos(chans) {#channel1 #channel2}#  Note: or set empty to Add Channels using:  .chanset &lt;chan&gt; +whosset whos(chans) {*}# Exempt:  hostmask(s) to not check on join#   Note: set empty to disable any masks testingset whos(xmasks) {*!*@*.irccloud.com *!*@*.mibbit.com}# Exempt:  flag(s) to not check on join#   Note: set empty to disable any flags testingset whos(xflags) "bfmno|bfmno"### punishment settings #### Bans:  set channel ban(s) on the offenders??  (0 = no || 1 = yes)set whos(dobans) 0# Bans:  set the type of banmask to use  (0 - 39)#   Note: uses the eggdrop tcl command:  maskhost#         see the other 35 masktype options at:#   docs.eggheads.org/mainDocs/tcl-commands.html#maskhost-nick-user-host-masktype# 0 =  *!user@host# 1 =  *!*user@host# 2 =  *!*@host# 3 =  *!*user@*.host   (default)# 4 =  *!*@*.hostset whos(masktype) 2# Bans:  set ban time in minutes  (before this script will remove these bans)#   0 = this script doesn't remove these bansset whos(bantime) 5# Bans:  max number of bans to stack in one mode command (1 - 10) #set whos(maxban) 6# Kicks:  kick offenders from the channels??  (0 = no || 1 = yes)set whos(dokick) 0# Kicks:  set a custom reason to use when kicking offenders#   Note: set empty to not use a custom kick reasonset whos(reason) ""# Kicks:  max number of kicks to stack in one kick command (1 - 12) #set whos(maxkick) 3# Modes:  channel modes to set when an offender joins the channel??#   Note: set empty to not set any channel modesset whos(domode) "+RN"# Modes:  remove the above channel modes after how many minutes?#   0 = this script doesn't remove these modesset whos(modetime) 2###### end settings ######setudef flag [set whos(udflag) [string trim [namespace current] ":"]]variable kbqueset whos(chans) [split [string tolower [string trim $whos(chans)]]]set whos(xmasks) [split [string trim $whos(xmasks)]]set whos(xflags) [string trim $whos(xflags)]if {$whos(dobans) != 0} {  set whos(dobans) 1  }if {![string is digit -strict $whos(masktype)] || $whos(masktype) &gt; 39} {  set whos(masktype) 3}if {![string is digit -strict $whos(bantime)]} {  set whos(bantime) 5} elseif {$whos(bantime) &gt; 720} {  set whos(bantime) 720  }if {$whos(bantime) &gt; 0} {  set whos(bantime) [expr {$whos(bantime) * 60}]  }if {![string is digit -strict $whos(maxban)] || $whos(maxban)&lt;1} {  set whos(maxban) 6} elseif {$whos(maxban) &gt; 10} {  set whos(maxban) 10  }if {$whos(dokick) != 0} {  set whos(dokick) 1  }set whos(reason) [string trim $whos(reason)]if {![string is digit -strict $whos(maxkick)] || $whos(maxkick)&lt;1} {  set whos(maxkick) 3} elseif {$whos(maxkick) &gt; 12} {  set whos(maxkick) 12  }set whos(domode) [string trim $whos(domode)]if {$whos(domode) ne ""} {  if {![string match {[-+]?*} $whos(domode)]} { set whos(domode) +$whos(domode) }  if {$whos(modetime)&gt;0} { set whos(unmode) [string map {+ - - +} $whos(domode)] }}if {![string is digit -strict $whos(modetime)]} {  set whos(modetime) 2} elseif {$whos(modetime) &gt; 720} {  set whos(modetime) 720  }if {$whos(modetime) &gt; 0} { set whos(modetime) [expr {$whos(modetime) * 60}] }############bind join - * [namespace current]::onjoinproc onjoin {nk uh hn ch} {  if {[isbotnick $nk]} {  return 0  }  ;# this Bot is Exempt from this script #  variable whos  #putlog "proc onjoin : nk=($nk) uh=($uh) hn=($hn) ch=($ch)"  if {$hn ne "*" &amp;&amp; $whos(xflags) ne ""} {   ;# check if handle has any Exempt Flags #    if {[matchattr $hn $whos(xflags) $ch]} {  return 0  }  }  set c [string tolower $ch]  ;  set validch 0     ;# check if is in a Valid Channel #  if {[channel get $ch $whos(udflag)]} {  set validch 1  }  if {$whos(chans) eq "*" || $c in $whos(chans)} {  set validch 1  }  if {$validch == 0} {  return 0  }  foreach xmask $whos(xmasks) {               ;# check if matches an Exempt Hostmask #    if {[matchaddr $xmask ${nk}!$uh]} {  return 0  }  }  set n [string tolower $nk]  ;  set now [clock milliseconds]  set id "${c},$n"  set joininfo [dict create ms $now nik $nk uho $uh hnd $hn cha $ch]  if {![info exists whos(joinque)]} {    set whos(joinque) [dict create $id $joininfo]    #putlog "   sent1:  WHOIS $nk ..."                        ;# &lt;&lt;== #################    putserv "WHOIS $nk"  ;  return 0  }  ####  set jqlist [dict keys $whos(joinque) "*,$n"]  if {![llength $jqlist]} {    dict set whos(joinque) $id $joininfo    #putlog "   sent2:  WHOIS $nk ..."                        ;# &lt;&lt;== #################    putserv "WHOIS $nk"  ;  return 0  }  if {$id in $jqlist} {    ## Do something, maybe?   #channel,nick  :already in $whos(joinque) ##    return 0  }  dict set whos(joinque) $id $joininfo  ####  return 0}  ;# end: proc onjoin############bind raw - 311 [namespace current]::onraw   ;# "rname (realname)"bind raw - 671 [namespace current]::onraw   ;# "secure"bind raw - 320 [namespace current]::onraw   ;# "country &amp; webirc"bind raw - 318 [namespace current]::onraw   ;# "done"proc onraw {from num txt} {  #putlog "=&gt; proc onraw : from=($from) num=($num) txt=($txt)"  variable whos  ;  variable kbque  if {![info exists whos(joinque)]} {  return 0  }  set tx [join [lassign [split $txt] bot target]]  set tgt [string tolower $target]  set jqlist [dict keys $whos(joinque) "*,$tgt"]  if {![llength $jqlist]} {  return 0  }  set key [lindex $jqlist 0]  if {$num == 311} {     ;# "rname (realname)"      #######  # from=(irc.Epikuri.com) num=(311) txt=(X debian Username Epikuri-1EF13586.access.hol.gr * :netedy)    set rname [join [lassign [split $tx] user host astr]]    if {$astr eq "*" &amp;&amp; [string index $rname 0] eq ":"} {      set rname [string range $rname 1 end]      dict set whos(joinque) $key rname $rname      #putlog "   realname: $rname"                        ;# &lt;&lt;== #################    }    return 0  }  if {$num == 671} {               ;# "secure"      #######    # from=(irc.Epikuri.com) num=(671) txt=(X Debian :is using a Secure Connection)    if {[matchstr ":is using a Secure Connection*" $tx]} {      dict set whos(joinque) $key secure 1    }    return 0  }  if {$num == 320} {     ;# "country &amp; webirc"      #######    # from=(irc.Epikuri.com) num=(320) txt=(X RINI :connected from United States (US))    if {[regexp {^:connected from (.+)$} $tx - country]} {      dict set whos(joinque) $key country $country      #putlog "   country: $country"                        ;# &lt;&lt;== #################    }    # from=(irc.Epikuri.com) num=(320) txt=(X Alb5422 :is connecting via WEBIRC)    if {[matchstr ":is connecting via WEBIRC" $tx]} {      dict set whos(joinque) $key webirc 1    }    return 0  }  if {$num == 318} {                 ;# "done"      #######    # from=(irc.Epikuri.com) num=(318) txt=(X RINI :End of /WHOIS list.)    if {[matchstr ":End of /WHOIS list." $tx]} {      set isSecure 0  ;  set isWebirc 0  ;  set isOk 0      if {[dict exists $whos(joinque) $key secure]} {  set isSecure 1  }      if {[dict exists $whos(joinque) $key webirc]} {  set isWebirc 1  }      if {$isSecure==1 || $isWebirc==1} {  set isOk 1  }      foreach key $jqlist {   set ch [dict get $whos(joinque) $key cha]        lappend cls $ch      }      if {$isOk==1} {  ;# Is connected by secure and/or by webirc #        #if {$isSecure==1 &amp;&amp; $isWebirc==1} {        #putlog "   &gt; IS connected Both Secure And Webirc!  $target is allowed in: [join $cls]"        #} elseif {$isSecure==1} {        #putlog "   &gt; Is using a Secure Connection.  $target is allowed in: [join $cls]"        #} else { putlog "   &gt; Is connecting via WEBIRC.  $target is allowed in: [join $cls]" }      } else {    ;# Else is Not connected by secure or by webirc #        #putlog "   &gt; NOT connected Secure or by Webirc!  KickBan $target in: [join $cls]"        if {$whos(domode) ne ""} {     ;# Set channel modes      #######          foreach ch $cls {   putquick "MODE $ch $whos(domode)"            if {$whos(modetime)&gt;0} {              utimer $whos(modetime) [list putquick "MODE $ch $whos(unmode)"]            }          }        }########  if doing bans and/or kicks  ##        if {$whos(dobans)==1 || $whos(dokick)==1} {          if {$whos(dobans)==1} {  set uho [dict get $whos(joinque) $key uho]            set bmask [maskhost "${target}!$uho" $whos(masktype)]          } else {  set bmask "-"  }          foreach ch $cls {   set c [string tolower $ch]            if {![info exists kbque($c)]} {              after 750 [list "[namespace current]::dokban" $c]  ;# &lt;= que time            }            lappend kbque($c) "${tgt},$bmask"          }        }########      }    ;#  END:  Else is Not connected by secure or by webirc #      if {[llength $jqlist]&gt;=[dict size $whos(joinque)]} {  unset whos(joinque)      } else {  set whos(joinque) [dict remove $whos(joinque) {*}$jqlist]  }    }  }  ;# end if 318 #  return 0}  ;# end: proc onraw##################################proc dokban {c} {  variable whos  ;  variable kbque  if {![info exists kbque($c)]} {  return 0  }  foreach item $kbque($c) {  lassign [split $item ","] nk bmask    if {$whos(dobans)==1 &amp;&amp; $bmask ne "-"} {  lappend maskls $bmask  }    if {$whos(dokick)==1} {  lappend nickls $nk  }  }  if {[info exists maskls]} {               ;######    if {$whos(bantime)&gt;0} {      utimer $whos(bantime) [list "[namespace current]::undoban" $c $maskls]    }    saybans $c $maskls   }  if {[info exists nickls]} {               ;######    while {[set len [llength $nickls]] &gt; 0} {      if {$len &gt; $whos(maxkick)} {        set nicks [join [lrange $nickls 0 [expr {$whos(maxkick) - 1}]] ","]        set nickls [lrange $nickls $whos(maxkick) end]      } else {        set nicks [join $nickls ","]        set nickls ""      }      if {$whos(reason) eq ""} {  putserv "KICK $c $nicks"      } else {  putserv "KICK $c $nicks :$whos(reason)"  }    }  }  unset kbque($c)}  ;# end: proc dokban############proc undoban {c maskls} {   variable whos  if {![botisop $c]} {  return 0  }  foreach mask $maskls {    if {[ischanban $mask $c]} {  lappend nowls $mask  }  }  if {[info exists nowls]} {  saybans $c $nowls "-"  }}  ;# end: proc undoban############proc saybans {c maskls {sign +} } {   variable whos  while {[set len [llength $maskls]] &gt; 0} {    if {$len &gt; $whos(maxban)} {      set mode [string repeat "b" $whos(maxban)]      set masks [join [lrange $maskls 0 [expr {$whos(maxban) - 1}]]]      set maskls [lrange $maskls $whos(maxban) end]    } else {      set mode [string repeat "b" $len]      set masks [join $maskls]      set maskls ""    }    putquick "MODE $c ${sign}$mode $masks"  }}  ;# end: proc saybans############}  ;## end of:  namespace eval whos ##putlog "whos.tcl ver 0.2 Loaded."</code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=7749">SpiKe^^</a> — Sun May 22, 2022 10:39 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Spartan]]></name></author>
		<updated>2022-05-17T12:25:33-04:00</updated>

		<published>2022-05-17T12:25:33-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=111111#p111111</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=111111#p111111"/>
		<title type="html"><![CDATA[Hi]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=111111#p111111"><![CDATA[
Spike^^  script is work great no errors but have 1 thing is kick before set ban and when is join 3 users is not set 3 ban in 1 line <br><br><br>ty again great code<br><br>1 user on join matched <br><div class="codebox"><p>Code: </p><pre><code>[19:06:14] * Joins: PAPPU (houezy@94DD7E6E.8E52E284.A6A01F07.IP[19:06:14] * X sets mode: +NR [19:06:15] * PAPPU was kicked from #test by X (Sorry, Try to connect via WEBIRC)[19:06:15] * X sets mode: +b *!*@94DD7E6E.8E52E284.A6A01F07.IP</code></pre></div>need to be in this order way  i think<br><div class="codebox"><p>Code: </p><pre><code>[19:06:14] * Joins: PAPPU (houezy@94DD7E6E.8E52E284.A6A01F07.IP[19:06:14] * X sets mode: +NR [19:06:15] * X sets mode: +b *!*@94DD7E6E.8E52E284.A6A01F07.IP[19:06:15] * PAPPU was kicked from #test by X (Sorry, Try to connect via WEBIRC)</code></pre></div><br>3 user on join matched <br><div class="codebox"><p>Code: </p><pre><code>[19:09:44] * Joins: PRISHU (ecifkg@526E5BBD.43F5E76B.D86B19F6.IP) [19:09:44] * Joins: CHIKOO (yarqkj@D90CA7AB.14C531F4.C64C234B.IP) [19:09:44] * Joins: GUDIYA (aasdqu@8BF03232.C88719AD.322F620B.IP)  [19:09:45] * PRISHU was kicked from #test by X (Sorry, Try to connect via WEBIRC)[19:09:45] * X sets mode: +b *!*@526E5BBD.43F5E76B.D86B19F6.IP[19:09:45] * CHIKOO was kicked from #test by X (Sorry, Try to connect via WEBIRC)[19:09:45] * X sets mode: +b *!*@D90CA7AB.14C531F4.C64C234B.IP[19:09:45] * GUDIYA was kicked from #test by X (Sorry, Try to connect via WEBIRC)[19:09:45] * X sets mode: +b *!*@8BF03232.C88719AD.322F620B.IP</code></pre></div>also here need to be in this order way<br><div class="codebox"><p>Code: </p><pre><code>[19:09:44] * Joins: PRISHU (ecifkg@526E5BBD.43F5E76B.D86B19F6.IP) [19:09:44] * Joins: CHIKOO (yarqkj@D90CA7AB.14C531F4.C64C234B.IP) [19:09:44] * Joins: GUDIYA (aasdqu@8BF03232.C88719AD.322F620B.IP)[19:09:45] * X sets mode: +bbb *!*@8BF03232.C88719AD.322F620B.IP *!*@D90CA7AB.14C531F4.C64C234B.IP *!*@526E5BBD.43F5E76B.D86B19F6.IP[19:09:45] * PRISHU was kicked from #test by X (Sorry, Try to connect via WEBIRC)[19:09:45] * CHIKOO was kicked from #test by X (Sorry, Try to connect via WEBIRC)[19:09:45] * GUDIYA was kicked from #test by X (Sorry, Try to connect via WEBIRC)</code></pre></div>Is possible to make the ban first after the kick and also when is match more from 1 nick on join to set all bans in 1 line ?<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=12970">Spartan</a> — Tue May 17, 2022 12:25 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[SpiKe^^]]></name></author>
		<updated>2022-05-17T10:48:53-04:00</updated>

		<published>2022-05-17T10:48:53-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=111110#p111110</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=111110#p111110"/>
		<title type="html"><![CDATA[whos.tcl ver 0.1]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=111110#p111110"><![CDATA[
Spartan,<br><br>This is the way I see that script request...<br><br>Script checks everyone joining the channel, see if they should be allowed to stay.<br><br>A trusted nick must meet at least one of these tests:<br><br>1) handle has any exempt flags<br>2) user matches an exempt hostmasks<br><br>   - if still not a trusted nick,  /whois nick...<br>3) is using a secure connection<br>4) is connecting via webirc<br><br><br>All other nicks are now judged as not trusted and could be ban/kicked?<br><br><br>Here's a script along those lines...<div class="codebox"><p>Code: </p><pre><code>#### whos.tcl ver 0.1 (17May2022) ####namespace eval whos {   variable whos##### begin settings ###### Channel(s) where bot to check on joins OR set to {*} for all channelsset whos(chans) {*}# Exempt:  hostmask(s) to not check on joinset whos(xmasks) {*!*@*.irccloud.com *!*@*.mibbit.com}# Exempt:  flag(s) to not check on joinset whos(xflags) "bfmno|bfmno"# Bans:  set channel ban(s) on the offenders??  (0 = no || 1 = yes)set whos(dobans) 0# Bans:  set the type of banmask to use# 0 =  *!user@host# 1 =  *!*user@host# 2 =  *!*@host# 3 =  *!*user@*.host# 4 =  *!*@*.hostset whos(masktype) 2# Bans:  set ban time in minutes#   0 = this script doesn't remove these bansset whos(bantime) 5# Kicks:  kick offenders from the channels??  (0 = no || 1 = yes)set whos(dokick) 0# Kicks:  set a custom reason to use when kicking offendersset whos(reason) ""# Modes:  channel modes to set when an offender joins the channel??set whos(domode) "+RN"# Modes:  remove the above channel modes after how many minutes?#   0 = this script doesn't remove these modesset whos(modetime) 2###### end settings ######setudef flag [set whos(udflag) [string trim [namespace current] ":"]]set whos(chans) [split [string tolower [string trim $whos(chans)]]]set whos(xmasks) [split [string trim $whos(xmasks)]]set whos(xflags) [string trim $whos(xflags)]if {$whos(bantime) &gt; 0} {  set whos(bantime) [expr {$whos(bantime) * 60}]  }set whos(reason) [string trim $whos(reason)]set whos(domode) [string trim $whos(domode)]if {$whos(domode) ne ""} {  if {![string match {[-+]?*} $whos(domode)]} { set whos(domode) +$whos(domode) }  if {$whos(modetime)&gt;0} { set whos(unmode) [string map {+ - - +} $whos(domode)] }}if {$whos(modetime) &gt; 0} { set whos(modetime) [expr {$whos(modetime) * 60}] }############bind join - * [namespace current]::onjoinproc onjoin {nk uh hn ch} {  if {[isbotnick $nk]} {  return 0  }  ;# this Bot is Exempt from this script #  variable whos  putlog "proc onjoin : nk=($nk) uh=($uh) hn=($hn) ch=($ch)"  if {$hn ne "*" &amp;&amp; $whos(xflags) ne ""} {   ;# check if handle has any Exempt Flags #    if {[matchattr $hn $whos(xflags) $ch]} {  return 0  }  }  set c [string tolower $ch]  ;  set validch 0     ;# check if is in a Valid Channel #  if {[channel get $ch $whos(udflag)]} {  set validch 1  }  if {$whos(chans) eq "*" || $c in $whos(chans)} {  set validch 1  }  if {$validch == 0} {  return 0  }  foreach xmask $whos(xmasks) {               ;# check if matches an Exempt Hostmask #    if {[matchaddr $xmask ${nk}!$uh]} {  return 0  }  }  set n [string tolower $nk]  ;  set now [clock milliseconds]  set id "${c},$n"  set joininfo [dict create ms $now nik $nk uho $uh hnd $hn cha $ch]  if {![info exists whos(joinque)]} {    set whos(joinque) [dict create $id $joininfo]    putlog "   sent1:  WHOIS $nk ..."                        ;# &lt;&lt;== #################    putserv "WHOIS $nk"  ;  return 0  }  ####  set jqlist [dict keys $whos(joinque) "*,$n"]  if {![llength $jqlist]} {    dict set whos(joinque) $id $joininfo    putlog "   sent2:  WHOIS $nk ..."                        ;# &lt;&lt;== #################    putserv "WHOIS $nk"  ;  return 0  }  if {$id in $jqlist} {    ## Do something, maybe?   #channel,nick  :already in $whos(joinque) ##    return 0  }  dict set whos(joinque) $id $joininfo  ####  return 0}  ;# end: proc onjoin############bind raw - 311 [namespace current]::onraw   ;# "rname (realname)"bind raw - 671 [namespace current]::onraw   ;# "secure"bind raw - 320 [namespace current]::onraw   ;# "country &amp; webirc"bind raw - 318 [namespace current]::onraw   ;# "done"proc onraw {from num txt} {  putlog "=&gt; proc onraw : from=($from) num=($num) txt=($txt)"  variable whos  if {![info exists whos(joinque)]} {  return 0  }  set tx [join [lassign [split $txt] bot target]]  set tgt [string tolower $target]  set jqlist [dict keys $whos(joinque) "*,$tgt"]  if {![llength $jqlist]} {  return 0  }  set key [lindex $jqlist 0]  if {$num == 311} {     ;# "rname (realname)"      #######    set rname [join [lassign [split $tx] user host astr]]    if {$astr eq "*" &amp;&amp; [string index $rname 0] eq ":"} {      set rname [string range $rname 1 end]      dict set whos(joinque) $key rname $rname      #putlog "   realname: $rname"                        ;# &lt;&lt;== #################    }    return 0  }  if {$num == 671} {               ;# "secure"      #######    if {[matchstr ":is using a Secure Connection*" $tx]} {      dict set whos(joinque) $key secure 1    }    return 0  }  if {$num == 320} {     ;# "country &amp; webirc"      #######    if {[regexp {^:connected from (.+)$} $tx - country]} {      dict set whos(joinque) $key country $country      #putlog "   country: $country"                        ;# &lt;&lt;== #################    }    if {[matchstr ":is connecting via WEBIRC" $tx]} {      dict set whos(joinque) $key webirc 1    }    return 0  }  if {$num == 318} {                 ;# "done"      #######    if {[matchstr ":End of /WHOIS list." $tx]} {      set isSecure 0  ;  set isWebirc 0  ;  set isOk 0      if {[dict exists $whos(joinque) $key secure]} {  set isSecure 1  }      if {[dict exists $whos(joinque) $key webirc]} {  set isWebirc 1  }      if {$isSecure==1 || $isWebirc==1} {  set isOk 1  }      foreach key $jqlist {   set ch [dict get $whos(joinque) $key cha]        lappend cls $ch      }      if {$isOk==1} {  ;# Is connected by secure and/or by webirc #        if {$isSecure==1 &amp;&amp; $isWebirc==1} {        putlog "   &gt; IS connected Both Secure And Webirc!  $target is allowed in: [join $cls]"        } elseif {$isSecure==1} {        putlog "   &gt; Is using a Secure Connection.  $target is allowed in: [join $cls]"        } else { putlog "   &gt; Is connecting via WEBIRC.  $target is allowed in: [join $cls]" }      } else {    ;# Else is Not connected by secure or by webirc #        putlog "   &gt; NOT connected Secure or by Webirc!  KickBan $target in: [join $cls]"        if {$whos(domode) ne ""} {     ;# Set channel modes      #######          foreach ch $cls {   putquick "MODE $ch $whos(domode)"            if {$whos(modetime)&gt;0} {              utimer $whos(modetime) [list putquick "MODE $ch $whos(unmode)"]            }          }        }                                        ;# Set channel bans      #######        if {$whos(dobans)==1} {   set uho [dict get $whos(joinque) $key uho]          set bmask [maskhost "${target}!$uho" $whos(masktype)]          foreach ch $cls {   pushmode $ch +b $bmask            if {$whos(bantime)&gt;0} {              utimer $whos(bantime) [list pushmode $ch -b $bmask]            }          }        }        if {$whos(dokick)==1} {   ;# Kick nicks from channel     #######          foreach ch $cls {            if {$whos(reason) eq ""} {  putkick $ch $target            } else {  putkick $ch $target $whos(reason)  }          }        }      }    ;#  END:  Else is Not connected by secure or by webirc #      if {[llength $jqlist]&gt;=[dict size $whos(joinque)]} {  unset whos(joinque)      } else {  set whos(joinque) [dict remove $whos(joinque) {*}$jqlist]  }    }  }  ;# end if 318 #  return 0}  ;# end: proc onraw}  ;## end of:  namespace eval whos ##putlog "whos.tcl ver 0.1 Loaded."</code></pre></div><br>Check it out and let me know<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=7749">SpiKe^^</a> — Tue May 17, 2022 10:48 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[simo]]></name></author>
		<updated>2022-05-16T13:00:07-04:00</updated>

		<published>2022-05-16T13:00:07-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=111109#p111109</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=111109#p111109"/>
		<title type="html"><![CDATA[script checker for webuser and ssl on join]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=111109#p111109"><![CDATA[
depending on network you could use channel modes for that for example<br>InspIRCd-3 and UnrealIRCd-6 have channel modes for that if certain modules are loaded<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=12505">simo</a> — Mon May 16, 2022 1:00 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Spartan]]></name></author>
		<updated>2022-05-16T09:38:59-04:00</updated>

		<published>2022-05-16T09:38:59-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=111108#p111108</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=111108#p111108"/>
		<title type="html"><![CDATA[script checker for webuser and ssl on join]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=111108#p111108"><![CDATA[
If is possible 1 script to match on join user who are not connected with SSL and via WEBIRC to set channel mode +RN {timemode} 5m and kickban all users on join also exempt host or ip of irccloude  (*.irccloud.com} with swois raw 671 for SSL, and raw 320 for via WEBIRC, raw 311 nick!iden@host:realname , and raw 318 for End of /WHOIS list<br>also channel target and option for kick and ban  0/1 to make only ban or only kick after channel mode is set +RN<br><br>If the user dont have 1 of this info {*Secure or *WEBIRC*} to set mode channel +RN and ban &amp; kick reason: Sorry , Try To Connect from Website<br><br>ty in advance<br><br><br>example :<br><div class="codebox"><p>Code: </p><pre><code>User swhois is connecting via WEBIRCUser is using a Secure Connection (SSL)</code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=12970">Spartan</a> — Mon May 16, 2022 9:38 am</p><hr />
]]></content>
	</entry>
	</feed>
