Documentation
¶
Overview ¶
Package routeplan owns bounded DKIM2 fanout planning and ticket state.
Index ¶
- func IsErrorCode(err error, code ErrorCode) bool
- type AuthorityResult
- func NewAuthorityResult(status AuthorityStatus, parentID [sha256.Size]byte, ...) AuthorityResult
- func NewFinalizeAuthorityResult(query FinalizeQuery, parentID, parentSeal [sha256.Size]byte, ...) AuthorityResult
- func NewTransitionAuthorityResult(status AuthorityStatus, query TicketQuery, ...) AuthorityResult
- type AuthorityStatus
- type Coordinator
- func (c Coordinator) Finalize(ctx context.Context, request PlanRequest) (RouteFanoutPlan, []CopyTicket, error)
- func (c Coordinator) Format(state fmt.State, _ rune)
- func (c Coordinator) GoString() string
- func (c Coordinator) Reserve(ctx context.Context, ticket CopyTicket) (Reservation, error)
- func (c Coordinator) String() string
- func (c Coordinator) Valid() bool
- type CopyTicket
- func (t CopyTicket) BindingIdentity() [sha256.Size]byte
- func (t CopyTicket) DisclosureClass() DisclosureClass
- func (t CopyTicket) DisclosureRecipients() [][]byte
- func (t CopyTicket) Format(state fmt.State, _ rune)
- func (t CopyTicket) GoString() string
- func (t CopyTicket) InboundReceiverBinding() []byte
- func (t CopyTicket) MatchesEnvelope(reversePath []byte, forwardPaths [][]byte) bool
- func (t CopyTicket) MatchesRevisionBinding(binding []byte) bool
- func (t CopyTicket) MatchesSource(raw []byte) bool
- func (t CopyTicket) OutboundReceiverBinding() []byte
- func (t CopyTicket) ParentIdentity() [sha256.Size]byte
- func (t CopyTicket) Purpose() Purpose
- func (t CopyTicket) ReversePath() []byte
- func (t CopyTicket) RouteClass() RouteClass
- func (t CopyTicket) RouteScope() []byte
- func (t CopyTicket) String() string
- func (t CopyTicket) TicketIdentity() [sha256.Size]byte
- func (t CopyTicket) TotalMultiplicity() int
- func (t CopyTicket) Valid() bool
- type DisclosureClass
- type Entry
- func NewClassifiedEntry(source ImmutableSource, purpose Purpose, reversePath []byte, ...) (Entry, error)
- func NewDualReceiverClassifiedEntry(source ImmutableSource, purpose Purpose, reversePath []byte, ...) (Entry, error)
- func NewEntry(source ImmutableSource, purpose Purpose, reversePath []byte, ...) (Entry, error)
- type Error
- type ErrorCode
- type FinalizeQuery
- type ImmutableSource
- type Limits
- type MemoryAuthority
- func (a *MemoryAuthority) Burn(ctx context.Context, query TicketQuery) (AuthorityResult, error)
- func (a *MemoryAuthority) ConsumeRelease(ctx context.Context, query TicketQuery) (AuthorityResult, error)
- func (a *MemoryAuthority) Finalize(ctx context.Context, query FinalizeQuery) (AuthorityResult, error)
- func (a *MemoryAuthority) Format(state fmt.State, _ rune)
- func (a *MemoryAuthority) GoString() string
- func (a *MemoryAuthority) ReleaseReservation(ctx context.Context, query TicketQuery) (AuthorityResult, error)
- func (a *MemoryAuthority) Replace(ctx context.Context, query TicketQuery) (AuthorityResult, error)
- func (a *MemoryAuthority) Reserve(ctx context.Context, query TicketQuery) (AuthorityResult, error)
- func (a *MemoryAuthority) String() string
- type PlanRequest
- type Purpose
- type ReleaseRequirement
- type Reservation
- func (r *Reservation) CommitSuccessfulSigning(requirement ReleaseRequirement) error
- func (r *Reservation) ConsumeRestrictedRelease(ctx context.Context, proof RestrictedReleaseProof) error
- func (r Reservation) Format(state fmt.State, _ rune)
- func (r Reservation) GoString() string
- func (r *Reservation) PrepareExternalBoundary(ctx context.Context) error
- func (r *Reservation) RecoverReplacement() (CopyTicket, error)
- func (r Reservation) RecoveryRequired() bool
- func (r *Reservation) ReleaseBeforeBoundary(ctx context.Context) error
- func (r Reservation) ReleaseRequired() bool
- func (r *Reservation) Replacement(ctx context.Context) (CopyTicket, error)
- func (r Reservation) ReplacementRequired() bool
- func (r *Reservation) RequiredRelease() ReleaseRequirement
- func (r *Reservation) RestrictedReleaseRequired() bool
- func (r Reservation) String() string
- type RestrictedReleaseProof
- type RouteClass
- type RouteFanoutAuthority
- type RouteFanoutPlan
- type TicketQuery
- func (q TicketQuery) BindingIdentity() [sha256.Size]byte
- func (q TicketQuery) CapabilitySeal() [sha256.Size]byte
- func (q TicketQuery) Format(state fmt.State, _ rune)
- func (q TicketQuery) GoString() string
- func (q TicketQuery) ParentIdentity() [sha256.Size]byte
- func (q TicketQuery) String() string
- func (q TicketQuery) TicketIdentity() [sha256.Size]byte
- func (q TicketQuery) Valid() bool
- type Usage
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func IsErrorCode ¶
IsErrorCode reports whether err contains a route error with code.
Types ¶
type AuthorityResult ¶
type AuthorityResult struct {
// contains filtered or unexported fields
}
AuthorityResult carries only opaque authority identities and a closed status.
func NewAuthorityResult ¶
func NewAuthorityResult(status AuthorityStatus, parentID [sha256.Size]byte, ticketIDs [][sha256.Size]byte) AuthorityResult
NewAuthorityResult constructs a detached authority result for a specific method.
func NewFinalizeAuthorityResult ¶
func NewFinalizeAuthorityResult(query FinalizeQuery, parentID, parentSeal [sha256.Size]byte, ticketIDs, ticketSeals [][sha256.Size]byte) AuthorityResult
NewFinalizeAuthorityResult constructs issuance bound to exact ordered finalize bindings.
func NewTransitionAuthorityResult ¶
func NewTransitionAuthorityResult(status AuthorityStatus, query TicketQuery, replacementIDs, replacementSeals [][sha256.Size]byte) AuthorityResult
NewTransitionAuthorityResult constructs one transition bound to the exact queried ticket.
func (AuthorityResult) Format ¶
func (r AuthorityResult) Format(state fmt.State, _ rune)
Format routes every result formatting form through the redacted summary.
func (AuthorityResult) GoString ¶
func (r AuthorityResult) GoString() string
GoString returns a constant secret-safe authority result Go representation.
func (AuthorityResult) Status ¶
func (r AuthorityResult) Status() AuthorityStatus
Status returns the closed result status.
func (AuthorityResult) String ¶
func (r AuthorityResult) String() string
String returns a constant secret-safe authority result summary.
type AuthorityStatus ¶
type AuthorityStatus string
AuthorityStatus identifies one method-specific route authority outcome.
const ( // AuthorityIssued reports successful parent and ticket identity issuance. AuthorityIssued AuthorityStatus = "issued" // AuthorityReserved reports an atomic fresh-to-reserved transition. AuthorityReserved AuthorityStatus = "reserved" // AuthorityReleased reports a pre-boundary reserved-to-released transition. AuthorityReleased AuthorityStatus = "released" // AuthorityBurned reports a reserved-to-burned external-boundary transition. AuthorityBurned AuthorityStatus = "burned" // AuthorityReplacementIssued reports same-lineage replacement issuance. AuthorityReplacementIssued AuthorityStatus = "replacement_issued" // AuthorityConsumed reports restricted release-phase consumption. AuthorityConsumed AuthorityStatus = "consumed" // AuthorityDenied reports a valid request refused by authority policy or state. AuthorityDenied AuthorityStatus = "denied" )
func (AuthorityStatus) Known ¶
func (s AuthorityStatus) Known() bool
Known reports whether status belongs to the closed authority vocabulary.
type Coordinator ¶
type Coordinator struct {
// contains filtered or unexported fields
}
Coordinator validates local planning and every injected authority matrix.
func NewCoordinator ¶
func NewCoordinator(authority RouteFanoutAuthority, limits Limits) (Coordinator, error)
NewCoordinator constructs a bounded route authority coordinator.
func (Coordinator) Finalize ¶
func (c Coordinator) Finalize(ctx context.Context, request PlanRequest) (RouteFanoutPlan, []CopyTicket, error)
Finalize validates and issues one immutable one-to-one parent fanout.
func (Coordinator) Format ¶
func (c Coordinator) Format(state fmt.State, _ rune)
Format routes every coordinator formatting form through the redacted summary.
func (Coordinator) GoString ¶
func (c Coordinator) GoString() string
GoString returns a constant secret-safe coordinator Go representation.
func (Coordinator) Reserve ¶
func (c Coordinator) Reserve(ctx context.Context, ticket CopyTicket) (Reservation, error)
Reserve atomically acquires one fresh ticket for an operation.
func (Coordinator) String ¶
func (c Coordinator) String() string
String returns a constant secret-safe coordinator summary.
func (Coordinator) Valid ¶
func (c Coordinator) Valid() bool
Valid reports whether the coordinator owns a bounded non-nil authority.
type CopyTicket ¶
type CopyTicket struct {
// contains filtered or unexported fields
}
CopyTicket is one immutable, non-reusable authority-bound fanout capability.
func (CopyTicket) BindingIdentity ¶
func (t CopyTicket) BindingIdentity() [sha256.Size]byte
BindingIdentity returns the opaque exact pre-sign transcript digest.
func (CopyTicket) DisclosureClass ¶
func (t CopyTicket) DisclosureClass() DisclosureClass
DisclosureClass returns the exact copy disclosure class.
func (CopyTicket) DisclosureRecipients ¶
func (t CopyTicket) DisclosureRecipients() [][]byte
DisclosureRecipients returns only this copy's disclosure-safe ordered rt set.
func (CopyTicket) Format ¶
func (t CopyTicket) Format(state fmt.State, _ rune)
Format routes every ticket formatting form through the redacted summary.
func (CopyTicket) GoString ¶
func (t CopyTicket) GoString() string
GoString returns a constant secret-safe ticket Go representation.
func (CopyTicket) InboundReceiverBinding ¶
func (t CopyTicket) InboundReceiverBinding() []byte
InboundReceiverBinding returns detached inbound OOB acceptance evidence.
func (CopyTicket) MatchesEnvelope ¶
func (t CopyTicket) MatchesEnvelope(reversePath []byte, forwardPaths [][]byte) bool
MatchesEnvelope reports exact reverse-path and ordered forward-path equality.
func (CopyTicket) MatchesRevisionBinding ¶
func (t CopyTicket) MatchesRevisionBinding(binding []byte) bool
MatchesRevisionBinding compares one sealed revision identity in constant time.
func (CopyTicket) MatchesSource ¶
func (t CopyTicket) MatchesSource(raw []byte) bool
MatchesSource reports whether exact bytes match the library-computed binding.
func (CopyTicket) OutboundReceiverBinding ¶
func (t CopyTicket) OutboundReceiverBinding() []byte
OutboundReceiverBinding returns detached outbound OOB acceptance evidence.
func (CopyTicket) ParentIdentity ¶
func (t CopyTicket) ParentIdentity() [sha256.Size]byte
ParentIdentity returns an opaque parent binding for trusted internal coordinators.
func (CopyTicket) Purpose ¶
func (t CopyTicket) Purpose() Purpose
Purpose returns the closed pre-sign binding purpose.
func (CopyTicket) ReversePath ¶
func (t CopyTicket) ReversePath() []byte
ReversePath returns this copy's exact detached SMTP reverse-path.
func (CopyTicket) RouteClass ¶
func (t CopyTicket) RouteClass() RouteClass
RouteClass returns the sealed restricted-release classification.
func (CopyTicket) RouteScope ¶
func (t CopyTicket) RouteScope() []byte
RouteScope returns a detached opaque scope for trusted internal authorization.
func (CopyTicket) String ¶
func (t CopyTicket) String() string
String returns a constant secret-safe ticket summary.
func (CopyTicket) TicketIdentity ¶
func (t CopyTicket) TicketIdentity() [sha256.Size]byte
TicketIdentity returns an opaque copy binding for trusted internal coordinators.
func (CopyTicket) TotalMultiplicity ¶
func (t CopyTicket) TotalMultiplicity() int
TotalMultiplicity returns the authority-sealed parent copy count.
func (CopyTicket) Valid ¶
func (t CopyTicket) Valid() bool
Valid reports whether the ticket has complete sealed binding state.
type DisclosureClass ¶
type DisclosureClass string
DisclosureClass identifies the recipient-disclosure policy of one copy.
const ( // DisclosureSingle exposes exactly one recipient. DisclosureSingle DisclosureClass = "single" // DisclosureAuthorizedGroup requires exact multi-recipient authorization. DisclosureAuthorizedGroup DisclosureClass = "authorized_group" // DisclosureBccSeparated identifies a single-recipient privacy copy. DisclosureBccSeparated DisclosureClass = "bcc_separated" )
func (DisclosureClass) Known ¶
func (c DisclosureClass) Known() bool
Known reports whether class belongs to the closed disclosure vocabulary.
type Entry ¶
type Entry struct {
// contains filtered or unexported fields
}
Entry describes one intended output before authority issuance.
func NewClassifiedEntry ¶
func NewClassifiedEntry( source ImmutableSource, purpose Purpose, reversePath []byte, forwardPaths [][]byte, disclosure DisclosureClass, routeClass RouteClass, routeScope, receiverBinding, revisionBinding []byte, ) (Entry, error)
NewClassifiedEntry constructs one immutable route entry with a closed release class.
func NewDualReceiverClassifiedEntry ¶
func NewDualReceiverClassifiedEntry( source ImmutableSource, purpose Purpose, reversePath []byte, forwardPaths [][]byte, disclosure DisclosureClass, routeClass RouteClass, routeScope, inboundReceiverBinding, outboundReceiverBinding, revisionBinding []byte, ) (Entry, error)
NewDualReceiverClassifiedEntry constructs one immutable route entry with independently sealed inbound and outbound OOB receiver evidence.
func NewEntry ¶
func NewEntry(source ImmutableSource, purpose Purpose, reversePath []byte, forwardPaths [][]byte, disclosure DisclosureClass, routeScope, revisionBinding []byte) (Entry, error)
NewEntry constructs one immutable ordinary external route entry.
type Error ¶
type Error struct {
// contains filtered or unexported fields
}
Error is a content-free route planning failure.
type ErrorCode ¶
type ErrorCode string
ErrorCode identifies one bounded route planning failure.
const ( // ErrorInvalidOptions reports invalid or widened limits. ErrorInvalidOptions ErrorCode = "invalid_options" // ErrorInvalidRequest reports malformed route input. ErrorInvalidRequest ErrorCode = "invalid_request" // ErrorLimitExceeded reports a coupled planning or call budget failure. ErrorLimitExceeded ErrorCode = "limit_exceeded" // ErrorDenied reports an authority denial. ErrorDenied ErrorCode = "denied" // ErrorTemporary reports typed retryable authority unavailability. ErrorTemporary ErrorCode = "temporary" // ErrorPermanent reports typed permanent authority unavailability. ErrorPermanent ErrorCode = "permanent" // ErrorContract reports an illegal authority result/error matrix. ErrorContract ErrorCode = "contract" // ErrorState reports an illegal ticket transition. ErrorState ErrorCode = "state" )
type FinalizeQuery ¶
type FinalizeQuery struct {
// contains filtered or unexported fields
}
FinalizeQuery carries trusted exact bindings across the explicit authority boundary.
func (FinalizeQuery) BindingDigest ¶
func (q FinalizeQuery) BindingDigest(index int) []byte
BindingDigest returns one detached exact pre-sign binding digest.
func (FinalizeQuery) Count ¶
func (q FinalizeQuery) Count() int
Count returns the required coupled copy/ticket count.
func (FinalizeQuery) Format ¶
func (q FinalizeQuery) Format(state fmt.State, _ rune)
Format routes every query formatting form through the redacted summary.
func (FinalizeQuery) GoString ¶
func (q FinalizeQuery) GoString() string
GoString returns a constant secret-safe query Go representation.
func (FinalizeQuery) String ¶
func (q FinalizeQuery) String() string
String returns a constant secret-safe query summary.
func (FinalizeQuery) Usage ¶
func (q FinalizeQuery) Usage() Usage
Usage returns bounded planning charges.
func (FinalizeQuery) Valid ¶
func (q FinalizeQuery) Valid() bool
Valid reports whether the query owns a complete coupled binding and usage shape.
type ImmutableSource ¶
type ImmutableSource struct {
// contains filtered or unexported fields
}
ImmutableSource owns exact cloned pre-sign RFC 5322 bytes and explicit identity.
func NewImmutableSource ¶
func NewImmutableSource(raw []byte) (ImmutableSource, error)
NewImmutableSource clones one exact source; equal independent inputs remain distinct sources.
func (ImmutableSource) Format ¶
func (s ImmutableSource) Format(state fmt.State, _ rune)
Format routes every source formatting form through the redacted summary.
func (ImmutableSource) GoString ¶
func (s ImmutableSource) GoString() string
GoString returns a constant secret-safe source Go representation.
func (ImmutableSource) String ¶
func (s ImmutableSource) String() string
String returns a constant secret-safe source summary.
func (ImmutableSource) Valid ¶
func (s ImmutableSource) Valid() bool
Valid reports whether the source was constructed with owned bytes.
type Limits ¶
type Limits struct {
MaxCopiesAndTickets int
MaxDescriptorBytes int
MaxWorkUnits int
MaxSourceBytes int
MaxUniqueSourceBytes int
MaxRecipientsPerCopy int
MaxEnvelopePathBytes int
MaxAuthorityCalls int
}
Limits contains routeplan-owned narrowable ceilings.
func DefaultLimits ¶
func DefaultLimits() Limits
DefaultLimits returns the route planning hard ceilings.
type MemoryAuthority ¶
type MemoryAuthority struct {
// contains filtered or unexported fields
}
MemoryAuthority is a concurrency-safe reference authority for library use and tests.
func NewMemoryAuthority ¶
func NewMemoryAuthority() *MemoryAuthority
NewMemoryAuthority constructs an empty authority state owner.
func (*MemoryAuthority) Burn ¶
func (a *MemoryAuthority) Burn(ctx context.Context, query TicketQuery) (AuthorityResult, error)
Burn atomically consumes retryability before an external callback.
func (*MemoryAuthority) ConsumeRelease ¶
func (a *MemoryAuthority) ConsumeRelease(ctx context.Context, query TicketQuery) (AuthorityResult, error)
ConsumeRelease atomically consumes one burned ticket's restricted release phase.
func (*MemoryAuthority) Finalize ¶
func (a *MemoryAuthority) Finalize(ctx context.Context, query FinalizeQuery) (AuthorityResult, error)
Finalize atomically issues one parent and exactly one unique ticket per binding.
func (*MemoryAuthority) Format ¶
func (a *MemoryAuthority) Format(state fmt.State, _ rune)
Format routes every authority formatting form through the redacted summary.
func (*MemoryAuthority) GoString ¶
func (a *MemoryAuthority) GoString() string
GoString returns a constant secret-safe authority Go representation.
func (*MemoryAuthority) ReleaseReservation ¶
func (a *MemoryAuthority) ReleaseReservation(ctx context.Context, query TicketQuery) (AuthorityResult, error)
ReleaseReservation atomically moves a pre-boundary reservation to the released retry state. Releasing the same authority-sealed ticket is idempotent so callers can reconcile a committed release whose acknowledgement was lost or malformed.
func (*MemoryAuthority) Replace ¶
func (a *MemoryAuthority) Replace(ctx context.Context, query TicketQuery) (AuthorityResult, error)
Replace atomically issues one fresh same-lineage replacement for a burned ticket.
func (*MemoryAuthority) Reserve ¶
func (a *MemoryAuthority) Reserve(ctx context.Context, query TicketQuery) (AuthorityResult, error)
Reserve atomically moves one fresh ticket to reserved.
func (*MemoryAuthority) String ¶
func (a *MemoryAuthority) String() string
String returns a constant secret-safe authority summary.
type PlanRequest ¶
type PlanRequest struct {
// contains filtered or unexported fields
}
PlanRequest contains one immutable complete intended fanout.
func NewPlanRequest ¶
func NewPlanRequest(entries []Entry) (PlanRequest, error)
NewPlanRequest snapshots the exact ordered route entries.
func (PlanRequest) Count ¶
func (r PlanRequest) Count() int
Count returns the immutable intended copy count.
func (PlanRequest) Format ¶
func (r PlanRequest) Format(state fmt.State, _ rune)
Format routes every request formatting form through the redacted summary.
func (PlanRequest) GoString ¶
func (r PlanRequest) GoString() string
GoString returns a constant secret-safe request Go representation.
func (PlanRequest) String ¶
func (r PlanRequest) String() string
String returns a constant secret-safe request summary.
type Purpose ¶
type Purpose string
Purpose identifies why exact pre-sign bytes are being routed.
const ( // PurposeOrigin identifies an originator copy. PurposeOrigin Purpose = "origin" // PurposeRevision identifies a verified revision copy. PurposeRevision Purpose = "revision" // PurposeNextDomain identifies a terminal next-domain copy. PurposeNextDomain Purpose = "next_domain" // PurposeDeliveryStatus identifies a DSN copy authorized by dedicated evidence. PurposeDeliveryStatus Purpose = "delivery_status" // PurposeDeliveryStatusPropagation identifies a propagated DSN copy whose // authority is the removed completion signature of a rebuilt report. PurposeDeliveryStatusPropagation Purpose = "delivery_status_propagation" )
type ReleaseRequirement ¶
type ReleaseRequirement string
ReleaseRequirement identifies the sole route proof required after successful signing.
const ( // ReleaseUnrestricted completes signing without a restricted release phase. ReleaseUnrestricted ReleaseRequirement = "unrestricted" // ReleaseOutOfBand requires a same-ticket sealed OOB receiver and envelope proof. ReleaseOutOfBand ReleaseRequirement = "out_of_band" )
func (ReleaseRequirement) Known ¶
func (r ReleaseRequirement) Known() bool
Known reports whether requirement belongs to the closed release vocabulary.
func (ReleaseRequirement) Restricted ¶
func (r ReleaseRequirement) Restricted() bool
Restricted reports whether successful signing retains an authority release phase.
type Reservation ¶
type Reservation struct {
// contains filtered or unexported fields
}
Reservation owns one operation's route-authority call budget and boundary state.
func (*Reservation) CommitSuccessfulSigning ¶
func (r *Reservation) CommitSuccessfulSigning(requirement ReleaseRequirement) error
CommitSuccessfulSigning closes replacement and records the exact release requirement.
func (*Reservation) ConsumeRestrictedRelease ¶
func (r *Reservation) ConsumeRestrictedRelease(ctx context.Context, proof RestrictedReleaseProof) error
ConsumeRestrictedRelease atomically consumes the exact proved release phase.
func (Reservation) Format ¶
func (r Reservation) Format(state fmt.State, _ rune)
Format routes every reservation formatting form through the redacted summary.
func (Reservation) GoString ¶
func (r Reservation) GoString() string
GoString returns a constant secret-safe reservation Go representation.
func (*Reservation) PrepareExternalBoundary ¶
func (r *Reservation) PrepareExternalBoundary(ctx context.Context) error
PrepareExternalBoundary burns the ticket before the first non-routeplan callback.
func (*Reservation) RecoverReplacement ¶
func (r *Reservation) RecoverReplacement() (CopyTicket, error)
RecoverReplacement returns a replacement issued before post-call cancellation.
func (Reservation) RecoveryRequired ¶
func (r Reservation) RecoveryRequired() bool
RecoveryRequired reports whether a failed cancellation cleanup retained a releasable reservation.
func (*Reservation) ReleaseBeforeBoundary ¶
func (r *Reservation) ReleaseBeforeBoundary(ctx context.Context) error
ReleaseBeforeBoundary releases a reservation only before any external boundary.
func (Reservation) ReleaseRequired ¶
func (r Reservation) ReleaseRequired() bool
ReleaseRequired reports whether a reserved ticket still precedes the external boundary.
func (*Reservation) Replacement ¶
func (r *Reservation) Replacement(ctx context.Context) (CopyTicket, error)
Replacement requests one fresh same-lineage ticket after a burn.
func (Reservation) ReplacementRequired ¶
func (r Reservation) ReplacementRequired() bool
ReplacementRequired reports whether a committed burn requires a replacement after failure.
func (*Reservation) RequiredRelease ¶
func (r *Reservation) RequiredRelease() ReleaseRequirement
RequiredRelease returns the exact pending restricted release requirement.
func (*Reservation) RestrictedReleaseRequired ¶
func (r *Reservation) RestrictedReleaseRequired() bool
RestrictedReleaseRequired reports whether successful restricted signing awaits route-bound release.
func (Reservation) String ¶
func (r Reservation) String() string
String returns a constant secret-safe reservation summary.
type RestrictedReleaseProof ¶
type RestrictedReleaseProof struct {
// contains filtered or unexported fields
}
RestrictedReleaseProof is an opaque exact-ticket release authorization.
func NewOutOfBandReleaseProof ¶
func NewOutOfBandReleaseProof( ticket CopyTicket, reversePath []byte, forwardPaths [][]byte, receiverBinding, routeScope []byte, ) (RestrictedReleaseProof, error)
NewOutOfBandReleaseProof proves one exact OOB receiver, envelope, and route.
func (RestrictedReleaseProof) Format ¶
func (p RestrictedReleaseProof) Format(state fmt.State, _ rune)
Format routes every release-proof formatting form through the redacted summary.
func (RestrictedReleaseProof) GoString ¶
func (p RestrictedReleaseProof) GoString() string
GoString returns a constant secret-safe release-proof Go representation.
func (RestrictedReleaseProof) Requirement ¶
func (p RestrictedReleaseProof) Requirement() ReleaseRequirement
Requirement returns the proof's closed restricted-release class.
func (RestrictedReleaseProof) String ¶
func (p RestrictedReleaseProof) String() string
String returns a constant secret-safe release-proof summary.
func (RestrictedReleaseProof) Valid ¶
func (p RestrictedReleaseProof) Valid() bool
Valid reports whether the proof binds one exact authority-issued ticket transition.
type RouteClass ¶
type RouteClass string
RouteClass identifies whether a sealed route is eligible for restricted release.
const ( // RouteExternal identifies an ordinary route that cannot release restricted output. RouteExternal RouteClass = "external" // RouteInControl identifies a sealed route that stays under the operator's control. RouteInControl RouteClass = "in_control" // RouteOutOfBand identifies a sealed receiver arrangement eligible for OOB release. RouteOutOfBand RouteClass = "out_of_band" )
func (RouteClass) Known ¶
func (c RouteClass) Known() bool
Known reports whether class belongs to the closed route-scope vocabulary.
type RouteFanoutAuthority ¶
type RouteFanoutAuthority interface {
Finalize(context.Context, FinalizeQuery) (AuthorityResult, error)
Reserve(context.Context, TicketQuery) (AuthorityResult, error)
ReleaseReservation(context.Context, TicketQuery) (AuthorityResult, error)
Burn(context.Context, TicketQuery) (AuthorityResult, error)
Replace(context.Context, TicketQuery) (AuthorityResult, error)
ConsumeRelease(context.Context, TicketQuery) (AuthorityResult, error)
}
RouteFanoutAuthority is the sole issuer and state-transition owner.
type RouteFanoutPlan ¶
type RouteFanoutPlan struct {
// contains filtered or unexported fields
}
RouteFanoutPlan is an immutable finalized parent fanout.
func (RouteFanoutPlan) CopyCount ¶
func (p RouteFanoutPlan) CopyCount() int
CopyCount returns finalized total multiplicity.
func (RouteFanoutPlan) Format ¶
func (p RouteFanoutPlan) Format(state fmt.State, _ rune)
Format routes every parent formatting form through the redacted summary.
func (RouteFanoutPlan) GoString ¶
func (p RouteFanoutPlan) GoString() string
GoString returns a constant secret-safe parent Go representation.
func (RouteFanoutPlan) String ¶
func (p RouteFanoutPlan) String() string
String returns a constant secret-safe parent summary.
func (RouteFanoutPlan) Usage ¶
func (p RouteFanoutPlan) Usage() Usage
Usage returns bounded planning usage.
func (RouteFanoutPlan) Valid ¶
func (p RouteFanoutPlan) Valid() bool
Valid reports whether the parent has a complete one-to-one sealed shape.
type TicketQuery ¶
type TicketQuery struct {
// contains filtered or unexported fields
}
TicketQuery identifies one exact authority-owned ticket transition.
func (TicketQuery) BindingIdentity ¶
func (q TicketQuery) BindingIdentity() [sha256.Size]byte
BindingIdentity returns the opaque exact-copy binding across the authority boundary.
func (TicketQuery) CapabilitySeal ¶
func (q TicketQuery) CapabilitySeal() [sha256.Size]byte
CapabilitySeal returns the authority-issued opaque ticket seal.
func (TicketQuery) Format ¶
func (q TicketQuery) Format(state fmt.State, _ rune)
Format routes every query formatting form through the redacted summary.
func (TicketQuery) GoString ¶
func (q TicketQuery) GoString() string
GoString returns a constant secret-safe ticket query Go representation.
func (TicketQuery) ParentIdentity ¶
func (q TicketQuery) ParentIdentity() [sha256.Size]byte
ParentIdentity returns the opaque parent identity across the authority boundary.
func (TicketQuery) String ¶
func (q TicketQuery) String() string
String returns a constant secret-safe ticket query summary.
func (TicketQuery) TicketIdentity ¶
func (q TicketQuery) TicketIdentity() [sha256.Size]byte
TicketIdentity returns the opaque ticket identity across the authority boundary.
func (TicketQuery) Valid ¶
func (q TicketQuery) Valid() bool
Valid reports whether every opaque ticket-transition identity is nonzero.