diff options
Diffstat (limited to 'lang/php5/patches/patch-bb')
-rw-r--r-- | lang/php5/patches/patch-bb | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/lang/php5/patches/patch-bb b/lang/php5/patches/patch-bb new file mode 100644 index 00000000000..07c69816914 --- /dev/null +++ b/lang/php5/patches/patch-bb @@ -0,0 +1,19 @@ +$NetBSD: patch-bb,v 1.1.2.2 2009/11/30 23:10:20 tron Exp $ + +Fix for http://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2009-3557: + http://svn.php.net/viewvc?view=revision&revision=288945 + http://svn.php.net/viewvc?view=revision&revision=288971 + +--- ext/standard/file.c.orig 2009-11-30 10:04:51.000000000 +0900 ++++ ext/standard/file.c +@@ -838,6 +838,10 @@ PHP_FUNCTION(tempnam) + convert_to_string_ex(arg1); + convert_to_string_ex(arg2); + ++ if (PG(safe_mode) &&(!php_checkuid(Z_STRVAL_PP(arg1), NULL, CHECKUID_ALLOW_ONLY_DIR))) { ++ RETURN_FALSE; ++ } ++ + if (php_check_open_basedir(Z_STRVAL_PP(arg1) TSRMLS_CC)) { + RETURN_FALSE; + } |