Closed Bug 1509397 Opened 2 years ago Closed 2 years ago
Mp4 parser should use per sample IV size from sample group if present
47 bytes, text/x-phabricator-request
|Details | Review|
MP4 encryption metadata may be present at several levels, each applying to a more specific unit of media. Data may be present at the track level, the sample group level, or at the individual sample level. If the same metadata is specified at multiple levels, we should use the more specific metadata. I.e. if a track specifies a per sample IV size, and a sample group in that same track also specifies a per sample IV size, we should opt to use the more specific sample group metadata. We are not currently doing this for the per sample IV size mentioned above. We will read this value from the track information but will not use the sample grouping per sample IV size if it is present. Bug 1318792 introduced reading information from sample group and using this instead of the track information, but only does so for the key id. We should also be doing so for the per sample IV size. I suspect this functionality is not exercised much and/or that the per sample IV size is often the same in the sample group as the track, as we don't seem to be running into issues. However, we should do this to comply with the spec.
If sample group metadata is present, it should be used over the less specific track metadata. This patch changes the mp4 parser to do so for per sample IV sizes.
Pushed by firstname.lastname@example.org: https://hg.mozilla.org/integration/autoland/rev/1924c38b2063 mp4: use per sample IV size from sample group metadata if present. r=jya
You need to log in before you can comment on or make changes to this bug.