Skip to content

Commit

Permalink
fix: linter
Browse files Browse the repository at this point in the history
  • Loading branch information
elsapet committed Apr 29, 2024
1 parent fb384a6 commit c3d5e47
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions rules/ruby/rails/sql_injection.yml
Original file line number Diff line number Diff line change
Expand Up @@ -117,13 +117,15 @@ auxiliary:
scope: cursor
- id: ruby_rails_sql_injection_safe_special_arg
patterns:
- pattern: | # where(["attr = ?", params[:oops]]) or where({ attr: params[:oops] })
- pattern:
| # where(["attr = ?", params[:oops]]) or where({ attr: params[:oops] })
$<_>($<OBJECT_ARG>$<...>)
focus: OBJECT_ARG
filters:
- variable: OBJECT_ARG
detection: ruby_rails_sql_injection_safe_special_object_arg
- pattern: | # User.where(["attr = ?", params[:oops]]) or User.where({ attr: params[:oops] })
- pattern:
| # User.where(["attr = ?", params[:oops]]) or User.where({ attr: params[:oops] })
$<_>.$<_>($<OBJECT_ARG>$<...>)
focus: OBJECT_ARG
filters:
Expand Down

0 comments on commit c3d5e47

Please sign in to comment.