font/sfnt: apply bounds checks before allocating read buffer When using ReadAt to read more than 1MiB of data from a font file, verify that the file contains the data before allocating the read buffer. Avoids excessive memory allocation when parsing corrupt or malicious font files. Thanks to Andy Gill, ZephrSec Ltd for reporting this issue. Fixes golang/go#78382 Fixes CVE-2026-33812 Change-Id: Icd5e7388661a76a6af800f0ba0b728c46a6a6964 Reviewed-on: https://go-review.googlesource.com/c/image/+/761180 LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com> Auto-Submit: Damien Neil <dneil@google.com> Reviewed-by: Neal Patel <nealpatel@google.com>
This repository holds supplementary Go image packages.
This repository uses Gerrit for code changes. To learn how to submit changes to this repository, see https://go.dev/doc/contribute.
The git repository is https://go.googlesource.com/image.
The main issue tracker for the image repository is located at https://go.dev/issues. Prefix your issue with “x/image:” in the subject line, so it is easy to find.