ActionController::Parameters .each returns an unsafe hash
该报告还没有中文解读。
原文摘录
摘自原文(2447 字符中的一小部分)
The goal of `ActionController::Parameters`'s `permit` method (strong parameters) is to prevent accidental trust in the parameters sent by the client. We can therefore not simply create a hash of all the parameters in the params without permitting them first. When we really want to do this there is …
原文中的代码
params = ActionController::Parameters.new(city: 'Nijmegen', country: 'Netherlands', language: 'Dutch') params.to_h # ActionController::UnfilteredParameters: unable to convert unpermitted parameters to hash # from …
默认不展示报告全文。以上为简短摘录,完整复现过程请阅读原文。版权归研究员与 Ruby on Rails 所有。
时间线
- 报告提交
- 公开披露
阅读 HackerOne 原文 ↗作者 @abuisman · 版权归作者与 Ruby on Rails 所有