Documentation ¶
Index ¶
- func New(c *config.Auth) auth.Provider
- type Config
- func (c *Config) Exchange(code string) (*oauth2.Token, error)
- func (c *Config) Name() string
- func (c *Config) Revoke(token *oauth2.Token) error
- func (c *Config) StartSession(state string) *auth.Session
- func (c *Config) Username(token *oauth2.Token) string
- func (c *Config) Valid(token *oauth2.Token) bool
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Config ¶
type Config struct {
// contains filtered or unexported fields
}
Config is an implementation of `auth.Provider` for authenticating using a Github account.
func (*Config) Revoke ¶
GitHub doesn't seem to allow token revocation - tokens are indefinite and there are no refresh options etc. Returns nil to satisfy the Provider interface.
func (*Config) StartSession ¶
StartSession retrieves an authentication endpoint from Github.
Click to show internal directories.
Click to hide internal directories.