Go Back   FlashFXP Forums > ioFTPD Forum > ioFTPD > Scripting > bounty's dZSbot

Reply
 
Thread Tools Rate Thread
Old 10-07-2004, 09:19 AM   #1
Junior Member
 
Join Date: Oct 2004
Posts: 12
Default %USER is downloading.....

Is this possible:

Every time a user start's a downloading a file there would be an line in IRC of it:

"Geek is downloading /mp3/Uriah Heep/lady.in.black.mp3"

I have so little traffic in my box so the amount of lines to IRC is no problem.

CP
CP-Geek is offline   Reply With Quote
Old 02-03-2005, 01:45 PM   #2
Junior Member
 
Join Date: Feb 2005
Posts: 8
Default announce

i also would like to know how to do this, VERY interested
byte-poet is offline   Reply With Quote
Old 02-03-2005, 04:27 PM   #3
Senior Member
FlashFXP Registered User
ioFTPD Foundation User
 
Join Date: Oct 2004
Posts: 113
Default

It is not complicated to write tcl script that would do what you want. Put it in

[FTP_Post-Command_Events]
retr = TCL ../scripts/logDownload.itcl

And inside the script:
putlog "DOWNLOAD: something or else"

I leave it up to you to get the the user, filename etc and to format the actual message correctly.
esmandil is offline   Reply With Quote
Old 02-03-2005, 09:31 PM   #4
deo
Banned
 
Join Date: Feb 2005
Posts: 53
Default

Code:
##!
##[FTP_Pre-Command_Events]
##retr		= TCL ..\scripts\download.itcl

catch {putlog "UPDATE: \"$pwd\" \"\002$user\002/$group has started to download $pwd\002[lindex $args 1]\002\""}

##end
deo is offline   Reply With Quote
Old 02-04-2005, 03:29 PM   #5
Junior Member
 
Join Date: Feb 2005
Posts: 8
Default

:banana: total newb here :banana:

where infact does this newly created script go? /eggdrop/scripts/ ?
byte-poet is offline   Reply With Quote
Old 02-09-2005, 05:08 AM   #6
Junior Member
 
Join Date: Oct 2004
Posts: 12
Default

Thanks Deo, I'll try to test that

CP

EDIT: Works like a charm! I also modifoed it and put a "User has downloaded ...." and tried to put "@ 123 KB/s" but didnt get the cookie to work? any ideas?
CP-Geek is offline   Reply With Quote
Old 02-09-2005, 08:57 AM   #7
Junior Member
 
Join Date: Oct 2004
Posts: 12
Default

Quote:
Originally posted by byte-poet
:banana: total newb here :banana:

where infact does this newly created script go? /eggdrop/scripts/ ?
No, to Your io's /scripts folder, You also have to edit ioftpd.ini.

CP
CP-Geek is offline   Reply With Quote
Old 02-09-2005, 07:13 PM   #8
Junior Member
 
Join Date: Feb 2005
Posts: 8
Default

thanks!

i will modify it tomorrow and report back my findings!

UPDATE: put everything in and restarted the ftp server....no change, only announces logons and logoffs...

i put the code into a file and put it in the scripts dir, and then modified the ioftpd.ini

dunno what im doin wrong here.....
byte-poet is offline   Reply With Quote
Old 02-10-2005, 06:37 AM   #9
Junior Member
 
Join Date: Oct 2004
Posts: 12
Default

Where and what did You edit in ioftpd.ini?

Also, I'd like to know how do to remove path from this:

Code:
catch {putlog "UPDATE: \"$pwd\" \"\002$user\002 uploaded $pwd\002[lindex $args 2]\002\""}
CP
CP-Geek is offline   Reply With Quote
Old 02-10-2005, 02:49 PM   #10
Junior Member
 
Join Date: Feb 2005
Posts: 8
Default

i created a file called download.itcl and i placed it in \ioFTPD\scripts...

in that file, i put in:

Code:
##!
##[FTP_Pre-Command_Events]
##retr		= TCL ..\scripts\download.itcl

catch {putlog "UPDATE: \"$pwd\" \"\002$user\002/$group has started to download $pwd\002[lindex $args 1]\002\""}

##end
and in the ioftpd.ini i now have a post section that looks like this...

Code:
[FTP_Post-Command_Events]
;mkd  =
;rmd  =
;stor =
;dele =
retr = TCL ..\scripts\download.itcl
any ideas what i 'm doin wrong?
byte-poet is offline   Reply With Quote
Old 02-17-2005, 12:53 AM   #11
Junior Member
 
Join Date: Feb 2005
Posts: 8
Default stillll not there

ok, after fiddling with this thing nightly, i cant get this to work. anyone able to help me out here?
byte-poet is offline   Reply With Quote
Old 02-17-2005, 04:24 AM   #12
Junior Member
 
Join Date: Oct 2004
Posts: 12
Default

It should be in

Code:
[FTP_Pre-Command_Events]
;mkd  =
;rmd  =
;stor =
;dele =
retr = TCL ..\scripts\download.itcl
Notice the Pre-Command-part?

Also I noticed that sometimes a restart is needed, rehash don't seem to reset everything.
CP-Geek is offline   Reply With Quote
Old 02-17-2005, 07:17 AM   #13
deo
Banned
 
Join Date: Feb 2005
Posts: 53
Thumbs up

yup. pre, else user isnt to start download, theyve finished it
deo is offline   Reply With Quote
Old 02-17-2005, 01:23 PM   #14
Junior Member
 
Join Date: Feb 2005
Posts: 8
Default

bwahahaha...will change and see whats up
byte-poet is offline   Reply With Quote
Old 02-17-2005, 01:56 PM   #15
Junior Member
 
Join Date: Feb 2005
Posts: 8
Default

ok, same stuff. It announces logins and logouts but not when created
files are as examples
the ioftpd.ini contains:
Code:
[FTP_Pre-Command_Events]
;list =
;stor =
;mkd  =
retr = TCL ..\scripts\download.itcl

[FTP_Post-Command_Events]
;mkd  =
;rmd  =
;stor =

and the download.itcl contains:
Code:
##!
##[FTP_Pre-Command_Events]
##retr		= TCL ..\scripts\download.itcl

catch {putlog "UPDATE: \"$pwd\" \"\002$user\002/$group has started to download $pwd\002[lindex $args 1]\002\""}

##end
i now have the ioftpd trying to execute it in the pre section, but no change...no output to the irc channel. It DOES look like its putting it to a log though...where do i go from here!?
byte-poet is offline   Reply With Quote
Reply
Create a free account to browse our forums without ads



Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Quick Question Rocket442 General Discussions 2 01-21-2005 03:25 AM


All times are GMT -5. The time now is 05:51 AM.