Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AccessToken ¶
type AccessTokenDefault ¶
type AccessTokenDefault struct { }
AccessTokenGenDefault is the default authorization token generator
func (*AccessTokenDefault) GenerateAccessToken ¶
func (a *AccessTokenDefault) GenerateAccessToken(data Access, generaterefresh bool) (accesstoken string, refreshtoken string, err error)
GenerateAccessToken generates base64-encoded UUID access and refresh tokens
func (*AccessTokenDefault) VerifyToken ¶
func (a *AccessTokenDefault) VerifyToken(code string) (Access, error)
type Authorize ¶
type Authorize interface { GetCode() string GetClient() Client GetUser() User GetState() string GetExpiresIn() int32 GetScope() string GetRedirectUri() string GetCodeChallenge() string GetCodeChallengeMethod() string GetCreatedAt() time.Time GetDeletedAt() time.Time IsExpired() bool IsExpiredAt(t time.Time) bool ExpireAt() time.Time }
type AuthorizeCode ¶
type AuthorizeCode interface {
GenerateCode(req *request.AuthorizeRequest) (accesstoken string, err error)
}
type AuthorizeCodeDefault ¶
type AuthorizeCodeDefault struct { }
AuthorizeTokenGenDefault is the default authorization token generator
func (*AuthorizeCodeDefault) GenerateCode ¶
func (a *AuthorizeCodeDefault) GenerateCode(req *request.AuthorizeRequest) (token string, err error)
GenerateAuthorizeToken generates a base64-encoded UUID code
Click to show internal directories.
Click to hide internal directories.