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.
Old posts that have not been replied to for several years.
s
sipko
Post
by sipko » Tue Nov 06, 2001 1:49 pm
Can some tell me where can I find (or hints to write) a tcl script wich disables bot users to add a new user. It is not important what their flags are.
So there must be a database or somethin' with nick who may add users.
greenbear
Owner
Posts: 733 Joined: Mon Sep 24, 2001 8:00 pm
Location: Norway
Post
by greenbear » Tue Nov 06, 2001 2:38 pm
I guess you could use the filt command for this.
the code would be something like this:
Code: Select all
# users that can use the +user command
set allowed "user1 user2"
bind filt - ".+user" +user:check
proc +user:check {idx args} {
global allowed
set usernick [idx2hand $idx]
if {[lindex $args 1] == ""} {
set icmd [lindex $args 0]
set args "$icmd "
}
if {[lsearch -exact [string tolower $allowed] [string tolower $usernick]] == -1} {
putdcc $idx "What? You need '.help'"
} else {
return $args
}
}
this would only allow 'user1' and 'user2' to use the +user command
Wcc
Master
Posts: 278 Joined: Sun Oct 28, 2001 8:00 pm
Location: USA
Contact:
Post
by Wcc » Tue Nov 06, 2001 2:59 pm
Should be
Code: Select all
bind filt - ".+u* * *" +user:check
, otherwise you could bypass it with .+u <blah>
s
sipko
Post
by sipko » Tue Nov 06, 2001 3:51 pm
Huh, guys tnx!
I will test this right away.
But i found out that there is another problem. All users can .su to antoher user and then add user.
how can I enable .su with password protection?
ppslim
Revered One
Posts: 3914 Joined: Sun Sep 23, 2001 8:00 pm
Location: Liverpool, England
Post
by ppslim » Tue Nov 06, 2001 4:11 pm
.su is password protected.
If memory serves me correct, only permanent owners (defined in the config file) can SU without using a password, all other users requir a password.
s
sipko
Post
by sipko » Tue Nov 06, 2001 5:34 pm
Oh, tnx!!
s
sipko
Post
by sipko » Tue Nov 06, 2001 6:40 pm
This is burjok.tcl script. I added it and then rehashed and restarted my bot. But still all (m&n) users may add people into the botnet. I have 2 bots on my botnet.
Have I made a mistake?
set allowed "SIPko burek12 kmeto"
bind filt - ".+u* * *" +user:check
proc +user:check {idx args} {
global allowed
set usernick [idx2hand $idx]
if {[lindex $args 1] == ""} {
set icmd [lindex $args 0]
set args "$icmd "
}
if {[lsearch -exact [string tolower $allowed] [string tolower $usernick]] == -1} {
putdcc $idx "What? You need '.help'"
} else {
return $args
}
}
putlog "burjok adduser skripta loaded:P"
<font size=-1>[ This Message was edited by: sipko on 2001-11-06 15:43 ]</font>
<font size=-1>[ This Message was edited by: sipko on 2001-11-06 15:45 ]</font>
ppslim
Revered One
Posts: 3914 Joined: Sun Sep 23, 2001 8:00 pm
Location: Liverpool, England
Post
by ppslim » Tue Nov 06, 2001 7:07 pm
After the line
putdcc $idx "What? You need '.help'"
Add the line
return ""
s
sipko
Post
by sipko » Tue Nov 06, 2001 7:08 pm
ok I managed the problem.. the problem was .+u* * * -> that has not solved the problem when I wrote .+user name .. and then later .+host
... I handeled that one;)
s
sipko
Post
by sipko » Tue Nov 06, 2001 7:09 pm
hm, ok... i will add this too...
Thank you for your help!
Wcc
Master
Posts: 278 Joined: Sun Oct 28, 2001 8:00 pm
Location: USA
Contact:
Post
by Wcc » Wed Nov 07, 2001 3:34 am
You also want to disable the .adduser command i'm sure.
s
sipko
Post
by sipko » Wed Nov 07, 2001 10:31 am
Huh, indeed;)
tnx again!
s
sipko
Post
by sipko » Wed Nov 07, 2001 3:36 pm
Now I would like to add these commands into the forbidden list:
.-user
.adduser
.chattr
.die
Is this tho solution to my problem if I add these lines to this .+user script?:
bind filt - ".-u* * *" -user:check
bind filt - ".adduser* * *" adduser:check
bind filt - ".chattr* *" chattr:check
bind filt - ".die" die:check
and then what do I have to add to proc lines?
Please help me adding these commands to be restricted like +user.
Thanx
Wcc
Master
Posts: 278 Joined: Sun Oct 28, 2001 8:00 pm
Location: USA
Contact:
Post
by Wcc » Wed Nov 07, 2001 7:42 pm
You can use the same proc for all of these, but chattr and adduser needed to be wild-card-ified
bind filt - ".-u* * *" +user:check
bind filt - ".addu* +user:check
bind filt - ".chatt* *" +user:check
bind filt - ".die" +user:check
s
sipko
Post
by sipko » Wed Nov 07, 2001 8:21 pm
huh, It works! Tnx ... I owe you a beer!;)