-
-
Notifications
You must be signed in to change notification settings - Fork 943
Description
Clone Thick repo (git://github.com/marekjelen/thick.git) and checkout the "loader" branch
Install required gems (rack, rake, rspec, sinatra)
JRuby version:
jruby 1.6.7 (ruby-1.9.2-p312) (2012-02-22 3e82bc8) (Java HotSpot(TM) 64-Bit Server VM 1.7.0_04) [darwin-x86_64-java]
jruby 1.7.0.preview1 (ruby-1.9.3-p203) (2012-05-19 00c8c98) (Java HotSpot(TM) 64-Bit Server VM 1.7.0_04) [darwin-x86_64-java]
cd thick/example
jruby ../bin/thick -R
and the request end with const missing error.
Edit jruby-1.7.0.preview1/gems/rack-protection-1.2.0/lib/rack/protection.rb in the block remove starting "::" from names
use Rack::Protection::FrameOptions, options unless except.include? :frame_options
use Rack::Protection::IPSpoofing, options unless except.include? :ip_spoofing
use Rack::Protection::JsonCsrf, options unless except.include? :json_csrf
use Rack::Protection::PathTraversal, options unless except.include? :path_traversal
use Rack::Protection::RemoteToken, options unless except.include? :remote_token
use Rack::Protection::SessionHijacking, options unless except.include? :session_hijacking
use Rack::Protection::XSSHeader, options unless except.include? :xss_header
restart the server and it ends with a different error in Sinatra.
The "extreme" use-case this happens (https://github.com/marekjelen/thick/blob/loader/lib/thick/loader.rb)