signerverifier

package
v0.6.8 Latest Latest
Warning

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

Go to latest
Published: Oct 23, 2024 License: Apache-2.0 Imports: 15 Imported by: 0

README

signerverifier

This package implements methods to sign and verify attestation envelopes.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AsCryptoSigner added in v0.6.0

func AsCryptoSigner(signer dsse.SignerVerifier) (crypto.Signer, error)

func ConvertToPEM

func ConvertToPEM(ecdsaPubKey *ecdsa.PublicKey) ([]byte, error)

func GenKeyPair

func GenKeyPair() (dsse.SignerVerifier, error)

func GetAWSSigner

func GetAWSSigner(ctx context.Context, keyARN string, region string) (dsse.SignerVerifier, error)

using AWS KMS.

func GetGCPSigner

func GetGCPSigner(ctx context.Context, reference string, opts ...option.ClientOption) (dsse.SignerVerifier, error)

using GCP KMS reference should be in the format projects/[PROJECT_ID]/locations/[LOCATION]/keyRings/[KEY_RING]/cryptoKeys/[KEY]/cryptoKeyVersions/[VERSION].

func KeyID

func KeyID(pubKey crypto.PublicKey) (string, error)

func LoadKeyPair

func LoadKeyPair(priv []byte) (dsse.SignerVerifier, error)

func NewECDSASignerVerifier added in v0.6.0

func NewECDSASignerVerifier(signer crypto.Signer) (dsse.SignerVerifier, error)

func NewECDSAVerifier added in v0.6.0

func NewECDSAVerifier(publicKey crypto.PublicKey) (dsse.Verifier, error)

func ParseECDSAPublicKey added in v0.6.0

func ParseECDSAPublicKey(pubkeyBytes []byte) (*ecdsa.PublicKey, error)

func ParsePublicKey

func ParsePublicKey(pubkeyBytes []byte) (crypto.PublicKey, error)

Types

This section is empty.

Jump to

Keyboard shortcuts

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