Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type StoredSessionLoader ¶
type StoredSessionLoader struct { RemoteKeySet *oidc.KeySet NeedsVerifier bool // contains filtered or unexported fields }
storedSessionLoader is responsible for loading sessions from cookie identified sessions in the session store.
func NewStoredSessionLoader ¶
func NewStoredSessionLoader(opts *StoredSessionLoaderOptions) (*StoredSessionLoader, alice.Constructor)
NewStoredSessionLoader creates a new StoredSessionLoader which loads sessions from the session store. If no session is found, the request will be passed to the nex handler. If a session was loader by a previous handler, it will not be replaced.
type StoredSessionLoaderOptions ¶
type StoredSessionLoaderOptions struct { // Session storage backend SessionStore sessionsapi.SessionStore // How often should sessions be refreshed RefreshPeriod time.Duration // Provider based session refreshing RefreshSession func(context.Context, *sessionsapi.SessionState, wrapper.HttpClient, func(args ...interface{}), uint32) (bool, error) // Provider based session validation. // If the session is older than `RefreshPeriod` but the provider doesn't // refresh it, we must re-validate using this validation. ValidateSession func(context.Context, *sessionsapi.SessionState) bool // Refresh request parameters RefreshClient wrapper.HttpClient RefreshRequestTimeout uint32 }
StoredSessionLoaderOptions contains all the requirements to construct a stored session loader. All options must be provided.
Click to show internal directories.
Click to hide internal directories.