Documentation
¶
Index ¶
- func GetAbsoluteURL(r *http.Request, path string) string
- type Config
- type Handler
- func (h *Handler) GoogleEnabled() bool
- func (h *Handler) HandleGoogleCallback(w http.ResponseWriter, r *http.Request)
- func (h *Handler) HandleGoogleLogin(w http.ResponseWriter, r *http.Request)
- func (h *Handler) HandleOIDCCallback(w http.ResponseWriter, r *http.Request)
- func (h *Handler) HandleOIDCLogin(w http.ResponseWriter, r *http.Request)
- func (h *Handler) OIDCEnabled() bool
- type IssueTokenFunc
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Config ¶
type Config struct {
GoogleClientID string
GoogleClientSecret string
GoogleRedirectURL string
OIDCIssuer string
OIDCClientID string
OIDCClientSecret string
OIDCRedirectURL string
AuthSuccessRedirect string
}
Config holds OAuth/OIDC provider configuration.
type Handler ¶
type Handler struct {
// contains filtered or unexported fields
}
Handler bundles OAuth handlers for providers.
func NewHandler ¶
func NewHandler(store *storage.Store, logger *logrus.Logger, cfg Config, sessStore sessions.SessionStore, issue IssueTokenFunc) *Handler
NewHandler constructs Handler.
func (*Handler) GoogleEnabled ¶
func (*Handler) HandleGoogleCallback ¶
func (h *Handler) HandleGoogleCallback(w http.ResponseWriter, r *http.Request)
func (*Handler) HandleGoogleLogin ¶
func (h *Handler) HandleGoogleLogin(w http.ResponseWriter, r *http.Request)
func (*Handler) HandleOIDCCallback ¶
func (h *Handler) HandleOIDCCallback(w http.ResponseWriter, r *http.Request)
func (*Handler) HandleOIDCLogin ¶
func (h *Handler) HandleOIDCLogin(w http.ResponseWriter, r *http.Request)
func (*Handler) OIDCEnabled ¶
type IssueTokenFunc ¶
IssueTokenFunc issues app JWT and refresh token for the given user ID.
Click to show internal directories.
Click to hide internal directories.