Skip to content

fix(binary): support deno versions 1.10.3 - 1.32.2 in binary cataloger#4904

Open
tjhub1983 wants to merge 2 commits into
anchore:mainfrom
tjhub1983:fix/deno-versions-v4
Open

fix(binary): support deno versions 1.10.3 - 1.32.2 in binary cataloger#4904
tjhub1983 wants to merge 2 commits into
anchore:mainfrom
tjhub1983:fix/deno-versions-v4

Conversation

@tjhub1983
Copy link
Copy Markdown

Summary

Fixes #4865.

Problem: The deno-binary classifier only matched the Deno/X.Y.Z string pattern found in newer deno binaries (1.32.3+). Versions 1.10.3 through 1.32.2 embed the version differently (via Rust binary metadata), causing syft to report deno with no version.

Before: syft denoland/deno:1.32.2 -> deno (no version)
After: syft denoland/deno:1.32.2 -> deno@1.32.2

Fix: Added a secondary FileContentsVersionMatcher pattern to detect deno X.Y.Z in older Rust binary string tables, covering versions 1.10.3 through 1.32.2.

DCO Sign-off: Each commit includes proper Signed-off-by: tjhub1983 <tjhub1983@users.noreply.github.com> as required by the DCO.


Co-Authored-By: Claude Sonnet 4.6 noreply@anthropic.com

tjhub1983 added 2 commits May 9, 2026 00:00
Added test case for deno 1.10.3 which uses a Rust-embedded version
string (different from newer deno versions that use Deno/X.Y.Z format).

The test verifies that syft correctly identifies the version from
binary snippets containing patterns like 'deno 1.10.3' in the
Rust binary string table.

Signed-off-by: tjhub1983 <tjhub1983@users.noreply.github.com>
Fixes anchore#4865.

The deno-binary classifier only matched the Deno/X.Y.Z string
pattern found in newer deno binaries (1.32.3+). Versions 1.10.3
through 1.32.2 embed the version differently (via Rust binary
metadata in the string table), causing syft to report 'deno' with
no version.

Added a secondary FileContentsVersionMatcher pattern to detect
'deno X.Y.Z' in older Rust binary string tables. This covers
versions 1.10.3 through 1.32.2.

Before: syft denoland/deno:1.32.2 -> deno (no version)
After:  syft denoland/deno:1.32.2 -> deno@1.32.2

Signed-off-by: tjhub1983 <tjhub1983@users.noreply.github.com>
@tjhub1983
Copy link
Copy Markdown
Author

Hi @kzantow, Ill address all cases in the issue and add comprehensive test cases covering the full version range (1.10.3 - 1.32.2). Ill update the PR with the test data shortly.

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.

Support deno binary old versions

1 participant