-
-
Notifications
You must be signed in to change notification settings - Fork 13
feat: XML Validator prevent parsing XXE #1063
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
43cc752
56e2966
709268a
dc13752
cc9c214
91f6d27
60cca6c
96ae065
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -48,7 +48,8 @@ async function getParser (): Promise<typeof parseXml> { | |
|
||
const xmlParseOptions: Readonly<ParserOptions> = Object.freeze({ | ||
nonet: true, | ||
compact: true | ||
compact: true, | ||
noent: true // prevent https://github.com/CycloneDX/cyclonedx-javascript-library/issues/1061 | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. noent: true means substitute entities. Omitting this option is the secure default. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. exactly. |
||
}) | ||
|
||
export class XmlValidator extends BaseValidator { | ||
|
Uh oh!
There was an error while loading. Please reload this page.