<?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/21645" />

	<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>2024-10-20T14:35:39-04:00</updated>

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

		<entry>
		<author><name><![CDATA[simo]]></name></author>
		<updated>2024-10-20T14:35:39-04:00</updated>

		<published>2024-10-20T14:35:39-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=113084#p113084</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=113084#p113084"/>
		<title type="html"><![CDATA[Re: Add user flag if nick gets opped via ChanServ]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=113084#p113084"><![CDATA[
ive tested with this but it seems to randomly trigger on random channel mode setting :<br><div class="codebox"><p>Code: </p><pre><code>#bind MODE - * Access:Cmodes_Checkproc Access:Cmodes_Check {nick uhost hand chan mode target} {          set hnick [nick2hand $target]            if {[isbotnick $target] || ![string match -nocase {ChanServ} "$nick"] || [matchattr $hnick +n] || [matchattr $hnick +m]} { putlog "«owner/master ignored»" ; return 0 }             switch $mode {                "+o" { after [expr {2*1000*1}] [list Delayed-Access:Cmodes_Check $nick $uhost $hand $chan $mode $target] }                "+h" { after [expr {2*1000*1}] [list Delayed-Access:Cmodes_Check $nick $uhost $hand $chan $mode $target]  }  }                  }proc Delayed-Access:Cmodes_Check {nick uhost hand chan mode target} {        set hnick [nick2hand $target]        if {[isbotnick $target] || ![string match -nocase {ChanServ} "$nick"] || [matchattr $hnick +n] || [matchattr $hnick +m]} { return 0 }         if {![isop $target] &amp;&amp; ![ishalfop $target]} { return 0 }          set uhostarget "[getchanhost $target]"         set site "[lindex [split $uhostarget "@"] 1]"     if {[string match -nocase "*.irccloud.com" $site]} {                     set ident [string trimleft [lindex [split $uhostarget @] 0] "~"]                   set xbmaskx [string map {sid id uid id} $ident]                   set addmask  *!*$xbmaskx@*.irccloud.com                  }  else {                    set addmask  "*!*@$site"                  }                        switch $mode {                "+o" { if {![validuser $target]} { adduser $target ; chattr $target -|+o $chan ; setuser $target HOSTS $addmask } }                "+h" { if {![validuser $target]} { adduser $target ; chattr $target -|+o $chan ; setuser $target HOSTS $addmask }  }  }}                bind part - * Part-Check-Access:Removeproc Part-Check-Access:Remove {nick uhost hand chan text} {   if {[isbotnick $nick] || [matchattr $hand +n] || [matchattr $hand +m]} { return 0 }   if {[validuser $hand] &amp;&amp; [matchattr $hand -|o $chan]} { deluser $hand }}bind sign - * Quit-Check-Access:Removeproc Quit-Check-Access:Remove {nick uhost hand chan reason} {      if {[isbotnick $nick] || [matchattr $hand +n] || [matchattr $hand +m]} { return 0 }      if {[validuser $hand] &amp;&amp; [matchattr $hand -|o $chan]} { deluser $hand }}</code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=12505">simo</a> — Sun Oct 20, 2024 2:35 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[simo]]></name></author>
		<updated>2024-10-20T11:22:31-04:00</updated>

		<published>2024-10-20T11:22:31-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=113083#p113083</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=113083#p113083"/>
		<title type="html"><![CDATA[Re: Add user flag if nick gets opped via ChanServ]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=113083#p113083"><![CDATA[
Thanks for your reply  CrazyCat but since we use this on dalnet wich afaik doesnt use account based checks (IRCV3)<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=12505">simo</a> — Sun Oct 20, 2024 11:22 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[CrazyCat]]></name></author>
		<updated>2024-10-20T11:06:36-04:00</updated>

		<published>2024-10-20T11:06:36-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=113082#p113082</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=113082#p113082"/>
		<title type="html"><![CDATA[Re: Add user flag if nick gets opped via ChanServ]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=113082#p113082"><![CDATA[
Do you know that you can now use things based on account ?<br><a href="https://docs.eggheads.org/using/accounts.html" class="postlink">https://docs.eggheads.org/using/accounts.html</a><br><a href="https://docs.eggheads.org/using/tcl-commands.html#getaccount-nickname-channel" class="postlink">https://docs.eggheads.org/using/tcl-com ... me-channel</a> and also bind account:<div class="codebox"><p>Code: </p><pre><code>bind account &lt;flags&gt; &lt;mask&gt; &lt;proc&gt;    procname &lt;nick&gt; &lt;user&gt; &lt;hand&gt; &lt;chan&gt; &lt;account&gt;    Description: this bind will trigger when eggdrop detects a change in the authentication status of a user’s service account. The mask for the bind is in the format “#channel nick!user@hostname.com account” and accepts wildcards. account is either the account name the user is logging in to or “*” if the user is not logged in to an account.    NOTE: the three required IRC components for account tracking are: the WHOX feature, the extended-join IRCv3 capability and the account-notify IRCv3 capability. if only some of the three feature are available, eggdrop provides best-effort account tracking but this bind could be triggered late or never on account changes. Please see doc/ACCOUNTS for additional information.</code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=691">CrazyCat</a> — Sun Oct 20, 2024 11:06 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[simo]]></name></author>
		<updated>2024-10-20T09:51:34-04:00</updated>

		<published>2024-10-20T09:51:34-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=113081#p113081</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=113081#p113081"/>
		<title type="html"><![CDATA[Add user flag if nick gets opped via ChanServ]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=113081#p113081"><![CDATA[
greetings folks,<br><br>Some of our chanops and admins on danet dont have a fixed IP/HOST to grant them user flag based on their IP/HOST<br>so i thought of a concept of adding their user with chattr -|+o $chan the moment they are opped via ChanServ  or chattr -|+v if they are halfopped via Chanserv that way we confirm their adminship in channel regardless of their IP/HOST, and the moment they part channel or quit IRC to del their user , oh and i forgot to mention in the case of a random chanadmin opping a random user and chanserv deops them instant as they arent in admin access list of the channel to make sure the user isnt added.<br><br> <br><br>This is what i have so far and im not sure where to go from here : <br> <br><div class="codebox"><p>Code: </p><pre><code>bind MODE - * Access:Cmodes_Checkproc Access:Cmodes_Check {nick uhost hand chan mode target} {          set hnick [nick2hand $target]        if {[isbotnick $target] || ![string match -nocase {ChanServ} "$nick"] || [matchattr $hnick +n] || [matchattr $hnick +m]} { return 0 }     set uhostarget "[getchanhost $target]"     set site "[lindex [split $uhostarget "@"] 1]"     if {[string match -nocase "*.irccloud.com" $site]} {                     set ident [string trimleft [lindex [split $uhostarget @] 0] "~"]                   set xbmaskx [string map {sid id uid id} $ident]                   set addmask  *!*$xbmaskx@*                  }  else {                    set addmask  "*!*@$site"                  }                        switch $mode {                "+o" { if {![validuser $hand]} { adduser $who ; chattr $target |+o $chan } }                "+h" { if {![validuser $hand]} { adduser $who ; chattr $target |+v $chan }  }} bind part - * Part-Check-Access:Removeproc Part-Check-Access:Remove {nick uhost hand chan text} {   if {[isbotnick $target] || [matchattr $hand +n] || [matchattr $hand +m]} { return 0 }   if {[validuser $hand] &amp;&amp; [matchattr $hand -|o $chan] || [matchattr $hand -|v $chan]} { deluser $hand }}bind sign - * Quit-Check-Access:Removeproc Quit-Check-Access:Remove {nick uhost hand chan reason} {      if {[isbotnick $target] || [matchattr $hand +n] || [matchattr $hand +m]} { return 0 }      if {[validuser $hand] &amp;&amp; [matchattr $hand -|o $chan] || [matchattr $hand -|v $chan]} { deluser $hand }}</code></pre></div><br>Thanks in advance.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=12505">simo</a> — Sun Oct 20, 2024 9:51 am</p><hr />
]]></content>
	</entry>
	</feed>
