[medium] devskim: DtdProcessing.Parse, or ProhibitDtd set to false, allows the XML parser to process a DTD. A DTD can declare external entities that read local files or make network requests, and can expand recursively to exhaust memory. #917

Closed
opened 2026-11-05 20:13:42 +00:00 by pruefwerk · 1 comment
Member

medium Finding

Scanner: devskim
Severity: medium
Rule: DS132782
CWE: CWE-611

Description

Do not enable external entity resolution.

Do not enable external entity resolution.: DtdProcessing.Parse, or ProhibitDtd set to false, allows the XML parser to process a DTD. A DTD can declare external entities that read local files or make network requests, and can expand recursively to exhaust memory.

Location

File: compliance-agent/rules/cra_semgrep_csharp.cs (line 129)

Code

            settings.DtdProcessing = DtdProcessing.Parse;

Remediation

Set DtdProcessing to Prohibit, as shown in the worked example in ADM.10010.


Fingerprint: d1eae0c0de42466abf6724de26b22cd527d3eb9304ac1bda186e6261189c18e7
Generated by compliance-scanner
Open in Prüfwerk / In Prüfwerk öffnen

## medium Finding **Scanner:** devskim **Severity:** medium **Rule:** DS132782 **CWE:** CWE-611 ### Description Do not enable external entity resolution. Do not enable external entity resolution.: DtdProcessing.Parse, or ProhibitDtd set to false, allows the XML parser to process a DTD. A DTD can declare external entities that read local files or make network requests, and can expand recursively to exhaust memory. ### Location **File:** `compliance-agent/rules/cra_semgrep_csharp.cs` (line 129) ### Code ``` settings.DtdProcessing = DtdProcessing.Parse; ``` ### Remediation Set DtdProcessing to Prohibit, as shown in the worked example in ADM.10010. --- *Fingerprint:* `d1eae0c0de42466abf6724de26b22cd527d3eb9304ac1bda186e6261189c18e7` *Generated by compliance-scanner* [Open in Prüfwerk / In Prüfwerk öffnen](https://pruefwerk.breakpilot.com/findings?target=6ae9aa2160f5d8045fc570a7)
pruefwerk added the severity:mediumcra:annex-ipruefwerk labels 2026-11-05 20:13:42 +00:00
Author
Member

Prüfwerk: Die Datei liegt in Testdaten (z. B. fixtures/ oder testdata/), die von der Prüfung ausgenommen sind.

The file lies in test data (such as fixtures/ or testdata/), which is left out of the scan.

**Prüfwerk:** Die Datei liegt in Testdaten (z. B. fixtures/ oder testdata/), die von der Prüfung ausgenommen sind. The file lies in test data (such as fixtures/ or testdata/), which is left out of the scan.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: platform/pruefwerk#917