Skip to content

Commit 36213c5

Browse files
committed
Merge branch 'tob/quantum-csharp' of github.com:trailofbits/codeql into tob/quantum-csharp
2 parents 07a3032 + 69e6308 commit 36213c5

File tree

1 file changed

+23
-0
lines changed

1 file changed

+23
-0
lines changed
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
/**
2+
* @name Print CBOM Graph
3+
* @description Outputs a graph representation of the cryptographic bill of materials.
4+
* This query only supports DGML output, as CodeQL DOT output omits properties.
5+
* @kind graph
6+
* @id csharp/print-cbom-graph
7+
* @tags quantum
8+
* experimental
9+
*/
10+
11+
import experimental.quantum.Language
12+
13+
query predicate nodes(Crypto::NodeBase node, string key, string value) {
14+
Crypto::nodes_graph_impl(node, key, value)
15+
}
16+
17+
query predicate edges(Crypto::NodeBase source, Crypto::NodeBase target, string key, string value) {
18+
Crypto::edges_graph_impl(source, target, key, value)
19+
}
20+
21+
query predicate graphProperties(string key, string value) {
22+
key = "semmle.graphKind" and value = "graph"
23+
}

0 commit comments

Comments
 (0)