auth

package
v1.3.0 Latest Latest
Warning

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

Go to latest
Published: Aug 6, 2021 License: Apache-2.0 Imports: 27 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AuthService

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

func NewAuthService

func NewAuthService(kubeclient kubernetes.Interface, credentials credentialprovider.Credentials) (*AuthService, error)

NewAuthService creates a new authentication service for akv2k8s

func (AuthService) AuthHandler

func (a AuthService) AuthHandler(w http.ResponseWriter, r *http.Request)

AuthHandler handles authentiction requests to the Auth Service

func (AuthService) AuthValidateHandler

func (a AuthService) AuthValidateHandler(w http.ResponseWriter, r *http.Request)

AuthValidateHandler validates if a pod has valid credentials for authenticating with the Auth Service. If not it will issue a new Secret for the pod to use when authenticating.

func (AuthService) NewMTLSServer

func (a AuthService) NewMTLSServer(router http.Handler, url string) *http.Server

NewMTLSServer creates a new http server with mtls authentication enabled

func (AuthService) NewPodSecret

func (a AuthService) NewPodSecret(pod *corev1.Pod, namespace string, mutationID types.UID) (*corev1.Secret, error)

NewPodSecret creates a new Kubernetes Secret with a client certificate needed for authenticating with the AuthService

type ClientCertificate

type ClientCertificate struct {
	CA  []byte
	Crt []byte
	Key []byte
}

Jump to

Keyboard shortcuts

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