cyclonedx-cli icon indicating copy to clipboard operation
cyclonedx-cli copied to clipboard

Add support for dynamic component pedigree

Open stevespringett opened this issue 4 years ago • 3 comments

For components that a development team knows are modified, CycloneDX CLI should ideally be able to reach out into the VCS (git) and retrieve the commits that make a modified version unique.

This ticket is specific to component/pedigree/ancestors and component/pedigree/commits. Automated support for patches and resolves are outside the scope of this ticket.

Given the bom-ref of a modified component (and possibly the purl of the original component) the CLI should be able to construct the ancestors node and retrieve all commits and attach the pedigree node to the component.

This ticket was created as a result of a Slack conversation.

This ticket is related to #14.

stevespringett avatar Mar 11 '21 21:03 stevespringett

This would be really cool. But how would it work?

Would the user provide the hash for the upstream commit they made their subsequent changes from?

coderpatros avatar Mar 12 '21 07:03 coderpatros

Would the user provide the hash for the upstream commit they made their subsequent changes from?

My thought is either commit hash to the tag name

stevespringett avatar Mar 12 '21 15:03 stevespringett

in other systems i've seen tings like v1.33.7+5278b9229bb058e66a74c00dc9e53604918d94b0 which derived from the latest version tag in the git history. and since the HEAD was not tagged, an additional +<git-node-id_of_HEAD> was added.

jkowalleck avatar Mar 12 '21 18:03 jkowalleck