oauth2

package
v0.0.0-...-7687a33 Latest Latest
Warning

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

Go to latest
Published: Sep 16, 2024 License: Apache-2.0 Imports: 25 Imported by: 0

Documentation

Index

Constants

View Source
const (
	RedirectUriSeparator = " "
)

Variables

This section is empty.

Functions

func NewClientStore

func NewClientStore(s store.AuthClients, def *types.AuthClient) *clientStore

func NewManager

func NewManager(opt options.AuthOpt, log *zap.Logger, cs oauth2.ClientStore, ts oauth2.TokenStore) *manage.Manager

func NewServer

func NewServer(manager oauth2.Manager) *server.Server

func NewTokenStore

func NewTokenStore(s tokenStorer) *tokenStore

func NewUserAuthorizer

func NewUserAuthorizer(sm *request.SessionManager, loginURL, clientAuthURL string) server.UserAuthorizationHandler

func UserIDSerializer

func UserIDSerializer(userID uint64, rr ...uint64) string

UserIDSerializer packs user ID and IDs of all roles into space delimited string

Main reason to do this is to simplify JWT claims encoding; we do not have access to user's membership info from there)

Types

This section is empty.

Jump to

Keyboard shortcuts

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