Skip to content

Commit 058fcc1

Browse files
authored
Merge pull request #17853 from michaelnebel/csharp/madtests
C#: Re-factor test for CWE-611/UntrustedDataInsecureXml.ql to pretty print models.
2 parents b112a9b + 82ff545 commit 058fcc1

File tree

2 files changed

+7
-4
lines changed

2 files changed

+7
-4
lines changed

csharp/ql/test/query-tests/Security Features/CWE-611/UntrustedDataInsecureXml.expected

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,11 @@
1+
#select
2+
| Test.cs:11:50:11:84 | access to indexer | Test.cs:11:50:11:72 | access to property QueryString : NameValueCollection | Test.cs:11:50:11:84 | access to indexer | This insecure XML processing depends on a $@ (DTD processing is enabled with an insecure resolver). | Test.cs:11:50:11:72 | access to property QueryString | user-provided value |
13
edges
24
| Test.cs:11:50:11:72 | access to property QueryString : NameValueCollection | Test.cs:11:50:11:84 | access to indexer | provenance | |
3-
| Test.cs:11:50:11:72 | access to property QueryString : NameValueCollection | Test.cs:11:50:11:84 | access to indexer | provenance | MaD:11692 |
5+
| Test.cs:11:50:11:72 | access to property QueryString : NameValueCollection | Test.cs:11:50:11:84 | access to indexer | provenance | MaD:1 |
6+
models
7+
| 1 | Summary: System.Collections.Specialized; NameValueCollection; false; get_Item; (System.String); ; Argument[this]; ReturnValue; taint; df-generated |
48
nodes
59
| Test.cs:11:50:11:72 | access to property QueryString : NameValueCollection | semmle.label | access to property QueryString : NameValueCollection |
610
| Test.cs:11:50:11:84 | access to indexer | semmle.label | access to indexer |
711
subpaths
8-
#select
9-
| Test.cs:11:50:11:84 | access to indexer | Test.cs:11:50:11:72 | access to property QueryString : NameValueCollection | Test.cs:11:50:11:84 | access to indexer | This insecure XML processing depends on a $@ (DTD processing is enabled with an insecure resolver). | Test.cs:11:50:11:72 | access to property QueryString | user-provided value |
Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
1-
Security Features/CWE-611/UntrustedDataInsecureXml.ql
1+
query: Security Features/CWE-611/UntrustedDataInsecureXml.ql
2+
postprocess: TestUtilities/PrettyPrintModels.ql

0 commit comments

Comments
 (0)