Git-Url: http://git.frugalware.org/gitweb/gitweb.cgi?p=frugalware-1.9.git;a=commitdiff;h=0bb87da47de216b65f3f121bab7b9048732d19f0
commit 0bb87da47de216b65f3f121bab7b9048732d19f0 Author: kikadf <[email protected]> Date: Fri Oct 17 10:23:15 2014 +0200 drupal7-7.22-2arcturus5-x86_64 * Fix CVE-2014-3704 diff --git a/source/network-extra/drupal7/FrugalBuild b/source/network-extra/drupal7/FrugalBuild index 645fae1..b9af52e 100644 --- a/source/network-extra/drupal7/FrugalBuild +++ b/source/network-extra/drupal7/FrugalBuild @@ -3,7 +3,7 @@ pkgname=drupal7 pkgver=7.22 -pkgrel=2arcturus4 +pkgrel=2arcturus5 pkgdesc="An open source content management platform" url="http://drupal.org" rodepends=('apache' 'php') @@ -21,12 +21,13 @@ options=('stick') # FSA fix *** source=(${source[@]} SA-CORE-2013-003.patch SA-CORE-2014-001.patch SA-CORE-2014-002.patch SA-CORE-2014-003.patch - SA-CORE-2014-004.patch) + SA-CORE-2014-004.patch SA-CORE-2014-005.patch) sha1sums=(${sha1sums[@]} '55f891eb3f4bebe75473073aad11cb843f19fcfe' \ '239b0251eac1a8dc8fb3a2368423d492df31cdea' \ 'a05c385dd251408ccef5cb7b2df115b1251473b9' \ '69ae289e73bdc43b8ac926fa7b33e1e99dcf5814' \ - 'ebda3d193d0d44741197c618db68109e7e4da694') + 'ebda3d193d0d44741197c618db68109e7e4da694' \ + '936eee8573326176efd84f0380a74aaf2de64e00') _F_cd_path="${pkgname//7/}-$pkgver" # *********** diff --git a/source/network-extra/drupal7/SA-CORE-2014-005.patch b/source/network-extra/drupal7/SA-CORE-2014-005.patch new file mode 100644 index 0000000..eadc035 --- /dev/null +++ b/source/network-extra/drupal7/SA-CORE-2014-005.patch @@ -0,0 +1,61 @@ +Reviewed-by: Gunnar Wolf <[email protected]> +Author: Stefan Horst; Drupal Security Team +Origin: https://www.drupal.org/SA-CORE-2014-005 + http://git.drupal.org/project/drupal.git Commit: 131a6f5 +Last-Update: 2014-10-15 +Applied-Upstream: Yes +Description: Fixed highly critical SQL injection. + See https://www.drupal.org/SA-CORE-2014-005, CVE-2014-3704 + +Index: drupal7/includes/database/database.inc +=================================================================== +--- drupal7.orig/includes/database/database.inc ++++ drupal7/includes/database/database.inc +@@ -717,7 +717,7 @@ abstract class DatabaseConnection extend + // to expand it out into a comma-delimited set of placeholders. + foreach (array_filter($args, 'is_array') as $key => $data) { + $new_keys = array(); +- foreach ($data as $i => $value) { ++ foreach (array_values($data) as $i => $value) { + // This assumes that there are no other placeholders that use the same + // name. For example, if the array placeholder is defined as :example + // and there is already an :example_2 placeholder, this will generate +Index: drupal7/modules/simpletest/tests/database_test.test +=================================================================== +--- drupal7.orig/modules/simpletest/tests/database_test.test ++++ drupal7/modules/simpletest/tests/database_test.test +@@ -3251,6 +3251,34 @@ class DatabaseQueryTestCase extends Data + + $this->assertEqual(count($names), 3, t('Correct number of names returned')); + } ++ ++ /** ++ * Test SQL injection via database query array arguments. ++ */ ++ public function testArrayArgumentsSQLInjection() { ++ // Attempt SQL injection and verify that it does not work. ++ $condition = array( ++ "1 ;INSERT INTO {test} SET name = 'test12345678'; -- " => '', ++ '1' => '', ++ ); ++ try { ++ db_query("SELECT * FROM {test} WHERE name = :name", array(':name' => $condition))->fetchObject(); ++ $this->fail('SQL injection attempt via array arguments should result in a PDOException.'); ++ } ++ catch (PDOException $e) { ++ $this->pass('SQL injection attempt via array arguments should result in a PDOException.'); ++ } ++ ++ // Test that the insert query that was used in the SQL injection attempt did ++ // not result in a row being inserted in the database. ++ $result = db_select('test') ++ ->condition('name', 'test12345678') ++ ->countQuery() ++ ->execute() ++ ->fetchField(); ++ $this->assertFalse($result, 'SQL injection attempt did not result in a row being inserted in the database table.'); ++ } ++ + } + + /** _______________________________________________ Frugalware-git mailing list [email protected] http://frugalware.org/mailman/listinfo/frugalware-git
