note 21841 added to function.include

From: Date: Wed, 29 May 2002 04:57:16 +0000
Subject: note 21841 added to function.include
Groups: php.notes 
Request: Send a blank email to php-notes+get-31135@lists.php.net to get a copy of this message
following mainframe@thewatercooler.com (29-Jul-1999), I used file_exists() to check the existence of a file before include(). Evil users could still sometimes see my file structures if the file was a directory, or other kinds of files that exist but are unreadable to PHP. Suggestion: use (is_file($file) or is_link($file)) to check suitability, and the edistence check then comes free. -- http://www.php.net/manual/en/function.include.php http://master.php.net/manage/user-notes.php?action=edit+21841 http://master.php.net/manage/user-notes.php?action=delete+21841 http://master.php.net/manage/user-notes.php?action=reject+21841

« previous php.notes (#31135) next »