package bundle
import "github.com/sigstore/sigstore-go/pkg/bundle"
Index ¶
- Constants
- Variables
- func ErrValidationError(err error) error
- func MediaTypeString(version string) (string, error)
- type Bundle
- func LoadJSONFromPath(path string) (*Bundle, error)
- func NewBundle(pbundle *protobundle.Bundle) (*Bundle, error)
- func (b *Bundle) Envelope() (*Envelope, error)
- func (b *Bundle) HasInclusionPromise() bool
- func (b *Bundle) HasInclusionProof() bool
- func (b *Bundle) MarshalJSON() ([]byte, error)
- func (b *Bundle) MinVersion(expectVersion string) bool
- func (b *Bundle) SignatureContent() (verify.SignatureContent, error)
- func (b *Bundle) Timestamps() ([][]byte, error)
- func (b *Bundle) TlogEntries() ([]*tlog.Entry, error)
- func (b *Bundle) UnmarshalJSON(data []byte) error
- func (b *Bundle) VerificationContent() (verify.VerificationContent, error)
- func (b *Bundle) Version() (string, error)
- type Certificate
- func NewCertificate(cert *x509.Certificate) *Certificate
- func (c *Certificate) Certificate() *x509.Certificate
- func (c *Certificate) CompareKey(key any, _ root.TrustedMaterial) bool
- func (c *Certificate) PublicKey() verify.PublicKeyProvider
- func (c *Certificate) ValidAtTime(t time.Time, _ root.TrustedMaterial) bool
- type Envelope
- func (e *Envelope) EnvelopeContent() verify.EnvelopeContent
- func (e *Envelope) MessageSignatureContent() verify.MessageSignatureContent
- func (e *Envelope) RawEnvelope() *dsse.Envelope
- func (e *Envelope) Signature() []byte
- func (e *Envelope) Statement() (*in_toto.Statement, error)
- type MessageSignature
- func NewMessageSignature(digest []byte, digestAlgorithm string, signature []byte) *MessageSignature
- func (m *MessageSignature) Digest() []byte
- func (m *MessageSignature) DigestAlgorithm() string
- func (m *MessageSignature) EnvelopeContent() verify.EnvelopeContent
- func (m *MessageSignature) MessageSignatureContent() verify.MessageSignatureContent
- func (m *MessageSignature) Signature() []byte
- type ProtobufBundle
- type PublicKey
Constants ¶
const IntotoMediaType = "application/vnd.in-toto+json"
Variables ¶
Functions ¶
func ErrValidationError ¶
func MediaTypeString ¶
MediaTypeString returns a mediatype string for the specified bundle version. The function returns an error if the resulting string does validate.
Types ¶
type Bundle ¶
type Bundle struct {
*protobundle.Bundle
// contains filtered or unexported fields
}
func LoadJSONFromPath ¶
func NewBundle ¶
func NewBundle(pbundle *protobundle.Bundle) (*Bundle, error)
func (*Bundle) Envelope ¶
func (*Bundle) HasInclusionPromise ¶
func (*Bundle) HasInclusionProof ¶
func (*Bundle) MarshalJSON ¶
func (*Bundle) MinVersion ¶
MinVersion returns true if the bundle version is greater than or equal to the expected version.
func (*Bundle) SignatureContent ¶
func (b *Bundle) SignatureContent() (verify.SignatureContent, error)
func (*Bundle) Timestamps ¶
func (*Bundle) TlogEntries ¶
func (*Bundle) UnmarshalJSON ¶
func (*Bundle) VerificationContent ¶
func (b *Bundle) VerificationContent() (verify.VerificationContent, error)
func (*Bundle) Version ¶
type Certificate ¶
type Certificate struct {
// contains filtered or unexported fields
}
func NewCertificate ¶
func NewCertificate(cert *x509.Certificate) *Certificate
func (*Certificate) Certificate ¶
func (c *Certificate) Certificate() *x509.Certificate
func (*Certificate) CompareKey ¶
func (c *Certificate) CompareKey(key any, _ root.TrustedMaterial) bool
func (*Certificate) PublicKey ¶
func (c *Certificate) PublicKey() verify.PublicKeyProvider
func (*Certificate) ValidAtTime ¶
func (c *Certificate) ValidAtTime(t time.Time, _ root.TrustedMaterial) bool
type Envelope ¶
func (*Envelope) EnvelopeContent ¶
func (e *Envelope) EnvelopeContent() verify.EnvelopeContent
func (*Envelope) MessageSignatureContent ¶
func (e *Envelope) MessageSignatureContent() verify.MessageSignatureContent
func (*Envelope) RawEnvelope ¶
func (*Envelope) Signature ¶
func (*Envelope) Statement ¶
type MessageSignature ¶
type MessageSignature struct {
// contains filtered or unexported fields
}
func NewMessageSignature ¶
func NewMessageSignature(digest []byte, digestAlgorithm string, signature []byte) *MessageSignature
func (*MessageSignature) Digest ¶
func (m *MessageSignature) Digest() []byte
func (*MessageSignature) DigestAlgorithm ¶
func (m *MessageSignature) DigestAlgorithm() string
func (*MessageSignature) EnvelopeContent ¶
func (m *MessageSignature) EnvelopeContent() verify.EnvelopeContent
func (*MessageSignature) MessageSignatureContent ¶
func (m *MessageSignature) MessageSignatureContent() verify.MessageSignatureContent
func (*MessageSignature) Signature ¶
func (m *MessageSignature) Signature() []byte
type ProtobufBundle ¶
type ProtobufBundle = Bundle
Deprecated: use Bundle instead
func NewProtobufBundle ¶
func NewProtobufBundle(b *protobundle.Bundle) (*ProtobufBundle, error)
Deprecated: use NewBundle instead
type PublicKey ¶
type PublicKey struct {
// contains filtered or unexported fields
}
func (*PublicKey) Certificate ¶
func (pk *PublicKey) Certificate() *x509.Certificate
func (*PublicKey) CompareKey ¶
func (pk *PublicKey) CompareKey(key any, tm root.TrustedMaterial) bool
func (PublicKey) Hint ¶
func (*PublicKey) PublicKey ¶
func (pk *PublicKey) PublicKey() verify.PublicKeyProvider
func (*PublicKey) ValidAtTime ¶
Source Files ¶
bundle.go signature_content.go verification_content.go
- Version
- v1.1.1 (latest)
- Published
- Aug 5, 2025
- Platform
- linux/amd64
- Imports
- 18 packages
- Last checked
- 8 months ago –
Tools for package owners.