You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We are using the license policy functionality for scanning the licenses inside the SBOM, there is an issue on getting the correct license when the license name is an URL.
Is there a possible fix for that, adjusting the license.json was not successful. I tried putting it as name,family, alias or url but the sbom-utitlity couldn't find any suitable license choice.
Is this a known Issue, I've seen the IBM implementation stated something about a similar issue with license expressions
@LeonKolataAtGov the value of the name field (of a licenseChoice) is simply a free-form string and not treated as an identifier. That is, you can put anything you wish in the name field and it will not be used/treated as an identifier it cannot be (for obvious reasons) for the purposes of policy lookup/assertion.
Syft simply chose to place the local filename of a license file in the name field (which they are free to do give it is just a string), but it cannot be used for deterministic processing (such as license assertion and risk assessment).
Ironically, one of the core reasons I created this utility was so that SBOM generation tooling providers would use the fields properly and adhere to schema. The field to use is id which SHOULD be a valid SPDX Identifier. As a generation tool, Syft should read the contents of the LICENSE file they identified (and added to the licenses array) and assert its contents is Apache 2.0 (or other) and set the id value to Apache-2.0 (which is also endorsed by the ASF I should mention: https://www.apache.org/licenses/LICENSE-2.0).
To be clear, other BOM generation tools likely choose to fill in the name value with other information (not local file paths); therefore, although code could be added to account specifically for Syft's use of the field and interpret the string "https://www.apache.org/licenses/LICENSE-2.0.txt" as being SPDX ID "Apache-2.0", this would still be a "guess" made that would then be presented as an assertion to the policy evaluation code (which companies use to determine risk). That is not a good security/compliance practice.
IMO, Syft should fix their gen. tool to use the id field when possible (or, of course, the license expression field which also uses SPDX IDs). In addition, if they choose not to make a determination for 'id''s vale, then they should include the source code of the actual license text which downstream viewers can read to make their own determination. That is, take advantage of the license text object.
We are using the license policy functionality for scanning the licenses inside the SBOM, there is an issue on getting the correct license when the license name is an URL.
Is there a possible fix for that, adjusting the license.json was not successful. I tried putting it as name,family, alias or url but the sbom-utitlity couldn't find any suitable license choice.
Is this a known Issue, I've seen the IBM implementation stated something about a similar issue with license expressions
I'm a nohead in go therefore I cannot fix it on my own :(
Example output:
Extract from the sbom
The text was updated successfully, but these errors were encountered: