PDA

View Full Version : ioSKIPLIST


scull
03-18-2004, 12:01 PM
Hi ..

I was sick and tired of traders uploading other sites "site-tags", so i made this little script.

It deny upload of files or folders that have "[" or "]" in their names.

- Edit your ioFTPD.ini

[FTP_Pre-Command_Events]
stor = EXEC ..\scripts\ioSKIPLIST\ioSKIPLIST.exe
mkd = EXEC ..\scripts\ioSKIPLIST\ioSKIPLIST.exe

- ALWAYS place ioSKIPLIST as first "mkd" or "stor" script.

//Scull

>>Download Here<< (http://www.ioftpd.com/scripts/script.php?id=92)

scull
03-18-2004, 12:13 PM
Opps :) .. Wrong name , It should be ioSKIPLIST .. NOT .. ioSKIPTAG ..

New renamed file uploaded. ( only change is that ioSKIPTAG.exe is renamed to ioSKIPLIST ).

//Scull

Zer0Racer
03-18-2004, 02:44 PM
Does it really block files without catching pre STOR?

ddeca
03-18-2004, 07:16 PM
i guess it only blocks TAGs that are made of dir..

scull
03-19-2004, 12:45 AM
Hi..

I havent tested if it blocks files , but it should if you put it in the pre-stor too.

It works and prevents dirs to be created BUT i have a little problem. ioFTPD want to "CWD" ( Change Owner Dir ) to the blocked UN-MADE dir, and when it does not find the dir ( because i blockt the MKD of it ) it times out trying CWD the dir ...

When timed out the USER that tried to upload the tag dir is connected again and NO tag dir is uploaded ( punishment ? ;) )

Any one know how to prevent the CWD ? I'm working in VB6.

//scull

Mouton
03-19-2004, 10:27 AM
The ftp client (ffxp ?) tries to CWD, not io...
And the ftp client tries to enter the dir because u didn't tell it that the MKD command failed.
U need to output something to the client... 530 Dir creation blocked by ioSKIPLIST. or something similar.
Check what's the right error code for mkd denied...

scull
03-20-2004, 09:50 AM
Thanx! ..

I fixed the "problem" now.

Now Files AND Folders are rejected if they have "[" or "]" in their names.

version 1.1 out.

//Scull

>>Download Here<< (http://www.ioftpd.com/scripts/script.php?id=92)

wooolF[RM]
03-22-2004, 11:57 AM
erm... why dont use ioftpd.ini for this task? under upload/download permissions... just wondering...

scull
03-22-2004, 12:27 PM
Originally posted by wooolF[RM]
erm... why dont use ioftpd.ini for this task? under upload/download permissions... just wondering...

hehe :) I wanted to learn how to do a script that deny a PRE operation.

//Scull

wooolF[RM]
03-22-2004, 01:25 PM
ah, oki :) and good job on learning :D