Documentation
¶
Index ¶
- Constants
- func NewGetEvidenceCustom(serverDetails *config.ServerDetails, ...) evidence.Command
- func NewGetEvidenceReleaseBundle(serverDetails *config.ServerDetails, ...) evidence.Command
- func ReadTestDataFile(filename string) (string, error)
- type ArtifactEvidence
- type BuildEvidence
- type CustomEvidenceOutput
- type CustomEvidenceResult
- type EvidenceEntry
- type JsonlLine
- type ReleaseBundleOutput
- type ReleaseBundleResult
- type SubjectType
Constants ¶
View Source
const SchemaVersion = "1.0"
Variables ¶
This section is empty.
Functions ¶
func NewGetEvidenceCustom ¶
func ReadTestDataFile ¶
ReadTestDataFile reads a test data file from the shared testdata directory.
Types ¶
type ArtifactEvidence ¶
type ArtifactEvidence struct {
Evidence EvidenceEntry `json:"evidence"`
PackageType string `json:"packageType"`
RepoPath string `json:"subjectRepoPath"`
}
type BuildEvidence ¶
type BuildEvidence struct {
Evidence EvidenceEntry `json:"evidence"`
BuildName string `json:"buildName"`
BuildNumber string `json:"buildNumber"`
StartedAt string `json:"startedAt"`
}
type CustomEvidenceOutput ¶
type CustomEvidenceOutput struct {
SchemaVersion string `json:"schemaVersion"`
Type SubjectType `json:"type"`
Result CustomEvidenceResult `json:"result"`
}
CustomEvidenceOutput represents the structured output format for custom evidence
type CustomEvidenceResult ¶
type CustomEvidenceResult struct {
RepoPath string `json:"subjectRepoPath"`
Evidence []EvidenceEntry `json:"evidence"`
}
type EvidenceEntry ¶
type EvidenceEntry struct {
PredicateSlug string `json:"predicateSlug"`
PredicateType string `json:"predicateType,omitempty"`
DownloadPath string `json:"downloadPath"`
Verified bool `json:"verified"`
SigningKey map[string]any `json:"signingKey,omitempty"`
Subject map[string]any `json:"subject"`
CreatedBy string `json:"createdBy"`
CreatedAt string `json:"createdAt"`
Predicate map[string]any `json:"predicate,omitempty"`
}
type JsonlLine ¶
type JsonlLine struct {
SchemaVersion string `json:"schemaVersion"`
Type SubjectType `json:"type"`
Result any `json:"result"`
}
type ReleaseBundleOutput ¶
type ReleaseBundleOutput struct {
SchemaVersion string `json:"schemaVersion"`
Type SubjectType `json:"type"`
Result ReleaseBundleResult `json:"result"`
}
type ReleaseBundleResult ¶
type ReleaseBundleResult struct {
ReleaseBundle string `json:"releaseBundle"`
ReleaseBundleVersion string `json:"releaseBundleVersion"`
Evidence []EvidenceEntry `json:"evidence"`
Artifacts []ArtifactEvidence `json:"artifacts,omitempty"`
Builds []BuildEvidence `json:"builds,omitempty"`
}
type SubjectType ¶
type SubjectType string // Types in GetEvidence output
const ( ArtifactType SubjectType = "artifact" BuildType SubjectType = "build" ReleaseBundleType SubjectType = "release-bundle" )
Click to show internal directories.
Click to hide internal directories.