-
-
Notifications
You must be signed in to change notification settings - Fork 86
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
Add optional configuration parameter "includeLicenses". #42
base: master
Are you sure you want to change the base?
Conversation
The default is true. Setting it to false will entirely omit component license information. This may be useful for environments where spdx.org cannot be reached or where license information is not relevant at all.
This appears to be an issue with the SPDX tools library used by CycloneDX Core and not specific to the Maven plugin. This PR seems to be a workaround rather than a solution. I'm more interested in having an offline solution that includes the license information than simply omitting it. I'll have to investigate the use of spdx-tools in cyclonedx-core-java and see if the license lookup functionality can be performed without spdx-tools, and if not, then I might need to create a ticket for the spdx-tools project to have their tool work in offline mode as a fallback. |
@stevespringett Can't we do both? Some will simply not be interested in the licensing altogether and this flag is valuable for those. |
@stevespringett Do you have any updates on this issue from SPDX tools library? As suggested by @davidkarlsen wouldn't it be helpful to have this flag as well for those not quite interested in the licensing? |
BOMs are a statement of fact. Crippling the plugin through configuration which produces inaccurate license information for the purpose of getting around locked-down build environments is not something I support. Other ecosystems actually require outside access, so it's fortunate that Maven contains most of the information to create accurate BOMs in a disconnected environment. Instead of modifying the plugin, try executing it with the following system property. mvn -DSPDXParser.OnlyUseLocalLicenses=true org.cyclonedx:cyclonedx-maven-plugin:1.6.1:makeAggregateBom |
Adding the system property seems to work wonders. Thanks! |
It would be nice to have the plugin pass a maven property to the |
@stevespringett, what about proxying configuration for |
@stevespringett, what about my suggestion to proxy the |
Thanks for the ping @mfriedenhagen. I'm actually working to remove reliance on SPDX Tools from the next major release of CycloneDX Core Java. v3.0.0 will likely be released in June shortly after the launch of the CycloneDX v1.2 spec. Once an updated Core Java module is published without SPDX Tools, the proxy issue disappears. |
The default is true. Setting it to false will entirely
omit component license information. This may be useful
for environments where spdx.org cannot be reached or
where license information is not relevant at all.