Documentation ¶
Index ¶
Constants ¶
View Source
const ( // UserToken is the prefix for the user session UserToken = "user" //SessToken is use for the cookie session name SessToken = "sess" // HookToken not sure HookToken = "hook" // CsrfToken is used for the csrf header prefix CsrfToken = "csrf" )
View Source
const SignerAlgo = "HS256"
SignerAlgo default algorithm used to sign JWT tokens.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Token ¶
Token holds basic token information
func Parse ¶
func Parse(raw string, fn SecretFunc) (*Token, error)
Parse is used to pull session information from a raw string
func ParseRequest ¶
func ParseRequest(r *http.Request, fn SecretFunc) (*Token, error)
ParseRequest is used to pull session information from a gin request
Click to show internal directories.
Click to hide internal directories.