SBOM report from JFrog-CLI tool #1800
Replies: 3 comments 2 replies
-
@ccconnected, |
Beta Was this translation helpful? Give feedback.
-
I just went down this rabbit hole. The main issue is finding the sha_256 for the build info to supply to the component/exportDetails API. Assuming you're publishing your build info to, you first call the dependencyGraph/build API
And you can parse the build info's sha_256 out of the response (
This should get you the CycloneDX SBOM for the published and scanned build info. However, I would very much like a more direct option built into the commands that perform the Xray scan. |
Beta Was this translation helpful? Give feedback.
-
@eyalbe4 I'm trying to use the v2 export component details API as it looks like it gets rid of the need to first pull the build dependency graph to find the sha. But all I can get back is $ jf xr curl 'api/v2/component/exportDetails' \
--header 'Content-Type: application/json'
--data '{
"component_name":"npmtest3:1.3.1",
"package_type":"build",
"path":"testproject1-build-info/npmtest3/1.3.1-1234567890.json",
"cyclonedx":true,
"cyclonedx_format":"json"
}' -o report.json
$ cat output.json
{"error":"Invalid request payload"} Am I on the right track with setting the path to the build info's json file? What's the best way for us to find the right |
Beta Was this translation helpful? Give feedback.
-
Good day JFrog-CLI Team,
I am interested in obtaining SBOM report from JFrog-CLI tool.
From this REST API https://www.jfrog.com/confluence/display/JFROG/Xray+REST+API#XrayRESTAPI-ExportComponentDetails I see there are available options:
Could something like this be implemented for JFrog-CLI tool, e.g. switches --spdx, --spdx_format, --cyclonedx, --cyclonedx_format?
Kind regards!
Beta Was this translation helpful? Give feedback.
All reactions