Skip to content

Commit

Permalink
fix: use tostring to match url
Browse files Browse the repository at this point in the history
  • Loading branch information
mnaumanali94 committed Mar 11, 2024
1 parent d233da8 commit c237408
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/ruleset.ts
Original file line number Diff line number Diff line change
Expand Up @@ -717,7 +717,7 @@ export default {
"Using external resource based on user input for webhooks, file fetching from URLs, custom SSO, URL previews, or redirects, can lead to a wide variety of security issues.\n\nLearn more about Server Side Request Forgery here: https://owasp.org/API-Security/editions/2023/en/0xa7-server-side-request-forgery/",
severity: DiagnosticSeverity.Information,
given:
'$.paths..parameters[*][?(@property === "name" && (@ === "callback" || @ === "redirect" || @.match(/(_url|Url|-url)$/)))]^',
'$.paths..parameters[*][?(@property === "name" && (@ === "callback" || @ === "redirect" || @.toString().match(/(_url|Url|-url)$/)))]^',
then: {
function: undefined,
},
Expand Down

0 comments on commit c237408

Please sign in to comment.