johannes                                 Thu, 12 Nov 2009 15:05:03 +0000

Revision: http://svn.php.net/viewvc?view=revision&revision=290578

Log:
Fix #50063 (safe_mode_include_dir fails)

Bug: http://bugs.php.net/50063 (Open) safe_mode_include_dir fails
      
Changed paths:
    U   php/php-src/branches/PHP_5_3/main/streams/plain_wrapper.c
    U   php/php-src/branches/PHP_5_3_1/NEWS
    U   php/php-src/branches/PHP_5_3_1/main/streams/plain_wrapper.c

Modified: php/php-src/branches/PHP_5_3/main/streams/plain_wrapper.c
===================================================================
--- php/php-src/branches/PHP_5_3/main/streams/plain_wrapper.c   2009-11-12 
14:28:14 UTC (rev 290577)
+++ php/php-src/branches/PHP_5_3/main/streams/plain_wrapper.c   2009-11-12 
15:05:03 UTC (rev 290578)
@@ -988,6 +988,10 @@
                return NULL;
        }

+       if ((php_check_safe_mode_include_dir(path TSRMLS_CC)) == 0) {
+               return php_stream_fopen_rel(path, mode, opened_path, options);
+       }
+
        if ((options & ENFORCE_SAFE_MODE) && PG(safe_mode) && 
(!php_checkuid(path, mode, CHECKUID_CHECK_MODE_PARAM)))
                return NULL;


Modified: php/php-src/branches/PHP_5_3_1/NEWS
===================================================================
--- php/php-src/branches/PHP_5_3_1/NEWS 2009-11-12 14:28:14 UTC (rev 290577)
+++ php/php-src/branches/PHP_5_3_1/NEWS 2009-11-12 15:05:03 UTC (rev 290578)
@@ -1,8 +1,9 @@
 PHP                                                                        NEWS
 |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
 ?? ??? 2009, PHP 5.3.1 RC4
+- Fixed bug #50063 (safe_mode_include_dir fails). (Johannes, christian at
+  elmerot dot se)

-
 03 Nov 2009, PHP 5.3.1 RC3
 - Added "max_file_uploads" INI directive, which can be set to limit the
   number of file uploads per-request to 100 by default, to prevent possible
@@ -10,7 +11,7 @@

 - Fixed crash in com_print_typeinfo when an invalid typelib is given. (Pierre)

-- Fuxed bug #50052 (Different Hashes on Windows and Linux on wrong Salt size).
+- Fixed bug #50052 (Different Hashes on Windows and Linux on wrong Salt size).
   (Pierre)
 - Fixed bug #49908 (throwing exception in __autoload crashes when interface
   is not defined). (Felipe)

Modified: php/php-src/branches/PHP_5_3_1/main/streams/plain_wrapper.c
===================================================================
--- php/php-src/branches/PHP_5_3_1/main/streams/plain_wrapper.c 2009-11-12 
14:28:14 UTC (rev 290577)
+++ php/php-src/branches/PHP_5_3_1/main/streams/plain_wrapper.c 2009-11-12 
15:05:03 UTC (rev 290578)
@@ -988,6 +988,10 @@
                return NULL;
        }

+       if ((php_check_safe_mode_include_dir(path TSRMLS_CC)) == 0) {
+               return php_stream_fopen_rel(path, mode, opened_path, options);
+       }
+
        if ((options & ENFORCE_SAFE_MODE) && PG(safe_mode) && 
(!php_checkuid(path, mode, CHECKUID_CHECK_MODE_PARAM)))
                return NULL;


-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to