auth_credentials

package
v0.7.0 Latest Latest
Warning

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

Go to latest
Published: Jan 19, 2022 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AuthCredential

type AuthCredential struct {
	KeySelector string `yaml:"keySelector"`
	In          string `yaml:"in"`
}

AuthCredential struct implements the AuthCredentials interface

func NewAuthCredential

func NewAuthCredential(selector string, location string) *AuthCredential

NewAuthCredential creates a new instance of AuthCredential

func (*AuthCredential) BuildRequestWithCredentials added in v0.2.0

func (c *AuthCredential) BuildRequestWithCredentials(ctx context.Context, endpoint string, method string, credentialValue string, body io.Reader) (*http.Request, error)

func (*AuthCredential) GetCredentialsFromReq

func (c *AuthCredential) GetCredentialsFromReq(httpReq *envoyServiceAuthV3.AttributeContext_HttpRequest) (string, error)

GetCredentialsFromReq will retrieve the secrets from a given location

func (*AuthCredential) GetCredentialsIn added in v0.2.0

func (c *AuthCredential) GetCredentialsIn() string

func (*AuthCredential) GetCredentialsKeySelector

func (c *AuthCredential) GetCredentialsKeySelector() string

type AuthCredentials

type AuthCredentials interface {
	GetCredentialsFromReq(*envoyServiceAuthV3.AttributeContext_HttpRequest) (string, error)
	GetCredentialsKeySelector() string
	GetCredentialsIn() string
	BuildRequestWithCredentials(ctx context.Context, endpoint string, method string, credentialValue string, body io.Reader) (*http.Request, error)
}

AuthCredentials interface represents the methods needed to fetch credentials from input

Directories

Path Synopsis
Package mock_auth_credentials is a generated GoMock package.
Package mock_auth_credentials is a generated GoMock package.

Jump to

Keyboard shortcuts

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