Skip to content
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

Identify weak XML parser properties that could lead to XXE #209

Closed
h3xstream opened this issue Jul 20, 2016 · 1 comment
Closed

Identify weak XML parser properties that could lead to XXE #209

h3xstream opened this issue Jul 20, 2016 · 1 comment
Labels
enhancement New feature or improvement to existing detector.
Milestone

Comments

@h3xstream
Copy link
Member

Taken from SonarQube mailinglist : https://groups.google.com/forum/#!topic/sonarqube/M-u9qObOWtU

public String parseXML(InputStream input, XMLStreamReader r) {
 StringBuilder content = new StringBuilder();
 XMLInputFactory factory = XMLInputFactory.newFactory();
 factory.setProperty(XMLInputFactory.IS_SUPPORTING_EXTERNAL_ENTITIES, true);
 factory.setProperty(XMLInputFactory.SUPPORT_DTD, true);
 XMLStreamReader reader = r;

should raise two issues, because the properties from XMLInputFactory are both set true, but there are
no issues created, see a good explanation on Stackoverflow

@h3xstream h3xstream added the enhancement New feature or improvement to existing detector. label Jul 20, 2016
@h3xstream h3xstream added this to the version-1.5.0 milestone Jul 20, 2016
@h3xstream
Copy link
Member Author

Duplicate #191

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or improvement to existing detector.
Projects
None yet
Development

No branches or pull requests

1 participant