auth

package
v1.32.1-x.3 Latest Latest
Warning

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

Go to latest
Published: Oct 16, 2026 License: MIT Imports: 17 Imported by: 0

Documentation

Index

Constants

View Source
const (
	EnvFile         = "XTEMPORAL_JTI_DENYLIST_FILE"
	EnvPollInterval = "XTEMPORAL_JTI_DENYLIST_POLL_INTERVAL"
	EnvStartupMode  = "XTEMPORAL_JTI_DENYLIST_STARTUP_MODE"
)

Variables

This section is empty.

Functions

func GetAuthorizerFromConfig

func GetAuthorizerFromConfig(cfg *config.Authorization) (authorization.Authorizer, error)

Types

type Denylist

type Denylist struct {
	// contains filtered or unexported fields
}

func NewDenylist

func NewDenylist(source Source, logger log.Logger, handler metrics.Handler, failClosed bool) *Denylist

func (*Denylist) Poll

func (d *Denylist) Poll(ctx context.Context, interval time.Duration)

func (*Denylist) Reload

func (d *Denylist) Reload(ctx context.Context)

func (*Denylist) Revoked

func (d *Denylist) Revoked(jti string) bool

type FileSource

type FileSource struct{ Path string }

func ConfigFromEnv

func ConfigFromEnv() (FileSource, time.Duration, bool, error)

func (FileSource) Load

func (s FileSource) Load(_ context.Context) (_ map[string]int64, retErr error)

type Mapper

type Mapper struct {
	// contains filtered or unexported fields
}

func NewMapper

func NewMapper(delegate authorization.ClaimMapper, denylist *Denylist) *Mapper

func (*Mapper) GetClaims

func (m *Mapper) GetClaims(info *authorization.AuthInfo) (*authorization.Claims, error)

type Source

type Source interface {
	Load(context.Context) (map[string]int64, error)
}

Jump to

Keyboard shortcuts

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