Documentation ¶
Index ¶
- func GetOauthServer() *server.Server
- func GetSAUserToken(user entity.User, req *http.Request) (token string, err error)
- type TokenStore
- func (t TokenStore) Create(info oauth2.TokenInfo) error
- func (t TokenStore) GetByAccess(access string) (oauth2.TokenInfo, error)
- func (t TokenStore) GetByCode(code string) (oauth2.TokenInfo, error)
- func (t TokenStore) GetByRefresh(refresh string) (oauth2.TokenInfo, error)
- func (t TokenStore) RemoveByAccess(access string) error
- func (t TokenStore) RemoveByCode(code string) error
- func (t TokenStore) RemoveByRefresh(refresh string) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetOauthServer ¶
Types ¶
type TokenStore ¶
type TokenStore struct { }
func NewTokenStore ¶
func NewTokenStore() *TokenStore
func (TokenStore) Create ¶
func (t TokenStore) Create(info oauth2.TokenInfo) error
func (TokenStore) GetByAccess ¶
func (t TokenStore) GetByAccess(access string) (oauth2.TokenInfo, error)
func (TokenStore) GetByCode ¶
func (t TokenStore) GetByCode(code string) (oauth2.TokenInfo, error)
func (TokenStore) GetByRefresh ¶
func (t TokenStore) GetByRefresh(refresh string) (oauth2.TokenInfo, error)
func (TokenStore) RemoveByAccess ¶
func (t TokenStore) RemoveByAccess(access string) error
func (TokenStore) RemoveByCode ¶
func (t TokenStore) RemoveByCode(code string) error
func (TokenStore) RemoveByRefresh ¶
func (t TokenStore) RemoveByRefresh(refresh string) error
Click to show internal directories.
Click to hide internal directories.