diff options
author | Pierre Joye <pajoye@php.net> | 2007-03-14 12:06:20 +0000 |
---|---|---|
committer | Pierre Joye <pajoye@php.net> | 2007-03-14 12:06:20 +0000 |
commit | fc3a62ed48633567ccf7ccad4cd4bf01de64ccf2 (patch) | |
tree | 7f45f6a59243f076d0e488b456dfe31d580e9bda /ext/zip/php_zip.c | |
parent | 6e47537a01dee5d8973593ef3e3ac561cf93ed3d (diff) | |
download | php-git-fc3a62ed48633567ccf7ccad4cd4bf01de64ccf2.tar.gz |
- MFH: openbasedir and safemode check in ::open()
Diffstat (limited to 'ext/zip/php_zip.c')
-rw-r--r-- | ext/zip/php_zip.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/ext/zip/php_zip.c b/ext/zip/php_zip.c index 88e5e88e12..f99450e425 100644 --- a/ext/zip/php_zip.c +++ b/ext/zip/php_zip.c @@ -917,6 +917,10 @@ static ZIPARCHIVE_METHOD(open) RETURN_FALSE; } + if (OPENBASEDIR_CHECKPATH(filename)) { + RETURN_FALSE; + } + if (!expand_filepath(filename, resolved_path TSRMLS_CC)) { RETURN_FALSE; } |