From owner-svn-ports-branches@FreeBSD.ORG Thu Mar 5 22:33:56 2015 Return-Path: Delivered-To: svn-ports-branches@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 65A84C60; Thu, 5 Mar 2015 22:33:56 +0000 (UTC) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4EFE427D; Thu, 5 Mar 2015 22:33:56 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.9/8.14.9) with ESMTP id t25MXuI2020288; Thu, 5 Mar 2015 22:33:56 GMT (envelope-from flo@FreeBSD.org) Received: (from flo@localhost) by svn.freebsd.org (8.14.9/8.14.9/Submit) id t25MXtMl020285; Thu, 5 Mar 2015 22:33:55 GMT (envelope-from flo@FreeBSD.org) Message-Id: <201503052233.t25MXtMl020285@svn.freebsd.org> X-Authentication-Warning: svn.freebsd.org: flo set sender to flo@FreeBSD.org using -f From: Florian Smeets Date: Thu, 5 Mar 2015 22:33:55 +0000 (UTC) To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-branches@freebsd.org Subject: svn commit: r380560 - in branches/2015Q1/lang/php53: . files X-SVN-Group: ports-branches MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-ports-branches@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: SVN commit messages for all the branches of the ports tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 05 Mar 2015 22:33:56 -0000 Author: flo Date: Thu Mar 5 22:33:54 2015 New Revision: 380560 URL: https://svnweb.freebsd.org/changeset/ports/380560 QAT: https://qat.redports.org/buildarchive/r380560/ Log: MFH: r379853 Add patches for - CVE-2014-8142 - CVE-2015-0231 Approved by: portmgr (erwin) Added: branches/2015Q1/lang/php53/files/patch-CVE-2014-8142.patch - copied unchanged from r379853, head/lang/php53/files/patch-CVE-2014-8142.patch branches/2015Q1/lang/php53/files/patch-CVE-2015-0231.patch - copied unchanged from r379853, head/lang/php53/files/patch-CVE-2015-0231.patch Modified: branches/2015Q1/lang/php53/Makefile Directory Properties: branches/2015Q1/ (props changed) Modified: branches/2015Q1/lang/php53/Makefile ============================================================================== --- branches/2015Q1/lang/php53/Makefile Thu Mar 5 22:31:43 2015 (r380559) +++ branches/2015Q1/lang/php53/Makefile Thu Mar 5 22:33:54 2015 (r380560) @@ -3,7 +3,7 @@ PORTNAME= php53 PORTVERSION= 5.3.29 -PORTREVISION?= 3 +PORTREVISION?= 4 CATEGORIES?= lang devel www MASTER_SITES= ${MASTER_SITE_PHP} MASTER_SITE_SUBDIR= distributions Copied: branches/2015Q1/lang/php53/files/patch-CVE-2014-8142.patch (from r379853, head/lang/php53/files/patch-CVE-2014-8142.patch) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ branches/2015Q1/lang/php53/files/patch-CVE-2014-8142.patch Thu Mar 5 22:33:54 2015 (r380560, copy of r379853, head/lang/php53/files/patch-CVE-2014-8142.patch) @@ -0,0 +1,56 @@ +Index: ext/standard/tests/serialize/bug68594.phpt +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ ext/standard/tests/serialize/bug68594.phpt 2015-02-13 11:27:34.753347966 -0500 +@@ -0,0 +1,23 @@ ++--TEST-- ++Bug #68545 Use after free vulnerability in unserialize() ++--FILE-- ++aaa = array(1,2,&$u,4,5); ++ $m->bbb = 1; ++ $m->ccc = &$u; ++ $m->ddd = str_repeat("A", $i); ++ ++ $z = serialize($m); ++ $z = str_replace("bbb", "aaa", $z); ++ $y = unserialize($z); ++ $z = serialize($y); ++} ++?> ++===DONE=== ++--EXPECTF-- ++===DONE=== +Index: ext/standard/var_unserializer.c +=================================================================== +--- ext/standard/var_unserializer.c 2015-02-13 11:27:34.793348294 -0500 ++++ ext/standard/var_unserializer.c 2015-02-13 11:27:34.753347966 -0500 +@@ -298,6 +298,9 @@ + } else { + /* object properties should include no integers */ + convert_to_string(key); ++ if (zend_symtable_find(ht, Z_STRVAL_P(key), Z_STRLEN_P(key) + 1, (void **)&old_data)==SUCCESS) { ++ var_push_dtor(var_hash, old_data); ++ } + zend_hash_update(ht, Z_STRVAL_P(key), Z_STRLEN_P(key) + 1, &data, + sizeof data, NULL); + } +Index: ext/standard/var_unserializer.re +=================================================================== +--- ext/standard/var_unserializer.re 2015-02-13 11:27:34.793348294 -0500 ++++ ext/standard/var_unserializer.re 2015-02-13 11:27:34.753347966 -0500 +@@ -304,6 +304,9 @@ + } else { + /* object properties should include no integers */ + convert_to_string(key); ++ if (zend_symtable_find(ht, Z_STRVAL_P(key), Z_STRLEN_P(key) + 1, (void **)&old_data)==SUCCESS) { ++ var_push_dtor(var_hash, old_data); ++ } + zend_hash_update(ht, Z_STRVAL_P(key), Z_STRLEN_P(key) + 1, &data, + sizeof data, NULL); + } Copied: branches/2015Q1/lang/php53/files/patch-CVE-2015-0231.patch (from r379853, head/lang/php53/files/patch-CVE-2015-0231.patch) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ branches/2015Q1/lang/php53/files/patch-CVE-2015-0231.patch Thu Mar 5 22:33:54 2015 (r380560, copy of r379853, head/lang/php53/files/patch-CVE-2015-0231.patch) @@ -0,0 +1,56 @@ +Index: ext/standard/tests/strings/bug68710.phpt +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ ext/standard/tests/strings/bug68710.phpt 2015-02-13 11:36:32.969760122 -0500 +@@ -0,0 +1,25 @@ ++--TEST-- ++Bug #68710 Use after free vulnerability in unserialize() (bypassing the ++CVE-2014-8142 fix) ++--FILE-- ++aaa = array(1,2,&$u,4,5); ++ $m->bbb = 1; ++ $m->ccc = &$u; ++ $m->ddd = str_repeat("A", $i); ++ ++ $z = serialize($m); ++ $z = str_replace("aaa", "123", $z); ++ $z = str_replace("bbb", "123", $z); ++ $y = unserialize($z); ++ $z = serialize($y); ++} ++?> ++===DONE=== ++--EXPECTF-- ++===DONE=== +Index: ext/standard/var_unserializer.c +=================================================================== +--- ext/standard/var_unserializer.c 2015-02-13 11:36:33.009760449 -0500 ++++ ext/standard/var_unserializer.c 2015-02-13 11:36:32.969760122 -0500 +@@ -298,7 +298,7 @@ + } else { + /* object properties should include no integers */ + convert_to_string(key); +- if (zend_symtable_find(ht, Z_STRVAL_P(key), Z_STRLEN_P(key) + 1, (void **)&old_data)==SUCCESS) { ++ if (zend_hash_find(ht, Z_STRVAL_P(key), Z_STRLEN_P(key) + 1, (void **)&old_data)==SUCCESS) { + var_push_dtor(var_hash, old_data); + } + zend_hash_update(ht, Z_STRVAL_P(key), Z_STRLEN_P(key) + 1, &data, +Index: ext/standard/var_unserializer.re +=================================================================== +--- ext/standard/var_unserializer.re 2015-02-13 11:36:33.009760449 -0500 ++++ ext/standard/var_unserializer.re 2015-02-13 11:36:32.969760122 -0500 +@@ -304,7 +304,7 @@ + } else { + /* object properties should include no integers */ + convert_to_string(key); +- if (zend_symtable_find(ht, Z_STRVAL_P(key), Z_STRLEN_P(key) + 1, (void **)&old_data)==SUCCESS) { ++ if (zend_hash_find(ht, Z_STRVAL_P(key), Z_STRLEN_P(key) + 1, (void **)&old_data)==SUCCESS) { + var_push_dtor(var_hash, old_data); + } + zend_hash_update(ht, Z_STRVAL_P(key), Z_STRLEN_P(key) + 1, &data,