o2wa

package
v1.0.4 Latest Latest
Warning

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

Go to latest
Published: Oct 10, 2023 License: Apache-2.0 Imports: 22 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Endpoint

type Endpoint struct {
	Path           string   `json:"path" yaml:"path"`
	Public         bool     `json:"public,omitempty" yaml:"public,omitempty"`
	RequiredGroups []string `json:"requiredGroups,omitempty" yaml:"requiredGroups,omitempty"`
	Command        []string `json:"command" yaml:"command"`
	BinaryOutput   bool     `json:"binaryOutput,omitempty" yaml:"binaryOutput,omitempty"`
	HTMLFile       string   `json:"htmlFile" yaml:"htmlFile"`
}

type Server

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

func NewServer

func NewServer(clientID, clientSecret, oidcIssuer, callbackURL string) *Server

func (*Server) AuthMiddleware

func (app *Server) AuthMiddleware(requiredGroups []string, next http.HandlerFunc) http.HandlerFunc

func (*Server) EndpointLogout added in v1.0.1

func (app *Server) EndpointLogout(w http.ResponseWriter, r *http.Request)

create a EndpointLogout function that will be used to log out the user

func (*Server) EndpointValues

func (app *Server) EndpointValues(w http.ResponseWriter, r *http.Request)

func (*Server) HandleCommandConfirm

func (app *Server) HandleCommandConfirm(w http.ResponseWriter, r *http.Request, e Endpoint)

func (*Server) HandleCommandRun

func (app *Server) HandleCommandRun(w http.ResponseWriter, r *http.Request, e Endpoint)

func (*Server) Oauth2Callback

func (app *Server) Oauth2Callback(w http.ResponseWriter, r *http.Request)

func (*Server) SessionMiddleware

func (a *Server) SessionMiddleware(handler http.Handler) http.Handler

Jump to

Keyboard shortcuts

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