|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.jasig.portal.channels.SaferHTMLHandler
@Deprecated public class SaferHTMLHandler
ContentHandler that will produce a document that only includes a white listed list of elements, attributes and URL schemes. Only HTML that is considered to be safe from cross-site scripting attacks is passed on to the document.
| Constructor Summary | |
|---|---|
SaferHTMLHandler(Document doc,
Node root)
Deprecated. |
|
| Method Summary | |
|---|---|
void |
characters(char[] ch,
int start,
int length)
Deprecated. |
void |
endDocument()
Deprecated. |
void |
endElement(String uri,
String localName,
String qName)
Deprecated. |
void |
endPrefixMapping(String prefix)
Deprecated. |
void |
ignorableWhitespace(char[] ch,
int start,
int length)
Deprecated. |
void |
processingInstruction(String target,
String data)
Deprecated. |
static String |
sanitizeURL(String url)
Deprecated. Make sure to only allow safe URL schemes. |
void |
setDocumentLocator(Locator locator)
Deprecated. |
void |
skippedEntity(String name)
Deprecated. |
void |
startDocument()
Deprecated. |
void |
startElement(String uri,
String localName,
String qName,
Attributes atts)
Deprecated. |
void |
startPrefixMapping(String prefix,
String uri)
Deprecated. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public SaferHTMLHandler(Document doc,
Node root)
| Method Detail |
|---|
public void setDocumentLocator(Locator locator)
setDocumentLocator in interface ContentHandler
public void startDocument()
throws SAXException
startDocument in interface ContentHandlerSAXException
public void endDocument()
throws SAXException
endDocument in interface ContentHandlerSAXException
public void startPrefixMapping(String prefix,
String uri)
throws SAXException
startPrefixMapping in interface ContentHandlerSAXException
public void endPrefixMapping(String prefix)
throws SAXException
endPrefixMapping in interface ContentHandlerSAXException
public void startElement(String uri,
String localName,
String qName,
Attributes atts)
throws SAXException
startElement in interface ContentHandlerSAXException
public void endElement(String uri,
String localName,
String qName)
throws SAXException
endElement in interface ContentHandlerSAXException
public void characters(char[] ch,
int start,
int length)
throws SAXException
characters in interface ContentHandlerSAXException
public void ignorableWhitespace(char[] ch,
int start,
int length)
throws SAXException
ignorableWhitespace in interface ContentHandlerSAXException
public void processingInstruction(String target,
String data)
throws SAXException
processingInstruction in interface ContentHandlerSAXException
public void skippedEntity(String name)
throws SAXException
skippedEntity in interface ContentHandlerSAXExceptionpublic static String sanitizeURL(String url)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||