handshakeauth

package
v1.6.0 Latest Latest
Warning

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

Go to latest
Published: Mar 18, 2019 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ClientMetadataFromContext

func ClientMetadataFromContext(ctx context.Context) interface{}

func NewClientTransportCredentials

func NewClientTransportCredentials(send map[string]interface{}, opts ...HSOption) credentials.TransportCredentials

func NewClientTransportCredentialsWrapping

func NewClientTransportCredentialsWrapping(send map[string]interface{}, wrap credentials.TransportCredentials, opts ...HSOption) credentials.TransportCredentials

func NewServerTransportCredentials

func NewServerTransportCredentials(validator ClientHandshakeValidator, opts ...HSOption) credentials.TransportCredentials

Types

type ClientHandshakeValidator

type ClientHandshakeValidator func(request map[string]interface{}) (authMetadata interface{}, err error)

ClientHandshakeValidator is the function called when a client tries to connect. It receives the k/v info from the client, and should return an object to attach to the AuthInfo, or error if the connection is rejected

type HSOption

type HSOption func(*hsOpts)

func WithErrorReporter

func WithErrorReporter(er reporters.ErrorReporter) HSOption

func WithMetricsReporter

func WithMetricsReporter(mr reporters.MetricsReporter) HSOption

Jump to

Keyboard shortcuts

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