Skip to content

feat(imaging): refuse a file whose tags claim more data than it holds, with sillybos 6 - #113

Merged
stephen-masters merged 1 commit into
mainfrom
feat/sillybos-6
Nov 17, 2026
Merged

stephen-masters merged 1 commit into
mainfrom
feat/sillybos-6

Conversation

@stephen-masters

Copy link
Copy Markdown
Contributor

Raises the sillybos pin from >=5,<6 to >=6,<7, and the lock from 5.0.0 to 6.0.1. Three sillybos releases come with it.

What changes for a run

  • 6.0.0 refuses by default a file whose tags claim more data between them than it holds: a TIFF's directory, or the EXIF block of a JPEG or PNG. A decoder reads every tag's value into memory, so thousands of tags pointing at the same bytes cost Pillow 1.6 GB to open a 144 KB TIFF (CVE-2026-128066). No writer produces such a file. One now goes to the triage queue with the reason, like any other refusal.
  • 6.0.1 refuses a JPEG with a second frame header before its image data. Pillow reports the size from the last header, so the size that was checked was not the size Pillow went on to use.
  • 5.1.0 added a policy on a greyscale or palette TIFF's spare samples (CVE-2026-128067). It stays at sillybos's default here, which allows them. That flaw needs the opened TIFF saved back with its tag table. Tetrak saves only copies of a frame (page_documents) and PNGs (orientation), and a carrier file saves cleanly through both. The Pillow floor here (>=13.0) already has the fix as well.

What was checked

  • All 1,645 scans in this checkout, the Armenian evaluation pages and one book's page frames get the same verdict from sillybos 5.0.0 and 6.0.1 under Tetrak's own policy. Nothing read today is newly refused.
  • A new test builds a TIFF whose hundred tags all claim the same bytes and expects InputRefusedError with sillybos's reason.
  • ruff check, ruff format --check, uv lock --check and pytest -m "not slow" pass locally, apart from three test_vision.py tests that fail on a Mac without the vision extra installed; they fail the same way on main's code.
  • uv lock --upgrade-package sillybos changed only the sillybos entry in uv.lock.

🤖 Generated with Claude Code

…, with sillybos 6

Raises the pin from >=5,<6 to >=6,<7 and the lock from 5.0.0 to 6.0.1.
sillybos 6.0.0 refuses by default a TIFF, or the EXIF block of a JPEG
or PNG, whose tags claim more data between them than the file holds:
thousands of tags pointing at the same bytes, which cost Pillow 1.6 GB
to open a 144 KB file (CVE-2026-128066). No writer produces such a
file; one now goes to the triage queue with the reason. 6.0.1 also
refuses a JPEG with a second frame header before its image data, whose
size Pillow would report from the wrong header.

5.1.0's policy on a greyscale or palette TIFF's spare samples comes
with it and stays at its default, which allows them
(CVE-2026-128067). That flaw needs the opened TIFF saved back with its
tag table, and Tetrak saves only copies of a frame and PNGs: a carrier
file saves cleanly through both, on a Pillow whose floor here already
has the fix.

All 1,645 scans in this checkout, the Armenian evaluation pages and
one book's page frames get the same verdict from 5.0.0 and 6.0.1.

Co-authored-by: Yvette Mankerian <yvettekm@gmail.com>
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
@cloudflare-workers-and-pages

Copy link
Copy Markdown

Deploying tetrak with  Cloudflare Pages  Cloudflare Pages

Latest commit: 8a8674d
Status: ✅  Deploy successful!
Preview URL: https://d68326d8.tetrak.pages.dev
Branch Preview URL: https://feat-sillybos-6.tetrak.pages.dev

View logs

@stephen-masters
stephen-masters merged commit a0c468b into main Nov 17, 2026
9 checks passed
@stephen-masters
stephen-masters deleted the feat/sillybos-6 branch November 18, 2026 09:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant