Sophie

Sophie

distrib > Mandriva > cs4.0 > i586 > by-pkgid > 665b53d51b37ef4d3a9c620ff5a368c6 > files > 32

php4-4.4.4-1mlcs4.src.rpm

--- ext/imap/php_imap.c	2006-08-26 15:03:47.000000000 +0200
+++ ext/imap/php_imap.c.oden	2006-08-26 15:08:19.000000000 +0200
@@ -756,6 +756,11 @@
 	convert_to_string_ex(mailbox);
 	convert_to_string_ex(user);
 	convert_to_string_ex(passwd);
+	
+	if ((PG(open_basedir) && *PG(open_basedir) || PG(safe_mode)) &&
+	        (!php_checkuid(mailbox, NULL, CHECKUID_CHECK_FILE_AND_DIR)))
+	        RETURN_FALSE;
+	        
 	if (myargc ==4) {
 		convert_to_long_ex(options);
 		flags = Z_LVAL_PP(options);