Skip to content

Reject a negative length in Zlib.crc32_combine - #160

Merged
hsbt merged 1 commit into
ruby:masterfrom
mame:zlib-crc32-combine-negative
Nov 26, 2026
Merged

hsbt merged 1 commit into
ruby:masterfrom
mame:zlib-crc32-combine-negative

Conversation

@mame

@mame mame commented Oct 24, 2026

Copy link
Copy Markdown
Member

zlib 1.3.1 loops forever in x2nmodp() on a negative length, and the loop cannot be interrupted.

  Zlib.crc32_combine(0, 0, -1)
  #=> never returns (with zlib 1.3.1)

@hsbt
hsbt force-pushed the zlib-crc32-combine-negative branch 2 times, most recently from ed97546 to 0066c91 Compare November 26, 2026 09:56
zlib 1.3.1 loops forever in x2nmodp() on a negative length, and the
loop cannot be interrupted.

  Zlib.crc32_combine(0, 0, -1)
  #=> never returns (with zlib 1.3.1)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@hsbt
hsbt force-pushed the zlib-crc32-combine-negative branch from 0066c91 to 5943150 Compare November 26, 2026 10:11
@hsbt
hsbt merged commit d1f7692 into ruby:master Nov 26, 2026
31 checks passed
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.

2 participants