auth

package
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Nov 12, 2025 License: GPL-3.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AuthenticatorCatcher

type AuthenticatorCatcher interface {
	Catch() connect.UnaryInterceptorFunc
}

AuthenticatorCatcher interface

type Interceptor

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

Interceptor is the authentication catcher interceptor

func NewInterceptor

func NewInterceptor(options *Options) *Interceptor

NewInterceptor creates a new authentication catcher interceptor

Parameters:

  • options: the options for the interceptor

Returns:

- *Interceptor: the authentication catcher interceptor

func (Interceptor) Catch

Catch is the unary interceptor that catches the issued tokens from the context and sets them in the response metadata and cookies

type Options

type Options struct {
	CustomRefreshTokenName     *string
	CustomAccessTokenName      *string
	CookieRefreshTokenDuration *time.Duration
	CookieAccessTokenDuration  *time.Duration
	CookieAttributes           map[string]http.Cookie
}

Options are the options for the authentication catcher interceptor

Jump to

Keyboard shortcuts

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