secsrc

package
v0.5.1 Latest Latest
Warning

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

Go to latest
Published: Mar 13, 2025 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type SecuritySource

type SecuritySource interface {
	TalentOAuth(ctx context.Context, operationName string) (string, error)
	BerlogaJWT(ctx context.Context, operationName string) (string, error)
	ServiceKey(ctx context.Context, operationName string) (string, error)
}

SecuritySource объявляет общее API для реализаций SecuritySource конкретных клиентов.

func BerlogaJWT

func BerlogaJWT(token string) SecuritySource

BerlogaJWT выполняет аутентификацию указанным токеном методом BerlogaJWT.

func Context

func Context() SecuritySource

Context выполняет аутентификацию токеном и методом, взятыми из контекста выполняемого запроса.

func NoSecurity added in v0.5.1

func NoSecurity() SecuritySource

NoSecurity возвращает SecuritySource который не выполняет ни какой аутентификации. Такой SecuritySource можно использовать при обращении к публичным операциям API.

func ServiceKey

func ServiceKey(key string) SecuritySource

ServiceKey выполняет аутентификацию указанным токеном методом ServiceKey.

Jump to

Keyboard shortcuts

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