pgpsign

package
v0.28.0 Latest Latest
Warning

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

Go to latest
Published: Mar 3, 2026 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ParseArmoredDetachedSignature

func ParseArmoredDetachedSignature(data []byte) (*packet.Signature, []byte, error)

ParseArmoredDetachedSignature parses a detached armored OpenPGP signature and returns the first signature packet and the decoded binary signature payload.

func ReadAllArmoredKeyRings

func ReadAllArmoredKeyRings(pubKeyData []byte) (openpgp.EntityList, error)

ReadAllArmoredKeyRings parses one or more concatenated armored OpenPGP key blocks and returns a combined entity list.

func VerifyArmoredDetachedSignature

func VerifyArmoredDetachedSignature(signedData io.Reader, signatureData, pubKeyData []byte, policy *VerifyPolicy) error

VerifyArmoredDetachedSignature verifies an armored detached OpenPGP signature against signedData using one or more armored public key blocks.

func VerifySignatureWithDigest

func VerifySignatureWithDigest(sig *packet.Signature, keyring openpgp.EntityList, dgst digest.Digest) error

VerifySignatureWithDigest verifies a parsed signature against a digest of the signed payload plus OpenPGP hash suffix (payload || suffix) using the provided keyring.

Types

type VerifyPolicy

type VerifyPolicy struct {
	RejectExpiredKeys bool
}

VerifyPolicy defines validation policy for OpenPGP signature verification.

Jump to

Keyboard shortcuts

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