Interface nsIApplicationReputationServiceType

A service for asynchronously querying an application reputation service based on metadata of the downloaded file.

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

  • Check if a file with this name should be treated as a binary executable, and is therefore subject to application reputation checks. Will return true if the filename's extension is either:

    • in kBinaryFileExtensions in ApplicationReputation.cpp
    • in sExecutableExts in nsLocalFileCommon.h and not in kNonBinaryExecutables in ApplicationReputation.cpp

    Parameters

    • aFilename: string

      The filename to check.

    Returns bool

  • Check if a file with this name should be treated as an executable, and should not be opened without caution. Will return true if the filename's extension is in sExecutableExts in nsLocalFileCommon.h.

    Parameters

    • aFilename: string

      The filename to check.

    Returns bool

  • Start querying the application reputation service.

    Remarks

    aCallback may not be null. onComplete is guaranteed to be called on aCallback. This function may not be called more than once with the same query object. If any of the attributes of aQuery have not been set or have been set with empty data (with the exception of sourceURI), then a valid request can still be constructed and will solicit a valid response, but won't produce any useful information.

    Parameters

    • aQuery: nsIApplicationReputationQuery

      The nsIApplicationReputationQuery containing metadata of the downloaded file.

    • aCallback: nsIApplicationReputationCallback

      The callback for receiving the results of the query.

    Returns void

Generated using TypeDoc