Documentation ¶
Index ¶
- func AuthAdmin(h httprouter.Handle, db *bolt.DB) httprouter.Handle
- func AuthUser(h httprouter.Handle, db *bolt.DB, ctrs ...Contexter) httprouter.Handle
- func AuthWSUser(h httprouter.Handle, db *bolt.DB, ctrs ...Contexter) httprouter.Handle
- func CtxGetRefreshToken(r *http.Request) auth.Token
- func CtxGetToken(r *http.Request) auth.Token
- func CtxGetUserID(r *http.Request) string
- func CtxSetRefreshToken(r *http.Request, ctx *auth.Context) *http.Request
- func CtxSetToken(r *http.Request, ctx *auth.Context) *http.Request
- func CtxSetUserID(r *http.Request, ctx *auth.Context) *http.Request
- func GetToken(kind auth.TokenType, from string) ([]byte, error)
- func GetWSToken(protocols string, kind auth.TokenType) ([]byte, error)
- type Contexter
- type Header
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AuthAdmin ¶
func AuthAdmin(h httprouter.Handle, db *bolt.DB) httprouter.Handle
func AuthUser ¶
func AuthUser(h httprouter.Handle, db *bolt.DB, ctrs ...Contexter) httprouter.Handle
func AuthWSUser ¶
func AuthWSUser(h httprouter.Handle, db *bolt.DB, ctrs ...Contexter) httprouter.Handle
func CtxGetUserID ¶
Types ¶
Click to show internal directories.
Click to hide internal directories.