contentbox.modules.contentbox-deps.modules.cbantisamy.models

Class AntiSamy

lucee.Component
    extended by contentbox.modules.contentbox-deps.modules.cbantisamy.models.AntiSamy

Copyright 2005-2007 ColdBox Framework by Luis Majano and Ortus Solutions, Corp www.ortussolutions.com --- OWASP AntiSamy Project that provides XSS cleanup operations to ColdBox applications http://www.owasp.org/index.php/Category:OWASP_AntiSamy_Project http://code.google.com/p/owaspantisamy/downloads/list

Class Attributes:
  • threadsafe
  •  
  • singleton
  •  
  • synchronized : false
  •  
  • accessors : false
  •  
  • persistent : false
  •  
    Property Summary
    type property default serializable required
    any javaLoader


    • access = public
    • returntype = any
    • inject = loader@cbjavaloader
    true false
    any moduleSettings


    • access = public
    • returntype = any
    • inject = coldbox:setting:antisamy
    true false
    Constructor Summary
    init()
          Constructor.
    Method Summary
    any clean(any HTMLData, [string policyFile='ebay'], [boolean resultsObject='false'])
         clean HTML from XSS scripts using the AntiSamy project.
    any HTMLSanitizer(any HTMLData, [string policyFile='ebay'], [boolean resultsObject='false'])
         clean HTML from XSS scripts using the AntiSamy project.
    any onDIComplete()
     
    Methods inherited from class lucee.Component
    None

    Constructor Detail

    init

    public init()

    Constructor


    Property Detail

    javaLoader

    property any javaLoader

    Attributes:
    access - public
    required - false
    returntype - any
    inject - loader@cbjavaloader
    serializable - true

    moduleSettings

    property any moduleSettings

    Attributes:
    access - public
    required - false
    returntype - any
    inject - coldbox:setting:antisamy
    serializable - true

    Method Detail

    clean

    public any clean(any HTMLData, [string policyFile='ebay'], [boolean resultsObject='false'])

    clean HTML from XSS scripts using the AntiSamy project. The available policies are antisamy, ebay, myspace, slashdot, custom

    Parameters:
    HTMLData
    policyFile
    resultsObject

    HTMLSanitizer

    public any HTMLSanitizer(any HTMLData, [string policyFile='ebay'], [boolean resultsObject='false'])

    clean HTML from XSS scripts using the AntiSamy project. The available policies are antisamy, ebay, myspace, slashdot, custom

    Parameters:
    HTMLData - The html data to clean
    policyFile - The policy file to use, by default it uses the ebay policy file
    resultsObject - By default it just returns the cleaned HTML, but if this is true, it will return the actual Java results object.
    Returns:
    HTMl data or an instance of org.owasp.validator.html.CleanResults

    onDIComplete

    public any onDIComplete()