|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.owasp.validator.css.CssScanner
public class CssScanner
Encapsulates the parsing and validation of a CSS stylesheet or inline
declaration. To make use of this class, instantiate the scanner with the
desired policy and call either scanInlineSheet() or
scanStyleSheet as appropriate.
scanInlineStyle(String, String),
scanStyleSheet(String)| Constructor Summary | |
|---|---|
CssScanner(Policy policy)
Constructs a scanner based on the given policy. |
|
| Method Summary | |
|---|---|
static void |
main(String[] args)
Deprecated. |
CleanResults |
scanInlineStyle(String taintedCss,
String tagName)
Scans the contents of an inline style declaration (ex. |
CleanResults |
scanStyleSheet(String taintedCss)
Scans the contents of a full stylesheet (ex. |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public CssScanner(Policy policy)
policy - the policy to follow when scanning| Method Detail |
|---|
public CleanResults scanStyleSheet(String taintedCss)
throws ScanException
taintedCss - a String containing the contents of the CSS
stylesheet to validate
CleanResuts object containing the results of the
scan
ScanException - if an error occurs during scanning
public CleanResults scanInlineStyle(String taintedCss,
String tagName)
throws ScanException
CssScanner's policy file.
taintedCss - a String containing the contents of the CSS
stylesheet to validatetagName - the name of the tag for which this inline style was declared
CleanResuts object containing the results of the
scan
ScanException - if an error occurs during scanning
public static void main(String[] args)
throws Exception
args - unused
Exception - if any error occurs
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||