attestation

package
v0.0.0-...-dc1648f Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 22, 2024 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Attestation

type Attestation struct {
	// contains filtered or unexported fields
}

Attestation controls the sining and verification of resources.

func NewAttestation

func NewAttestation(key string) (*Attestation, error)

NewAttestation instantiate the Attestation helper setting the default parameters expected for signing and verifying resources.

func (*Attestation) GetPass

func (a *Attestation) GetPass(confirm bool) ([]byte, error)

GetPass prompts for the user private-key password only once, when the password is already stored it returns instead.

func (*Attestation) Sign

func (a *Attestation) Sign(payloadPath, outputSignature string) error

Sign signs the resource file (first argument) on the specificed signature location.

func (*Attestation) Verify

func (a *Attestation) Verify(ctx context.Context, blobRef, sigRef string) error

Verify verifies the resource signature

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL