Documentation
¶
Index ¶
- Constants
- func AuthMiddleware(authService *auth.Service, cookieName string) func(http.Handler) http.Handler
- func CSRFMiddleware(csrfConfig models.CSRFConfig) func(http.Handler) http.Handler
- func CorsMiddleware(allowedOrigins []string) func(http.Handler) http.Handler
- func EndpointHooksMiddleware(config *models.Config, authService *auth.Service) func(http.Handler) http.Handler
- func OptionalAuthMiddleware(authService *auth.Service, cookieName string) func(http.Handler) http.Handler
- func RateLimitMiddleware(rateLimitService models.RateLimitService) func(http.Handler) http.Handler
- func Redirect(ctx *models.EndpointHookContext, url string, status int)
- func RedirectAuthMiddleware(authService *auth.Service, cookieName string, redirectURL string, status int) func(http.Handler) http.Handler
Constants ¶
View Source
const ContextUserID ctxKey = "user_id"
Variables ¶
This section is empty.
Functions ¶
func AuthMiddleware ¶
func CSRFMiddleware ¶ added in v1.0.4
func EndpointHooksMiddleware ¶ added in v1.0.3
func OptionalAuthMiddleware ¶
func RateLimitMiddleware ¶ added in v1.0.4
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.