discovery

package
v0.4.0 Latest Latest
Warning

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

Go to latest
Published: Jun 23, 2026 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

Variables

This section is empty.

Functions

This section is empty.

Types

type Document

type Document struct {
	ProtocolVersion string            `json:"protocol_version"`
	ServerURL       string            `json:"server_url"`
	IssuedAt        time.Time         `json:"issued_at"`
	ExpiresAt       time.Time         `json:"expires_at"`
	Signature       SignatureEnvelope `json:"signature"`
}

func (Document) SigningPayload

func (d Document) SigningPayload() Document

SigningPayload preserves the empty signature object in JSON for compatibility with existing workflow-compute discovery signatures.

func (Document) Validate

func (d Document) Validate(now time.Time) error

func (Document) ValidateForProtocol

func (d Document) ValidateForProtocol(now time.Time, protocolVersion string) error

type SignatureEnvelope

type SignatureEnvelope struct {
	Algorithm string `json:"algorithm,omitempty"`
	KeyID     string `json:"key_id,omitempty"`
	Value     string `json:"value,omitempty"`
	Verified  bool   `json:"-"`
}

Jump to

Keyboard shortcuts

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