View Full Version : [mods] ioB 2.0 r1 and third-party scripts
I made that mod because of i'm using ioB 2.0 release 1 by using the mp3 sport with autospacemaker there still allot of death symbolic linkes @ sorted dirs.. (deathlinks) to remove them i used ioSYMCHECK.itcl witch comes with ioFTPD.log support so i dediced to get it working for ioB 2.0 r1.
the following files are needed (can be found @ scripts section):
- ioB 2.0 r1
- ioSYMCHECK
open ioBanana.tcl
search for:
set enable(MP3CHK)
add following lines:
###; Symcheck
set enable(ioSYMCHECK) 1
search for:
set defaulttypes "LOGIN LOGOUT INVITE GIVE TAKE REQUEST REQFILLED REQDEL APPROVE CLOSE OPEN VOTE VOTETOPIC VOTERESULT"
replace with:
set defaulttypes "LOGIN LOGOUT INVITE GIVE TAKE REQUEST REQFILLED REQDEL APPROVE CLOSE OPEN VOTE VOTETOPIC VOTERESULT ioSYMCHECK"
search for:
set variables(VOTERESULT)
add following lines:
###; ioSYMCHECK
set variables(ioSYMCHECK) "%symcheck"
_____________________________________
open ioB2.skin
search for:
set announce(VOTERESULT)
add following lines:
###; ioSYMCHECK
set announce(ioSYMCHECK) "\[[b]SYMCHECK[b]\] %symcheck"
_____________________________________
open ioSYMCHECK.itcl
search for:
putlog "ioSYMCHECK: Started Running"
replace with:
putlog "ioSYMCHECK: \"Started Running\""
search for:
putlog "ioSYMCHECK: Completed (Checked [llength $templist] Directories, Found $alive Alive Symlinks & $dead Dead Symlinks)"
replace with:
putlog "ioSYMCHECK: \"Completed (Checked [llength $templist] Directories, Found $alive Alive Symlinks & $dead Dead Symlinks)\""
_____________________________________
thats all hf:)
That's interesting. Thank you.
That's of course when you don't want to use the spider that comes with ioBanana ;)
I would also suggest redirecting the ioSYMCHECK messages so they spam the admin channel instead.
oh good idea:) ill change it that you can choose beween admin/default chan:)
Well it will announce new affilalation on main irc channel also remove affilation and even witch sections the new affilation supports. This mod will work only for fundation users cuz of the required scripts!
the following files are needed (can be found @ scripts section):
- ioB 2.0 r1 by Harm
- ioPRECFG.itcl by Harm
open ioBanana.tcl
search for:
set enable(MP3CHK)
add following lines:
###; ioPREDIR
set enable(ioAFFILADD) 1
set enable(ioAFFILDEL) 1
search for:
set defaulttypes
add to set defaulttypes:
ioAFFILADD ioAFFILDEL
into the "..." !!
search for:
set variables(VOTERESULT)
add following lines:
###; ioPREDIR
set variables(ioAFFILADD) "%ioAFFILGRP %ioAFFILTYPES"
set variables(ioAFFILDEL) "%ioAFFILGRP"
_____________________________________
open ioB2.skin
search for:
set announce(VOTERESULT)
add following lines:
###; ioPREDIR
set announce(ioAFFILADD) "\[[c]3[b]AFFiL[b][c]\] [b]%ioAFFILGRP[b] has just join'd [b]%sitename[b].\n\[[c]3[b]AFFiL[b][c]\] supported areas: [b]%ioAFFILTYPES[b]"
set announce(ioAFFILDEL) "\[[c]4[b]AFFiL[b][c]\] [b]%ioAFFILGRP[b] has just dropp'd [b]%sitename[b]."
_____________________________________
open ioPRECFG.itcl
search for:
putsyslog "'[resolve uid $uid]' added group '$grp(name)' as affil for '[join $grp(types)]'"
add following line:
putlog "ioAFFILADD: \"$grp(name)\" \"$grp(types)\""
search for:
putsyslog "'[resolve uid $uid]' removed group '$grp(name)' from affils list"
add following line:
putlog "ioAFFILDEL: \"$grp(name)\""
_____________________________________
thats all hf:)
next mod ioB 2.0 r1 will announce dual upload in same sfv.. and kick the uploader form site.
(DoS) [DUAL UPLOAD] iXi/SiTEOP try'd to upload two times in dvdr/test2.
the following files are needed (can be found @ scripts section):
- ioB 2.0 r1 by Harm
- ioNODUAL.itcl by _tUFF
Since there are to much changes needed in ioNODUAL.itcl by _tUFF ill post the complett changed code here i hope that issnt a problem..
create file: ioNODUAL.itcl
###; ioTOOLS.ioNODUALUP.itcl v0.4 by _tUFF (01/02/2006) ioFTPD 5.8.5r+
###; changelog...
###; 0.1 - bored, noticed a request for a script to stop dual uploading on the same sfv
###; 0.2 - ignore certain directories, dZSbot friendly feature requests added
###; 0.3 - fixed the directory ignore
###; 0.4 - changed for ioB 2.0 r1 announce!
###; install...
###; add the follow line under [FTP_Pre-Command_Events] in your ioftpd.ini and remember to site config rehash
###; stor = TCL ..\scripts\ioBanana\ioNODUAL.itcl
###; dont modify these!
set user [resolve uid $uid]
set grp [resolve gid $gid]
set release [string range [string range $pwd 1 end-1] [expr [string first "/" [string range $pwd 1 end-1]] +1 ] end]
###; settings...
###; nderror - the error message you want the user to see when he attempts to upload more than once in the same directory
###; ndignore - VFS directoried to ignore for dual up
set nderror "dont dual upload in the same directory muppet!"
set ndkick 1
set ndignore {
"_Groups"
"_Requests"
"_Speed"
"_Private"
}
global args uid gid cid ioerror pwd
set who ""
set ignore 0
if {[client who init "UID" "VIRTUALPATH" "ACTION"] == 0} {
while { 1 } {
set data [client WHO FETCH]
if {$data == ""} {break}
lappend who $data
}
}
foreach entry $who {
if {[string match "$uid" [lindex $entry 0]]} {
set nduid [lindex $entry 0]
set ndvfs [lindex $entry 1]
set ndact [lindex $entry 2]
foreach ignored $ndignore {
if {[string match -nocase "*$ignored*" $ndvfs]} {set ignore 1}
}
if {$ignore != 1} {
if {[string match -nocase "stor" [lindex $ndact 0]] || [string match -nocase "appe" [lindex $ndact 0]]} {
if {[string match -nocase "$pwd" $ndvfs]} {
iputs -nobuffer "226 $nderror"
iputs -nobuffer "550 Command failed."
set ioerror 1
if {$ndkick} {client kill clientid $cid}
putlog "ioNODUAL: \"$user\" \"$grp\" \"$release\""
return 0
}
}
}
}
}
set ioerror 0
________________________________________
open ioBanana.tcl
search:
set enable(MP3CHK)
add lines:
###; ioNODUAL
set enable(ioNODUAL) 1
search:
set defaulttypes
add to set defaulttypes:
ioNODUAL
into the quotes "" !!
search:
set variables(VOTERESULT)
add line:
###; ioNODUAL
set variables(ioNODUAL) "%user %group %release"
search:
set ioBvar(redirect,WARCWIPE)
add line:
set ioBvar(redirect,ioNODUAL) "#ioBanana"
________________________________________
open ioB2.skin
search:
set announce(VOTERESULT)
add lines:
###; ioNODUAL
set announce(ioNODUAL) "\[[c]4[b]DUAL UPLOAD[b][c]\] [b]%user[b]/%group try'd to upload two times in [b]%release[b]."
________________________________________
Thats all:)
another ioB 2.0r1 mod (this time no 3th party addon) just moded ioUINFO.itcl
default site user output:
[R] site user
[R] 200 Command successful.
moded site user output:
[R] site user
[R] 200- Syntax:
[R] 200- site user <username>
[R] 200 Command successful.
the following files are needed (can be found @ scripts section):
- ioB 2.0 r1 by Harm
open file: ioUINFO.itcl
search:
if {![info exists args]} {return 0}
return [uinfo]
remove both lines
add:
proc ioUINFO:help {} {
iputs -nobuffer " Syntax:"
iputs -nobuffer " site user <username>"
return
}
if {([info exists args])} { return [uinfo] } else { ioUINFO:help }
save and exit thats it:)
another ioB 2.0r1 mod (this time no 3th party addon) just moded ioGINFO.itcl
default site group output:
[R] site group
[R] 200 Command successful.
moded site user output:
[R] site group
[R] 200- Syntax:
[R] 200- site group <groupname>
[R] 200 Command successful.
the following files are needed (can be found @ scripts section):
- ioB 2.0 r1 by Harm
open file: ioGINFO.itcl
search:
if {![info exists args]} {return 0}
return [ginfo]
remove both lines
add:
proc ioGINFO:help {} {
iputs -nobuffer " Syntax:"
iputs -nobuffer " site group <groupname>"
return
}
if {([info exists args])} { return [ginfo] } else { ioGINFO:help }
save and exit thats it:)
another 3th party addon for ioB 2.0 r1.. base on iojM by jeza all credits belongs to him!
go into your ioFTPD\scripts\ioBanana\ dir
create file called ioMASTER.itcl and insert the following code:
################################################## #######################################
# all credits belongs to jeza! #
# orginal script: #
# http://www.inicom.net/pages/en.ioftpd-scripts.php?did=15 #
# modded for ioB 2.0 r1 to have an announce @ admin chan while add/remove a master! #
# #
# copy ioMASTER.itcl to ..\scripts\ioBanana [or where u want] #
# #
# in ioFTPD.ini add #
# #
# [FTP_Custom_Commands] #
# addmaster = TCL ..\scripts\ioBanana\ioMASTER.itcl add #
# delmaster = TCL ..\scripts\ioBanana\ioMASTER.itcl del #
# #
# [FTP_Command_Permissions] #
# addmaster = M #
# delmaster = M #
# #
# restart/rehash ioFTPD #
# #
################################################## #######################################
###; Path to SysOp.log
set ioM(syslog) "../logs/SysOp.log"
################################################## #######################################
# STOP HERE #
################################################## #######################################
proc putsyslog {text} {
global ioM
set now [clock format [clock seconds] -format {%m-%d-%Y %H:%M:%S}]
set syslog [open $ioM(syslog) a+]; puts $syslog "$now $text."; close $syslog
return 0
}
proc ioMASTER:main { arg } {
global ioMASTER ioerror muid ioM
set muid [resolve user [lindex $arg 1]]
if { $muid == -1 } {
iputs -nobuffer "[lindex $arg 1]: Not found. "
set ioerror 2
return 1
}
if { [userfile open [lindex $arg 1]]== 0 } {
userfile lock
set uf [split [userfile bin2ascii] \n]
if {[set fn [lsearch $uf {flags *}]] != -1} {
set flg [lindex $uf $fn]
set flg [lrange $flg 1 end]
if { [string tolower [lindex $arg 0]] == "add" } {
putsyslog "Adding Master Flag to [lindex $arg 1]"
iputs -nobuffer "Adding Master Flag to [lindex $arg 1]"
set rf "M"
set rf [concat $rf$flg]
set uf [lreplace $uf $fn $fn "flags $rf"]
}
if { [string tolower [lindex $arg 0]] == "del" } {
putsyslog "Removing Master Flag from [lindex $arg 1]"
iputs -nobuffer "Removing Master Flag from [lindex $arg 1]"
regsub -all -- "M" $flg "" flg;
set rf $flg
set uf [lreplace $uf $fn $fn "flags $rf"]
}
}
set nuf {}
foreach line $uf {
set nuf "${nuf}$line\n"
}
userfile ascii2bin $nuf
userfile unlock
} else {
iputs -nobuffer "Cant open UserFile!"
}
return 0
}
proc ioMASTER:help {} {
iputs -nobuffer " Syntax:"
iputs -nobuffer " site addmaster <name>"
iputs -nobuffer " site delmaster <name>"
return
}
if { ([info exists args]) && ([llength $args] == 2) } { ioMASTER:main "$args" } else { ioMASTER:help }
it will announce @ staff/admin chan add/del of masters on your site.
thats all..
ChipMunk666
06-21-2006, 03:28 PM
nice work thx a lot
vBulletin® v3.8.11 Alpha 3, Copyright ©2000-2024, vBulletin Solutions, Inc.