Skip to content
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

Dependencies in manifest are a flat list instead of graph for .NET Solution #585

Open
Tram13 opened this issue May 28, 2024 · 1 comment
Labels
tabled We like this idea, but we are not going to action on it in the moment

Comments

@Tram13
Copy link

Tram13 commented May 28, 2024

Problem

In the resulting manifest.spdx.json file created by SBOM Tool, the "relationships" are all defined as depending on SPDXRef-RootPackage instead of the proper subdependency.

Context

I have created a simple Hello-World C# project, and added some random dependencies. You can find the project I used here:
hello-world-dotnet.zip

Then, I ran dotnet restore. This creates the project.assets.json file, which is read by Component-Detection.

To be sure Component-Detection works as expected, I used .\componentdetection.exe scan --SourceDirectory . --SourceFileRoot . --ManifestFile componentdetection_manifest.json. This generated the file componentdetection_manifest.json. In this file, the dependencies are stored as a graph, not a flat list where all dependencies point to the root package:
afbeelding

But when executing .\sbom.exe Generate -b . -bc . -ps "MyTest" -pn "MyPackageName" -pv "1.0.0", this hierarchy is not kept in the resulting spdx file: manifest.spdx.json
afbeelding

@sfoslund sfoslund added needs triage Default status upon issue submission needs investigation Our team will investigate and determine next actions and removed needs triage Default status upon issue submission labels May 28, 2024
@sfoslund sfoslund added tabled We like this idea, but we are not going to action on it in the moment and removed needs investigation Our team will investigate and determine next actions labels Jun 27, 2024
@woutersmit
Copy link

Due to this security scanners like Trivy are not able to seperate direct from indirect package relationships

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
tabled We like this idea, but we are not going to action on it in the moment
Projects
None yet
Development

No branches or pull requests

4 participants