auth

package
v0.0.0-...-a6f3d4c Latest Latest
Warning

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

Go to latest
Published: Dec 16, 2024 License: MIT Imports: 7 Imported by: 4

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetTokenFromCtx

func GetTokenFromCtx(ctx context.Context) (entity.Token, error)

func NewAuthFunc

func NewAuthFunc(tokenParser tokens.Parser, tracer trace.Tracer) grpc_auth.AuthFunc

NewAuthFunc returns a callback to be used with grpc_auth interceptor. It reads the Bearer token from the context of an incoming request and verifies it using given tokens.Validator. If the validator fails to verify the token an error is returned. Otherwise the context is returned unaltered.

Types

This section is empty.

Jump to

Keyboard shortcuts

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