web

package
v1.18.1 Latest Latest
Warning

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

Go to latest
Published: Apr 10, 2026 License: MIT Imports: 27 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ConfigStore added in v1.17.0

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

ConfigStore holds user-submitted config overrides mapped by ID.

func (*ConfigStore) Delete added in v1.17.0

func (cs *ConfigStore) Delete(id string)

Delete removes a config from the store.

func (*ConfigStore) Get added in v1.17.0

func (cs *ConfigStore) Get(id string) *config.Config

Get retrieves a stored config by ID, or nil if not found.

func (*ConfigStore) Save added in v1.17.0

func (cs *ConfigStore) Save(conf *config.Config) string

Save stores the config and returns its ID.

type FileGroup

type FileGroup struct {
	File    string
	Results []model.IndexedResult
}

FileGroup organizes results by file for template rendering

type Scanner

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

Scanner handles cloning and scanning operations

func NewScanner

func NewScanner(configPath, rootConfigPath string) *Scanner

NewScanner creates a scanner with optional config overrides

func (*Scanner) DefaultConfig added in v1.17.0

func (sc *Scanner) DefaultConfig() (*config.Config, error)

DefaultConfig returns the effective base configuration (no session override applied).

func (*Scanner) RunLocalScan

func (sc *Scanner) RunLocalScan(ctx context.Context, sess *model.ScanSession)

RunLocalScan scans a local directory or file

func (*Scanner) RunOrgScan

func (sc *Scanner) RunOrgScan(ctx context.Context, sess *model.ScanSession)

RunOrgScan lists repos in an org and scans each one

func (*Scanner) RunRepoScan

func (sc *Scanner) RunRepoScan(ctx context.Context, sess *model.ScanSession)

RunRepoScan clones a repo and scans it, sending progress to the session

type Server

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

Server is the web UI HTTP server

func NewServer

func NewServer(scanner *Scanner) *Server

NewServer creates and configures the web server

func (*Server) ServeHTTP

func (s *Server) ServeHTTP(w http.ResponseWriter, r *http.Request)

ServeHTTP implements http.Handler, applying security headers to every response.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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