Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var (
Manager *session.Manager
)
View Source
var MaxHistoryPath = 64
Functions ¶
func RegisterHandler ¶
func RegisterHandler(name string, register HandlerRegister)
Types ¶
type Config ¶
type Config struct { Default string `yaml:"default" env:"SESSION_HANDLER" default:"file"` Dir string `yaml:"dir" default:"sessions"` MaxLifeTime int `yaml:"max_life_time" default:"600"` CacheStore string `yaml:"cache_store" default:"session"` CookieName string `yaml:"cookie_name" default:"enorith-session" env:"COOKIE_NAME"` Domain string `yaml:"domain" default:""` Path string `yaml:"path" default:"/"` Secure bool `yaml:"secure" default:"false"` HttpOnly bool `yaml:"http_only" default:"true"` SameSite string `yaml:"same_site" default:"lax"` Encrypted bool `yaml:"encrypted" default:"false"` }
type HandlerRegister ¶
type History ¶ added in v0.1.2
type History []string
func (History) RedirectBack ¶ added in v0.1.2
func (hp History) RedirectBack(r contracts.RequestContract) contracts.ResponseContract
func (History) SessionKey ¶ added in v0.1.2
type Middleware ¶
type Middleware struct {
// contains filtered or unexported fields
}
func (Middleware) Handle ¶
func (m Middleware) Handle(r contracts.RequestContract, next pipeline.PipeHandler) contracts.ResponseContract
type Service ¶
type Service struct {
// contains filtered or unexported fields
}
func NewService ¶
type SessionInjector ¶ added in v0.1.2
type SessionInjector struct {
// contains filtered or unexported fields
}
func NewSessionInjector ¶ added in v0.1.2
func NewSessionInjector(id string) *SessionInjector
func (*SessionInjector) When ¶ added in v0.1.2
func (si *SessionInjector) When(abs interface{}) bool
type SessionLoader ¶ added in v0.1.2
type SessionLoader interface {
SessionKey() string
}
Click to show internal directories.
Click to hide internal directories.