Re: php unlink a file - is it possible?
| From: | Evan Nemerson | Date: | Thu, 09 Oct 2003 03:57:00 +0000 |
| Subject: | Re: php unlink a file - is it possible? | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-165552@lists.php.net to get a copy of this message | ||
Unless you change the permissions of the file, the run the FTP as nobody, run
apache as the ftp user, run apache as root (can't believe I even said that...
blasphemy!), etc., it shouldn't be possible.
If you find a way to do it w/out any of the above, I'd suggest you email the
Apache Software Foundation and/or the FTP software people, as well as
full-disclosure@lists.netsys.com, bugtraq@securityfocus.com, etc.
That being said, would it be feasible to set up a cron job to do this w/ the
PHP CLI running as an appropriatly privledged user?
On Wednesday 08 October 2003 08:11 pm, Alex Shi wrote:
> Hi,
>
> How can have a php script unlink/delete a file uploaded via FTP?
> Usually a ftp-uploaded file belongs to the ftp user, and a php
> script is running by apache/nobody. Seems like there shouldn't
> be any way to do this...OK, my situation is that I want a php script
> to this: it can move bulk uploaded (ftp) file to certain directories
> and then remove the original files, something just like a "move".
> If anyone knows on how to "move" or "delete" a file, please give
> me a hand. Thanks in advance!
>
> Alex
--
Evan Nemerson
evan@coeus-group.com
--
"Who controls the past controls the future. Who controls the present controls
the past."
-George Orwell