lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-Id: <873C85C5-2BCB-4631-BA18-919CE448A7CE@collabora.com>
Date: Sat, 27 Sep 2025 10:56:46 +0200
From: Daniel Almeida <daniel.almeida@...labora.com>
To: opensource india <opensource206@...il.com>
Cc: mchehab@...nel.org,
 hverkuil@...nel.org,
 ribalda@...omium.org,
 laurent.pinchart@...asonboard.com,
 yunkec@...gle.com,
 sakari.ailus@...ux.intel.com,
 james.cowgill@...ize.com,
 hansg@...nel.org,
 linux-kernel@...r.kernel.org,
 linux-media@...r.kernel.org
Subject: Re: [PATCH v3] media: v4l2-ctrls: add full AV1 profile validation in
 validate_av1_sequence()

Hi, I’ll review this in the coming weeks.

> On 27 Sep 2025, at 06:51, opensource india <opensource206@...il.com> wrote:
> 
> On Sat, Sep 13, 2025 at 4:23 PM Pavan Bobba <opensource206@...il.com> wrote:
>> 
>> Complete the "TODO: PROFILES" by enforcing profile-specific and
>> monochrome constraints as defined by the AV1 specification
>> (Section 5.5.2, "Color config syntax").
>> 
>> The validator now checks:
>> 
>> - Flags: reject any unknown bits set in sequence->flags
>> - Profile range: only profiles 0..2 are valid
>> - Profile 0: 8/10-bit only, subsampling must be 4:2:0 (sx=1, sy=1),
>>   monochrome allowed
>> - Profile 1: 8/10-bit only, subsampling must be 4:4:4 (sx=0, sy=0),
>>   monochrome forbidden
>> - Profile 2:
>>    * 8/10-bit: only 4:2:2 allowed (sx=1, sy=0)
>>    * 12-bit: 4:4:4 (sx=0, sy=0), 4:2:2 (sx=1, sy=0), or 4:2:0 (sx=1, sy=1)
>>      allowed
>> - Monochrome path (all profiles except 1): forces subsampling_x=1,
>>   subsampling_y=1, separate_uv_delta_q=0
>> 
>> These checks prevent userspace from providing invalid AV1 sequence
>> headers that would otherwise be accepted, leading to undefined driver
>> or hardware behavior.

Mauro,

A reminder that I have been warning about this for quite a while [0], which
includes mentioning that patches like this, although welcome, do not solve the
root issue completely.

I keep working on what I believe to be the solution [1][2]. I would appreciate if
we could restart this discussion.

[0]: https://lwn.net/Articles/970565/
[1]: https://lore.kernel.org/linux-media/20250818-v4l2-v1-0-6887e772aac2@collabora.com/
[2]: https://lwn.net/Articles/963966/


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ