|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.atlassian.security.xml.SecureXmlParserFactory
public final class SecureXmlParserFactory
Utility methods to produce parsers suitable for untrusted XML. These cover the core parsing APIs included
in JDK 1.6. Other factories in com.atlassian.security.xml.libs can create parsers for other libraries.
Parsers will have FEATURE_SECURE_PROCESSING enabled and be configured to ignore external resources used for, or in, DTDs.
| Method Summary | |
|---|---|
static org.xml.sax.EntityResolver |
emptyEntityResolver()
Create a new EntityResolver that will resolve every entity to an empty stream, rather
than fetching resources from the network. |
static javax.xml.parsers.DocumentBuilder |
newDocumentBuilder()
Create a new DOM DocumentBuilder suitable for parsing XML from an untrusted source. |
static javax.xml.parsers.DocumentBuilder |
newNamespaceAwareDocumentBuilder()
Create a new namespace-aware DOM DocumentBuilder suitable for parsing XML from an untrusted source. |
static org.xml.sax.XMLReader |
newNamespaceAwareXmlReader()
Create a new namespace-aware SAX XMLReader suitable for parsing XML from an untrusted source. |
static javax.xml.stream.XMLInputFactory |
newXmlInputFactory()
Create a new StAX XMLInputFactory suitable for parsing XML from an untrusted source. |
static org.xml.sax.XMLReader |
newXmlReader()
Create a new SAX XMLReader suitable for parsing XML from an untrusted source. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Method Detail |
|---|
public static javax.xml.parsers.DocumentBuilder newDocumentBuilder()
DocumentBuilder suitable for parsing XML from an untrusted source.
public static org.xml.sax.XMLReader newXmlReader()
XMLReader suitable for parsing XML from an untrusted source.
public static org.xml.sax.XMLReader newNamespaceAwareXmlReader()
XMLReader suitable for parsing XML from an untrusted source.
public static javax.xml.parsers.DocumentBuilder newNamespaceAwareDocumentBuilder()
DocumentBuilder suitable for parsing XML from an untrusted source.
public static javax.xml.stream.XMLInputFactory newXmlInputFactory()
XMLInputFactory suitable for parsing XML from an untrusted source.
public static org.xml.sax.EntityResolver emptyEntityResolver()
EntityResolver that will resolve every entity to an empty stream, rather
than fetching resources from the network.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||