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

Twitch VOD failed to download m3u8 info http error 403 #22677

Closed
5 of 6 tasks
sug-do opened this issue Oct 11, 2019 · 10 comments
Closed
5 of 6 tasks

Twitch VOD failed to download m3u8 info http error 403 #22677

sug-do opened this issue Oct 11, 2019 · 10 comments
Labels

Comments

@sug-do
Copy link

sug-do commented Oct 11, 2019

Checklist

  • I'm reporting a broken site support issue
  • I've verified that I'm running youtube-dl version 2019.09.28
  • I've checked that all provided URLs are alive and playable in a browser
  • I've checked that all URLs and arguments with special characters are properly quoted or escaped
  • I've searched the bugtracker for similar bug reports including closed ones
  • I've read bugs section in FAQ

Verbose log

$ youtube-dl -Fv https://www.twitch.tv/primevideo
[debug] System config: []
[debug] User config: []
[debug] Custom config: []
[debug] Command-line args: ['-Fv', 'https://www.twitch.tv/primevideo']
[debug] Encodings: locale UTF-8, fs utf-8, out UTF-8, pref UTF-8
[debug] youtube-dl version 2019.09.28
[debug] Python version 3.7.4 (CPython) - Linux-5.3.5-1-MANJARO-x86_64-with-arch-Manjaro-Linux
[debug] exe versions: ffmpeg 4.2.1, ffprobe 4.2.1, rtmpdump 2.4
[debug] Proxy map: {}
[twitch:stream] primevideo: Downloading stream JSON
[twitch:stream] primevideo: Downloading channel access token
[twitch:stream] primevideo: Downloading m3u8 information
ERROR: Failed to download m3u8 information: HTTP Error 403: Forbidden (caused by <HTTPError 403: 'Forbidden'>); please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; see  https://yt-dl.org/update  on how to update. Be sure to call youtube-dl with the --verbose flag and include its complete output.
  File "/usr/lib/python3.7/site-packages/youtube_dl/extractor/common.py", line 627, in _request_webpage
    return self._downloader.urlopen(url_or_request)
  File "/usr/lib/python3.7/site-packages/youtube_dl/YoutubeDL.py", line 2237, in urlopen
    return self._opener.open(req, timeout=self._socket_timeout)
  File "/usr/lib/python3.7/urllib/request.py", line 531, in open
    response = meth(req, response)
  File "/usr/lib/python3.7/urllib/request.py", line 641, in http_response
    'http', request, response, code, msg, hdrs)
  File "/usr/lib/python3.7/urllib/request.py", line 569, in error
    return self._call_chain(*args)
  File "/usr/lib/python3.7/urllib/request.py", line 503, in _call_chain
    result = func(*args)
  File "/usr/lib/python3.7/urllib/request.py", line 649, in http_error_default
    raise HTTPError(req.full_url, code, msg, hdrs, fp)

Description

When trying to stream https://www.twitch.tv/primevideo it results in a 403 error. The message is similar to #21538 in that it complains about m3u8 information. When loading any other stream that is live, it works as expected. Example of working stream:

$ youtube-dl -Fv https://www.twitch.tv/cdnthe3rd
[debug] System config: []
[debug] User config: []
[debug] Custom config: []
[debug] Command-line args: ['-Fv', 'https://www.twitch.tv/cdnthe3rd']
[debug] Encodings: locale UTF-8, fs utf-8, out UTF-8, pref UTF-8
[debug] youtube-dl version 2019.09.28
[debug] Python version 3.7.4 (CPython) - Linux-5.3.5-1-MANJARO-x86_64-with-arch-Manjaro-Linux
[debug] exe versions: ffmpeg 4.2.1, ffprobe 4.2.1, rtmpdump 2.4
[debug] Proxy map: {}
[twitch:stream] cdnthe3rd: Downloading stream JSON
[twitch:stream] cdnthe3rd: Downloading channel access token
[twitch:stream] cdnthe3rd: Downloading m3u8 information
[info] Available formats for 35929101600:
format code       extension  resolution note
audio_only        mp4        audio only  161k , mp4a.40.2
160p              mp4        284x160     230k , avc1.4D401F, mp4a.40.2
360p              mp4        640x360     630k , avc1.4D401F, mp4a.40.2
480p              mp4        852x480    1430k , avc1.4D401F, mp4a.40.2
720p              mp4        1280x720   2375k , avc1.4D401F, mp4a.40.2
720p60            mp4        1280x720   3425k , avc1.4D401F, mp4a.40.2
1080p60__source_  mp4        1920x1080  6882k , avc1.640032, mp4a.40.2 (best)
@sug-do
Copy link
Author

sug-do commented Oct 11, 2019

In case these are useful, I'm documenting them.
primevideo:

https://video-weaver.ord02.hls.ttvnw.net/v1/playlist/CowEorTKc04GVmh_kHHWyF8eqwRLb_D72li7N7t6EPKfqg7dnEoiDe8-35URPpI9AdIz35rwG5RB2AizWz11TG-L6yrIhDlsiX137Ve0iJoAPCKuOD0C3SEK46YvUTg7yB8z_E2ZVsJHCOsoDIqRhsgt7kqePJ4ajWJ-akbBmAdRiSTvrdezfeA4bEF7eeYZT_pAxhlUD1a83EDvdbuA8MoLicF6ivIfuEqAgw8n0I2VxpCi5WFSch_66D_2C3tZfSy-knYEskeNRdFsD2D5yTcjI2cz6gxmHYi5ur98yG6bEp5wHgHtX5sNlL9r0sL12deKimPGez7UN7NklObjOAvuth1IRFQwmqgs5h3_da8aGThnJY-HD9iQmCHVUL4FOtFHlqCmYhzvOo9cV_wnKcsnrA66oGsynfPj4wEETBCMyitBYt24gqllVFBuIAkzYAoZvXTlJdcsxioxckS6_NZTEPFxmsrxOMQkjIN4lb5KWQy26SXq8nfB96k8UI5NrvYUh6XVh5F6Fad055a3XTMZ99e-0j5J6hBenU-flHOA1NX3UaUJFlLiQ4mee24IQhfhyB_MublB7L9vqGCWxXeg_w6x_FOkXjIXh2xnjRiCUHg5lCB5VkpYfasVd3fUHaOtseiPrY4K4BVUinY5YmRzifwZehRydPRM3-qkGNF8s1CD_KMTKepqK_2LCpwSEEMoDEY9RGzPtiQU0s2cOyYaDLGA5VPLFHqMWqyL-A.m3u8

other example stream

https://video-weaver.jfk04.hls.ttvnw.net/v1/playlist/CrEEDih-m13S6cFVnYJm4BNpMacLjErAp_r23geL_mkRRrmy2-NEerM29JvHBIDODDSiSxNmAkN0y-WlSH5jCldDktpHwJAJv1PJLt6MCFvsUaTSAETNgO8uC1HYJkeO5_rmo7BYGM97ViJGnXSlrtjmMqgdRFPIRSlnRSXXJmil430byi8sehBxgOloIRj66sZelzSwwQbtVATHlh856mpi4-9iEJ2GWgcPxW19UJeAQFa5NNY8T-hPDAQjxrmiyZ1JnHgfXm1Dt1qqfUgNuz7jzbFvqOPRjQlnnt-YKaVe4sdZzJVo3FNUKU3vZwamBPyM3lh8ba9YB7EIy7YEtHX4PEZqrEJtF2OG47p_pav8LhYZ8CmM8IswTGtcuPrNdEaK5nlVvHL5CT-ix2Ep9S0jn_lQMhTdnWmxtGSojkvZUQOiKPcxR-CabFvJJarfjBUx-VMRAESZ5bEtQ6169i5FK98oZsqkoqmeIOW_HEiGTp7o0eY1tkoGK1nV91F0ICJTWR_NKBCJ6ntLu3jn0zLRCd1ZlsHjCyajCZa5I_FfPcrJnXIfH_PCQTzKWCLne6HE7P9wllI-wV3PeeeYE2vC5fld4zdvpjNWUPzhGvTJbNVuHsJLNuW7O0EsN9Ojgu9NulF7mSse6_mU54KxQhKcY2YYhr6r0UogtGHjjj2lX09Y1P_HAkVteLbJDDaZvl_MhAL1UN3cq4bTUiwDPRBxooY3F37IHbS7m1PglNm-gy9rEhCHp8DO687mXupkjIRNU_iEGgxgq5Rr4MZlhYflGwQ.m3u8

@remitamine
Copy link
Collaborator

The stream is offline now so this can't be fixed unless there is a live URL that has the same problem.

@sug-do
Copy link
Author

sug-do commented Nov 9, 2019

The stream goes live at least every Thursday night (NFL coverage). The URL will remain the same. I'll try again from my end. You should be able to replicate the same issue.

@remitamine
Copy link
Collaborator

if the stream is accessible for a short live window and timezone differences, this makes it difficult to reproduce the problem and fix it, anyway will reopen the issue if the problem persists.

@sug-do
Copy link
Author

sug-do commented Nov 10, 2019

The stream is live right now. Tried again and getting the same result for https://www.twitch.tv/primevideo URL:

youtube-dl -Fv https://www.twitch.tv/primevideo
[debug] System config: []
[debug] User config: []
[debug] Custom config: []
[debug] Command-line args: ['-Fv', 'https://www.twitch.tv/primevideo']
[debug] Encodings: locale UTF-8, fs utf-8, out UTF-8, pref UTF-8
[debug] youtube-dl version 2019.10.29
[debug] Python version 3.7.4 (CPython) - Linux-5.3.8-3-MANJARO-x86_64-with-arch-Manjaro-Linux
[debug] exe versions: ffmpeg 4.2.1, ffprobe 4.2.1, rtmpdump 2.4
[debug] Proxy map: {}
[twitch:stream] primevideo: Downloading stream JSON
[twitch:stream] primevideo: Downloading channel access token
[twitch:stream] primevideo: Downloading m3u8 information
ERROR: Failed to download m3u8 information: HTTP Error 403: Forbidden (caused by <HTTPError 403: 'Forbidden'>); please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; see  https://yt-dl.org/update  on how to update. Be sure to call youtube-dl with the --verbose flag and include its complete output.
  File "/usr/lib/python3.7/site-packages/youtube_dl/extractor/common.py", line 627, in _request_webpage
    return self._downloader.urlopen(url_or_request)
  File "/usr/lib/python3.7/site-packages/youtube_dl/YoutubeDL.py", line 2237, in urlopen
    return self._opener.open(req, timeout=self._socket_timeout)
  File "/usr/lib/python3.7/urllib/request.py", line 531, in open
    response = meth(req, response)
  File "/usr/lib/python3.7/urllib/request.py", line 641, in http_response
    'http', request, response, code, msg, hdrs)
  File "/usr/lib/python3.7/urllib/request.py", line 569, in error
    return self._call_chain(*args)
  File "/usr/lib/python3.7/urllib/request.py", line 503, in _call_chain
    result = func(*args)
  File "/usr/lib/python3.7/urllib/request.py", line 649, in http_error_default
    raise HTTPError(req.full_url, code, msg, hdrs, fp)

A different URL working:

youtube-dl -Fv https://www.twitch.tv/xqcow
[debug] System config: []
[debug] User config: []
[debug] Custom config: []
[debug] Command-line args: ['-Fv', 'https://www.twitch.tv/xqcow']
[debug] Encodings: locale UTF-8, fs utf-8, out UTF-8, pref UTF-8
[debug] youtube-dl version 2019.10.29
[debug] Python version 3.7.4 (CPython) - Linux-5.3.8-3-MANJARO-x86_64-with-arch-Manjaro-Linux
[debug] exe versions: ffmpeg 4.2.1, ffprobe 4.2.1, rtmpdump 2.4
[debug] Proxy map: {}
[twitch:stream] xqcow: Downloading stream JSON
[twitch:stream] xqcow: Downloading channel access token
[twitch:stream] xqcow: Downloading m3u8 information
[info] Available formats for 36186223456:
format code       extension  resolution note
audio_only        mp4        audio only  162k , mp4a.40.2
160p              mp4        284x160     230k , avc1.4D401F, mp4a.40.2
360p              mp4        640x360     630k , avc1.4D401F, mp4a.40.2
480p              mp4        852x480    1430k , avc1.4D401F, mp4a.40.2
720p              mp4        1280x720   2375k , avc1.4D401F, mp4a.40.2
720p60            mp4        1280x720   3425k , avc1.4D401F, mp4a.40.2
1080p60__source_  mp4        1920x1080  6888k , avc1.64002A, mp4a.40.2 (best)

@remitamine remitamine reopened this Nov 10, 2019
@remitamine
Copy link
Collaborator

remitamine commented Nov 11, 2019

DRM protected(manifest extracted after adding cdm=wv param to the manifest request):

python __main__.py https://www.twitch.tv/primevideo
[twitch:stream] primevideo: Downloading stream JSON
[twitch:stream] primevideo: Downloading channel access token
[twitch:stream] primevideo: Downloading m3u8 information
[download] Destination: primevideo 2019-11-11 00_59-36187827360.mp4
ffmpeg version n4.2.1 Copyright (c) 2000-2019 the FFmpeg developers
  built with gcc 9.2.0 (GCC)
  configuration: --prefix=/usr --disable-debug --disable-static --disable-stripping --enable-fontconfig --enable-gmp --enable-gnutls --enable-gpl --enable-ladspa --enable-libaom --enable-libass --enable-libbluray --enable-libdav1d --enable-libdrm --enable-libfreetype --enable-libfribidi --enable-libgsm --enable-libiec61883 --enable-libjack --enable-libmodplug --enable-libmp3lame --enable-libopencore_amrnb --enable-libopencore_amrwb --enable-libopenjpeg --enable-libopus --enable-libpulse --enable-libsoxr --enable-libspeex --enable-libssh --enable-libtheora --enable-libv4l2 --enable-libvidstab --enable-libvorbis --enable-libvpx --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxcb --enable-libxml2 --enable-libxvid --enable-nvdec --enable-nvenc --enable-omx --enable-shared --enable-version3
  libavutil      56. 31.100 / 56. 31.100
  libavcodec     58. 54.100 / 58. 54.100
  libavformat    58. 29.100 / 58. 29.100
  libavdevice    58.  8.100 / 58.  8.100
  libavfilter     7. 57.100 /  7. 57.100
  libswscale      5.  5.100 /  5.  5.100
  libswresample   3.  5.100 /  3.  5.100
  libpostproc    55.  5.100 / 55.  5.100
[hls @ 0x5582fa293340] Skip ('#EXT-X-VERSION:6')
[hls @ 0x5582fa293340] Skip ('#EXT-X-TWITCH-ELAPSED-SECS:5289.000')
[hls @ 0x5582fa293340] Skip ('#EXT-X-TWITCH-TOTAL-SECS:5319.000')
[hls @ 0x5582fa293340] Skip ('#EXT-X-DATERANGE:ID="source-1573430313",CLASS="twitch-stream-source",START-DATE="2019-11-10T23:58:33.028Z",END-ON-NEXT=YES,X-TV-TWITCH-STREAM-SOURCE="live"')
[hls @ 0x5582fa293340] Skip ('#EXT-X-DATERANGE:ID="trigger-1573430313",CLASS="twitch-trigger",START-DATE="2019-11-10T23:58:33.028Z",END-ON-NEXT=YES,X-TV-TWITCH-TRIGGER-URL="https://video-weaver.lhr03.hls.ttvnw.net/trigger/Cr0DNZgdK0SUiYwnJuljrOubxUpGPksb38frF9vKhb041GQMMschbBfuNIx28h5hgob9cObfWY1klmmkQnZ4Moy00N0ByzJ_SeDagda3tlOr8p_4X6CvsLofp5C-6Vu8qOgGo-o4OFkSRG94yVf8eZeS5rUgQyA9z7kHt5aFC8POl2nxPkVAzFINxKSIPd2dEVPN4dCd1BHcNp7x_rhI3BDqRSH2ef3qdPWqPmpqTpmAWp3dWHcoHy23C1QmwubpMaUbHJMHldIcG1IVHxCdbY2egrks8R6ETQ6lKttVBwYwlW6Th3n5SCw_mLoPDe2w4RDGYATTt3UVv6BE8natROhgLYIBOUhy3CBaLXa3Fxn0BYqhEXMEmYXVNj0AknuchvwZ1qDqh7q3owmCMqYB9PnKKgKYyu-U9tAIQM-WoDeISAklQBjd-oqdAt6lCn8ytxAw8qKXmudFZww9xJxNea1ojgz1YdStQShO6pSl-dKrUE7cZplQQno6BBj2KYZE3uWkoWZCeN67yXQDP01Jg9JNLhlX8XxIkjBvMKCd5wGrylStg_C_u9urAONDyfkAS3zfU1TvuOdfokAFI6x0UhIQVP-4KfTM5ZDqk45NTL-LpBoMT484aJeWSUOy8Sd8"')
[hls @ 0x5582fa293340] Skip ('#EXT-X-PROGRAM-DATE-TIME:2019-11-10T23:58:33.028Z')
[hls @ 0x5582fa293340] Skip ('#EXT-X-PROGRAM-DATE-TIME:2019-11-10T23:58:36.028Z')
[hls @ 0x5582fa293340] Skip ('#EXT-X-PROGRAM-DATE-TIME:2019-11-10T23:58:39.028Z')
[hls @ 0x5582fa293340] Skip ('#EXT-X-PROGRAM-DATE-TIME:2019-11-10T23:58:42.028Z')
[hls @ 0x5582fa293340] Skip ('#EXT-X-PROGRAM-DATE-TIME:2019-11-10T23:58:45.028Z')
[hls @ 0x5582fa293340] Skip ('#EXT-X-PROGRAM-DATE-TIME:2019-11-10T23:58:48.028Z')
[hls @ 0x5582fa293340] Skip ('#EXT-X-PROGRAM-DATE-TIME:2019-11-10T23:58:51.028Z')
[hls @ 0x5582fa293340] Skip ('#EXT-X-PROGRAM-DATE-TIME:2019-11-10T23:58:54.028Z')
[hls @ 0x5582fa293340] Skip ('#EXT-X-PROGRAM-DATE-TIME:2019-11-10T23:58:57.028Z')
[hls @ 0x5582fa293340] Skip ('#EXT-X-PROGRAM-DATE-TIME:2019-11-10T23:59:00.028Z')
[hls @ 0x5582fa293340] Opening 'https://video-edge-c67f78.lhr03.abs.hls.ttvnw.net/v1/segment/CuADIE3NIjpVvX5EWfoFgNhn2-cqJx535hdkt_TyDEQdyAMH_SpfeMZ_OvzWuo5KmUJfC5Bw2WTkMrtIdg81FsPRP4HZQ7BxO4OjZtZ7Hd4lSmh5V9VPi_wYMv_s33yDpqQCKpdgKpJd5KnXvT8Sk-hnTp-OmbmIcXrkJ7McRQQ7RgggOQ_vA9pCBucKl2mozg3Bq5HHe_uFZgM4RlQgaw-owWiWH_KBYAHuXXR8Q_P3aWW-Ai3qs5Bgk_pnbdmD6tEkXKlSZ7A9U57Nh92lHqO6F1ZdgmhaLPYdKIPw_7VQykoZxPfcwJPok36hvmhvfE7TY6HGt424DSLoAWkMVtjLTtS__AwP28_FM53TL9LmrNwWQW_Kq891EUWvrqDD2TvgerdMrUgdjcBWENa81sca2WDsBtSvYnwftkK-Lz66gl2aN1cO91rFiqTKu6mBxID91fh1jj_174ni-rK3yImqMm6Bj5BQfb0g367RNaLQ0FWzt2MLCTHzND7xL4Q8g7BDmff0ysOPTG4TDjDbvnVbslFBs9yAviSt4Kxwh4tPkKmh3lxlF1PEkQtJOc_auWWvdkZ1cjNK2CWfTrRrNjRFNjoGaTaK8UEgiwIJ_6omtXp51t0_k1HACPcVF4QbEJ8jEhBFOc4wZVowte7T0olKclCCGgzO08DFl1xMJj8ae5Q.mp4' for reading
[hls @ 0x5582fa293340] Opening 'https://video-edge-c67f78.lhr03.abs.hls.ttvnw.net/v1/segment/CuwDnMTkK-3AnAjJ8sPD34IrxTHqXxJJYKixpZb9wWZ16qLys8QUyz3IkAmVPaBQz-qyyOqYRjrefwGk1YSRV7zwuhA1naV89kHIVXjlAa_Fw9njwYqsETB_T_dXGfFb2PzIDcAMVJrW_JLFseCY2lDBb89_TBt5PHxxWoL8mnaBUdH843qcwLYTHWn87g7gN-xzWtrvyrwUYlLHP272CCkI7f3M6PqQRu2G2TSPIDzpHYHyqu4egpZfFHTxPV39es8znLpGkhyqAEhFNAUTbKAuUJUc2aN9rsbBVB71ZxeyXXE2FZVJSiclnxPOhVYBBrYy5jnNNUtEN4E39QNZb6MMx0jc9hNWW5Y13aqL5oUW74q6tiuAcrqwGoMX1eb3xcPx9TurruMzyvayHYjY3pybcP-iEJWu5dm7tYcfRuCj5gALC2ftfVAGAz8CrtkN19EoZBP7wxAmKOR8s0dOKAymJtUi5_KBb0w5ZsXdL_pPS0TQ2bocduQMPLEKJSp937Rk2QsKTglnLTfKR5yFQo88avYnBqlSPMQL5MAhCBeaGT-N5ltLfAECDagNX9e1NlYH5hK5UP2WGUXeftGtHUYt8rpTQu7VsEJAVdYzMoqkC3gSoRC_AKLc0gp-uCukYd9ysai_CjRQ2PUzROHSEhCgsaVy8Ay7nzDSqgP90ySPGgyg7SR50xxSnYRkfUA.mp4' for reading
[hls @ 0x5582fa293340] Opening 'https://video-edge-c67f78.lhr03.abs.hls.ttvnw.net/v1/segment/CuwDYrnD1lQJaWQE36ro-1QFT3-qbKU-xQcuKpNaxJ33eYPkyw4As9dwY276swE04dThtnhkPf5YU-JXpPiqKctfNOxReiDg0F2Dh07nYrnT7a2l7BGOT4WpeFnRhTDLS6IWxlbZmjSXIkcDQyhvCgZHk6bfIB0TddpG7X0eh-2kT4y6BhdDP0axuXtGBGN4jo89hq-K3kZTzZf0o7XelFCtyfbLzYBOfiQ1WfrfdJXnKe6wl8v0yOGmM-N1cHMf14tOZv75yE7F4FLUprsXV285exG9sf1QNsS3_4NgjUensaND-Dlo3AbRbsDbavr_y0yq_s3smof2mh5O-nJD-AEf1qkZuFZJu9kOXnPJB-V6Br54pP6qEXgRwc-ahLUJPBU39y0hiOJg0tla9Tt8FfC3QS2FBzDjZhraxjpaqFqfrBFHGk4I1RBEL31nRdppi9x5Z-HDkORGnNGMPxnkBwb2jXWU5mY9BBXPyMTVef5Tr50RpzaKLL8jr3fK-VmzgA8EzCAXNqOUNioLiSsq9xScqAx_wzNOXeeQQEjESd7ErE2rdQhvbGxgNOmD2GLwnrD6NqtyWFiqSuwpz1NWfFI5meR_0jLgysXV9dDLhaTsM42B56EiHTt9Ga7cQU3YdphZq0KAq7RU275w8AhiEhAUSveniGhJkhz4z-rn2EfCGgz3g8a9aMvWov0u57w.mp4' for reading
[mov,mp4,m4a,3gp,3g2,mj2 @ 0x5582fa33bdc0] Failed to seek for auxiliary info, will only parse senc atoms for encryption info
    Last message repeated 1 times
[aac @ 0x5582fa8aa6c0] Sample rate index in program config element does not match the sample rate index configured by the container.
[aac @ 0x5582fa8aa6c0] Inconsistent channel configuration.
[aac @ 0x5582fa8aa6c0] get_buffer() failed
[h264 @ 0x5582fa309ac0] top block unavailable for requested intra mode
[h264 @ 0x5582fa309ac0] error while decoding MB 1 0
[h264 @ 0x5582fa309ac0] concealing 3600 DC, 3600 AC, 3600 MV errors in I frame
[mov,mp4,m4a,3gp,3g2,mj2 @ 0x5582fa33bdc0] Failed to seek for auxiliary info, will only parse senc atoms for encryption info
    Last message repeated 1 times
[h264 @ 0x5582fa309ac0] top block unavailable for requested intra mode
[h264 @ 0x5582fa309ac0] error while decoding MB 50 0
[h264 @ 0x5582fa309ac0] concealing 3599 DC, 3599 AC, 3599 MV errors in P frame
[mov,mp4,m4a,3gp,3g2,mj2 @ 0x5582fa33bdc0] Failed to seek for auxiliary info, will only parse senc atoms for encryption info
    Last message repeated 1 times
[h264 @ 0x5582fa309ac0] negative number of zero coeffs at 31 1
[h264 @ 0x5582fa309ac0] error while decoding MB 31 1
[h264 @ 0x5582fa309ac0] concealing 3538 DC, 3538 AC, 3538 MV errors in P frame
[mov,mp4,m4a,3gp,3g2,mj2 @ 0x5582fa33bdc0] Failed to seek for auxiliary info, will only parse senc atoms for encryption info
    Last message repeated 1 times
[h264 @ 0x5582fa309ac0] out of range intra chroma pred mode
[h264 @ 0x5582fa309ac0] error while decoding MB 29 0
[h264 @ 0x5582fa309ac0] concealing 3600 DC, 3600 AC, 3600 MV errors in P frame
[mov,mp4,m4a,3gp,3g2,mj2 @ 0x5582fa33bdc0] Failed to seek for auxiliary info, will only parse senc atoms for encryption info
    Last message repeated 1 times
[h264 @ 0x5582fa309ac0] ref 4 overflow
[h264 @ 0x5582fa309ac0] error while decoding MB 21 0
[h264 @ 0x5582fa309ac0] concealing 3600 DC, 3600 AC, 3600 MV errors in P frame
[mov,mp4,m4a,3gp,3g2,mj2 @ 0x5582fa33bdc0] Failed to seek for auxiliary info, will only parse senc atoms for encryption info
    Last message repeated 1 times
[h264 @ 0x5582fa309ac0] ref 4 overflow
[h264 @ 0x5582fa309ac0] error while decoding MB 13 0
[h264 @ 0x5582fa309ac0] concealing 3600 DC, 3600 AC, 3600 MV errors in P frame
[mov,mp4,m4a,3gp,3g2,mj2 @ 0x5582fa33bdc0] Failed to seek for auxiliary info, will only parse senc atoms for encryption info
    Last message repeated 1 times
[h264 @ 0x5582fa309ac0] ref 3 overflow
[h264 @ 0x5582fa309ac0] error while decoding MB 37 0
[h264 @ 0x5582fa309ac0] concealing 3600 DC, 3600 AC, 3600 MV errors in P frame
[mov,mp4,m4a,3gp,3g2,mj2 @ 0x5582fa33bdc0] Failed to seek for auxiliary info, will only parse senc atoms for encryption info
    Last message repeated 27 times
Input #0, hls, from 'https://video-weaver.lhr03.hls.ttvnw.net/v1/playlist/Cr0DNZgdK0SUiYwnJuljrOubxUpGPksb38frF9vKhb041GQMMschbBfuNIx28h5hgob9cObfWY1klmmkQnZ4Moy00N0ByzJ_SeDagda3tlOr8p_4X6CvsLofp5C-6Vu8qOgGo-o4OFkSRG94yVf8eZeS5rUgQyA9z7kHt5aFC8POl2nxPkVAzFINxKSIPd2dEVPN4dCd1BHcNp7x_rhI3BDqRSH2ef3qdPWqPmpqTpmAWp3dWHcoHy23C1QmwubpMaUbHJMHldIcG1IVHxCdbY2egrks8R6ETQ6lKttVBwYwlW6Th3n5SCw_mLoPDe2w4RDGYATTt3UVv6BE8natROhgLYIBOUhy3CBaLXa3Fxn0BYqhEXMEmYXVNj0AknuchvwZ1qDqh7q3owmCMqYB9PnKKgKYyu-U9tAIQM-WoDeISAklQBjd-oqdAt6lCn8ytxAw8qKXmudFZww9xJxNea1ojgz1YdStQShO6pSl-dKrUE7cZplQQno6BBj2KYZE3uWkoWZCeN67yXQDP01Jg9JNLhlX8XxIkjBvMKCd5wGrylStg_C_u9urAONDyfkAS3zfU1TvuOdfokAFI6x0UhIQVP-4KfTM5ZDqk45NTL-LpBoMT484aJeWSUOy8Sd8.m3u8':
  Duration: N/A, start: 5391.033000, bitrate: 0 kb/s
  Program 0 
    Metadata:
      variant_bitrate : 0
    Stream #0:0: Audio: aac (LC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp
    Metadata:
      variant_bitrate : 0
      major_brand     : mp42
      minor_version   : 1
      compatible_brands: isommp42dashavc1iso6hlsf
    Stream #0:1: Video: h264 (Constrained Baseline) (avc1 / 0x31637661), yuv420p(tv, unknown/bt709/unknown), 1280x720, 0 kb/s, 30 tbr, 1000k tbn, 2k tbc
    Metadata:
      variant_bitrate : 0
[mp4 @ 0x5582fa8bd800] track 1: codec frame size is not set
Output #0, mp4, to 'file:primevideo 2019-11-11 00_59-36187827360.mp4.part':
  Metadata:
    encoder         : Lavf58.29.100
    Stream #0:0: Video: h264 (Constrained Baseline) (avc1 / 0x31637661), yuv420p(tv, unknown/bt709/unknown), 1280x720, q=2-31, 0 kb/s, 30 tbr, 1000k tbn, 1000k tbc
    Metadata:
      variant_bitrate : 0
    Stream #0:1: Audio: aac (LC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp
    Metadata:
      variant_bitrate : 0
      major_brand     : mp42
      minor_version   : 1
      compatible_brands: isommp42dashavc1iso6hlsf
Stream mapping:
  Stream #0:1 -> #0:0 (copy)
  Stream #0:0 -> #0:1 (copy)
Press [q] to stop, [?] for help
[mov,mp4,m4a,3gp,3g2,mj2 @ 0x5582fa33bdc0] Failed to seek for auxiliary info, will only parse senc atoms for encryption info
....

@remitamine remitamine added the DRM label Nov 11, 2019
@boulderob
Copy link

@remitamine. where are you adding the cdm=wv in your request to get this to work? i don't see it in your code paste above?

also a more general question about DRM with regards to downloading streams:

i see a lot of issue requests here being tagged as DRM. it appears that ytdl's policy is to not mess or attempt to download DRM streams. what i was wondering though is if this is just a policy decision, whether it's actually impossible to download the DRM streams or both?

what i mean is i recently saw another thread that was closed regarding 6play.fr due to DRM. i normally can load most streams and use my browser dev tools and find the appropriate metadata / manifest json / xhr files to manually download the video and subtitles files if i absolutely have to. in the case of 6play, i couldn't find any useful metadata files to do that though.

so using the 6play DRM example, 1) are you able to find the metadata files which would allow one to still download the media / subtitle files manually if one wanted to regardless of whether ytdl wants to adhere to an off-limits policy OR 2) is downloading the media files just impossible once DRM is used?

i ask for the reasons just mentioned but also more generally b/c i see different issues in the queue for different IEs download problems tagged with DRM. some of those issues are immediately closed but others are left open which leads me to believe DRM in and of itself doesn't preclude one from actually still downloading the media.

i'm mostly interested in the subtitle files more than the pure media if it matters, but i couldn't get these to work with 6play since some changes were made on their backend which seem to be related to DRM.

thx!

@remitamine
Copy link
Collaborator

remitamine commented Dec 18, 2019

where are you adding the cdm=wv in your request to get this to work? i don't see it in your code paste above?

to the query dict, but the downloaded file won't be playable.

what i was wondering though is if this is just a policy decision, whether it's actually impossible to download the DRM streams or both?

it's not impossible.
I can only list my personal reasons for not working on it:

  • it's time-consuming and requires a lot of resources.
  • all the content I'm interested in are not DRM protected, so it's not a priority for me.

are you able to find the metadata files which would allow one to still download the media / subtitle files manually if one wanted to regardless of whether ytdl wants to adhere to an off-limits policy

I can think of two options:

  • download the code, and modify sixplay.py and add a fake format when no formats are available before this call while using the --skip-download option.
  • write your own script to make this request and process the metadata returned.

some of those issues are immediately closed but others are left open.

based on:

  • availability of a workaround to access unprotected media files.
  • whether a proper error is returned when the DRM protection can be detected accurately.

i'm mostly interested in the subtitle files more than the pure media if it matters, but i couldn't get these to work with 6play since some changes were made on their backend which seem to be related to DRM.

there is an open issue related to this in #23223.

@boulderob
Copy link

thx for the thoughtful reply @remitamine. so it looks like i might still be able to do what i want to do but that it just requires more digging and triggering my custom lookup before the extract function completes and while simultaneously using --skip-download to not trigger the DRM exit to fire.

regarding what you wrote here:

write your own script to make this request and process the metadata returned.

which is this request here:

data = self._download_json(
'https://pc.middleware.6play.fr/6play/v2/platforms/m6group_web/services/%s/videos/clip_%s' % (service, video_id),
video_id, headers={
'x-customer-name': consumer_name
}, query={
'csa': 5,
'with': 'clips',
})

my guess is this is the stock "goto" url media for the "old used to work" sixplay. i normally would be able to find something like this on my own using the browser devtools network console but i'm not seeing it in the browser for recent 6play videos i'm wanting to download subs for. so the question is are you suggesting this 'request' script and more importantly the underlying url based upon reality in light of the new issues or just hunch based on the fact this used to work solidly with the old pre DRM issues and might be obfuscated under the hood?

the reason i ask b/c it would seem like that or any meaningful media url has to be made available at runtime in some other file loaded in the network console and i'm not seeing this with 6play in it's current state (ie as if they changed the underlying path / mechanism)

thx!

@remitamine
Copy link
Collaborator

i'm sure what do you mean, the request works fine regardless of whether it's used now in the browser or not, anyway, the discussion now is not related to the original issue reported here(Twitch streams), so it won't be appropriate for people watching this issue to receive unrelated notfications.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants