Documentation ¶
Overview ¶
This Source Code Form is subject to the terms of the Mozilla Public License, version 2.0. If a copy of the MPL was not distributed with this file, You can obtain one at http://mozilla.org/MPL/2.0/.
Index ¶
- type Provider
- func (p *Provider) AuthenticateClient(username, password string) (types.Client, error)
- func (p *Provider) AuthenticateUser(username, password string) bool
- func (p *Provider) ClientInfo(clientID string) (types.Client, error)
- func (p *Provider) GenGrant(client types.Client, scopes types.Scopes, expiration time.Duration) (types.Grant, error)
- func (p *Provider) GenToken(grant types.Grant, client types.Client, refreshToken bool, ...) (types.Token, error)
- func (p *Provider) GrantInfo(code string) (types.Grant, error)
- func (p *Provider) IsUserAuthenticated() bool
- func (p *Provider) RefreshToken(refreshToken types.Token, scopes types.Scopes) (types.Token, error)
- func (p *Provider) ResourceScopes(url *url.URL) (types.Scopes, error)
- func (p *Provider) RevokeToken(token string) error
- func (p *Provider) ScopesInfo(scopes string) (types.Scopes, error)
- func (p *Provider) TokenInfo(code string) (types.Token, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Provider ¶
type Provider struct { Client types.Client Grants map[string]types.Grant AccessTokens map[string]types.Token RefreshTokens map[string]types.Token // contains filtered or unexported fields }
func NewProvider ¶
func (*Provider) AuthenticateClient ¶
func (*Provider) AuthenticateUser ¶
func (*Provider) IsUserAuthenticated ¶
func (*Provider) RefreshToken ¶
func (*Provider) ResourceScopes ¶
func (*Provider) RevokeToken ¶
Click to show internal directories.
Click to hide internal directories.