Re: PHP FTP a security risk?????
| From: | Chris Wesley | Date: | Tue, 11 Feb 2003 20:22:18 +0000 |
| Subject: | Re: PHP FTP a security risk????? | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-135239@lists.php.net to get a copy of this message | ||
On Tue, 11 Feb 2003, Chris Wesley wrote:
> On Tue, 11 Feb 2003, Christopher Ditty wrote:
>
> > errors, no nothing. I talked to his host and found out that they do
> > not allow PHP FTP because it is a security risk. ????? Ummmm, ok?
>
> That said ... FTP is a protocol; there's nothing stopping you from
> opening a socket and talking FTP back & forth across it (unless your host
> has disabled fsockopen() too). If you know the protocol, you probably
> know how and why to avoid its security concerns.
>
> Other options: Move to a less security-minded hosting provider (looks
> like you've already started that), or ask the FTP server admin to provide
> download access to your file via HTTP.
You might find this interesting too -- straight from Example 1 for fopen()
in the PHP manual: http://www.php.net/manual/en/function.fopen.php
$handle = fopen ("ftp://user:password@example.com/somefile.txt",
"w");
b.careful ... g.luck,
~Chris