Security - XML Parsing Vulnerable to XXE (DocumentBuilder)
Security - XML Parsing Vulnerable to XXE (SAXParser)
Security - XML Parsing Vulnerable to XXE (XMLReader)
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
Regards,
Gilbert
--
You received this message because you are subscribed to the Google Groups "SonarQube" group.
To unsubscribe from this group and stop receiving emails from it, send an email to sonarqube+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/sonarqube/f7820378-fa56-4e11-b63b-2486f0d39a0c%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.