auth

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Sep 21, 2025 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AuthManager

type AuthManager interface {
	Authenticate(ctx *gin.Context) error
}

func NewAuthManager

func NewAuthManager(ctx context.Context, config *Config, cache cache.Cache) (AuthManager, error)

type Config

type Config struct {
	Name     string                `yaml:"Name"`
	OpenAuth openauth.ClientConfig `yaml:"OpenAuth"`
}

type OpenAuthStrategy

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

func (*OpenAuthStrategy) Authenticate

func (s *OpenAuthStrategy) Authenticate(ctx *gin.Context) error

func (*OpenAuthStrategy) Close

func (s *OpenAuthStrategy) Close() error

type Strategy

type Strategy interface {
	Authenticate(ctx *gin.Context) error
}

func NewOpenAuthStrategy

func NewOpenAuthStrategy(ctx context.Context, config *openauth.ClientConfig, cache cache.Cache) (Strategy, error)

Jump to

Keyboard shortcuts

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