Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:77670 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 90559 invoked from network); 26 Sep 2014 13:03:07 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 26 Sep 2014 13:03:07 -0000 Authentication-Results: pb1.pair.com header.from=ajf@ajf.me; sender-id=pass Authentication-Results: pb1.pair.com smtp.mail=ajf@ajf.me; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain ajf.me designates 198.187.29.245 as permitted sender) X-PHP-List-Original-Sender: ajf@ajf.me X-Host-Fingerprint: 198.187.29.245 imap11-3.ox.privateemail.com Received: from [198.187.29.245] ([198.187.29.245:48511] helo=imap11-3.ox.privateemail.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 7B/0C-27411-A0465245 for ; Fri, 26 Sep 2014 09:03:06 -0400 Received: from localhost (localhost [127.0.0.1]) by mail.privateemail.com (Postfix) with ESMTP id F2F048800D2; Fri, 26 Sep 2014 09:03:02 -0400 (EDT) X-Virus-Scanned: Debian amavisd-new at imap11.ox.privateemail.com Received: from mail.privateemail.com ([127.0.0.1]) by localhost (imap11.ox.privateemail.com [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 5NsB6qLe24W3; Fri, 26 Sep 2014 09:03:02 -0400 (EDT) Received: from oa-res-27-90.wireless.abdn.ac.uk (oa-res-27-90.wireless.abdn.ac.uk [137.50.27.90]) (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.privateemail.com (Postfix) with ESMTPSA id 9FE518800E2; Fri, 26 Sep 2014 09:03:01 -0400 (EDT) Content-Type: text/plain; charset=windows-1252 Mime-Version: 1.0 (Mac OS X Mail 7.3 \(1878.6\)) In-Reply-To: <44AEFF63-5705-44F1-98E6-1958CA0BB95D@ajf.me> Date: Fri, 26 Sep 2014 14:02:57 +0100 Cc: PHP Developers Mailing List Content-Transfer-Encoding: quoted-printable Message-ID: References: <44AEFF63-5705-44F1-98E6-1958CA0BB95D@ajf.me> To: marius adrian popa X-Mailer: Apple Mail (2.1878.6) Subject: Re: [PHP-DEV] Cases Where Bash Shellshock Does Not Apply (mod_php, php-fpm ) From: ajf@ajf.me (Andrea Faulds) On 26 Sep 2014, at 11:48, Andrea Faulds wrote: > On 26 Sep 2014, at 11:46, marius adrian popa wrote: >=20 >> Maybe we need an official stance about shellshock >=20 > Do we? As I understand it, this isn=92t a PHP-level vulnerability, and = I=92m not sure there=92s much we can reasonably do about it. Similarly = to the Heartbleed bug, control is not in our hands here. So I did a little research: 1) On many systems, /bin/sh is a symlink for bash 2) popen() uses /bin/sh 3) PHP uses popen() for its backticks, shell_exec, exec, system, = passthru and proc_open functions. To cause the bash issue, you just need an environment variable which is = set from user data. This means that almost all PHP CGI apps which use any of the Program = Execution Functions are vulnerable, and possibly many non-CGI apps if = they do anything which sets the environment variables based on user = data. I think it might be worth us putting a statement on the homepage. = PHP-level vulnerability it isn=92t, but it is a serious one. -- Andrea Faulds http://ajf.me/