[FFmpeg-trac] #8707(ffmpeg:new): Audio ADTS error when m3u8 playlist has id3v2 tag

FFmpeg trac at avcodec.org
Tue Jun 2 17:27:07 EEST 2020


#8707: Audio ADTS error when m3u8 playlist has id3v2 tag
-------------------------------------+-------------------------------------
             Reporter:  Anan5a       |                     Type:  defect
               Status:  new          |                 Priority:  important
            Component:  ffmpeg       |                  Version:
             Keywords:  ADTS error,  |  unspecified
  m3u8, id3v2                        |               Blocked By:
             Blocking:               |  Reproduced by developer:  0
Analyzed by developer:  0            |
-------------------------------------+-------------------------------------
 Summary of the bug:

 I'm trying to download a video from a VOD service. But when I access it
 using ffmpeg and try saving ffmpeg will fail with audio error. If i skip
 audio I can save the video, no problem.

 How to reproduce:
 {{{

     root at Debian-102-buster-64-minimal ~/mx2 # ffmpeg -i "https://<link-
 redacted>/index.m3u8?hdnea=st=1590939053~exp=1590942053~acl=/*~hmac=6b7a5de4831a50a9b7c680ef4f80f85fc60d137da166dcbe0c9ecf6aeacd9cfb"
 -c copy -y file.mkv
     ffmpeg version N-97423-g945b928730-anan5a-2020-04-21 Copyright (c)
 2000-2020 the FFmpeg developers
       built with gcc 8 (Debian 8.3.0-6)
       configuration: --extra-version=anan5a-2020-04-21 --enable-gpl
 --enable-version3 --enable-static --enable-small --enable-avisynth
 --enable-chromaprint --enable-frei0r --enable-gmp --enable-gnutls
 --enable-ladspa --enable-libaom --enable-libass --enable-libcaca --enable-
 libcdio --enable-libcodec2 --enable-libfontconfig --enable-libfreetype
 --enable-libfribidi --enable-libgme --enable-libgsm --enable-libjack
 --enable-libmodplug --enable-libmp3lame --enable-libopencore-amrnb
 --enable-libopencore-amrwb --enable-libopencore-amrwb --enable-libopenjpeg
 --enable-libopenmpt --enable-libopus --enable-libpulse --enable-librsvg
 --enable-librubberband --enable-librtmp --enable-libshine --enable-
 libsnappy --enable-libsoxr --enable-libspeex --enable-libssh --enable-
 libtesseract --enable-libtheora --enable-libtwolame --enable-libv4l2
 --enable-libvo-amrwbenc --enable-libvorbis --enable-libvpx --enable-
 libwavpack --enable-libwebp --enable-libx264 --enable-libx265 --enable-
 libxvid --enable-libxml2 --enable-libzmq --enable-libzvbi --enable-lv2
 --enable-openal --enable-opencl --enable-opengl --enable-libdrm --enable-
 nonfree --enable-libfdk-aac --enable-libbluray --enable-libzimg
       libavutil      56. 42.102 / 56. 42.102
       libavcodec     58. 80.100 / 58. 80.100
       libavformat    58. 42.101 / 58. 42.101
       libavdevice    58.  9.103 / 58.  9.103
       libavfilter     7. 79.100 /  7. 79.100
       libswscale      5.  6.101 /  5.  6.101
       libswresample   3.  6.100 /  3.  6.100
       libpostproc    55.  6.100 / 55.  6.100
     [hls @ 0x5621afe0a240] Skip ('# Created with KeyOS MultiPack
 mp4-hls.py version 1.1.0r615')
     [hls @ 0x5621afe0a240] Skip ('#EXT-X-VERSION:4')
     [hls @ 0x5621afe0a240] Skip ('# Audio')
     [hls @ 0x5621afe0a240] Skip ('# Media Playlists')
     [hls @ 0x5621afe0a240] Skip ('# I-Frame Playlists')
     [hls @ 0x5621afe0a240] Skip ('#EXT-X-I-FRAME-STREAM-INF:AVERAGE-
 BANDWIDTH=22351,BANDWIDTH=22351,CODECS="avc1.64000C",RESOLUTION=300x144,URI="media-1/hdntl=exp=1591028160~acl=%2f*~data=hdntl~hmac=8280ff33a10a7520d79d5304e0be64ebfc8377b54dacd82fba4608d5908bb5c2/iframes.m3u8?aka_me_session_id=AAAAAAAAAADAKdVeAAAAACh5C5hgA4Ne5X+a44CTGFmsLmM4wFceNVWjG0b0Dk4kE57JjHePT4kKR%2fyD6zbuB5cfMAbEX3Xc"')
     [hls @ 0x5621afe0a240] Skip ('#EXT-X-I-FRAME-STREAM-INF:AVERAGE-
 BANDWIDTH=42201,BANDWIDTH=42201,CODECS="avc1.42C01E",RESOLUTION=502x240,URI="media-2/hdntl=exp=1591028160~acl=%2f*~data=hdntl~hmac=8280ff33a10a7520d79d5304e0be64ebfc8377b54dacd82fba4608d5908bb5c2/iframes.m3u8?aka_me_session_id=AAAAAAAAAADAKdVeAAAAACh5C5hgA4Ne5X+a44CTGFmsLmM4wFceNVWjG0b0Dk4kE57JjHePT4kKR%2fyD6zbuB5cfMAbEX3Xc"')
     [hls @ 0x5621afe0a240] Skip ('#EXT-X-I-FRAME-STREAM-INF:AVERAGE-
 BANDWIDTH=78608,BANDWIDTH=78608,CODECS="avc1.42C01E",RESOLUTION=752x360,URI="media-3/hdntl=exp=1591028160~acl=%2f*~data=hdntl~hmac=8280ff33a10a7520d79d5304e0be64ebfc8377b54dacd82fba4608d5908bb5c2/iframes.m3u8?aka_me_session_id=AAAAAAAAAADAKdVeAAAAACh5C5hgA4Ne5X+a44CTGFmsLmM4wFceNVWjG0b0Dk4kE57JjHePT4kKR%2fyD6zbuB5cfMAbEX3Xc"')
     [hls @ 0x5621afe0a240] Skip ('#EXT-X-I-FRAME-STREAM-INF:AVERAGE-
 BANDWIDTH=122813,BANDWIDTH=122813,CODECS="avc1.4D401F",RESOLUTION=1004x480,URI="media-4/hdntl=exp=1591028160~acl=%2f*~data=hdntl~hmac=8280ff33a10a7520d79d5304e0be64ebfc8377b54dacd82fba4608d5908bb5c2/iframes.m3u8?aka_me_session_id=AAAAAAAAAADAKdVeAAAAACh5C5hgA4Ne5X+a44CTGFmsLmM4wFceNVWjG0b0Dk4kE57JjHePT4kKR%2fyD6zbuB5cfMAbEX3Xc"')
     [hls @ 0x5621afe0a240] Skip ('#EXT-X-I-FRAME-STREAM-INF:AVERAGE-
 BANDWIDTH=170817,BANDWIDTH=170817,CODECS="avc1.4D401F",RESOLUTION=1204x576,URI="media-5/hdntl=exp=1591028160~acl=%2f*~data=hdntl~hmac=8280ff33a10a7520d79d5304e0be64ebfc8377b54dacd82fba4608d5908bb5c2/iframes.m3u8?aka_me_session_id=AAAAAAAAAADAKdVeAAAAACh5C5hgA4Ne5X+a44CTGFmsLmM4wFceNVWjG0b0Dk4kE57JjHePT4kKR%2fyD6zbuB5cfMAbEX3Xc"')
     [hls @ 0x5621afe0a240] Skip ('#EXT-X-I-FRAME-STREAM-INF:AVERAGE-
 BANDWIDTH=255456,BANDWIDTH=255456,CODECS="avc1.64001F",RESOLUTION=1506x720,URI="media-6/hdntl=exp=1591028160~acl=%2f*~data=hdntl~hmac=8280ff33a10a7520d79d5304e0be64ebfc8377b54dacd82fba4608d5908bb5c2/iframes.m3u8?aka_me_session_id=AAAAAAAAAADAKdVeAAAAACh5C5hgA4Ne5X+a44CTGFmsLmM4wFceNVWjG0b0Dk4kE57JjHePT4kKR%2fyD6zbuB5cfMAbEX3Xc"')
     [hls @ 0x5621afe0a240] Skip ('#EXT-X-I-FRAME-STREAM-INF:AVERAGE-
 BANDWIDTH=272377,BANDWIDTH=272377,CODECS="avc1.64001F",RESOLUTION=2260x1080,URI="media-7/hdntl=exp=1591028160~acl=%2f*~data=hdntl~hmac=8280ff33a10a7520d79d5304e0be64ebfc8377b54dacd82fba4608d5908bb5c2/iframes.m3u8?aka_me_session_id=AAAAAAAAAADAKdVeAAAAACh5C5hgA4Ne5X+a44CTGFmsLmM4wFceNVWjG0b0Dk4kE57JjHePT4kKR%2fyD6zbuB5cfMAbEX3Xc"')
     [hls @ 0x5621afe0a240] Opening
 'https://<redacted>/audio/aac/en/hdntl=exp=1591028160~acl=%2f*~data=hdntl~hmac=8280ff33a10a7520d79d5304e0be64ebfc8377b54dacd82fba4608d5908bb5c2/stream.m3u8?aka_me_session_id=AAAAAAAAAADAKdVeAAAAACh5C5hgA4Ne5X+a44CTGFmsLmM4wFceNVWjG0b0Dk4kE57JjHePT4kKR%2fyD6zbuB5cfMAbEX3Xc'
 for reading
     [hls @ 0x5621afe0a240] Skip ('#EXT-X-VERSION:4')
     Input #0, hls, from
 'https://<redacted>/index.m3u8?hdnea=st=1590939053~exp=1590942053~acl=/*~hmac=6b7a5de4831a50a9b7c680ef4f80f85fc60d137da166dcbe0c9ecf6aeacd9cfb':
       Duration: 01:53:22.68, start: 0.000000, bitrate: 0 kb/s
       Program 0
         Metadata:
           variant_bitrate : 225453
         Stream #0:0(hi): Audio: aac, 48000 Hz, stereo, fltp, 4 kb/s
 (default)
         Metadata:
           variant_bitrate : 3195588
           id3v2_priv.com.apple.streaming.transportStreamTimestamp:
 \x00\x00\x00\x00\x00\x00\x00\x00
           comment         : हिन्दी
         Stream #0:1: Video: h264 ([27][0][0][0] / 0x001B), yuv420p,
 300x144 [SAR 216:215 DAR 90:43], 25 fps, 25 tbr, 90k tbn, 50 tbc
         Metadata:
           variant_bitrate : 225453
       Program 1
         Metadata:
           variant_bitrate : 380485
         Stream #0:0(hi): Audio: aac, 48000 Hz, stereo, fltp, 4 kb/s
 (default)
         Metadata:
           variant_bitrate : 3195588
           id3v2_priv.com.apple.streaming.transportStreamTimestamp:
 \x00\x00\x00\x00\x00\x00\x00\x00
           comment         : हिन्दी
         Stream #0:2: Video: h264 ([27][0][0][0] / 0x001B), yuv420p,
 502x240 [SAR 1543:1542 DAR 387293:185040], 25 tbr, 90k tbn, 50 tbc
         Metadata:
           variant_bitrate : 380485
       Program 2
         Metadata:
           variant_bitrate : 688769
         Stream #0:0(hi): Audio: aac, 48000 Hz, stereo, fltp, 4 kb/s
 (default)
         Metadata:
           variant_bitrate : 3195588
           id3v2_priv.com.apple.streaming.transportStreamTimestamp:
 \x00\x00\x00\x00\x00\x00\x00\x00
           comment         : हिन्दी
         Stream #0:3: Video: h264 ([27][0][0][0] / 0x001B), yuv420p,
 752x360 [SAR 2025:2021 DAR 90:43], 25 tbr, 90k tbn, 50 tbc
         Metadata:
           variant_bitrate : 688769
       Program 3
         Metadata:
           variant_bitrate : 893944
         Stream #0:0(hi): Audio: aac, 48000 Hz, stereo, fltp, 4 kb/s
 (default)
         Metadata:
           variant_bitrate : 3195588
           id3v2_priv.com.apple.streaming.transportStreamTimestamp:
 \x00\x00\x00\x00\x00\x00\x00\x00
           comment         : हिन्दी
         Stream #0:4: Video: h264 ([27][0][0][0] / 0x001B), yuv420p,
 1004x480 [SAR 1543:1542 DAR 387293:185040], 25 fps, 25 tbr, 90k tbn, 50
 tbc
         Metadata:
           variant_bitrate : 893944
       Program 4
         Metadata:
           variant_bitrate : 1355444
         Stream #0:0(hi): Audio: aac, 48000 Hz, stereo, fltp, 4 kb/s
 (default)
         Metadata:
           variant_bitrate : 3195588
           id3v2_priv.com.apple.streaming.transportStreamTimestamp:
 \x00\x00\x00\x00\x00\x00\x00\x00
           comment         : हिन्दी
         Stream #0:5: Video: h264 ([27][0][0][0] / 0x001B), yuv420p,
 1204x576 [SAR 2287:2284 DAR 688387:328896], 25 fps, 25 tbr, 90k tbn, 50
 tbc
         Metadata:
           variant_bitrate : 1355444
       Program 5
         Metadata:
           variant_bitrate : 2685829
         Stream #0:0(hi): Audio: aac, 48000 Hz, stereo, fltp, 4 kb/s
 (default)
         Metadata:
           variant_bitrate : 3195588
           id3v2_priv.com.apple.streaming.transportStreamTimestamp:
 \x00\x00\x00\x00\x00\x00\x00\x00
           comment         : हिन्दी
         Stream #0:6: Video: h264 ([27][0][0][0] / 0x001B), yuv420p,
 1506x720 [SAR 1543:1542 DAR 387293:185040], 25 fps, 25 tbr, 90k tbn, 50
 tbc
         Metadata:
           variant_bitrate : 2685829
       Program 6
         Metadata:
           variant_bitrate : 3195588
         Stream #0:0(hi): Audio: aac, 48000 Hz, stereo, fltp, 4 kb/s
 (default)
         Metadata:
           variant_bitrate : 3195588
           id3v2_priv.com.apple.streaming.transportStreamTimestamp:
 \x00\x00\x00\x00\x00\x00\x00\x00
           comment         : हिन्दी
         Stream #0:7: Video: h264 ([27][0][0][0] / 0x001B), yuv420p,
 2260x1080 [SAR 4096:4095 DAR 231424:110565], 25 fps, 25 tbr, 90k tbn, 50
 tbc
         Metadata:
           variant_bitrate : 3195588
     Output #0, matroska, to 'file.mkv':
       Metadata:
         encoder         : Lavf58.42.101
         Stream #0:0: Video: h264 (H264 / 0x34363248), yuv420p, 2260x1080
 [SAR 4096:4095 DAR 231424:110565], q=2-31, 25 fps, 25 tbr, 1k tbn, 90k tbc
         Metadata:
           variant_bitrate : 3195588
         Stream #0:1(hi): Audio: aac ([255][0][0][0] / 0x00FF), 48000 Hz,
 stereo, fltp, 4 kb/s (default)
         Metadata:
           variant_bitrate : 3195588
           id3v2_priv.com.apple.streaming.transportStreamTimestamp:
 \x00\x00\x00\x00\x00\x00\x00\x00
           comment         : हिन्दी
     Stream mapping:
       Stream #0:7 -> #0:0 (copy)
       Stream #0:0 -> #0:1 (copy)
     Press [q] to stop, [?] for help
     [hls @ 0x5621afe0a240] Opening
 'crypto+https://<redacted>/audio/aac/en/hdntl=exp=1591028160~acl=%2f*~data=hdntl~hmac=8280ff33a10a7520d79d5304e0be64ebfc8377b54dacd82fba4608d5908bb5c2/segment-10.aac?aka_me_session_id=AAAAAAAAAADAKdVeAAAAACh5C5hgA4Ne5X+a44CTGFmsLmM4wFceNVWjG0b0Dk4kE57JjHePT4kKR%2fyD6zbuB5cfMAbEX3Xc&aka_msn=10&aka_hls_version=4'
 for reading
     [aac_adtstoasc @ 0x5621b0f69840] Error parsing ADTS frame header!
     [aac_adtstoasc @ 0x5621b0f69840] Failed to receive packet from filter
 aac_adtstoasc for stream 0
     [aac_adtstoasc @ 0x5621b0f69840] Error parsing ADTS frame header!
     [aac_adtstoasc @ 0x5621b0f69840] Failed to receive packet from filter
 aac_adtstoasc for stream 0
     [aac_adtstoasc @ 0x5621b0f69840] Error parsing ADTS frame header!
     [aac_adtstoasc @ 0x5621b0f69840] Failed to receive packet from filter
 aac_adtstoasc for stream 0
     [hls @ 0x5621afe0a240] Opening
 'crypto+https://<redacted>/audio/aac/en/hdntl=exp=1591028160~acl=%2f*~data=hdntl~hmac=8280ff33a10a7520d79d5304e0be64ebfc8377b54dacd82fba4608d5908bb5c2/segment-12.aac?aka_me_session_id=AAAAAAAAAADAKdVeAAAAACh5C5hgA4Ne5X+a44CTGFmsLmM4wFceNVWjG0b0Dk4kE57JjHePT4kKR%2fyD6zbuB5cfMAbEX3Xc&aka_msn=12&aka_hls_version=4'
 for reading
     [aac_adtstoasc @ 0x5621b0f69840] Error parsing ADTS frame header!
     [aac_adtstoasc @ 0x5621b0f69840] Failed to receive packet from filter
 aac_adtstoasc for stream 0
     [aac_adtstoasc @ 0x5621b0f69840] Error parsing ADTS frame header!

     ...
     ...
     [hls @ 0x5621afe0a240] Opening
 'crypto+https://<redacted>/audio/aac/en/hdntl=exp=1591028160~acl=%2f*~data=hdntl~hmac=8280ff33a10a7520d79d5304e0be64ebfc8377b54dacd82fba4608d5908bb5c2/segment-49.aac?aka_me_session_id=AAAAAAAAAADAKdVeAAAAACh5C5hgA4Ne5X+a44CTGFmsLmM4wFceNVWjG0b0Dk4kE57JjHePT4kKR%2fyD6zbuB5cfMAbEX3Xc&aka_msn=49&aka_hls_version=4'
 for reading
     [aac_adtstoasc @ 0x5621b0f69840] Multiple RDBs per frame with CRC is
 not implemented. Update your FFmpeg version to the newest one from Git. If
 the problem still occurs, it means that your file has a feature which has
 not been implemented.
     [aac_adtstoasc @ 0x5621b0f69840] Failed to receive packet from filter
 aac_adtstoasc for stream 0
     [hls @ 0x5621afe0a240] Opening
 'crypto+https://<redacted>/media-7/hdntl=exp=1591028160~acl=%2f*~data=hdntl~hmac=8280ff33a10a7520d79d5304e0be64ebfc8377b54dacd82fba4608d5908bb5c2/segment-52.ts?aka_me_session_id=AAAAAAAAAADAKdVeAAAAACh5C5hgA4Ne5X+a44CTGFmsLmM4wFceNVWjG0b0Dk4kE57JjHePT4kKR%2fyD6zbuB5cfMAbEX3Xc&aka_msn=52&aka_hls_version=4'
 for reading

     https://<link-
 redacted>/index.m3u8?hdnea=st=1590939053~exp=1590942053~acl=/*~hmac=6b7a5de4831a50a9b7c680ef4f80f85fc60d137da166dcbe0c9ecf6aeacd9cfb:
 Invalid data found when processing input
     frame= 7821 fps=400 q=-1.0 Lsize=  123615kB time=00:05:12.83
 bitrate=3237.1kbits/s speed=  16x
     video:120028kB audio:3525kB subtitle:0kB other streams:0kB global
 headers:0kB muxing overhead: 0.050259%


 }}}

 I have tried using bitstream filter ```-bsf:a aac_adtstoasc ``` but same
 ADTS error.
 I think it is related to the id3 tag, because other videos from the same
 service without a id3 tag works fine!

 How can I fix it? What's wrong? (The .ts on playlist are certainly not
 corrupted)

--
Ticket URL: <https://trac.ffmpeg.org/ticket/8707>
FFmpeg <https://ffmpeg.org>
FFmpeg issue tracker


More information about the FFmpeg-trac mailing list