VideoHelp Forum




+ Reply to Thread
Results 1 to 17 of 17
  1. Member
    Join Date
    May 2024
    Location
    France
    Search PM
    I think i have the pssh AAAAWnBzc2gAAAAA7e+LqXnWSs6jyCfc1R0h7QAAADoIARIQzn 9i+aLcIUXhUJ51ZaH3JyIkZXlKaGMzTmxkRWxrSWpvaVkyeHBj Rjh4TXpBMk56QTJNU0o5

    I think i have the headers Accept-Language: fr-FR,fr;q=0.9,en-US;q=0.8,en;q=0.7
    Origin: https://www.6play.fr
    Referer: https://www.6play.fr/
    User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/124.0.0.0 Safari/537.36

    BUt it said {"code":400,"error":true,"message":"Failed to get license: 412 "}

    the link to my video is https://www.6play.fr/top-chef-p_872/s15-e8-2-2-c_13067061 Help me pls
    Quote Quote  
  2. Member
    Join Date
    Dec 2021
    Location
    england
    Search Comp PM
    Code:
    --key ce7f62f9a2dc2145e1509e7565a1f727:de5df46bda25df958db095ee611ba4be
    Code:
    N_m3u8DL-RE -M format=mkv --key ce7f62f9a2dc2145e1509e7565a1f727:de5df46bda25df958db095ee611ba4be "https://lbcdn.6cloud.fr/resource/m6web/s/m6web/output/4/a/1/4a16dfd52c05991924a4bf9aa7d35c5e88c3024a/static/13067061_2db01202581db08e584aaee481063121_web_dash_upTo720p_720p_vbr_cae_drm_software.mpd?expiration=1715212139&scheme=https&groups%5B0%5D=m6web&token=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpYXQiOjE3MTUxNzYxMzgsIm5iZiI6MTcxNTE3NjEzOCwiZXhwIjoxNzE1MjEyMTM5LCJyX2hhc2giOiJlMjNlMjBiNDRhZjVkYzUwYmEyMmM2YzUyNzlkZWJjYmYxMzNiMjBhIn0.SyMberpblDkMj22h2HC4U7J9253mTnlR1TaH6AuyOyw
    " --save-name video
    Quote Quote  
  3. BUt it said {"code":400,"error":true,"message":"Failed to get license: 412 "}


    delete this line from the headers
    Code:
    'Content-Type': 'application/x-www-form-urlencoded',
    Quote Quote  
  4. Member
    Join Date
    May 2024
    Location
    France
    Search PM
    thank but how did you get the license url and the video is bugged with a lot of colors help me pls
    Quote Quote  
  5. Member aqzs's Avatar
    Join Date
    Mar 2024
    Location
    Paris
    Search Comp PM
    Originally Posted by yotot View Post
    thank but how did you get the license url and the video is bugged with a lot of colors help me pls
    The licence will always be the same. The part ?specConform=true is to return the response directly and not in json format.

    You can use the following script :
    Code:
    from pywidevine.cdm import Cdm
    from pywidevine.device import Device
    from pywidevine.pssh import PSSH
    import requests
    
    TOKEN = ''
    
    headers = {
        'x-dt-auth-token': TOKEN,
    }
    
    pssh = input("PSSH? ")
    pssh = PSSH(pssh)
    lic_url='https://lic.drmtoday.com/license-proxy-widevine/cenc/?specConform=true'
    
    device = Device.load(r"/Users/noham/Documents/GitHub/DRM-remover/TOOLS/WVD/xiaomi_redmi_5_plus_v5.1.0-android_701ec55d_4445_l3.wvd")
    cdm = Cdm.from_device(device)
    session_id = cdm.open()
    challenge = cdm.get_license_challenge(session_id, pssh)
    
    licence = requests.post(lic_url, headers = headers, data=challenge)
    licence.raise_for_status()
    cdm.parse_license(session_id, licence.content)
    
    for key in cdm.get_keys(session_id):
        #print(f"[{key.type}] {key.kid.hex}:{key.key.hex()}")
        if key.type=='CONTENT':
            print(f"\n--key {key.kid.hex}:{key.key.hex()}")
    
    cdm.close(session_id)
    Code:
    N_m3u8DL-RE 'https://th2-edge-01.cdn.bedrock.tech/m6web/output/4/a/1/4a16dfd52c05991924a4bf9aa7d35c5e88c3024a/static/13067061_2db01202581db08e584aaee481063121_web_dash_upTo720p_720p_vbr_cae_drm_software.mpd?st=9pQ4URwHqEZtRg34ItEJDQ&e=1715224079' --key ce7f62f9a2dc2145e1509e7565a1f727:de5df46bda25df958db095ee611ba4be -M format=mkv
    Image
    [Attachment 78945 - Click to enlarge]
    Quote Quote  
  6. Member
    Join Date
    May 2024
    Location
    France
    Search PM
    ok thanks but when i ouput my final video it is glitchy with a lot of color so help me pls
    Quote Quote  
  7. Member aqzs's Avatar
    Join Date
    Mar 2024
    Location
    Paris
    Search Comp PM
    Originally Posted by yotot View Post
    ok thanks but when i ouput my final video it is glitchy with a lot of color so help me pls
    which command did you use to decrypt the video ? are you sure about the key you used ?
    Quote Quote  
  8. Member
    Join Date
    May 2024
    Location
    France
    Search PM
    [h264 @ 0000011b1fe01840] top block unavailable for requested intra mode -1
    [h264 @ 0000011b1fe01840] error while decoding MB 0 0, bytestream 20430

    this what i got
    Quote Quote  
  9. Member
    Join Date
    May 2024
    Location
    France
    Search PM
    sorry i was using the wrong key and thaks for your help
    Quote Quote  
  10. Originally Posted by aqzs View Post
    Originally Posted by yotot View Post
    thank but how did you get the license url and the video is bugged with a lot of colors help me pls
    The licence will always be the same. The part ?specConform=true is to return the response directly and not in json format.

    You can use the following script :
    Code:
    from pywidevine.cdm import Cdm
    from pywidevine.device import Device
    from pywidevine.pssh import PSSH
    import requests
    
    TOKEN = ''
    
    headers = {
        'x-dt-auth-token': TOKEN,
    }
    
    pssh = input("PSSH? ")
    pssh = PSSH(pssh)
    lic_url='https://lic.drmtoday.com/license-proxy-widevine/cenc/?specConform=true'
    
    device = Device.load(r"/Users/noham/Documents/GitHub/DRM-remover/TOOLS/WVD/xiaomi_redmi_5_plus_v5.1.0-android_701ec55d_4445_l3.wvd")
    cdm = Cdm.from_device(device)
    session_id = cdm.open()
    challenge = cdm.get_license_challenge(session_id, pssh)
    
    licence = requests.post(lic_url, headers = headers, data=challenge)
    licence.raise_for_status()
    cdm.parse_license(session_id, licence.content)
    
    for key in cdm.get_keys(session_id):
        #print(f"[{key.type}] {key.kid.hex}:{key.key.hex()}")
        if key.type=='CONTENT':
            print(f"\n--key {key.kid.hex}:{key.key.hex()}")
    
    cdm.close(session_id)
    Code:
    N_m3u8DL-RE 'https://th2-edge-01.cdn.bedrock.tech/m6web/output/4/a/1/4a16dfd52c05991924a4bf9aa7d35c5e88c3024a/static/13067061_2db01202581db08e584aaee481063121_web_dash_upTo720p_720p_vbr_cae_drm_software.mpd?st=9pQ4URwHqEZtRg34ItEJDQ&e=1715224079' --key ce7f62f9a2dc2145e1509e7565a1f727:de5df46bda25df958db095ee611ba4be -M format=mkv
    Image
    [Attachment 78945 - Click to enlarge]
    Hello aqzs,
    again your script helped me out to get some keys from m6, see this thread.

    But now i am wondering how you guys indeed KNOW that we have to add this
    Code:
    ?specConform=true
    at this end of the license request.
    Because when i follow all the guides of this forum, i just make a POSIX curl copy of the request, post it in https://curlconverter.com/, and here is what i get:

    Image
    [Attachment 84743 - Click to enlarge]


    As you see, no "?specConform=true" in the request, so how did you come to that solution?
    Just for interest, thx
    Quote Quote  
  11. ah, aqzs disappeared several months. I don't know how or who find that param '?specConform=true'. but you can understand it as this: if you use that param, the license server will return bytes response, when you don't add that param likes you see in browser, you will get json response, you need parse it to get decryption keys. that's the difference. infact no difference, I prefer use no param one and parse json response since it never failed.
    Quote Quote  
  12. ah ok thx, and can you show me how your script looks like then?
    Quote Quote  
  13. It's straight forward; in my application it looks like:
    Code:
        # license is the return object from license request
        license_content = license.content
        try:
            # if content is returned as JSON object:
            match = re.search(r'"(CAIS.*?)"', license.content.decode('utf-8'))
            if match:
                license_content = match.group(1)
        except:
            pass
    
        cdm.parse_license(session_id, license_content)
        keys = cdm.get_keys(session_id)
        # ...
    IIRC the site rte.ie uses JSON with their license requests and responses.
    Last edited by Obo; 12th Jan 2025 at 01:50.
    Quote Quote  
  14. im not skillful on programing, so i can only give simple example, it looks like this:

    Code:
    licence = requests.post('https://lic.drmtoday.com/license-proxy-widevine/cenc/', headers=headers, data=challenge)
    license_b64 = licence.json()['license']
    cdm.parse_license(session_id, license_b64)
    Quote Quote  
  15. Yeah, that is if the license field in the returned JSON object is named "license"...
    Quote Quote  
  16. only for sites use drmtoday, yes if want to write all in one tool, Obo's method more useful.
    Quote Quote  



Similar Threads

Visit our sponsor! Try DVDFab and backup Blu-rays!