Skip to content

Conversation

bxf12315
Copy link
Contributor

@bxf12315 bxf12315 commented Apr 28, 2025

@bxf12315 bxf12315 requested a review from ctron April 28, 2025 13:06
@bxf12315 bxf12315 force-pushed the adr-sbom-dashboard branch 2 times, most recently from cc3103d to eb567af Compare April 28, 2025 13:12
@bxf12315 bxf12315 force-pushed the adr-sbom-dashboard branch from eb567af to f9053cc Compare May 6, 2025 05:58
Copy link
Contributor

@ctron ctron left a comment

Choose a reason for hiding this comment

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

I am missing the following information in this document:

  • What the meaning/definition of the different "total" values? How can we produce this information?
  • How do we handle custom licenses and complex SPDX expressions?
  • What's the id path variable exactly? We have different ways of addressing SBOMs at the moment. Which one do we use here?

I also think that we might want to think about:

  • Who's eligible to retrieve that information (authorization)
  • Does it make sense caching this information? If so, how?

"total_licenses": "0"
}
```
- Vulnerabilities state
Copy link
Contributor

Choose a reason for hiding this comment

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

What's the reason for having three "state" endpoints? Wouldn't it be simpler to have one?

## Decision
Design an endpoint for each of these parts.
- sbom state
- **HTTP GET api//v2/sbom/{id}/sbom-status**
Copy link
Contributor

Choose a reason for hiding this comment

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

So far, we don't use kebab-case, why now? Some for the others.

- Reponse playload
```json
{
"name": "Sbom-name",
Copy link
Contributor

Choose a reason for hiding this comment

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

Why do we have additional SBOM information (name, version, …) here. But not in the others?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

These all came from the mockup, and I also think they’re not very reasonable; we could consider removing them.

"version": "0",
"published_date": "",
"licenses": [
{ "name:": "Apache-2.0", "count": "10"},
Copy link
Contributor

Choose a reason for hiding this comment

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

To my understanding some SPDX licenses are actually license expressions. How do we handle those?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

We already have spdx_licenses to store the standard SPDX IDs parsed from license expressions.

Copy link
Contributor

@ctron ctron May 6, 2025

Choose a reason for hiding this comment

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

Ok, but what's then the meaning of an entry of e.g. MIT?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Indicates how many times the MIT license appears.

Copy link
Contributor

Choose a reason for hiding this comment

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

So MIT OR LGPL-2.1-only would show up as MIT and LGPL-2.1-only? That feels wrong.

Copy link
Contributor Author

@bxf12315 bxf12315 May 6, 2025

Choose a reason for hiding this comment

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

Purely from the perspective of occurrence counts, this does not involve the semantics of specific SPDX expressions and should be fine. Only when dealing with actual license relationships might issues occur.

Copy link
Contributor

Choose a reason for hiding this comment

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

So what the benefit of the user having this?

"total_critical": "0",
"total_high": "0",
"total_medium": "0",
"total_low": "0"
Copy link
Contributor

Choose a reason for hiding this comment

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

What about "none"?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

‘none’ is just 0.

Copy link
Contributor

Choose a reason for hiding this comment

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

To my understanding none is a dedicated severity. So there can 5 vulnerabilities of type none.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

you are right.

```json
{
"total_packages": "0",
"total_licenses": "0"
Copy link
Contributor

Choose a reason for hiding this comment

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

Wouldn't that information make more sense in the license state endpoint?

@bxf12315 bxf12315 force-pushed the adr-sbom-dashboard branch from f9053cc to 16f5b34 Compare May 6, 2025 13:11
@bxf12315 bxf12315 force-pushed the adr-sbom-dashboard branch from 16f5b34 to e740005 Compare May 6, 2025 14:22
@bxf12315 bxf12315 requested review from mrizzi and carlosthe19916 May 7, 2025 13:02
@ctron ctron added the ADR label May 27, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants