feat: Add Java binary catalogers#1392
Merged
kzantow merged 1 commit intoanchore:mainfrom Dec 8, 2022
Merged
Conversation
9316a44 to
676c862
Compare
spiffcs
approved these changes
Dec 8, 2022
Contributor
spiffcs
left a comment
There was a problem hiding this comment.
Approved - small comment on TODO
| // [NUL]openjdk[NUL]java[NUL]1.8[NUL]1.8.0_352-b08[NUL] | ||
| `(?m)\x00openjdk\x00java\x00(?P<release>[0-9]+[.0-9]+)\x00(?P<version>[0-9]+[-._a-zA-Z0-9]+)\x00`), | ||
| Package: "java", | ||
| // TODO the updates might need to be part of the CPE, like: 1.8.0:update152 |
Contributor
There was a problem hiding this comment.
Does this TODO still apply? Are there any changes we have to make in the CPE generation logic?
Contributor
Author
There was a problem hiding this comment.
@Spiffs yes I think the TODO is still possibly applicable, but for now I think it's okay to just surface the entire version string because that's what the package managers are doing. I think they will all have the same potential problem matching against the CPEs and I'd rather find a solution for all java packages instead of just these classifiers. It needs more investigation
Signed-off-by: Keith Zantow <kzantow@gmail.com>
676c862 to
7a3bb79
Compare
spiffcs
added a commit
to raboof/syft
that referenced
this pull request
Dec 20, 2022
* main: (87 commits) feat: Add license parsing for java (anchore#1385) fix: cyclonedx component type for binaries (anchore#1406) fix: openjdk detection pattern (anchore#1415) bug: spdx checksum empty array; allow syft to generate SHA1 for spdx-tag-value documents (anchore#1404) Add NetBSD support. (anchore#1412) feat: add catalog delete (anchore#1377) docs: remove file classifier (anchore#1397) chore: update latest cyclonedx library (anchore#1390) feat: Add Java binary catalogers (anchore#1392) chore: Update SPDX license list to 3.19 (anchore#1389) fix: add manual vendor/product removal to fix false flags (anchore#1070) Update Stereoscope to c5ff155d72f166e2332e160a75c3ff2b8e9c7e2e (anchore#1395) chore: fix test busybox image sha (anchore#1393) fix: go version not properly identified in binary (anchore#1384) Update Stereoscope to 3b80d983223f6e6fc2d33b0ffa003d30268418e9 (anchore#1376) fix: Update node binary package name (anchore#1375) feat: Generic Binary Cataloger (anchore#1336) recover from bad parsing of golang binary (anchore#1371) Fix parsing of apk databases with large entries (anchore#1365) Update syft bootstrap tools to latest versions. (anchore#1369) ...
GijsCalis
pushed a commit
to GijsCalis/syft
that referenced
this pull request
Feb 19, 2024
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR adds a binary cataloger for Java runtimes, including popular runtimes: openjdk, Oracle, IBM, SAP.
The images tested include:
Binaries from Oracle for Linux and macOS were also included in testing. The 4 tests included have seemed to cover all these images as well as the downloaded Oracle packages.
Fixes #1388