Hi,
FormMail will only use the $FILE_REPOSITORY setting plus the basename of the uploaded file (or it's renamed value).
So,
PHP Code:
$FILE_REPOSITORY = "/home/you/www/repos";
with a file name of "/a/path/to/abc123.txt", will get stored as "/home/you/www/repos/abc123.txt"
The reason for this is to protect your server.
The main problem we have thought of is someone providing a pathname of "../../filename" - i.e. referencing parent directories.
Imagine, for example, if they could get FormMail to overwrite "../index.html" from "/home/you/www/repos"!
So, the answer is "no".
Of course, if we're really careful we could relax this restriction.
It would mean stripping out or detecting all and any file name hacks (such as "../").
But that's harder to be confident of.
If you really need this, then you can hire us (or someone) to provide a specific version of FormMail for you.
Bookmarks