-
Notifications
You must be signed in to change notification settings - Fork 573
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support to exclude scope for Maven Projects like compile, runtime, provided or test in Syft #3130
Comments
I think this is a great idea and there are a couple paths forward. One path is more complicated: capture java relationships for these dependencies (we are going to do this, anyway) but capture additional information including the dependency scope, and post-process relationships to exclude "development" scoped dependencies. This has the benefit that NPM has a similar issue where Another path is fairly simple: we have some maven configuration (and the CLI configuration), we could simply add a
Does this sound like something that would work for you? |
Yes @kzantow this sounds good with the second approach... It's not only scope exclusion, but providing support to exclude groups or artifacts IDs , is a great benefit to Maven Users. |
I would like to add my point of view to this issue. For me it would be useful to be able to differentiate between direct test dependencies and the test dependencies of the direct dependencies. I am actually interested in my test dependencies (e.g. in terms of identifying vulnerabilities or to be able to check for updates for those test dependencies). But I am not interested in the test dependencies of the transitive dependencies because I will not be in touch with them, they are not part of my build process or of my runtime environment. My direct test dependencies are part of my build process so I want to be able to report them without having the test dependencies of the transitive dependencies. Just excluding certain scopes would not fully allow for this use case. Please consider a solution which would allow for reporting all direct and only transitive compile dependencies. |
What happened: Not able to find any support to decide or exclude what scope to be included for scanning.
What you expected to happen:
Support like how we have in Maven arguments -DincludeCompileScope=true -DincludeProvidedScope=false -DincludeRuntimeScope=true -DincludeTestScope=false
Steps to reproduce the issue:
Anything else we need to know?:
Environment:
syft version
: release tag='v1.11.0' version='1.11.0' os='linux' arch='amd64'cat /etc/os-release
or similar):The text was updated successfully, but these errors were encountered: