File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed
javascript/ql/src/semmle/javascript/frameworks Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -263,13 +263,13 @@ module ClientRequest {
263
263
/** An expression that is used as a credential in a request. */
264
264
private class AuthorizationHeader extends CredentialsExpr {
265
265
AuthorizationHeader ( ) {
266
- exists ( DataFlow:: PropWrite write | write .getPropertyName ( ) = "Authorization" |
266
+ exists ( DataFlow:: PropWrite write | write .getPropertyName ( ) . regexpMatch ( "(?i)authorization" ) |
267
267
this = write .getRhs ( ) .asExpr ( )
268
268
)
269
269
or
270
270
exists ( DataFlow:: MethodCallNode call | call .getMethodName ( ) = [ "append" , "set" ] |
271
271
call .getNumArgument ( ) = 2 and
272
- call .getArgument ( 0 ) .mayHaveStringValue ( "Authorization ") and
272
+ call .getArgument ( 0 ) .getStringValue ( ) . regexpMatch ( "(?i)authorization ") and
273
273
this = call .getArgument ( 1 ) .asExpr ( )
274
274
)
275
275
}
You can’t perform that action at this time.
0 commit comments