uaaclient

package
v0.0.0-...-ef1509a Latest Latest
Warning

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

Go to latest
Published: Apr 5, 2024 License: Apache-2.0 Imports: 16 Imported by: 38

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewAPI

func NewAPI(cfg Config, logger lager.Logger) (*uaa.API, error)

Types

type Config

type Config struct {
	Port              int
	Protocol          string
	SkipSSLValidation bool
	ClientName        string
	ClientSecret      string
	CACerts           string
	TokenEndpoint     string
	RequestTimeout    time.Duration
}

type TokenFetcher

type TokenFetcher interface {
	FetchKey() (*uaa.JWK, error)
	FetchToken(ctx context.Context, forceUpdate bool) (*oauth2.Token, error)
}

func NewTokenFetcher

func NewTokenFetcher(
	devMode bool,
	cfg Config,
	clk clock.Clock,
	maxNumberOfRetries uint,
	retryInterval time.Duration,
	expirationBufferInSec int64,
	logger lager.Logger,
) (TokenFetcher, error)

type TokenValidator

type TokenValidator interface {
	ValidateToken(uaaToken string, desiredPermissions ...string) error
}

func NewTokenValidator

func NewTokenValidator(devMode bool, cfg Config, logger lager.Logger) (TokenValidator, error)

Directories

Path Synopsis
Code generated by counterfeiter.
Code generated by counterfeiter.

Jump to

Keyboard shortcuts

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