Documentation
¶
Index ¶
Constants ¶
View Source
const ( CommitRef = "refs/attestations/commits" TreeRef = "refs/attestations/trees" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Attestor ¶ added in v0.3.2
type Attestor struct {
// contains filtered or unexported fields
}
func NewAttestor ¶ added in v0.3.2
func NewAttestor(repo *git.Repository, sv *sign.SignerVerifier, rekorFn rekorUpload) *Attestor
func (*Attestor) WriteAttestation ¶ added in v0.3.2
func (a *Attestor) WriteAttestation(ctx context.Context, refName string, sha plumbing.Hash, input Reader, attType string) (plumbing.Hash, error)
WriteAttestion writes the given content + a DSSE signed attestation to the corresponding attestation ref. The SHA of the created commit is returned.
repo: What repository to write to. refName: What ref to write to (e.g. refs/attestations/commits) sha: Commit SHA you are attesting to. input: Attestation file input. attType: Attestation type. See attestation.GenerateStatement for allowed values.
type Encoder ¶
type Encoder interface {
Encode(o plumbing.EncodedObject) error
}
type NamedReader ¶ added in v0.3.2
func (NamedReader) Name ¶ added in v0.3.2
func (r NamedReader) Name() string
Click to show internal directories.
Click to hide internal directories.