Commit graph

9 commits

Author SHA1 Message Date
Thibault Saunier
8c7579e129 matroskademux: Start support for upstream segments in TIME format
So we can use matroskademux for dash webm dash streams.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3159>
2022-10-27 19:45:44 +00:00
Sebastian Dröge
cf887f1b8e matroskademux: Avoid integer-overflow resulting in heap corruption in WavPack header handling code
blocksize + WAVPACK4_HEADER_SIZE might overflow gsize, which then
results in allocating a very small buffer. Into that buffer blocksize
data is memcpy'd later which then causes out of bound writes and can
potentially lead to anything from crashes to remote code execution.

Thanks to Adam Doupe for analyzing and reporting the issue.

CVE: CVE-2022-1920

https://gstreamer.freedesktop.org/security/sa-2022-0004.html

Fixes https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/1226

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/2612>
2022-06-15 18:35:12 +00:00
Nicolas Dufresne
0f15580853 matroska: Fix AV1 alignment to TU
Matroska stores AV1 in temporal unit, so that all OBU sharing the same
timestamp are put together. This was previously just assumed, which isn't
safe now that we have more alignments.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/1837>
2022-03-04 21:58:15 +00:00
Jan Schmidt
7efdc9c7f5 matroskademux: Don't parse Tracks element twice
If the tracks element was parsed from the SeekEntry, don't
parse it a second time and recreate tracks, as this
loses any tags that were read using the seek table.

If a genuinely new Tracks element is found, do read that
as it is needed for MSE support.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/1798>
2022-03-01 13:17:40 +00:00
Nirbheek Chauhan
4e22ef5bd2 matroska-demux: Emit a warning when no codec data found
It is bad if an mkv file does not have codec data for the ProRes
variant, so we should emit a warning. ffmpeg does the same thing.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/1739>
2022-02-21 08:49:28 +00:00
Sebastian Wick
e61e069189 matroska: default prores fourcc apcn
If there is no codec private data for prores it should default to Apple
ProRes 422 Standard Definition (apcn). Can be tested with
strobe_scientist.mkv from
https://developers.google.com/media/vp9/hdr-encoding

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/1734>
2022-02-18 08:38:31 +00:00
Rafał Dzięgiel
41385ab6f7 matroska: Ref index table when updating track info
Track index table array was being lost during track info update.
Ref it over to updated info, so it can be used for finding
nearest seek points.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/1203>
2021-11-12 12:28:40 +00:00
Rafał Dzięgiel
478f94edc7 matroska: Use g_array_unref everywhere
Instead of using g_array_free which is not thread safe use g_array_unref instead

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/1203>
2021-11-12 12:28:40 +00:00
Thibault Saunier
5ff769d731 Move files from gst-plugins-good into the "subprojects/gst-plugins-good/" subdir 2021-09-24 16:13:50 -03:00
Renamed from gst/matroska/matroska-demux.c (Browse further)