IWMDRMSecurity::PerformSecurityUpdate method

[The feature associated with this page, Windows Media Format 11 SDK, is a legacy feature. It has been superseded by Source Reader and Sink Writer. Source Reader and Sink Writer have been optimized for Windows 10 and Windows 11. Microsoft strongly recommends that new code use Source Reader and Sink Writer instead of Windows Media Format 11 SDK, when possible. Microsoft suggests that existing code that uses the legacy APIs be rewritten to use the new APIs if possible.]

The PerformSecurityUpdate method initiates a security update to the DRM subsystem on the local computer.

Syntax

HRESULT PerformSecurityUpdate(
  [in]  DWORD    dwFlags,
  [out] IUnknown **ppunkCancelationCookie
);

Parameters

dwFlags [in]

Update option expressed as one of the following flags.

Flag Description
WMDRM_SECURITY_PERFORM_INDIV Causes the DRM component to be individualized only if the version of the client is out of date.
WMDRM_SECURITY_PERFORM_REVOCATION_REFRESH Causes the revocation lists on the client computer to be updated.
WMDRM_SECURITY_PERFORM_FORCE_INDIV Causes the DRM component to be individualized even if the version of the client is up to date.

ppunkCancelationCookie [out]

Address of a variable that receives a pointer to an object that can be used to cancel this operation.

Return value

The method returns an HRESULT. Possible values include, but are not limited to, those in the following table.

Return code Description
S_OK
The method succeeded.

Remarks

This method executes asynchronously. It returns immediately after being called and then generates events depending on the flag set in the dwFlags parameter.

For individualization (flag set to WMDRM_SECURITY_PERFORM_INDIV or WMDRM_SECURITY_PERFORM_FORCE_INDIV), a series of MEWMDRMIndividualizationProgress events is generated followed by an MEWMDRMIndividualizationCompleted event when processing is complete. The value of each of the MEWMDRMIndividualizationProgress events obtained by calling IMFMediaEvent::GetValue is an IUnknown pointer. You can call the QueryInterface method of the retrieved IUnknown interface to get an instance of the IWMDRMIndividualizationStatus interface.

For refreshing the revocation lists (flag set to WMDRM_SECURITY_PERFORM_REVOCATION_REFRESH), an MEWMDRMREvocationDownloadCompleted event is generated when processing is complete.

Note

When PerformSecurityUpdate completes individualization, the only existing objects that will reflect the new individualized state are those that inherit from IWMDRMSecurity. All other existing objects will not be updated. You must release and re-create any other objects so that they will reflect the new individualized state.

For more information about using the asynchronous methods of the Windows Media DRM Client Extended APIs, see Using the Media Foundation Event Model.

Requirements

Requirement Value
Header
Wmdrmsdk.h
Library
Wmdrmsdk.lib

See also

Automated Component Revocation and Renewal

DRM Individualization Example

IWMDRMSecurity Interface

Performing DRM Individualization