Documentation ¶
Index ¶
- func LogTrace(next http.Handler) http.Handler
- func OCSFormatCtx(next http.Handler) http.Handler
- func RequireAdmin(opts ...Option) func(next http.Handler) http.Handler
- func RequireSelfOrAdmin(opts ...Option) func(next http.Handler) http.Handler
- func RequireUser(opts ...Option) func(next http.Handler) http.Handler
- type Option
- type Options
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func OCSFormatCtx ¶
OCSFormatCtx middleware is used to determine the content type from the format URL parameter passed in an ocs request. Defaults to XML
func RequireAdmin ¶
RequireAdmin middleware is used to require the user in context to be an admin / have account management permissions
func RequireSelfOrAdmin ¶
RequireSelfOrAdmin middleware is used to require the requesting user to be an admin or the requested user himself
Types ¶
type Option ¶
type Option func(o *Options)
Option defines a single option function.
func RoleManager ¶
RoleManager provides a function to set the RoleManager option.
Click to show internal directories.
Click to hide internal directories.