middleware

package
v1.2.2 Latest Latest
Warning

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

Go to latest
Published: Oct 29, 2026 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

View Source
const UserIDKey contextKey = "user_id"

Variables

This section is empty.

Functions

func MaxPayloadSizeMiddleware added in v1.1.0

func MaxPayloadSizeMiddleware(limit int64) func(http.Handler) http.Handler

func NewSessionStore

func NewSessionStore(credentials *oauth2.Config) *sessions.CookieStore

Types

type DesktopMiddleware added in v1.2.0

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

func NewDesktopMiddleware added in v1.2.0

func NewDesktopMiddleware(logger log.Logger) DesktopMiddleware

func (DesktopMiddleware) RequireDesktop added in v1.2.0

func (m DesktopMiddleware) RequireDesktop(next http.Handler) http.Handler

type SessionMiddleware

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

func NewSessionMiddleware

func NewSessionMiddleware(
	jwtManager crypto.JwtManager,
	store *sessions.CookieStore,
	credentials *oauth2.Config,
	onlyoffice *shared.OnlyofficeConfig,
	logger log.Logger,
) SessionMiddleware

func (SessionMiddleware) Protect

func (m SessionMiddleware) Protect(next http.Handler) http.Handler

Jump to

Keyboard shortcuts

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