auth

package
v1.1.11 Latest Latest
Warning

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

Go to latest
Published: Mar 9, 2023 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AConfig

type AConfig struct {
	Logger    hclog.Logger
	MountPath string
	WrapTTL   time.Duration
	Config    map[string]interface{}
}

type AHandler

type AHandler struct {
	DoneCh   chan struct{}
	OutputCh chan string
	// contains filtered or unexported fields
}

AHandler is responsible for keeping a token alive and renewed and passing new tokens to the sink server

func NewAHandler

func NewAHandler(conf *AHandlerConfig) *AHandler

func (*AHandler) Run

func (ah *AHandler) Run(ctx context.Context, am AMethod)

type AHandlerConfig

type AHandlerConfig struct {
	Logger                       hclog.Logger
	Client                       *api.Client
	WrapTTL                      time.Duration
	EnableReauthOnNewCredentials bool
}

type AMethod

type AMethod interface {
	Authenticate(context.Context, *api.Client) (string, map[string]interface{}, error)
	NewCreds() chan struct{}
	CredSuccess()
	Shutdown()
}

Jump to

Keyboard shortcuts

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