The GenerateSigningKeys method creates a private and public key for signing and verifying the header.
[in, out] Variant containing the private key for signing the header.
[in, out] Variant containing the public key for verifying the header signature.
This method does not return a value. If the method fails, it returns a number in the error object.
|0xC004291B||Key-pair generation failed.|
Typically, the content packager generates these keys once and stores them securely. The content packager uses the private key to sign the content header. The content packager must deliver the public key to the license issuer, who uses the public key to verify the content header signature.
If the content packager uses more than one key pair for his or her packaged files, the license issuer needs to know which public key to use for any given packaged file, which increases the complexity of sharing and managing public keys.
This method can also be used to generate key pairs for other purposes, such as license revocation.
' Create public and private signing keys. Use the private key to sign ' the content header. Share the public key with the license issuer to ' verify the signature. ' Declare variables and objects. Dim sPrivKey, sPubKey Dim KeysObj ' Create objects. Set KeysObj = Server.CreateObject("Wmrmobjs.WMRMKeys") ' Generate the public and private keys. Call KeysObj.GenerateSigningKeys (sPrivKey, sPubKey)
Version: Windows Media Rights Manager 7 SDK or later
Reference: wmrmobjs 1.0 Type Library
Platform: Windows Server 2003