mirror of
https://github.com/php/php-src.git
synced 2024-11-24 18:34:21 +08:00
all functions based on php_stat are now safe mode aware...
This commit is contained in:
parent
a0aa59e738
commit
02e6cd022a
@ -553,6 +553,10 @@ static void php_stat(const char *filename, php_stat_len filename_length, int typ
|
||||
char *stat_sb_names[13]={"dev", "ino", "mode", "nlink", "uid", "gid", "rdev",
|
||||
"size", "atime", "mtime", "ctime", "blksize", "blocks"};
|
||||
|
||||
if (PG(safe_mode) &&(!php_checkuid(filename, NULL, CHECKUID_CHECK_FILE_AND_DIR))) {
|
||||
RETURN_FALSE;
|
||||
}
|
||||
|
||||
if (php_check_open_basedir(filename TSRMLS_CC)) {
|
||||
RETURN_FALSE;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user