IWMDRMNetReceiver::GetLicenseChallenge 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 GetLicenseChallenge method generates a Windows Media DRM for Network Devices license challenge that can be sent to a transmitter when requesting protected content.

Syntax

HRESULT GetLicenseChallenge(
  [in]  BSTR  bstrAction,
  [out] BYTE  **ppbLicenseChallenge,
  [out] DWORD *pcbLicenseChallenge
);

Parameters

bstrAction [in]

Action for which to generate the challenge.

ppbLicenseChallenge [out]

Address of a pointer that is set to the address of the generated challenge. When finished with this data, you must release the memory by calling CoTaskMemFree.

pcbLicenseChallenge [out]

Address of a variable that receives the size of the license challenge in bytes.

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

None.

Requirements

Requirement Value
Header
Wmdrmsdk.h

See also

IWMDRMNetReceiver Interface

IWMDRMNetReceiver::ProcessLicenseResponse