Code:headers = { 'accept': '*/*', 'accept-language': 'en-US,en;q=0.9', 'token': '<fastly expiring drm token >', 'sec-ch-ua': '"Not_A Brand";v="8", "Chromium";v="120", "Google Chrome";v="120"', 'sec-ch-ua-mobile': '?0', 'sec-ch-ua-platform': '"Windows"', 'sec-fetch-dest': 'empty', 'sec-fetch-mode': 'cors', 'sec-fetch-site': 'cross-site', 'user-agent': 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Safari/537.36', 'content-type': 'application/x-www-form-urlencoded', } data = '<browser cdm data>'
[Attachment 76474 - Click to enlarge]
License url,
There is only 2 license requests (Method: OPTIONS and Method: POST).
Only browser cdm data in the payload ( no widevineChallenge or any other data in the payload).
[Attachment 76473 - Click to enlarge]
with pywidevine
Error:
I'm able to get the license response with WKS-KEYSCode:500 internal server error
License Response:Code:widevine_license = requests.post(url=lic_url, data=wvdecrypt.get_challenge(), headers=headers, proxies=proxies, auth=proxy_auth)
but I can't extract the decryption keys from license response received from the License Server.Code:CAIS.................................
I need help with this process.
tried ,
Error:Code:license_b64 = b64encode(widevine_license.content) wvdecrypt.update_license(license_b64) Correct, keyswvdecrypt = wvdecrypt.start_process() if Correct: return Correct, keyswvdecrypt correct, keys = WV_Function(pssh, lic_url)
protobufs==3.19.5Code:unable to parse license - check protobufs
+ Reply to Thread
Results 1 to 8 of 8
-
-
usually this error due to headers problem
Code:unable to parse license - check protobufs
-
didnt work. still unable to phrase
[Attachment 76484 - Click to enlarge]
Code:def WV_Function(pssh, lic_url, cert_b64=None): wvdecrypt = WvDecrypt(init_data_b64=pssh, cert_data_b64=cert_b64, device=deviceconfig.device_android_generic) widevine_license = requests.post(url=lic_url, data=wvdecrypt.get_challenge(), headers=headers, proxies=proxies, auth=proxy_auth) print(f"\n[+] License Request: {widevine_license.request.body}") print(f"\n[+] License Response: {widevine_license.content}") license_b64 = b64encode(widevine_license.content) wvdecrypt.update_license(license_b64) Correct, keyswvdecrypt = wvdecrypt.start_process() if Correct: return Correct, keyswvdecrypt correct, keys = WV_Function(pssh, lic_url) print() for key in keys: print('--key ' + key)
-
Your response is already in base64 so you just need a slight modification to your code
replace this:
Code:license_b64 = b64encode(widevine_license.content)
Code:license_b64 = widevine_license.content
Code:license_b64 = widevine_license.text
-
Thanks it worked !
removed everything from the headers except the 'token'
replacedCode:license_b64 = widevine_license.content
Similar Threads
-
Help w/ fetching keys - unable to parse license - check protobufs
By rentala17 in forum Video Streaming DownloadingReplies: 4Last Post: 20th Oct 2023, 01:01 -
Same PSSH, different license gives differnet keys?
By Devilman in forum Video Streaming DownloadingReplies: 8Last Post: 15th Jul 2023, 09:03 -
get decryption key from license request/response
By HORDTHIONZAC in forum Video Streaming DownloadingReplies: 26Last Post: 30th Jun 2023, 08:56 -
FairPlay License Request/Response
By Rathan in forum Video Streaming DownloadingReplies: 6Last Post: 16th Jun 2023, 09:51 -
problem getting L3 keys from eventive (unable to parse license - check pro)
By monk87 in forum Video Streaming DownloadingReplies: 7Last Post: 10th Oct 2022, 13:29