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.

sicherheit scripts

Old posts that have not been replied to for several years.
D
Diablo
Voice
Posts: 12
Joined: Mon May 02, 2005 6:24 am

sicherheit scripts

Post by Diablo »

Hi!

Does anybody know what scripts are used by #sicherheit bots on Quakenet? I mean not all of them, but main scripts (when bot joins and checks the channel.. )

LP
m
metroid
Owner
Posts: 771
Joined: Wed Jun 16, 2004 2:46 am

Post by metroid »

They wrote their own, request scripts aren't very hard to make either.
D
Diablo
Voice
Posts: 12
Joined: Mon May 02, 2005 6:24 am

Post by Diablo »

hm.. i see. ty :]
D
Diablo
Voice
Posts: 12
Joined: Mon May 02, 2005 6:24 am

Post by Diablo »

does anyone has some good request scripts for quakenet? i mean like the bot cannot be requested for #help, #feds, #quakenet and so on..
User avatar
demond
Revered One
Posts: 3073
Joined: Sat Jun 12, 2004 9:58 am
Location: San Francisco, CA
Contact:

Post by demond »

requesting what? strippers doing lap dance?
D
Diablo
Voice
Posts: 12
Joined: Mon May 02, 2005 6:24 am

Post by Diablo »

i need a request script like sicherheit and chanbot, where a random bot joins, it scans the channel for clones and other stuff, if channel meets the req bot joins otherwise channel is rejected.


P.S sry for my bad english :)
User avatar
demond
Revered One
Posts: 3073
Joined: Sat Jun 12, 2004 9:58 am
Location: San Francisco, CA
Contact:

Post by demond »

and what would that bot do then?
D
Diablo
Voice
Posts: 12
Joined: Mon May 02, 2005 6:24 am

Post by Diablo »

it is security bot. it would also require+amo on L/Q
D
Dizzle
Op
Posts: 109
Joined: Thu Apr 28, 2005 11:21 am
Contact:

Post by Dizzle »

the only way too do this is too scripts it yourself diablo, sicherheit did it like 10 other botservices on Q-net.
I think they use a lot of scripts already made by ppl, there is a botrequest in the tcl archive its based on a botnet.

I have this script from Metroid, a good basic script for a request system, i used it.


Code: Select all

 
# Configuration 

# homechannel where they can request 
set setting(home) "#chan
# users the channel needs atleast 
set setting(needed) "50" 
# deny request if there is no Q or L? 
set setting(service) "1" 
# the flags he wants 
set setting(flags) "+av" 

# end of config 

# don't touch this setting! 
set setting(busy) 0 

bind pub -|- !request request:pub 

proc request:pub {nick host hand chan arg} { 
global setting 
# ignore the request because it isn't the request channel 
if {![string equal $chan $setting(home)]} { 
return 0 
} 
if {$setting(busy)} { 
putquick "NOTICE $nick :There is currently already an request in progress." 
return 0 
} 
set channel [lindex [split $arg] 0] 
# tell him he needs to input a channel first 
if {$channel == ""} { 
putquick "NOTICE $nick :Please state the channel you wish to request for." 
return 0 
} 
if {[validchan $channel]} { 
return 0; 
} 
# activate the busy signal so no other requests can be done 
bind RAW -|- 315 request:endofwho 
set setting(busy) 1 
set setting(chan) "$channel" 
set setting(nick) "$nick" 
channel add $channel 
} 

proc request:endofwho {from key arg} { 
global setting 
if {$setting(busy)} { 
if {![onchan $setting(nick) $setting(chan)] || ![isop $setting(nick) $setting(chan)]} { 
set setting(busy) 0 
putquick "NOTICE $setting(nick) :You aren't on $setting(chan) or you're not opped. Request denied." 
channel remove $setting(chan) 
unbind RAW -|- 315 request:endofwho 
return 0 
} 
if {$setting(service)} { 
if {![onchan L $setting(chan)] && ![onchan Q $setting(chan)]} { 
set setting(busy) 0 
putquick "NOTICE $setting(nick) :Q or L was not found on $setting(chan). Request denied." 
channel remove $setting(chan) 
unbind RAW -|- 315 request:endofwho 
return 0 
} 
} 
if {[llength [chanlist $setting(chan)]] < $setting(needed)} { 
set setting(busy) 0 
putquick "NOTICE $setting(nick) :$setting(chan) has less than $setting(needed) users. Request denied." 
channel remove $setting(chan) 
unbind RAW -|- 315 request:endofwho 
return 0 
} 
if {![validuser [nick2hand $setting(nick)]]} { 
adduser $setting(nick) *!*@[lindex [split [getchanhost $setting(nick) $setting(chan)] @] 1] 
} 
chattr [nick2hand $setting(nick)] |+n $setting(chan) 
putquick "NOTICE $setting(nick) :The request was succesfull. I will stay here. Please give me $setting(flags) on [request:service $setting(chan)]" 
putquick "PRIVMSG $setting(home) :$setting(nick) requested me for $setting(chan). The channel has [llength [chanlist $setting(chan)]] users. And they have the service bot: [request:service $setting(chan)]. Request was accepted." 
unset setting(chan); unset setting(nick) 
set setting(busy) 0 
unbind RAW -|- 315 request:endofwho 
return 1 
} 
} 

proc request:service {channel} { 
if {[onchan L $channel]} { 
return "L" 
} elseif {[onchan Q $channel]} { 
return "Q" 
} 
}
Hope this will help you, remember too make a good botservice, you need too learn TCL ;)
r
r0t3n
Owner
Posts: 507
Joined: Tue May 31, 2005 6:56 pm
Location: UK

Post by r0t3n »

is it possible to add a clonescan to that basic script by Metroid?
r0t3n @ #r0t3n @ Quakenet
D
Dizzle
Op
Posts: 109
Joined: Thu Apr 28, 2005 11:21 am
Contact:

Post by Dizzle »

like i sad tosser Metroid posted it on the forum for use for yourself, if you want a clonescan in it try put it in
What's this real life ppl keep talking about ??? And where can I download it ???
m
metroid
Owner
Posts: 771
Joined: Wed Jun 16, 2004 2:46 am

Post by metroid »

It's a flexible script so you can easily add it yourself
r
r0t3n
Owner
Posts: 507
Joined: Tue May 31, 2005 6:56 pm
Location: UK

Post by r0t3n »

Code: Select all

# Basic Request script

# GNU License
# This program is free software; you can redistribute it and/or modify      
# it under the terms of the GNU General Public License as published by      
# the Free Software Foundation; either version 2 of the License, or         
# (at your option) any later version.                                       
#                                                                           
# This program is distributed in the hope that it will be useful,           
# but WITHOUT ANY WARRANTY; without even the implied warranty of            
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the             
# GNU General Public License for more details.                              
#                                                                           
# You should have received a copy of the GNU General Public License         
# along with this program; if not, write to the Free Software               
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA 

# /* This is a basic request script, It will join the channel, check some settings and stay/part if accepted.
# *  This does NOT add other bots to that channel.
# *  If you want it to do that, You will have to make it do that yourself :)
# *  If you have any questions about this script, feel free to ask me in #v1per on irc.quakenet.org
# *  Also, if you find any bugs, the same channel, my nickname is metroid
# *  Also, leave my copyright in, If you want to put your own copyright in MY script, Make your own script completely from scratch.
# */

# /* Installing the request script
# *  First, put the script into your /home/user/*eggdrop name*/scripts folder.
# *  Then at the end of your eggdrop.conf, Put:
# *  source scripts/request.tcl
# *  Just rehash the bot after you've done this and it should work.
# */

# /* This is a VERY basic idea of what you can use for a request system with eggdrops.
# *  It's very flexible as it's really easy to just add whatever you want to it :)
# *  Good luck with making your own request script and if you need some help, you can contact me.
# */

namespace eval request {
 variable version "1.0"
 variable author  "metroid"
 
 # Configuration!
 # Our homechannel, they can only request here.
 variable homechan "#ShoVe"
 # Ammount of people we require.
 variable needed   "20"
 # Do we want a Q or L?
 variable service  "1"
 
 # Do we send a message to the homechannel when a request fails?
 variable tell     "1"
 
 # End of Config!
 # Do NOT edit anything below these lines
 
 variable busy     "0"
 
 bind PUB  -|-  !request  [namespace current]::request
}

proc request::request {nickname hostname handle channel arguments} {
 if {[string equal -nocase $channel $request::homechan]} {
  if {!$request::busy} {
   set chan [lindex [split $arguments] 0]
   if {$chan != "" && ![validchan $chan]} {
    if {[string index $chan 0] == "#"} {
     set request::busy 1
	 bind RAW -|- 315 [namespace current]::who
	 utimer 30 [list [namespace current]::timeout $chan]
	 channel add $chan
	 set ::info "$nickname $chan"
	} else {
	 putquick "NOTICE $nickname :A channel name starts with an #."
	}
   } else {
    putquick "NOTICE $nickname :You seem to have given an improper syntax for the channel."
   }
  } else {
   putquick "NOTICE $nickname :Sorry, there is already a request in progress."
  }
 }
}

proc request::who {server raw arguments} {
unbind RAW -|- 315 [namespace current]::who
if {$request::busy} {
 if {![info exists ::info]} { return 0 }
 set nickname [lindex [split $::info] 0]
 set channel [lindex [split $::info] 1]
 unset ::info
 set request::busy 0
 if {![onchan $nickname $channel] || ![isop $nickname $channel]} {
  putquick "NOTICE $nickname :You are not on $channel or you aren't opped."
  if {$request::tell} {
   putquick "PRIVMSG $request::homechan :Request for $channel failed. $nickname is not on $channel or is not opped."
  }
  channel remove $channel
  return 0
 }
 if {$request::service} {
   if {![onchan L $channel] && ![onchan Q $channel]} {
    set busy 0
    putquick "NOTICE $nickname :Q or L was not found on $channel."
    if {$request::tell} {
     putserv "PRIVMSG $request::homechan :Request for $channel failed. There is no Q or L on $channel."
    }
    channel remove $channel
    return 0
   }
  }
  clone:scan $hostname $channel
  if {$clones($channel) < $request::needed} {
    putquick "NOTICE $nickname :$channel has less than $request::needed users, you have $clones($channel) real users.."
    if {$request::tell} {
     putserv "PRIVMSG $request::homechan :Request for $channel failed. There are not enough users on $channel (There are $clones($channel) real users users, 20 real users needed)."
    }
    channel remove $channel
    return 0
  }
  # Request is accepted
  putquick "NOTICE $nickname :Your request is accepted. I will stay on $channel."
  putquick "PRIVMSG $request::home :Request from $nickname for $channel was accepted. The channel has [llength [chanlist $channel]] users."
  if {![validuser [nick2hand $nickname]]} {
   adduser $nickname *![getchanhost $nickname]
   chattr $nickname |+n $channel
  } else {
   chattr [nick2hand $nickname] |+n $channel
  }
 }
}
  
proc request::timeout {chan} {
 if {[validchan $chan] && ![botonchan $chan]} {
  channel remove $chan
  putquick "PRIVMSG $request::homechan :Request for $chan failed. Bot cannot join $chan."
  if {[info exists ::info]} { unset ::info }
 }
}

proc request::version {} {
 putlog "Basic Request script version: $request::version by $request::author was loaded successfully."
}
	
request::version

proc clone:scan {host chan} {
  set fp [open "clonescan.$chan" a]
  foreach host {[chanlist $chan]} {
    set host *!*@[lindex [split $host "@"] 1]
    puts $fp $host
  }
  close $fp
  clone:check $host $chan
}

proc clone:check {host chan} {
  set fp [open "clonescan.$chan" r]
  set data [read -nonewline $fp]
  close $fp
  set hosts [split $data "\n"]
  foreach host {[chanlist $chan]} {
    set host *!*@[lindex [split $host "@"] 1]
    if {[string match "$host" $hosts]} {
      inc clones($chan) 1
    }
  }
}
Now, i just attempted to add a lame clonescan which i have never made a clonescan before. Do any of you think that it won't work, like all the foreach and open/close of clonescan.#channel. Its my first attempt of adding a kinda clonescan to a request script.
r0t3n @ #r0t3n @ Quakenet
User avatar
demond
Revered One
Posts: 3073
Joined: Sat Jun 12, 2004 9:58 am
Location: San Francisco, CA
Contact:

Post by demond »

how about your first attempt to code something basic first? like, for example, counting words in a string? oh wait... that doesn't bring in much irc glory hehe
m
metroid
Owner
Posts: 771
Joined: Wed Jun 16, 2004 2:46 am

Post by metroid »

I see you found your way to the script i made this morning
Locked