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] [thread-next>] [day] [month] [year] [list]
Message-ID: <20260105-abiding-aloof-locust-dcadac@houat>
Date: Mon, 5 Jan 2026 11:36:29 +0100
From: Maxime Ripard <mripard@...nel.org>
To: Xiao Kan <814091656@...com>
Cc: maarten.lankhorst@...ux.intel.com, tzimmermann@...e.de, 
	airlied@...il.com, simona@...ll.ch, dri-devel@...ts.freedesktop.org, 
	linux-kernel@...r.kernel.org, w@....eu, security@...nel.org, kanxiao666@...il.com, 
	xiao.kan@...sung.com
Subject: Re: [PATCH] drm: limit property blob creation per file

Hi,

On Sat, Jan 03, 2026 at 10:25:29AM -0500, Xiao Kan wrote:
> DRM_IOCTL_MODE_CREATEPROPBLOB allows userspace to create property blobs
> whose lifetime is scoped to a drm_file.
> 
> Currently, a single drm_file may create an unbounded number of blobs.
> Repeated ioctl calls can trigger unbounded kernel memory allocation and
> lead to OOM, resulting in a denial-of-service.
> 
> Introduce a per-drm_file limit on the number of user-created property
> blobs. The limit is enforced at the point where a blob becomes associated
> with a drm_file, matching the existing ownership and lifetime model.
> This bounds per-file allocations while the total number of DRM file
> descriptors remains constrained by existing kernel limits.
> 
> Signed-off-by: Xiao Kan <814091656@...com>
> Signed-off-by: Xiao Kan <xiao.kan@...sung.com>

Wouldn't it make more sense to account the allocation in memcg by
passing GFP_ACCOUNT to the kvzalloc call in drm_property_create_blob?

Maxime

Download attachment "signature.asc" of type "application/pgp-signature" (274 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ