Re: Problem using fread with https
| From: | Curt Zirzow | Date: | Fri, 27 Aug 2004 03:30:18 +0000 |
| Subject: | Re: Problem using fread with https | ||
| References: | 1 2 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-194883@lists.php.net to get a copy of this message | ||
* Thus wrote Justin Patrin:
> On Thu, 26 Aug 2004 14:40:46 -0700, Pablo Gosse <gossep@unbc.ca> wrote:
> > Hi folks. I'm getting the following error when attempting to use
> > PEAR::HTTP_Request to check the existence of a file.
> >
> > It's throwing an error from fread on an https stream:
> >
> > Warning: fread(): SSL: fatal protocol error in
> > /u0/local/lib/php/Net/Socket.php on line 263
> >
> > Line 263 is as follows:
> >
> > return fread($this->fp, $size);
> >
> > My PHP version is 4.3.4, and it's compiled with openssl, so I can't see
> > why this is throwing an error since according to the docs as long as
> > openssl is compiled https is supported.
> >
> > Does anyone have any suggestions?
> >
>
> It's a bug in PHP. Upgrade or add a @ at the beginning of that fread()
> call. It should still work fine.
Its actually a bug in the remote server (paticularily in some
versions of IIS) not properly closing down the ssl connection
properly.
IIRC, More recent versions of PHP will issue a E_NOTICE instead of
a E_WARNING.
See:
http://bugs.php.net/23220
Curt
--
First, let me assure you that this is not one of those shady pyramid schemes
you've been hearing about. No, sir. Our model is the trapezoid!