-
-
Notifications
You must be signed in to change notification settings - Fork 607
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
Incompatibility with SBOM from @cyclonedx/cyclonedx-npm #2265
Comments
From first analysis and having in mind the discussions regarding duplication of components, which are produced in BOMs from @cyclonedx/cyclonedx-npm (see https://github.com/CycloneDX/cyclonedx-node-npm/milestone/2 and CycloneDX/cyclonedx-node-npm#307), we think this is happening due to some kind of duplication/relation/tree issue. Uploading the "faulty" BOM to Dependency-Track, Downloading the BOM that Dependency-Track offers in the UI (which contains no graph information), and uploading that to a new project to use as base, then trying to reproduce this with another BOM will show, that the BOM generated by Dependency-Track does not fail anymore. So there likely must be some problem when processing the graph contained in the original BOM. The error seems to happen in the recursive deletion of old components. Since the new BOM is a lot different to the old, with a lot less components, a lot of components have to be deleted. Somehow during this process some components always are NULL already which leads to this issue. This possibly can also be a bug in the bom file generated by @cyclonedx/cyclonedx-npm, but Dependency-Track needs to be failure resistent and if it succeeds importing a BOM file it should always be able to replace this content with a new BOM file. I assume the stored relations are inconsistent somehow. |
The error and possibly scenario (recursive / duplicate delete of components) seems similar to #2131. |
@valentijnscholten you are right. This sounds related |
Yes fine for me |
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
Current Behavior
We found some kind of incompatibility with some SBOMs generated by @cyclonedx/cyclonedx-npm. We could not reproduce this with SBOMs from the older NPM tool or other sbom tools.
When a project exists with a BOM from @cyclonedx/cyclonedx-npm, and you try to upload a very different BOM file or one generated by another tool, upload API will return 200, but the "Last BOM Upload" timestamp will not update, neither will the components reflect what the latest uploaded BOM contained.
The log shows an error:
Steps to Reproduce
Expected Behavior
Dependency-Track Version
4.6.2
Dependency-Track Distribution
Container Image
Database Server
Microsoft SQL Server
Database Server Version
No response
Browser
Google Chrome
Checklist
The text was updated successfully, but these errors were encountered: