Class AntiSamy


  • public class AntiSamy
    extends java.lang.Object
    This is the only class from which the outside world should be calling. The scan() method holds the meat and potatoes of AntiSamy. The file contains a number of ways for scan()'ing depending on the accessibility of the policy file.
    Author:
    Arshan Dabirsiaghi
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static int DOM  
      static int SAX  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      CleanResults scan​(java.lang.String taintedHTML)
      The meat and potatoes.
      CleanResults scan​(java.lang.String taintedHTML, int scanType)  
      CleanResults scan​(java.lang.String taintedHTML, java.io.File policyFile)
      This method wraps scan() using the policy File object passed in.
      CleanResults scan​(java.lang.String taintedHTML, java.lang.String filename)
      This method wraps scan() using the Policy object passed in.
      CleanResults scan​(java.lang.String taintedHTML, Policy policy)
      This method wraps scan() using the Policy object passed in.
      CleanResults scan​(java.lang.String taintedHTML, Policy policy, int scanType)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait