Skip to content

CodeQL Query to find path between source and sink and ensuring source and sink are in different json files #855

Answered by aibaars
anaapte asked this question in Q&A
Discussion options

You must be logged in to vote

CodeQL's dataflow library links dataflow steps together to form paths that start in a source and end in a sink. The dataflow library has many builtin steps that model the semantics of the analysed programming language. However, there are no steps for JSON because JSON files are typically static files without any flow. It could be that for your usecase the JSON files are not just static data. For example if you use JSON to describe the API of a webservice. In such cases you may need to define "additional flow steps" to link some node in the JSON file to a node in the program code. Once you made that step, CodeQL should be able to follow the flow further throughout the program using its bui…

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@anaapte
Comment options

Answer selected by anaapte
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants