2011-05-23 08:07:54 +00:00
|
|
|
require 'rack/protection'
|
|
|
|
|
|
|
|
module Rack
|
|
|
|
module Protection
|
2011-05-24 11:23:57 +00:00
|
|
|
##
|
|
|
|
# Prevented attack:: CSRF
|
|
|
|
# Supported browsers:: all
|
|
|
|
# More infos:: http://en.wikipedia.org/wiki/Cross-site_request_forgery
|
|
|
|
#
|
|
|
|
# Only accepts unsafe HTTP requests if a given access token matches the token
|
|
|
|
# included in the session *or* the request comes from the same origin.
|
|
|
|
#
|
|
|
|
# Compatible with Rails and rack-csrf.
|
|
|
|
#
|
|
|
|
# Not Yet Implemented!
|
2011-05-23 08:07:54 +00:00
|
|
|
class RemoteToken < AuthenticityToken
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|