PDA

View Full Version : wu-ftp / allowable file names


cflhosting
2004-01-14, 11:33 AM
Is there good reason for not allowing file names with spaces or apostrophes to be uploaded to the server?

Had some people ask me about it, and I figured it must be the default for *some* reason, but I'm not sure what that reason is.


Secondly, if it's not a problem, what do I change the regexps to? I've dealt with them only minimally, which is probably sad considering my major.

Currently allowing:
^[-+A-Za-z0-9_.]*$

Disallowing:
^\. ^-

Thanks,
C.F.L.

QT
2004-01-14, 12:08 PM
wu-ftpd has a list of files that are not allowed to be uploaded or downloaded, but files with spaces or single quotes are not in that list.

What FTP client is being used and what errors are being produced when someone tries to upload?

cflhosting
2004-01-14, 12:37 PM
I have the problem too, so I'll give you the information I get.

I'm using smartFTP, and when trying to upload a file with spaces in the name, I get:

STOR basement hopping.txt
550 basement hopping.txt: Permission denied on server. (Filename (accept))


and for '

STOR basement'hopping.txt
550 basement'hopping.txt: Permission denied on server. (Filename (accept))

knightfoo
2004-01-14, 17:29 PM
Try changing the allowed charset to:

^[-+A-Za-z0-9_.\ \\']*$

You should probably use proftpd instead of wu-ftpd too, it makes a lot more sense. Even Red Hat has stopped using wu-ftpd.

-knightfoo

cflhosting
2004-01-14, 21:24 PM
It didn't like your regexp :P

It's alright, I'll probably try switching to proftpd this weekend.

Thank for your help

C.F.L.