Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CORSMiddleware ¶
func CORSMiddleware() gin.HandlerFunc
Types ¶
type Auth ¶
type Auth struct { Issuer string Audience string Secret string TokenExpiry time.Duration CookieDomain string CookiePath string CookieName string }
var AdminAuth *Auth
func (*Auth) AuthRequest ¶
func (j *Auth) AuthRequest() gin.HandlerFunc
func (*Auth) GenerateTokenPair ¶
func (j *Auth) GenerateTokenPair(user *JwtUser) (TokenPairs, error)
type TokenPairs ¶
type TokenPairs struct {
Token string `json:"access_token"`
}
Click to show internal directories.
Click to hide internal directories.