Class IsSafeHTML

java.lang.Object
ortus.boxlang.runtime.bifs.BIF
ortus.boxlang.modules.esapi.bifs.IsSafeHTML

@BoxBIF @BoxMember(type=STRING) public class IsSafeHTML extends ortus.boxlang.runtime.bifs.BIF
  • Field Summary

    Fields inherited from class ortus.boxlang.runtime.bifs.BIF

    __functionName, __isMemberExecution, asyncService, cacheService, componentService, declaredArguments, functionService, interceptorService, moduleService, runtime
  • Constructor Summary

    Constructors
    Constructor
    Description
    Constructor
  • Method Summary

    Modifier and Type
    Method
    Description
    _invoke(ortus.boxlang.runtime.context.IBoxContext context, ortus.boxlang.runtime.scopes.ArgumentsScope arguments)
    Verifies if the HTML is safe using antisamy policy rules.

    Methods inherited from class ortus.boxlang.runtime.bifs.BIF

    announce, getDeclaredArguments, invoke

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • IsSafeHTML

      public IsSafeHTML()
      Constructor
  • Method Details

    • _invoke

      public Object _invoke(ortus.boxlang.runtime.context.IBoxContext context, ortus.boxlang.runtime.scopes.ArgumentsScope arguments)
      Verifies if the HTML is safe using antisamy policy rules. If no policy is provided, the default policy is used which is the eBay policy.

      Available policies are:

      • anythinggoes
      • ebay
      • myspace
      • slashdot
      • tinymce

      If a policy is not one of the above, it is assumed to be an absolute path to a custom policy file.

      Specified by:
      _invoke in class ortus.boxlang.runtime.bifs.BIF
      Parameters:
      context - The current Box context
      arguments - The arguments passed to the function
      Returns:
      True if the HTML is safe, false otherwise