Customizing string representation of data flow nodes in SARIF or CSV results for Taint Tracking
- Lingua principale
- CodeQL
- Stelle
- 10.1k
- Fork
- 2.1k
- Merge medio
- 2g 15h
- PR unite (30g)
- 141
Descrizione
Hi,
Currently, when running a cwe query such as TaintedPath (cwe 22) on a java project, I retrieve the CodeFlow for each result in the SARIF files as shown below. Is there an easy way to customize the string representation of nodes in the output, such as, in the message["text"] part for the node? For instance, for a method call I would like the string to have the format "package:class:methodname" instead of "methodname(...)" -- which is the default. Would I need to override the data flow node for this?
Thanks in advance!
```SARIF
...
"codeFlows" : [ {
"threadFlows" : [ {
"locations" : [ {
"location" : {
"physicalLocation" : {
"artifactLocation" : {
"uri" : "one-java-agent/src/main/java/com/alibaba/oneagent/AgentImpl.java",
"uriBaseId" : "%SRCROOT%",
"index" : 0
},
"region" : {
"startLine" : 81,
"startColumn" : 35,
"endColumn" : 69
}
},
"message" : {
"text" : "getFile(...) : String"
}
}
},
....
```
Guida per i contributori
Apri la guida per i contributori
Valutazione
Questa issue non è ancora stata valutata.