Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

thomassui
Copy link

Description

Syft catalogs ".rar" Java resource adapter files.

Type of change

Checklist:

  • I have added unit tests that cover changed behavior
  • I have tested my code in common scenarios and confirmed there are no regressions

// LifeRay makes it pretty cumbersome to make a such plugins; their docs are
// out of date, and they charge for their IDE. If you find an example
// project that we can build in CI feel free to include it
"**/*.rar", // Java Resource Adapter Archive
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this going to cause a problem when Win RAR archives are encountered?

Copy link
Author

@thomassui thomassui Aug 14, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

An unexpected format (which I believe can happen with any file extension) will cause a 'not valid zip file' DEBUG message, and further processing of this file is stopped. See the example log entry in DEBUG mode when I provide a WinRAR file.

[0005] DEBUG cannot find beginning of zip archive="/tmp/syft-archive-contents-469710021/archive-testfile.rar3.rar" : zip: not a valid zip file
[0005] DEBUG unable to open zip archive (/tmp/syft-archive-contents-469710021/archive-testfile.rar3.rar): zip: not a valid zip file

@kzantow
Copy link
Contributor

kzantow commented Aug 18, 2025

Hey @thomassui it looks like there are test failures, are you able to have a look?

Signed-off-by: Marc Thomas <[email protected]>
@thomassui
Copy link
Author

Hey @kzantow, I investigated the failing unit test and fixed it. I’ll do better next time.

@thomassui thomassui changed the title Enable the .rar files for Java resource adapters to be cataloged. feat: Enable .rar files for Java resource adapters to be cataloged. Oct 22, 2025
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.

Add Java resource adapter extension ".rar" as supported Java archive

2 participants