auth

package
v0.8.0 Latest Latest
Warning

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

Go to latest
Published: Feb 22, 2024 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Overview

Package auth holds logic for authentication.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Token

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

Token supports authentication by providing a token and comparing it to a hash stored in Kubernetes.

func NewToken

func NewToken(k kubeClient, l *zap.SugaredLogger, namespaceUID []byte) *Token

NewToken returns a new Token struct.

func (*Token) Valid

func (p *Token) Valid(ctx context.Context, token string) (bool, error)

Valid returns true if the provided token is valid/correct.

Jump to

Keyboard shortcuts

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