Skip to content

Commit 27f91b3

Browse files
Update javascript/ql/src/experimental/Security/CWE-347/JWTMissingSecretOrPublicKeyVerification.ql
Co-authored-by: Erik Krogh Kristensen <[email protected]>
1 parent 37f44d9 commit 27f91b3

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

javascript/ql/src/experimental/Security/CWE-347/JWTMissingSecretOrPublicKeyVerification.ql

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,11 @@
1111

1212
import javascript
1313
import DataFlow
14+
import semmle.javascript.RestrictedLocations
1415

1516
from CallNode call
1617
where
1718
call = moduleMember("jsonwebtoken", "verify").getACall() and
1819
unique(boolean b | b = call.getArgument(1).analyze().getABooleanValue()) = false
19-
select call.getStartLine(), call,
20+
select call.asExpr().(FirstLineOf),
2021
"does not verify the JWT payload with a cryptographic secret or public key."

0 commit comments

Comments
 (0)