From 0f8b09cf115fea94d9135a71e2189e00703b4fc2 Mon Sep 17 00:00:00 2001 From: evanweaver Date: Wed, 20 Feb 2008 04:48:59 +0000 Subject: Restore fix for path traversal issue; fix camping handler. git-svn-id: svn+ssh://rubyforge.org/var/svn/mongrel/branches/stable_1-1@964 19e92222-5c0b-0410-8929-a290d50e31e9 --- lib/mongrel/handlers.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib/mongrel') diff --git a/lib/mongrel/handlers.rb b/lib/mongrel/handlers.rb index 2a6bca4..e643025 100644 --- a/lib/mongrel/handlers.rb +++ b/lib/mongrel/handlers.rb @@ -133,7 +133,7 @@ module Mongrel req_path = File.join(@path, req_path) if @path req_path = File.expand_path req_path - if File.exist? req_path # and (!@path or req_path.index(@path) == 0) + if File.exist? req_path and (!@path or req_path.index(@path) == 0) # It exists and it's in the right location if File.directory? req_path # The request is for a directory -- cgit v1.2.3-24-ge0c7