From nobody Wed May 15 16:34:28 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of seabios.org designates 78.46.105.101 as permitted sender) client-ip=78.46.105.101; envelope-from=seabios-bounces@seabios.org; helo=coreboot.org; Authentication-Results: mx.zohomail.com; spf=pass (zohomail.com: domain of seabios.org designates 78.46.105.101 as permitted sender) smtp.mailfrom=seabios-bounces@seabios.org Return-Path: Received: from coreboot.org (coreboot.org [78.46.105.101]) by mx.zohomail.com with SMTPS id 1709720874762635.9459359734299; Wed, 6 Mar 2024 02:27:54 -0800 (PST) Received: from authenticated-user (PRIMARY_HOSTNAME [PUBLIC_IP]) by coreboot.org (Postfix) with ESMTPA id 90D6B21868; Wed, 6 Mar 2024 10:27:49 +0000 (UTC) Received: from authenticated-user (PRIMARY_HOSTNAME [PUBLIC_IP]) by coreboot.org (Postfix) with ESMTP id 2EB1121569 for ; Wed, 6 Mar 2024 10:27:34 +0000 (UTC) Received: from authenticated-user (PRIMARY_HOSTNAME [PUBLIC_IP]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) (Authenticated sender: daniel@drv.nu) by oak.drv.nu (Postfix) with ESMTPSA id 1C4CE103045; Wed, 6 Mar 2024 02:27:32 -0800 (PST) From: Daniel Verkamp To: seabios@seabios.org Date: Wed, 6 Mar 2024 02:27:28 -0800 Message-ID: <20240306102728.2062789-1-daniel@drv.nu> MIME-Version: 1.0 X-Spam-Level: ** Message-ID-Hash: AGF33AW2VHUWTS5WGDRHIE5ACSX7HV42 X-Message-ID-Hash: AGF33AW2VHUWTS5WGDRHIE5ACSX7HV42 X-MailFrom: daniel@drv.nu X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; header-match-seabios.seabios.org-0; header-match-seabios.seabios.org-1; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header X-Mailman-Version: 3.3.6b1 Precedence: list Subject: [SeaBIOS] [PATCH] vbe: Add VBE 2.0+ OemData field to struct vbe_info List-Id: SeaBIOS mailing list Archived-At: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: Content-Transfer-Encoding: quoted-printable Authentication-Results: coreboot.org; auth=pass smtp.auth=mailman@coreboot.org smtp.mailfrom=seabios-bounces@seabios.org X-Spamd-Bar: / X-ZM-MESSAGEID: 1709720876512100001 Content-Type: text/plain; charset="utf-8" Per the VBE 2.0 specification, the VBE controller information is 512 bytes long when the "VBE2" signature is provided, instead of the original 256 bytes. src/bootsplash.c uses the original pre-VBE-2.0 256-byte structure while also filling in the "VBE2" signature, so a video BIOS that makes use of the VBE2 OemData area could write past the end of the allocated region. The original bootsplash code did not have this bug; it was introduced when the bootsplash VBE structures were merged with the VGA ROM struct definitions. Fixes: 69e941c159ed ("Merge bootsplash and VGA ROM vbe structure definition= s") Signed-off-by: Daniel Verkamp --- src/std/vbe.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/std/vbe.h b/src/std/vbe.h index 94b4ad86..fe96f5ec 100644 --- a/src/std/vbe.h +++ b/src/std/vbe.h @@ -18,6 +18,8 @@ struct vbe_info { struct segoff_s oem_product_string; struct segoff_s oem_revision_string; u8 reserved[222]; + /* VBE 2.0 */ + u8 oem_data[256]; } PACKED; =20 struct vbe_mode_info { --=20 2.43.0 _______________________________________________ SeaBIOS mailing list -- seabios@seabios.org To unsubscribe send an email to seabios-leave@seabios.org