Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CSRF token in query string not supported #1

Closed
ghost opened this issue Aug 29, 2011 · 0 comments
Closed

CSRF token in query string not supported #1

ghost opened this issue Aug 29, 2011 · 0 comments

Comments

@ghost
Copy link

ghost commented Aug 29, 2011

In the case of JSONP calls which can only GET, it is common to use Rack::MethodOverride or similar to turn GET into other verbs as soon as it hits the middleware stack. In this scenario, it is not possible to include the CSRF token anywhere but the query string, even though the call later becomes a POST or other.

If you want to support having the token in the query string, you can check for the token using Rack::Request.params which is a union of both Rack::Request.GET & Rack::Request.POST

@baldowl baldowl closed this as completed in 07cd612 Sep 3, 2011
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant