Skip to content

Fix BLAKE3 size validation#2517

Open
marko1olo wants to merge 1 commit into
gchq:masterfrom
marko1olo:fix-blake3-size-validation
Open

Fix BLAKE3 size validation#2517
marko1olo wants to merge 1 commit into
gchq:masterfrom
marko1olo:fix-blake3-size-validation

Conversation

@marko1olo

Copy link
Copy Markdown

Fixes #2512.

Summary

  • validate the BLAKE3 output size before passing it to @noble/hashes
  • convert negative and fractional size values into a controlled OperationError
  • add regression coverage for -6 and 1.2 size values

Checks

  • node --no-warnings --no-deprecation --openssl-legacy-provider tests/operations/index.mjs -> 1962 passing
  • npx eslint src/core/operations/BLAKE3.mjs tests/operations/tests/BLAKE3.mjs
  • npx grunt configTests
  • git diff --check

@CLAassistant

Copy link
Copy Markdown

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.
You have signed the CLA already but the status is still pending? Let us recheck it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

bug(Blake3): negative size bytes and float size bytes cause an unhandled RangeError

3 participants