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

	<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>2011-10-23T07:23:41-04:00</updated>

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

		<entry>
		<author><name><![CDATA[doggo]]></name></author>
		<updated>2011-10-23T07:23:41-04:00</updated>

		<published>2011-10-23T07:23:41-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=98001#p98001</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=98001#p98001"/>
		<title type="html"><![CDATA[Connecting vBulletin Users Database Table with IRC]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=98001#p98001"><![CDATA[
this should do the trick, bit late with the response but... <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_biggrin.gif" width="15" height="15" alt=":D" title="Very Happy"><br><br><div class="codebox"><p>Code: </p><pre><code>package require mysqltcl 3.05package require md5 namespace eval reqs { namespace eval sett { #START SETTINGS    variable req_chan "#YOUR_CHAN" #DB CONNECTION variable db_host "DB_HOST" variable db_port "3306" variable db_username "DB_USER" variable db_password "DB_PASSWORD" variable db_name "DB_NAME" #CHANNEL USER TABLE variable db_table "TABLE_NAME" variable db_user "USERNAME_FIELD" variable db_pass "PW_FIELD" variable db_salt "SALT_FIELD" #BINDS bind MSGM -|- "*" reqs::user_add_voice::voice_add_user #END SETTINGS NAMESPACE } # SCRIPT STARTS namespace eval user_add_voice {  proc voice_add_user {nick uhost handle text} { set check_nick [lindex $text 0] set get_pass [lindex $text 1] set salt [lindex $text 1]# from what you said above# $password_hash = md5(md5($password_text) . $user_salt);# but without acces to a forum db i cannot test and have no idea on how the pws are stored/encrypted...set check_pass [md5 [md5 $salt][md5[$getpass]]set find_it [::mysql::connect -host $reqs::sett::db_host -port $reqs::sett::db_port -user $reqs::sett::db_username -password $reqs::sett::db_password -db $reqs::sett::db_name]; set it_find [::mysql::sel $find_it "SELECT $reqs::sett::db_user,$reqs::sett::db_pass FROM $reqs::sett::db_table WHERE $reqs::sett::db_user = '$check_nick' AND $reqs::sett::db_pass = '$check_pass'" AND $reqs::sett::db_salt = '$check_pass'"-flatlist]; ::mysql::endquery $find_it ::mysql::close $find_it if {$it_find == ""} {putquick "NOTICE $nick :invalid login";return} else { set valid_nick [lindex $it_find 0] set valid_pass [lindex $it_find 1] if {![isvoice $nick $reqs::sett::req_chan] &amp;&amp; $check_nick == "$valid_nick" &amp;&amp; $check_pass == "$valid_pass"} {   putquick "MODE $reqs::sett::req_chan +v $nick"    putquick "NOTICE $nick :thanks for logging in.."     } else {            return          }       }    } }      #END NAMESPACE }</code></pre></div><br>untested  <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_smile.gif" width="15" height="15" alt=":)" title="Smile"><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=11046">doggo</a> — Sun Oct 23, 2011 7:23 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Murtific]]></name></author>
		<updated>2011-07-06T17:54:55-04:00</updated>

		<published>2011-07-06T17:54:55-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=97164#p97164</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=97164#p97164"/>
		<title type="html"><![CDATA[Connecting vBulletin Users Database Table with IRC]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=97164#p97164"><![CDATA[
I'm very interested in this, However I would like it if the bot had o:line access to be able to kick people off the server within 10 seconds if they did not /msg bot username pass.<br><br>I saw this in another forum and thought it might be helpful for this thread.<br><a href="https://www.vbulletin.com/forum/showthread.php/363985-vBulletin-password-salt-issue?highlight=connecting" class="postlink">https://www.vbulletin.com/forum/showthr ... connecting</a><br><br>If it is at all possible for somebody to code this, this would be awesome.<br><br>I also want the bot to invite users to multiple channels on authorization and I want it to have commands so that I can add people to @ list +list and regular. <br><br>Also depending upon what access they have (@+) I'd like them to be invited to those channels as well.<br><br>WOULD LOVE TO SEE THIS!!!!!!!!!! I dont know anything about this type of coding or how to put it into my IRCD, but I'm willing to learn and if somebody is able to create this, would be nice for a step by step tutorial. &lt;3 in advance.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=11720">Murtific</a> — Wed Jul 06, 2011 5:54 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[danswano]]></name></author>
		<updated>2011-04-25T16:42:22-04:00</updated>

		<published>2011-04-25T16:42:22-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=96761#p96761</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=96761#p96761"/>
		<title type="html"><![CDATA[Connecting vBulletin Users Database Table with IRC]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=96761#p96761"><![CDATA[
Hello dude, i saw a field called "salt" in my vb_user table contain random characters that adds the extra encryption, can you write something so the tcl can read both the password and the salt fields together as vbulletin read them?<br><br>someone assured for me that vbulletin use this method of hashing:<div class="codebox"><p>Code: </p><pre><code>$password_hash = md5(md5($password_text) . $user_salt);</code></pre></div>please help me <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_smile.gif" width="15" height="15" alt=":)" title="Smile"><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=11635">danswano</a> — Mon Apr 25, 2011 4:42 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[danswano]]></name></author>
		<updated>2011-04-25T11:48:22-04:00</updated>

		<published>2011-04-25T11:48:22-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=96758#p96758</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=96758#p96758"/>
		<title type="html"><![CDATA[Connecting vBulletin Users Database Table with IRC]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=96758#p96758"><![CDATA[
i saw some were trying to get the password for external use but he has a problem because he is using arabic, but can you take a look at his code if it might be useful? <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_smile.gif" width="15" height="15" alt=":)" title="Smile"><br><br><a href="http://www.vbulletin.com/forum/showthread.php/351399-what-the-vBulletindo-to-the-password-%28integration%29?highlight=password+hash" class="postlink">http://www.vbulletin.com/forum/showthre ... sword+hash</a><br><br>i also found those cases for md5+salt<br><div class="codebox"><p>Code: </p><pre><code>– md5($pass.$salt) – md5($salt.$pass)– md5($salt.md5($pass))– md5($salt.$pass.$salt)– md5($salt.'–'.md5($pass))– md5(md5($salt).$pass)– md5(md5($salt).md5($pass))– md5(md5($pass).$salt)– md5(md5($pass).md5($salt))– md5(md5($username.$pass).$salt)– md5($salt.$pass.$username)– md5($salt.md5($salt.$pass))– md5($salt.md5($pass.$salt))– md5($salt.md5($pass).$salt)– md5($username.md5($pass).$salt) </code></pre></div>can i use them as they are in replacement of?<br>set check_pass [<strong class="text-strong">md5</strong> $get_pass]<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=11635">danswano</a> — Mon Apr 25, 2011 11:48 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[danswano]]></name></author>
		<updated>2011-04-25T10:10:01-04:00</updated>

		<published>2011-04-25T10:10:01-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=96755#p96755</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=96755#p96755"/>
		<title type="html"><![CDATA[Connecting vBulletin Users Database Table with IRC]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=96755#p96755"><![CDATA[
This worked buddy but if anyone knows the user's email will login as him, any idea how to use md5 with salt in your script? <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_smile.gif" width="15" height="15" alt=":)" title="Smile"><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=11635">danswano</a> — Mon Apr 25, 2011 10:10 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[doggo]]></name></author>
		<updated>2011-04-25T10:02:14-04:00</updated>

		<published>2011-04-25T10:02:14-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=96754#p96754</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=96754#p96754"/>
		<title type="html"><![CDATA[Connecting vBulletin Users Database Table with IRC]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=96754#p96754"><![CDATA[
<a href="http://www.vbulletin.com/forum/showthread.php/311252-Encryption-method-of-password?s=254eaaacb5f983ca2d4d841fca9f8658" class="postlink">http://www.vbulletin.com/forum/showthre ... 1fca9f8658</a><br><br>sounds tricky.. maybe auth users who provide usename and email just to test.. it does what you want..<br><br><div class="codebox"><p>Code: </p><pre><code>package require mysqltcl 3.05 namespace eval reqs { namespace eval sett { #START SETTINGS    variable req_chan "#YOUR_CHAN" #DB CONNECTION variable db_host "DB_HOST" variable db_port "3306" variable db_username "DB_USER" variable db_password "DB_PASSWORD" variable db_name "DB_NAME" #CHANNEL USER TABLE variable db_table "TABLE_NAME" variable db_user "USERNAME_FIELD" variable db_email "EMAIL_FIELD" #BINDS bind MSGM -|- "*" reqs::user_add_voice::voice_add_user #END SETTINGS NAMESPACE } # SCRIPT STARTS namespace eval user_add_voice {  proc voice_add_user {nick uhost handle text} { set check_nick [lindex $text 0] set check_email [lindex $text 1] set find_it [::mysql::connect -host $reqs::sett::db_host -port $reqs::sett::db_port -user $reqs::sett::db_username -password $reqs::sett::db_password -db $reqs::sett::db_name]; set it_find [::mysql::sel $find_it "SELECT $reqs::sett::db_user,$reqs::sett::db_email FROM $reqs::sett::db_table WHERE $reqs::sett::db_user = '$check_nick' AND $reqs::sett::db_email = '$check_email'" -flatlist]; ::mysql::endquery $find_it ::mysql::close $find_it if {$it_find == ""} {putquick "NOTICE $nick :invalid login";return} else { set valid_nick [lindex $it_find 0] set valid_email [lindex $it_find 1] if {![isvoice $nick $reqs::sett::req_chan] &amp;&amp; $check_nick == "$valid_nick" &amp;&amp; $check_email == "$valid_email"} {    putquick "MODE $reqs::sett::req_chan +v $nick"    putquick "NOTICE $nick :thanks for logging in.."     } else {            return          }       }    } }      #END NAMESPACE }</code></pre></div><br>maybe someone else knows how to send the password?<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=11046">doggo</a> — Mon Apr 25, 2011 10:02 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[danswano]]></name></author>
		<updated>2011-04-25T09:43:07-04:00</updated>

		<published>2011-04-25T09:43:07-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=96753#p96753</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=96753#p96753"/>
		<title type="html"><![CDATA[Connecting vBulletin Users Database Table with IRC]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=96753#p96753"><![CDATA[
i found something useful here<br><br><a href="http://www.vbulletin.com/forum/showthread.php/377595-What-cryptographic-hash-function-is-VBulletin-using-for-user-passwords-protection" class="postlink">http://www.vbulletin.com/forum/showthre ... protection</a><br><blockquote class="uncited"><div>We use a double md5 hash with a salt. Without the salt its moderately hard to get a value that works for the password.<br><br>something like md5(md5(password)salt)</div></blockquote><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=11635">danswano</a> — Mon Apr 25, 2011 9:43 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[danswano]]></name></author>
		<updated>2011-04-25T09:34:35-04:00</updated>

		<published>2011-04-25T09:34:35-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=96752#p96752</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=96752#p96752"/>
		<title type="html"><![CDATA[Connecting vBulletin Users Database Table with IRC]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=96752#p96752"><![CDATA[
Maybe they changed, it's vbulletin version 4, do you know what they are using? can i help you with something so you can know?<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=11635">danswano</a> — Mon Apr 25, 2011 9:34 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[doggo]]></name></author>
		<updated>2011-04-25T09:33:20-04:00</updated>

		<published>2011-04-25T09:33:20-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=96751#p96751</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=96751#p96751"/>
		<title type="html"><![CDATA[Connecting vBulletin Users Database Table with IRC]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=96751#p96751"><![CDATA[
how are the paswords stored in your database are you sure its md5?<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=11046">doggo</a> — Mon Apr 25, 2011 9:33 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[danswano]]></name></author>
		<updated>2011-04-25T09:25:51-04:00</updated>

		<published>2011-04-25T09:25:51-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=96750#p96750</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=96750#p96750"/>
		<title type="html"><![CDATA[Connecting vBulletin Users Database Table with IRC]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=96750#p96750"><![CDATA[
Thanks, it loaded now but i'm getting invalid login<br><br>any idea why?<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=11635">danswano</a> — Mon Apr 25, 2011 9:25 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[doggo]]></name></author>
		<updated>2011-04-25T09:19:23-04:00</updated>

		<published>2011-04-25T09:19:23-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=96749#p96749</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=96749#p96749"/>
		<title type="html"><![CDATA[Connecting vBulletin Users Database Table with IRC]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=96749#p96749"><![CDATA[
i have tested again and updated the code in the previous post <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_biggrin.gif" width="15" height="15" alt=":D" title="Very Happy"><br><br>i wrote it late last night, so there were bound to be some errors:P <br><br>quick test<br><div class="codebox"><p>Code: </p><pre><code>[02:16pm] * doggo sets mode: +h NZB-Bot`[02:17pm] -&gt; *NZB-Bot`* doggo PiKEYs   &lt; wrong pass!&gt;[02:17pm] -NZB-Bot`- invalid login[02:17pm] -&gt; *NZB-Bot`* doggo PiKEY   &lt;correct pass&gt;[02:17pm] * NZB-Bot` sets mode: +v doggo[02:17pm] -NZB-Bot`- thanks for logging in..</code></pre></div>loads and runs ok<br><div class="codebox"><p>Code: </p><pre><code>[14:22] Rehashing ...[14:22] main_conf.conf loaded without errors[14:22] egghttp.tcl API v1.1.0 by strikelight now loaded.[14:22] egghttp.tcl loaded without errors[14:22] alltools.tcl loaded without errors[14:22] action.fix.tcl loaded without errors[14:22] vb_script.tcl loaded without errors[14:22] Listening at telnet port ******** (all).[14:22] Userfile loaded, unpacking...</code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=11046">doggo</a> — Mon Apr 25, 2011 9:19 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[danswano]]></name></author>
		<updated>2011-04-25T08:39:14-04:00</updated>

		<published>2011-04-25T08:39:14-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=96748#p96748</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=96748#p96748"/>
		<title type="html"><![CDATA[Connecting vBulletin Users Database Table with IRC]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=96748#p96748"><![CDATA[
<blockquote class="uncited"><div>Error while loading vb-script.tcl: missing close-brace</div></blockquote>when i loaded the scripts in the eggdrop,conf like this:<div class="codebox"><p>Code: </p><pre><code>source scripts/vb-script.tcl</code></pre></div>i got this error<blockquote class="uncited"><div>[13:03:13] missing close-brace<br>    while executing<br>"namespace eval reqs {<br>namespace eval set {<br><br>#START SETTINGS<br>variable req_chan "#chan"<br><br>#DB CONNECTION<br>variable db_host "localhost"<br>variable db_po..."<br>    (file "scripts/vb-script.tcl" line 3)<br>    invoked from within<br>"source scripts/vb-script.tcl"<br>    (file "eggdrop.conf" line 219)<br>[13:03:13] * CONFIG FILE NOT LOADED (NOT FOUND, OR ERROR)</div></blockquote><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=11635">danswano</a> — Mon Apr 25, 2011 8:39 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[doggo]]></name></author>
		<updated>2011-04-24T22:11:23-04:00</updated>

		<published>2011-04-24T22:11:23-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=96746#p96746</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=96746#p96746"/>
		<title type="html"><![CDATA[Connecting vBulletin Users Database Table with IRC]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=96746#p96746"><![CDATA[
<blockquote class="uncited"><div>I'm sorry dude but i'm not that pro in eggdrop, where do i paste those settings and do i need additional tcl? Thanks.</div></blockquote><br>if you save all the above code into a file called vb-script.tcl save to the scripts DIR and edit these to match your user database tables<br><div class="codebox"><p>Code: </p><pre><code>#DB CONNECTION variable db_host "DB_HOST" variable db_port "3306" variable db_username "DB_USER" variable db_password "DB_PASS" variable db_name "DB_NAME" #CHANNEL USER TABLE variable db_table "TABLE_NAME" variable db_nick "USERNAME_FIELD" variable db_pass "MD5_PASSWORDED_FIELD" </code></pre></div><br>and add the line <br><br><div class="codebox"><p>Code: </p><pre><code>if {[catch {source scripts/vb-script.tcl} err]} {putlog "Error while loading vb-script.tcl: $err"} else {putlog "vb-script.tcl loaded without errors"}</code></pre></div>to your eggdrop.conf, then .restart your eggdrop via the partyline<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=11046">doggo</a> — Sun Apr 24, 2011 10:11 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[danswano]]></name></author>
		<updated>2011-04-24T19:24:44-04:00</updated>

		<published>2011-04-24T19:24:44-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=96745#p96745</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=96745#p96745"/>
		<title type="html"><![CDATA[Connecting vBulletin Users Database Table with IRC]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=96745#p96745"><![CDATA[
I'm sorry dude but i'm not that pro in eggdrop, where do i paste those settings and do i need additional tcl? Thanks.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=11635">danswano</a> — Sun Apr 24, 2011 7:24 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[doggo]]></name></author>
		<updated>2011-04-25T09:18:50-04:00</updated>

		<published>2011-04-24T18:02:51-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=96744#p96744</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=96744#p96744"/>
		<title type="html"><![CDATA[Connecting vBulletin Users Database Table with IRC]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=96744#p96744"><![CDATA[
ive tested and seems to work ok..<br><br><br>just edit the SETTINGS part and restart the bot.. <br><br><br>usage <div class="codebox"><p>Code: </p><pre><code>/MSG botnick site_name site_pass</code></pre></div><div class="codebox"><p>Code: </p><pre><code>package require mysqltcl 3.05namespace eval reqs {namespace eval sett {#START SETTINGS    variable req_chan "#YOUR_CHAN"#DB CONNECTIONvariable db_host "DB_HOST"variable db_port "3306"variable db_username "DB_USER"variable db_password "DB_PASS"variable db_name "DB_NAME"#CHANNEL USER TABLEvariable db_table "TABLE_NAME"variable db_user "USERNAME_FIELD"variable db_pass "MD5_PASSWORDED_FIELD"#BINDS bind MSGM -|- "*" reqs::user_add_voice::voice_add_user #END SETTINGS NAMESPACE } # SCRIPT STARTS namespace eval user_add_voice {  proc voice_add_user {nick uhost handle text} { set check_nick [lindex $text 0] set get_pass [lindex $text 1] set check_pass [md5 $get_pass] set find_it [::mysql::connect -host $reqs::sett::db_host -port $reqs::sett::db_port -user $reqs::sett::db_username -password $reqs::sett::db_password -db $reqs::sett::db_name]; set it_find [::mysql::sel $find_it "SELECT $reqs::sett::db_user,$reqs::sett::db_pass FROM $reqs::sett::db_table WHERE $reqs::sett::db_user = '$check_nick' AND $reqs::sett::db_pass = '$check_pass'" -flatlist]; ::mysql::endquery $find_it ::mysql::close $find_it if {$it_find == ""} {putquick "NOTICE $nick :invalid login";return} else { set valid_nick [lindex $it_find 0] set valid_pass [lindex $it_find 1] if {![isvoice $nick $reqs::sett::req_chan] &amp;&amp; $check_nick == "$valid_nick" &amp;&amp; $check_pass == "$valid_pass"} {    putquick "MODE $reqs::sett::req_chan +v $nick"    putquick "NOTICE $nick :thanks for logging in.."     } else {            return }} } }      #END NAMESPACE }</code></pre></div>** code updated to fix the missing } **<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=11046">doggo</a> — Sun Apr 24, 2011 6:02 pm</p><hr />
]]></content>
	</entry>
	</feed>
