Re: About #37799
| From: | Mehdi Achour | Date: | Fri, 29 Dec 2006 23:52:34 +0000 |
| Subject: | Re: About #37799 | ||
| References: | 1 2 3 | Groups: | php.internals php.internals |
| Request: | Send a blank email to internals+get-27217@lists.php.net to get a copy of this message | ||
Hi,
Nuno Lopes wrote:
Pierre, I completely agree, user should have a real error. The problem is that ftp_ssl_connect doesn't really do the SSL connection. The silent switch is made when ftp_login() is called. If we make anyone fail, it should be ftp_login() and that would make sense. MehdiYes, I have to agree here. I would also prefer returning false on failure (as other extensions do). NunoI had a look at http://bugs.php.net/37799 and I would really like to have a little warning added upon SSL connection failure. From my understanding, the silent fall back to a normal connection is made in ftp.c at line 269, which as the bug reporter says, "leads to a false sense of security".I would instead make ftp_ssl_connect failing and returns false. I prefer functions without too much error messages for expected errors (a network connection can fail, no need to raise a warning here). Then let the user decides to try again using ftp_connect. --Pierre