ID: 22213
User updated by: [EMAIL PROTECTED]
Reported By: [EMAIL PROTECTED]
Status: Open
Bug Type: cURL related
Operating System: FreeBSD 4.6-STABLE
PHP Version: 4CVS-2003-02-13 (stable)
New Comment:
Regarding notes/issues raised on bug #22112:
I made sure that apache is linking against only one copy of libssl and
libcrypto.
We have a global ErrorLog directive in the httpd.conf we're testing
with, but no VirtualHost blocks at all: it's a base conf file, and the
server doesn't even need to serve any pages for this to be a problem
for us.
Our httpd.conf conditionally turns on SSL only when the "-DSSL" flag is
present. When apache is run without that flag, it works without any
problems. It crashes only when SSL is running.
("SSLEngine on" only happens with -DSSL)
Thanks.
Previous Comments:
------------------------------------------------------------------------
[2003-02-14 08:33:47] [EMAIL PROTECTED]
The configure command:
./configure --with-apache=/usr/pair/sw/apachessl_1.3.27
--with-config-file-path=/usr/local/etc --enable-magic-quotes
--enable-bcmath --without-cdb --with-zlib-dir=/usr/local --with-gd
--without-ttf --without-msql --with-mysql=/usr/local --with-iodbc
--with-pdflib --enable-inline-optimization --disable-memory-limit
--with-db --without-gdbm --with-ndbm --without-db2 --without-dbm
--with-gettext --without-readline --with-recode
--with-openssl=/usr/local/ssl --with-mcrypt --without-db3 --enable-dba
--with-curl=/usr/local/lib --with-png-dir=/usr/local/lib
Compiling without "--with-curl" fixes the bug. Compiling curl
"--without-ssl" also does the trick.
------------------------------------------------------------------------
[2003-02-13 19:22:22] [EMAIL PROTECTED]
And the full configure line used to configure php was..?
------------------------------------------------------------------------
[2003-02-13 16:17:05] [EMAIL PROTECTED]
This bug could be related to bug #22112.
------------------------------------------------------------------------
[2003-02-13 15:56:40] [EMAIL PROTECTED]
I've reproduced this bug with PHP versions 4.2.2, and the STABLE PHP
dated Feb 13, 2003.
FreeBSD 4.6-stable
PHP 4.2.2 --with-curl
curl --with-ssl, versions 7.9.8 and 7.10.3
Apache 1.3.27 mod_ssl
OpenSSL 0.9.7, and a variety of flavors of 0.9.6.
To reproduce the bug:
* start apache
* send a HUP signal to apache's parent process (to restart it)
The server needn't serve any pages (php or otherwise) before the HUP is
sent. Apache crashes, I believe while trying to reinitialize the
mod_ssl module.
Running the same version of everything, but curl compiled
--without-ssl
makes it work correctly: the apache parent kills off its children and
spawns new ones without the parent segfaulting.
It seems to be dying inside SSL_CTX_ctrl (via SSL_CTX_set_options) when
called from apache's ssl_init_ConfigureServer, at this line:
SSL_CTX_set_options(ctx, SSL_OP_ALL);
Unfortunately, by the time it segfaults, the stack has been corrupted,
and it gets really difficult to debug.
Alan
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=22213&edit=1