Versions in this module Expand all Collapse all v0 v0.1.0 Sep 3, 2015 Changes in this version + const DefaultSessionValidityWindow + const SessionStateDead + const SessionStateIdentified + const SessionStateNew + const SessionStateRemoteAttached + func DefaultGenerateCode() (string, error) + type GenerateCodeFunc func() (string, error) + type Session struct + ClientID string + ClientState string + ConnectorID string + CreatedAt time.Time + ExpiresAt time.Time + ID string + Identity oidc.Identity + Nonce string + RedirectURL url.URL + Register bool + Scope []string + State SessionState + UserID string + func (s *Session) Claims(issuerURL string) jose.Claims + type SessionKey struct + Key string + SessionID string + type SessionKeyRepo interface + Pop func(string) (string, error) + Push func(SessionKey, time.Duration) error + func NewSessionKeyRepo() SessionKeyRepo + func NewSessionKeyRepoWithClock(clock clockwork.Clock) SessionKeyRepo + type SessionManager struct + Clock clockwork.Clock + GenerateCode GenerateCodeFunc + ValidityWindow time.Duration + func NewSessionManager(sRepo SessionRepo, skRepo SessionKeyRepo) *SessionManager + func (m *SessionManager) AttachRemoteIdentity(sessionID string, ident oidc.Identity) (*Session, error) + func (m *SessionManager) AttachUser(sessionID string, userID string) (*Session, error) + func (m *SessionManager) ExchangeKey(key string) (string, error) + func (m *SessionManager) Get(sessionID string) (*Session, error) + func (m *SessionManager) Kill(sessionID string) (*Session, error) + func (m *SessionManager) NewSession(connectorID, clientID, clientState string, redirectURL url.URL, nonce string, ...) (string, error) + func (m *SessionManager) NewSessionKey(sessionID string) (string, error) + type SessionRepo interface + Create func(Session) error + Get func(string) (*Session, error) + Update func(Session) error + func NewSessionRepo() SessionRepo + func NewSessionRepoWithClock(clock clockwork.Clock) SessionRepo + type SessionState string