Interface nsIContentSecurityManagerType

nsIContentSecurityManager Describes an XPCOM component used to perform security checks.

Hierarchy

Methods

  • Increases the reference count for this interface. The associated instance will not be deleted unless the reference count is returned to zero.

    Returns

    The resulting reference count.

    Returns number

  • Parameters

    • aIID: object
    • Optional aInstancePtr: object

    Returns any

  • A run time mechanism for interface discovery.

    Returns

    NS_OK if the interface is supported by the associated instance, NS_NOINTERFACE if it is not.

    aInstancePtr must not be null.

    Parameters

    • aIID: object

      [in] A requested interface IID

    • aInstancePtr: object

      [out] A pointer to an interface pointer to receive the result.

    Returns void

  • Decreases the reference count for this interface. Generally, if the reference count returns to zero, the associated instance is deleted.

    Returns

    The resulting reference count.

    Returns number

  • Checks whether a channel is allowed to access the given URI and whether the channel should be openend or should be blocked consulting internal security checks like Same Origin Policy, Content Security Policy, Mixed Content Blocker, etc.

    If security checks within performSecurityCheck fail, the function throws an exception.

    Returns

    The StreamListener of the channel wrapped into CORSListenerProxy.

    Throws

    NS_ERROR_DOM_BAD_URI If accessing the URI is not allowed (e.g. prohibted by SOP)

    Throws

    NS_ERROR_CONTENT_BLOCKED If any of the security policies (CSP, Mixed content) is violated

    Parameters

    • aChannel: nsIChannel

      The channel about to be openend

    • aStreamListener: nsIStreamListener

      The Streamlistener of the channel potentially wrapped into CORSListenerProxy.

    Returns nsIStreamListener

Generated using TypeDoc