Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var VERSION string
Functions ¶
func PrettyToken ¶
func RandomString ¶
Types ¶
type Config ¶
type Config struct {
StaticDir string
CookieSecret string
SessionLifetime time.Duration
SessionManager *SessionManager
}
Config holds the servers configurtion parameters
type OidcWorkflow ¶
type OidcWorkflow struct{}
type SamlWorkflow ¶
type SamlWorkflow struct {
}
type Session ¶
type Session struct {
ID string `json:"id"`
Expires time.Time `json:"expires"`
Certificates []*cert.Certificate `json:"certificates"`
Provider *oidc.Provider `json:"-"`
Config *oauth2.Config `json:"-"`
OIDCVerifier *Verifier `json:"-"`
OAuthCodeOpts []oauth2.AuthCodeOption `json:"-"`
SamlMw *samlsp.Middleware `json:"-"`
SamlOpts SamlOpts `json:"-"`
State string `json:"-"`
CsrfToken string `json:"-"`
}
type SessionManager ¶
type SessionManager struct {
sync.Mutex
Items map[string]*Session `json:"sessions"`
// contains filtered or unexported fields
}
func LoadSessionManager ¶ added in v0.2.3
func LoadSessionManager(filepath string) (*SessionManager, error)
func (*SessionManager) Get ¶
func (m *SessionManager) Get(hash string) *Session
func (*SessionManager) New ¶ added in v0.2.3
func (m *SessionManager) New() (*Session, error)
func (*SessionManager) Remove ¶
func (m *SessionManager) Remove(hash string)
func (*SessionManager) RunSessionCleanup ¶ added in v0.2.3
func (m *SessionManager) RunSessionCleanup(shutdown <-chan struct{}, routines *sync.WaitGroup)
func (*SessionManager) Save ¶ added in v0.2.3
func (m *SessionManager) Save() error
Click to show internal directories.
Click to hide internal directories.