mtls

package
v0.13.9 Latest Latest
Warning

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

Go to latest
Published: Oct 13, 2023 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Overview

Package mtls is an authentication plugin that uses mTLS.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	// CAFile is the path to a CA file to use to verify client certificates.
	// If not provided, the system pool and any intermediate chains provided
	// in the authentication request will be used.
	CAFile string `koanf:"ca-file" mapstructure:"ca-file"`
}

Config is the configuration for the mTLS plugin.

func (*Config) AsMapStructure added in v0.3.1

func (c *Config) AsMapStructure() map[string]any

func (*Config) BindFlags added in v0.3.1

func (c *Config) BindFlags(prefix string, fs *pflag.FlagSet)

BindFlags binds the plugin flags to the given flag set.

func (*Config) DefaultOptions added in v0.3.1

func (c *Config) DefaultOptions() *Config

DefaultOptions returns the default options for the plugin.

func (*Config) SetMapStructure added in v0.8.0

func (c *Config) SetMapStructure(in map[string]any)

type Plugin

type Plugin struct {
	v1.UnimplementedPluginServer
	v1.UnimplementedAuthPluginServer
	// contains filtered or unexported fields
}

Plugin is the mTLS plugin.

func (*Plugin) Authenticate

func (*Plugin) Close

func (p *Plugin) Close(ctx context.Context, req *emptypb.Empty) (*emptypb.Empty, error)

func (*Plugin) Configure

func (p *Plugin) Configure(ctx context.Context, req *v1.PluginConfiguration) (*emptypb.Empty, error)

func (*Plugin) GetInfo

func (p *Plugin) GetInfo(context.Context, *emptypb.Empty) (*v1.PluginInfo, error)

Jump to

Keyboard shortcuts

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