package webhook

import "k8s.io/apiserver/plugin/pkg/authenticator/token/webhook"

Package webhook implements the authenticator.Token interface using HTTP webhooks.

Index

Types

type WebhookTokenAuthenticator

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

func New

func New(kubeConfigFile string, implicitAuds authenticator.Audiences) (*WebhookTokenAuthenticator, error)

New creates a new WebhookTokenAuthenticator from the provided kubeconfig file. It is recommend to wrap this authenticator with the token cache authenticator implemented in k8s.io/apiserver/pkg/authentication/token/cache.

func NewFromInterface

NewFromInterface creates a webhook authenticator using the given tokenReview client. It is recommend to wrap this authenticator with the token cache authenticator implemented in k8s.io/apiserver/pkg/authentication/token/cache.

func (*WebhookTokenAuthenticator) AuthenticateToken

func (w *WebhookTokenAuthenticator) AuthenticateToken(ctx context.Context, token string) (*authenticator.Response, bool, error)

AuthenticateToken implements the authenticator.Token interface.

Source Files

webhook.go

Version
v0.16.14
Published
Aug 13, 2020
Platform
linux/amd64
Imports
12 packages
Last checked
7 minutes ago

Tools for package owners.