Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Shaka player with Playready DRM report FAILED_TO_GENERATE_LICENSE_REQUEST error.(EDGE Broswer) #6763

Open
tongwu460 opened this issue Jun 6, 2024 · 4 comments
Labels
status: waiting on response Waiting on a response from the reporter(s) of the issue type: question A question from the community

Comments

@tongwu460
Copy link

tongwu460 commented Jun 6, 2024

I am using attachment(3261225582(9).zip) manifiest play with Playready DRM in Shaka Demo V4.9.2 & got below error.
Appriciate if anyone can give some suggestion why this error report & How to fix it?
DRM:Verimatrix.
Video Codecs="hev1.2.4.L153.B0"
Auido codecs="mp4a.40.2"

Shaka Error DRM.FAILED_TO_GENERATE_LICENSE_REQUEST (Failed to execute 'generateRequest' on 'MediaKeySession': Initialization data for CENC is incorrect.,TypeError: Failed to execute 'generateRequest' on 'MediaKeySession': Initialization data for CENC is incorrect.,)

image

3261225582 (9).zip

@tongwu460 tongwu460 added the type: question A question from the community label Jun 6, 2024
@tongwu460
Copy link
Author

@avelad can you pls give some suggestion?

@avelad
Copy link
Collaborator

avelad commented Jun 10, 2024

I am not an expert in PlayReady, perhaps someone else in the community can help.

@avelad avelad added the status: waiting on response Waiting on a response from the reporter(s) of the issue label Jun 11, 2024
@BucherTomas
Copy link
Contributor

@tongwu460 Your primary issue appears to be the value of ContentProtection descriptor within the mpd manifest.

As long as the descriptor consists of just cenc:pssh element as in your case, the Base64-encoded value must include the whole ISOBFF PSSH box including the PSSH header and the DRM SystemID followed by PSSH Data (in the case of PlayReady it's just XML PlayReady Header Object and its data size) while your value carries just the PSSH Data. This value must be used only with mspr:pro element of ContentProtection descriptor but not with cenc:pssh.

In other words, the value for cenc:pssh should be
AAADsnBzc2gAAAAAmgTweZhAQoarkuZb4IhflQAAA5KSAwAAAQABAIgDPABXAFIATQBIAEUAQQBEAEUAUgAgAHgAbQBsAG4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HYAZQByAGkAbQBhAHQAcgBpAHgAdQBhAHQAYwBsAG8AdQBkAC4AbgBlAHQALwBQAGwAYQB5AFIAZQBhAGQAeQAvAHIAaQBnAGgAdABzAG0AYQBuAGEAZwBlAHIALgBhAHMAbQB4ADwALwBMAFUASQBfAFUAUgBMAD4APAAvAEQAQQBUAEEAPgA8AC8AVwBSAE0ASABFAEEARABFAFIAPgA=

Decode the Base64 strings to see the difference. That is why the PlayReady Content Decryption Module considers your shorter value invalid for initialization.

Further reading https://learn.microsoft.com/en-us/playready/specifications/mpeg-dash-playready#212-including-a-playready-object-in-the-mpd and https://www.w3.org/TR/eme-initdata-cenc/#example

@shaka-bot shaka-bot removed the status: waiting on response Waiting on a response from the reporter(s) of the issue label Jun 17, 2024
@avelad avelad added the status: waiting on response Waiting on a response from the reporter(s) of the issue label Jun 17, 2024
@tongwu460
Copy link
Author

Thanks for feedback, I will do the test and feedback result asap

@shaka-bot shaka-bot removed the status: waiting on response Waiting on a response from the reporter(s) of the issue label Jun 24, 2024
@avelad avelad added the status: waiting on response Waiting on a response from the reporter(s) of the issue label Jun 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status: waiting on response Waiting on a response from the reporter(s) of the issue type: question A question from the community
Projects
None yet
Development

No branches or pull requests

4 participants