何时跳过 verify_authenticity_token
为什么人们会跳过验证并增加应用程序的安全漏洞?在只有 GET 请求的页面上禁用它是否有益?提前致谢。
Why would people skip the verification and increase the security vulnerability of their app? Is it beneficial to disable it on pages that have only GET requests? Thanks in advance.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
Rails 中的 GET 请求已跳过 CRSF 检查
http://guides.rubyonrails.org/security.html
您也可以看到该方法本身。
http://api.rubyonrails.org/classes/ActionController/RequestForgeryProtection .html#method-i-verify_authenticity_token
CRSF check is already skipped for GET request in rails
http://guides.rubyonrails.org/security.html
You can see the method itself as well.
http://api.rubyonrails.org/classes/ActionController/RequestForgeryProtection.html#method-i-verify_authenticity_token
如果您有跨域应用程序,则 authtoken 验证可能会出现错误,您可以禁用它,但当然您的应用程序将不安全。 Rails 3 中有一些开箱即用的跨域解决方案的特殊方法
If you have cross domain application you could have errors with authtoken verifying and you can disable it, but of course your application won't be secure. In rails 3 there are special methods for cross domain solution in out of box