Posted by Toby A Inkster on 02/14/07 16:31
howa wrote:
> echo file_get_contents("../temp/../test.php");
Easy way is to just check to see whether your file path matches this PCRE:
#(^|/)..(/|$)#
That is the start of the string followed by '../'; or '/../' anywhere in
the string; or '/..' at the end of the string; or the string consisting
only of '..'.
--
Toby A Inkster BSc (Hons) ARCS
Contact Me ~ http://tobyinkster.co.uk/contact
Geek of ~ HTML/SQL/Perl/PHP/Python*/Apache/Linux
* = I'm getting there!
Navigation:
[Reply to this message]
|