php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login

Patch open-basedir-without-realpath for Safe Mode/open_basedir Bug #52065

Patch version 2015-04-29 20:11 UTC

Return to Bug #52065 | Download this patch
Patch Revisions:

Developer: cmb@php.net

 main/fopen_wrappers.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/main/fopen_wrappers.c b/main/fopen_wrappers.c
index 85127c3..bb70a11 100644
--- a/main/fopen_wrappers.c
+++ b/main/fopen_wrappers.c
@@ -164,7 +164,7 @@ PHPAPI int php_check_specific_open_basedir(const char *basedir, const char *path
 	}
 
 	/* normalize and expand path */
-	if (expand_filepath(path, resolved_name) == NULL) {
+	if (expand_filepath_with_mode(path, resolved_name, NULL, 0, FALSE) == NULL) {
 		return -1;
 	}
 
 
PHP Copyright © 2001-2019 The PHP Group
All rights reserved.
Last updated: Tue Oct 22 21:01:30 2019 UTC