workload

package
v1.0.2 Latest Latest
Warning

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

Go to latest
Published: May 18, 2023 License: Apache-2.0 Imports: 25 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Attestor

type Attestor interface {
	Attest(ctx context.Context) ([]*common.Selector, error)
}

type Config

type Config struct {
	Manager                       Manager
	Attestor                      Attestor
	AllowUnauthenticatedVerifiers bool
	AllowedForeignJWTClaims       map[string]struct{}
	TrustDomain                   spiffeid.TrustDomain
}

Handler implements the Workload API interface

type Handler

type Handler struct {
	workload.UnsafeSpiffeWorkloadAPIServer
	// contains filtered or unexported fields
}

func New

func New(c Config) *Handler

func (*Handler) FetchJWTBundles

FetchJWTBundles processes request for JWT bundles

func (*Handler) FetchJWTSVID

func (h *Handler) FetchJWTSVID(ctx context.Context, req *workload.JWTSVIDRequest) (resp *workload.JWTSVIDResponse, err error)

FetchJWTSVID processes request for a JWT-SVID

func (*Handler) FetchX509Bundles

FetchX509Bundles processes request for x509 bundles

func (*Handler) FetchX509SVID

FetchX509SVID processes request for an x509 SVID

func (*Handler) ValidateJWTSVID

ValidateJWTSVID processes request for JWT-SVID validation

type Manager

type Manager interface {
	SubscribeToCacheChanges(ctx context.Context, key cache.Selectors) (cache.Subscriber, error)
	MatchingRegistrationEntries(selectors []*common.Selector) []*common.RegistrationEntry
	FetchJWTSVID(ctx context.Context, spiffeID spiffeid.ID, audience []string) (*client.JWTSVID, error)
	FetchWorkloadUpdate([]*common.Selector) *cache.WorkloadUpdate
}

Jump to

Keyboard shortcuts

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