mirror of
https://github.com/github/codeql.git
synced 2026-04-27 17:55:19 +02:00
update framework tests
This commit is contained in:
@@ -22,6 +22,7 @@ activeRecordSqlExecutionRanges
|
||||
| ActiveRecord.rb:46:20:46:32 | ... + ... |
|
||||
| ActiveRecord.rb:52:16:52:28 | "name #{...}" |
|
||||
| ActiveRecord.rb:56:20:56:39 | "username = #{...}" |
|
||||
| ActiveRecord.rb:78:27:78:76 | "this is an unsafe annotation:..." |
|
||||
activeRecordModelClassMethodCalls
|
||||
| ActiveRecord.rb:2:3:2:17 | call to has_many |
|
||||
| ActiveRecord.rb:6:3:6:24 | call to belongs_to |
|
||||
@@ -44,6 +45,8 @@ activeRecordModelClassMethodCalls
|
||||
| ActiveRecord.rb:60:5:60:33 | call to find_by |
|
||||
| ActiveRecord.rb:62:5:62:34 | call to find |
|
||||
| ActiveRecord.rb:68:5:68:45 | call to delete_by |
|
||||
| ActiveRecord.rb:74:13:74:54 | call to annotate |
|
||||
| ActiveRecord.rb:78:13:78:77 | call to annotate |
|
||||
potentiallyUnsafeSqlExecutingMethodCall
|
||||
| ActiveRecord.rb:9:5:9:68 | call to find |
|
||||
| ActiveRecord.rb:19:5:19:25 | call to destroy_by |
|
||||
@@ -55,6 +58,7 @@ potentiallyUnsafeSqlExecutingMethodCall
|
||||
| ActiveRecord.rb:46:5:46:33 | call to delete_by |
|
||||
| ActiveRecord.rb:52:5:52:29 | call to order |
|
||||
| ActiveRecord.rb:56:7:56:40 | call to find_by |
|
||||
| ActiveRecord.rb:78:13:78:77 | call to annotate |
|
||||
activeRecordModelInstantiations
|
||||
| ActiveRecord.rb:9:5:9:68 | call to find | ActiveRecord.rb:5:1:15:3 | User |
|
||||
| ActiveRecord.rb:13:5:13:40 | call to find_by | ActiveRecord.rb:1:1:3:3 | UserGroup |
|
||||
|
||||
@@ -68,3 +68,13 @@ class BazController < BarController
|
||||
Admin.delete_by(params[:admin_condition])
|
||||
end
|
||||
end
|
||||
|
||||
class AnnotatedController < ActionController::Base
|
||||
def index
|
||||
users = User.annotate("this is a safe annotation")
|
||||
end
|
||||
|
||||
def unsafe_action
|
||||
users = User.annotate("this is an unsafe annotation:#{params[:comment]}")
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user