ID:               22061
 Updated by:       [EMAIL PROTECTED]
 Reported By:      [EMAIL PROTECTED]
-Status:           Closed
+Status:           Bogus
 Bug Type:         URL related
 Operating System: Linux Redhat 7.3 - 2.4.18
 PHP Version:      4.3.0
 New Comment:

not bug -> bogus.



Previous Comments:
------------------------------------------------------------------------

[2003-02-04 18:01:35] [EMAIL PROTECTED]

actually the problem is not with self signed certificates, its when the
name on the certificate doesn't match the URL used.  Since this is a
security issue, I doubt it will be changed.  I will ask on the mailing
list about what the right way to do this is.  This is not a bug

------------------------------------------------------------------------

[2003-02-04 17:51:56] [EMAIL PROTECTED]

The function file() fails when I try to open a https URL where the site
uses a self-signed certificate.

Example:

<?php

$var=file('https://mail.xalan.com');
var_dump($var);

?>

This script fails.  All that gets printed out is

bool(false)

In the apache error logs I get the following message:

[Tue Feb  4 18:10:28 2003] [error] PHP Warning:  file() [<a
href='http://www.php.net/function.file'>function.file</a>]:
php_hostconnect: connect failed in
/usr/local/apache/htdocs/test_ssl.php on line 3
[Tue Feb  4 18:10:28 2003] [error] PHP Warning: 
file(https://mail.xalan.com) [<a
href='http://www.php.net/function.file'>function.file</a>]: failed to
create stream: Connection timed out in
/usr/local/apache/htdocs/test_ssl.php on line 3

However, if I substitute the URL with a site that uses a trusted
certificate it works fine:

<?php

$var=file('https://www.wachovia.com');
var_dump($var);

?>

 './configure' '--with-apxs=/usr/local/apache/bin/apxs'
'--with-openssl=/usr/local/ssl' '--with-bz2' '--with-pspell'
'--with-db3=/usr/lib' '--enable-ftp' '--with-gd'
'--with-imap=/usr/local/imap-2002b'
'--with-imap-ssl=/usr/local/imap-2002b' '--with-ldap'
'--with-jpeg-dir=/usr/lib' '--with-xpm-dir=/usr/lib'
'--with-freetype-dir=/usr/lib' '--enable-sigchild' '--with-gettext'
'--with-mcrypt' '--with-xml' '--with-mysql=/usr/local/mysql'
'--with-mhash' '--with-zlib' '--with-dom' '--with-dom-xslt'
'--with-dom-exslt' '--with-png-dir=/usr/lib' '--enable-mime-magic'

Also my max_execution_time = 90000.  The URL loads in less than 2
seconds when I use my browser.


------------------------------------------------------------------------


-- 
Edit this bug report at http://bugs.php.net/?id=22061&edit=1

Reply via email to