Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 21 Sep 2005 17:58:06 GMT
From:      Max Belushkin <m.belushkin@fz-juelich.de>
To:        freebsd-gnats-submit@FreeBSD.org
Subject:   www/86421: Apache-2.0.54_4 PHP popen hangs
Message-ID:  <200509211758.j8LHw6go019441@www.freebsd.org>
Resent-Message-ID: <200509211800.j8LI0TsE050623@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         86421
>Category:       www
>Synopsis:       Apache-2.0.54_4 PHP popen hangs
>Confidential:   no
>Severity:       serious
>Priority:       high
>Responsible:    freebsd-www
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Wed Sep 21 18:00:29 GMT 2005
>Closed-Date:
>Last-Modified:
>Originator:     Max Belushkin
>Release:        FreeBSD 5.1
>Organization:
University of Bonn
>Environment:
FreeBSD localhost 5.1-RELEASE FreeBSD 5.1-RELEASE #0: Thu Jun  5 02:55:42 GMT 2003     root@wv1u.btc.adaptec.com:/usr/obj/usr/src/sys/GENERIC  i386
>Description:
After the upgrade to apache 2.0.54_4, the following simple PHP script freezes the apache thread: $handle=popen("/bin/cat", "w");. This only occurs on programs which request stdin input - i.e. $handle=popen("/bin/ls", "w") will not produce the above problem. Naturally, this freezes the "mail" function of PHP.
I have did portupgrade -fRr on apache2, I have done portupgrade -fPP on apache2, the problem persists in all cases.
The problem does not exist in the command-line PHP interpreter.
ps ax will report sh -c cat and cat in the process list. httpd will not fully exit until those are killed - it still takes up the port.
>How-To-Repeat:
On apache-2.0.54_4 with php4 as module:
<?php $handle=fopen("/bin/cat", "w");?>, save as, i.e., test.php, and try opening it with your browser.
The command-line php interpreter (php test.php) will work on it fine, but not the apache module.
>Fix:
      
>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200509211758.j8LHw6go019441>