server

package
v0.0.0-...-72a65b5 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 29, 2022 License: MIT Imports: 23 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ComponentPreferences

type ComponentPreferences struct {
	Timezone string
	Username string
	Role     string
}

type NewServerInput

type NewServerInput struct {
	EventStorage      *storage.EventStore
	UserStorage       *storage.UserStore
	Port              int
	CallBackURL       string
	SessionSecret     string
	MaxSessionSeconds int
	MinPasswordLength int
	MaxOldPasswordUse int
	MaxFailedLogins   int
	LockoutSeconds    int
	MaxQueryResults   int
}

type Renderer

type Renderer struct {
	// contains filtered or unexported fields
}

func MustNewRenderer

func MustNewRenderer() *Renderer

func (*Renderer) Render

func (t *Renderer) Render(w io.Writer, name string, data any, c echo.Context) error

type Server

type Server struct {
	// contains filtered or unexported fields
}

func MustNewServer

func MustNewServer(config NewServerInput) *Server

func (*Server) RunServer

func (s *Server) RunServer()

RunServer starts a blocking server process

type SessionData

type SessionData struct {
	Username              string `json:"username,omitempty"`
	Role                  string `json:"role,omitempty"`
	UserID                string `json:"user_id,omitempty"`
	SessionID             string `json:"session_id,omitempty"`
	MFACompleted          bool   `json:"mfa_completed,omitempty"`
	MFASetupRequired      bool   `json:"mfa_setup_required,omitempty"`
	PasswordResetRequired bool   `json:"password_reset_required,omitempty"`
	Timezone              string `json:"timezone,omitempty"`
}

type SessionMessages

type SessionMessages struct {
	ErrorMessage string `json:"error_message"`
	InfoMessage  string `json:"info_message"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL