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

Invalid LA_URL error with LA_URL specified in --playready_extra_header_data #961

Closed
kqyang opened this issue Jun 18, 2021 · 1 comment
Closed
Labels
status: archived Archived and locked; will not be updated type: bug Something isn't working correctly

Comments

@kqyang
Copy link
Collaborator

kqyang commented Jun 18, 2021

System info

Operating System: Ubuntu
Shaka Packager Version: latest

Issue and steps to reproduce the problem

Packager Command:

packager \
in=llama_aac_audio_playready.mp4,stream=audio,output=enc/llama_aac_audio_playready.mp4,drm_label=AUDIO \
in=llama_h264_baseline_240p_800_playready.mp4,stream=video,output=enc/llama_h264_baseline_240p_800_playready.mp4,drm_label=240P \
in=llama_h264_high_1080p_20000_playready.mp4,stream=video,output=enc/llama_h264_high_1080p_20000_playready.mp4,drm_label=1080P \
in=llama_h264_high_uhd_30000_playready.mp4,stream=video,output=enc/llama_h264_high_uhd_30000_playready.mp4,drm_label=UHD \
in=llama_h264_main_480p_2000_playready.mp4,stream=video,output=enc/llama_h264_main_480p_2000_playready.mp4,drm_label=480P \
in=llama_h264_main_720p_8000_playready.mp4,stream=video,output=enc/llama_h264_main_720p_8000_playready.mp4,drm_label=720P \
--enable_raw_key_encryption \
--keys label=AUDIO:key_id=30303030303030303030303030303030:key=3f0a33f34098b9e22bc078e0a1b5e854,label=240P:key_id=30303030303030303030303030303035:key=9ac3036e04ac9d2be946ed62405149bc,label=1080P:key_id=30303030303030303030303030303033:key=42466c842ac1c5439b1e0c09fbb4e1d2,label=UHD:key_id=30303030303030303030303030303037:key=79b8734fb98d275a907a6a5a150128bb,label=480P:key_id=30303030303030303030303030303031:key=78a1dc0646119707e903514d8a00735f,label=720P:key_id=30303030303030303030303030303032:key=1f379ea38c70e407f76b23ec6401caef \
--protection_systems PlayReady \
--crypto_period_duration 0 \
--clear_lead 0 \
--playready_extra_header_data '<LA_URL>https://proxy.uat.widevine.com/proxy?ck1=Pwoz80CYueIrwHjgobXoVA&amp;ck2=IvCfhLVopdAH5LHRFpQ1gQ&amp;ck3=msMDbgSsnSvpRu1iQFFJvA&amp;ck4=MUWYWCQzTsTLSsS9w+K+7w&amp;ck5=eKHcBkYRlwfpA1FNigBzXw&amp;ck6=Hzeeo4xw5Af3ayPsZAHK7w&amp;ck7=QkZshCrBxUObHgwJ+7Th0g&amp;ck8=ebhzT7mNJ1qQempaFQEouw&amp;ck9=P0PRqE7loH18NCmwyMEkqw&amp;ck10=nLcSUOeegJg/HJxEPm0kKg</LA_URL> 

What is the expected result?

Content plays.

What happens instead?

Fails to play on both Android and Shaka Player on Windows.

Android error:

Widevine Logcat (short LA_URL):
11-12 14:30:37.956  8689  8730 I KeyRequester: Init data: [B@91521ae optionalKeyRequestParameters: null
11-12 14:30:38.013  3175  8727 I DxModule_0x80000000: Initialized PlayReady DRM context: 0x5049E548 at external/DxDrm/PlayReady/Server/DxPrdyServerSdkApi.cpp(172)
11-12 14:30:38.014  3175  8727 E DxModule_0x10: PlayReady error: DRM_E_NO_URL (0x8004C05D), Can not find URL info at external/DxDrm/PlayReady/ServerSDK/../Device_PK_1.2/Source/core/drmlicacqv3.c(2840)
11-12 14:30:38.014  3175  8727 E DxModule_0x10: PlayReady error: DRM_E_NO_URL (0x8004C05D), Can not find URL info at external/DxDrm/PlayReady/ServerSDK/../Device_PK_1.2/Source/drmmanager/drmmanager.c(3015)
11-12 14:30:38.014  3175  8727 E DxModule_0x10: PlayReady error: DRM_E_NO_URL (0x8004C05D), Can not find URL info at external/DxDrm/PlayReady/ServerSDK/../Device_PK_1.2/Source/drmmanager/drmmanager.c(3198)
11-12 14:30:38.014  3175  8727 I DxModule_0x80000000: Could not retrieve LA URL from header at external/DxDrm/PlayReady/Server/DxPrdyServerSdkApi.cpp(636)
11-12 14:30:38.014  3175  8727 E DxModule_0x80000000: Returning Error Code: (0x8004C05D) at external/DxDrm/PlayReady/Server/DxPrdyServerSdkApi.cpp(637)
11-12 14:30:38.014  3175  8727 E DxModule_0x80000000: Returning Error Code: (0x8004C05D) at external/DxDrm/PlayReady/Client/IDxPrdyBaseContext.cpp(587)
11-12 14:30:38.014  3175  8727 E DxDrmModularPlugin: getKeyRequest : got invalid LA URL
11-12 14:30:38.014  3175  8727 W DxDrmModularPlugin: Unable to convert legacy status: -2147483648, defaulting to UNKNOWN
11-12 14:30:38.014  8689  8730 E MediaDrm-JNI: Illegal state exception: Failed to get key request (-2147483648)
11-12 14:30:38.016  8689  8730 D NoExceptions: Unexpected exception during test:
11-12 14:30:38.016  8689  8730 D NoExceptions: android.media.MediaDrm$MediaDrmStateException: Failed to get key request
11-12 14:30:38.016  8689  8730 D NoExceptions: 	at android.media.MediaDrm.getKeyRequest(Native Method)
11-12 14:30:38.016  8689  8730 D NoExceptions: 	at com.google.android.media.gts.videoplayer.KeyRequester.getKeyRequest(KeyRequester.java:105)
11-12 14:30:38.016  8689  8730 D NoExceptions: 	at com.google.android.media.gts.videoplayer.KeyRequester.getKeyRequest(KeyRequester.java:84)
11-12 14:30:38.016  8689  8730 D NoExceptions: 	at com.google.android.media.gts.videoplayer.KeyRequester.send(KeyRequester.java:116)
11-12 14:30:38.016  8689  8730 D NoExceptions: 	at com.google.android.media.gts.videoplayer.DrmPlayer$2.run(DrmPlayer.java:163)
11-12 14:30:38.016  8689  8730 D NoExceptions: 	at com.google.android.media.gts.videoplayer.Worker.invokeNext(Worker.java:156)
11-12 14:30:38.016  8689  8730 D NoExceptions: 	at com.google.android.media.gts.videoplayer.Worker.next(Worker.java:146)
11-12 14:30:38.016  8689  8730 D NoExceptions: 	at com.google.android.media.gts.videoplayer.Worker.access$000(Worker.java:30)
11-12 14:30:38.016  8689  8730 D NoExceptions: 	at com.google.android.media.gts.videoplayer.Worker$3.run(Worker.java:80)

Shaka Player error:

get a message that states:
"Shaka Error DRM.NO_LICENSE-SERVER-GIVEN (com.microsoft.playready)

When I click on the link, it displays Error Number: 6012 NO_LICENSE_SERVER_GIVEN
@kqyang kqyang added the type: bug Something isn't working correctly label Jun 18, 2021
@kqyang
Copy link
Collaborator Author

kqyang commented Jun 18, 2021

Passing the LA_URL in the playready_extra_header_data is creating an invalid WRMHEADER.

<WRMHEADER xmlns="http://schemas.microsoft.com/DRM/2007/03/PlayReadyHeader" version="4.0.0.0"><DATA><PROTECTINFO><KEYLEN>16</KEYLEN><ALGID>AESCTR</ALGID></PROTECTINFO><KID>MDAwMDAwMDAwMDAwMDAwMA==</KID><CHECKSUM>+uPUuAgGBes=</CHECKSUM></DATA><LA_URL>https://proxy.uat.widevine.com/proxy</LA_URL></WRMHEADER>

LA_URL should be enclosed in the element. In fact, all the playready extra data should be enclosed in DATA element.

https://docs.microsoft.com/en-us/playready/specifications/playready-header-specification

@shaka-bot shaka-bot added the status: archived Archived and locked; will not be updated label Sep 3, 2021
@shaka-project shaka-project locked and limited conversation to collaborators Sep 3, 2021
sr1990 pushed a commit to sr1990/shaka-packager that referenced this issue Feb 18, 2023
It should be enclosed in the <DATA> element.

https://docs.microsoft.com/en-us/playready/specifications/playready-header-specification

Fixes shaka-project#961.
Fixes b/173146719.

Change-Id: I7d235a44afda4a0a301e7231dc8a4e87cce124be
sr1990 pushed a commit to sr1990/shaka-packager that referenced this issue Feb 18, 2023
It should be enclosed in the <DATA> element.

https://docs.microsoft.com/en-us/playready/specifications/playready-header-specification

Fixes shaka-project#961.
Fixes b/173146719.

Change-Id: I7d235a44afda4a0a301e7231dc8a4e87cce124be
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
status: archived Archived and locked; will not be updated type: bug Something isn't working correctly
Projects
None yet
Development

No branches or pull requests

2 participants