JS: add ad hoc whitelist checks as sanitizers - #230
Merged
Merged
Conversation
ghost
self-requested a review
as a code owner
September 26, 2018 06:54
xiemaisi
suggested changes
Sep 26, 2018
xiemaisi
left a comment
There was a problem hiding this comment.
I'm not averse to having a heuristic check like this, but I'm bit wary of adding it to all configurations. Could we for now just add it to the one where we observed the FP?
Also, you'll probably want to check that the substring auth of the name isn't part of unauthorized or author or similar.
Author
|
Comments addressed. |
xiemaisi
approved these changes
Sep 26, 2018
xiemaisi
left a comment
There was a problem hiding this comment.
LGTM, but a second opinion from @asger-semmle would be great.
Contributor
|
LGTM as well. I'll probably want to use this in the query I'm working on right now. |
aibaars
added a commit
that referenced
this pull request
Oct 14, 2021
enable unicode parsing in the ReDoS query
smowton
pushed a commit
to smowton/codeql
that referenced
this pull request
Feb 7, 2022
Kotlin: Extract fake overrides for now
MathiasVP
pushed a commit
to MathiasVP/ql
that referenced
this pull request
Aug 10, 2025
Sync Main (autogenerated)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds support for whitelist sanitizer calls, based on the callee name:
This is a slightly more heuristic sanitizer implementation than the existing ones, let me know if it is too heuristic.
Motivated by this FP: https://lgtm.com/projects/g/hmcts/ccd-api-gateway/snapshot/3dd64210f75c172ae64a2b471690eb9ff9dad2ee/files/app/security/cors.js?#x628dfb3697365894:1
Evaluation (internal link): no changes.