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

Content Identifiers for Software Artifacts #701

Merged
merged 5 commits into from
Apr 11, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 30 additions & 0 deletions model/Software/Classes/ContentIdentifier.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
SPDX-License-Identifier: Community-Spec-1.0

# ContentIdentifier

## Summary

A canonical, unique, immutable identifier

## Description

A ContentIdentifier is a canonical, unique, immutable identifier of the content of a software artifact, such as a package, a file, or a snippet.
It can be used for verifying its identity and integrity.

## Metadata

- name: ContentIdentifier
- SubclassOf: /Core/IntegrityMethod
- Instantiability: Concrete

## Properties

- contentIdentifierType
- type: ContentIdentifierType
- minCount: 1
- maxCount: 1
- contentIdentifierValue
- type: xsd:anyURI
- minCount: 1
- maxCount: 1

7 changes: 3 additions & 4 deletions model/Software/Classes/SoftwareArtifact.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,6 @@ such as a package, a file, or a snippet.

## Properties

- gitoid
- type: xsd:anyURI
- minCount: 0
- maxCount: 2
- primaryPurpose
- type: SoftwarePurpose
- minCount: 0
Expand All @@ -37,4 +33,7 @@ such as a package, a file, or a snippet.
- attributionText
- type: xsd:string
- minCount: 0
- contentIdentifier
- type: ContentIdentifier
- minCount: 0

19 changes: 19 additions & 0 deletions model/Software/Properties/contentIdentifier.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
SPDX-License-Identifier: Community-Spec-1.0

# contentIdentifier

## Summary

A canonical, unique, immutable identifier of the artifact content, that may be used for verifying its identity and/or integrity.

## Description

A contentIdentifier is a canonical, unique, immutable identifier of the content of a software artifact, such as a package, a file, or a snippet.
It may be used for verifying its identity and/or integrity.

## Metadata

- name: contentIdentifier
- Nature: DataProperty
- Range: ContentIdentifier

18 changes: 18 additions & 0 deletions model/Software/Properties/contentIdentifierType.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
SPDX-License-Identifier: Community-Spec-1.0

# contentIdentifierType

## Summary

Specifies the type of the content identifier.

## Description

A contentIdentifierType specifies the type of the content identifier.

## Metadata

- name: contentIdentifierType
- Nature: ObjectProperty
- Range: ContentIdentifierType

18 changes: 18 additions & 0 deletions model/Software/Properties/contentIdentifierValue.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
SPDX-License-Identifier: Community-Spec-1.0

# contentIdentifierValue

## Summary

Specifies the value of the content identifier.

## Description

A contentIdentifierValue specifies the value of a content identifier.

## Metadata

- name: contentIdentifierValue
- Nature: DataProperty
- Range: xsd:anyURI

23 changes: 0 additions & 23 deletions model/Software/Properties/gitoid.md

This file was deleted.

21 changes: 21 additions & 0 deletions model/Software/Vocabularies/ContentIdentifierType.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
SPDX-License-Identifier: Community-Spec-1.0

# ContentIdentifierType

## Summary

Specifies the type of a content identifier.

## Description

ContentIdentifierType specifies the type of a content identifier.

## Metadata

- name: ContentIdentifierType

## Entries

- gitoid: Gitoid stands for [Git Object ID](https://git-scm.com/book/en/v2/Git-Internals-Git-Objects) and a gitoid of type blob is a unique hash of a binary artifact. A gitoid may represent the software [Artifact ID](https://github.com/omnibor/spec/blob/main/spec/SPEC.md#artifact-id) or the [OmniBOR Identifier](https://github.com/omnibor/spec/blob/main/spec/SPEC.md#omnibor-identifier) for the software artifact's associated [OmniBOR Document](https://github.com/omnibor/spec/blob/main/spec/SPEC.md#omnibor-document).
- swhid: SoftWare Hash IDentifier, persistent intrinsic identifiers for digital artifacts. The syntax of the identifiers is defined in the [SWHID specification](https://www.swhid.org/specification/v1.1/4.Syntax) and in the case of filess they typically look like `swh:1:cnt:94a9ed024d3859793618152ea559a168bbcbb5e2`.