ui

package
v0.2.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: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RunUI

func RunUI(app *App) error

RunUI starts the Wails desktop window. Blocks until the window is closed.

Types

type App

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

App is the Wails-bound application struct. All exported methods are callable from the frontend.

func NewApp

func NewApp(server *proxy.Server, store *audit.SessionStore, engine *policy.Engine, cfg *config.Config, cfgPath string) *App

func (*App) AddAllowedDirectory added in v0.0.7

func (a *App) AddAllowedDirectory(dir string)

func (*App) AddDenyContentKeyword added in v0.1.0

func (a *App) AddDenyContentKeyword(keyword string)

func (*App) AddDenyContentTag added in v0.2.0

func (a *App) AddDenyContentTag(tag string)

func (*App) AddDenyPattern

func (a *App) AddDenyPattern(pattern string)

func (*App) GetAllowedDirectories added in v0.0.7

func (a *App) GetAllowedDirectories() []string

func (*App) GetContentBlacklist added in v0.2.0

func (a *App) GetContentBlacklist() []string

func (*App) GetContentWhitelist added in v0.2.0

func (a *App) GetContentWhitelist() []string

func (*App) GetDenyContentKeywords added in v0.1.0

func (a *App) GetDenyContentKeywords() []string

func (*App) GetDenyContentTags added in v0.2.0

func (a *App) GetDenyContentTags() []string

func (*App) GetDenyPatterns

func (a *App) GetDenyPatterns() []string

func (*App) GetListenAddress

func (a *App) GetListenAddress() string

func (*App) GetRecentSessions

func (a *App) GetRecentSessions(limit int) []*audit.Session

func (*App) GetSession

func (a *App) GetSession(id string) *audit.Session

func (*App) GetStats

func (a *App) GetStats() audit.StoreStats

func (*App) IsPolicyBypassed

func (a *App) IsPolicyBypassed() bool

func (*App) IsProxyRunning

func (a *App) IsProxyRunning() bool

func (*App) PromptUser added in v0.1.0

func (a *App) PromptUser(prompt policy.ContentPrompt) policy.ContentPromptResponse

PromptUser implements policy.PromptResolver. It emits a Wails event and blocks until the frontend calls ResolveContentPrompt or the 30s timeout expires.

func (*App) RemoveAllowedDirectory added in v0.0.7

func (a *App) RemoveAllowedDirectory(dir string)

func (*App) RemoveDenyContentKeyword added in v0.1.0

func (a *App) RemoveDenyContentKeyword(keyword string)

func (*App) RemoveDenyContentTag added in v0.2.0

func (a *App) RemoveDenyContentTag(tag string)

func (*App) RemoveDenyPattern

func (a *App) RemoveDenyPattern(pattern string)

func (*App) RemoveFromContentBlacklist added in v0.2.0

func (a *App) RemoveFromContentBlacklist(path string)

func (*App) RemoveFromContentWhitelist added in v0.2.0

func (a *App) RemoveFromContentWhitelist(path string)

func (*App) ResolveContentPrompt added in v0.1.0

func (a *App) ResolveContentPrompt(promptID string, action string)

ResolveContentPrompt is called by the frontend to respond to a content keyword prompt.

func (*App) ResolveContentPromptForFile added in v0.1.0

func (a *App) ResolveContentPromptForFile(action string, filePath string)

ResolveContentPromptForFile is called by the frontend with a specific file path for whitelist/blacklist persistence, separate from the blocking resolution.

func (*App) SaveConfig

func (a *App) SaveConfig() error

func (*App) SetAllowedDirectories added in v0.0.7

func (a *App) SetAllowedDirectories(dirs []string)

func (*App) SetDenyContentKeywords added in v0.1.0

func (a *App) SetDenyContentKeywords(keywords []string)

func (*App) SetDenyContentTags added in v0.2.0

func (a *App) SetDenyContentTags(tags []string)

func (*App) SetDenyPatterns

func (a *App) SetDenyPatterns(patterns []string)

func (*App) SetPolicyBypassed

func (a *App) SetPolicyBypassed(bypassed bool)

func (*App) Shutdown

func (a *App) Shutdown(ctx context.Context)

Shutdown is called by Wails when the app closes.

func (*App) StartProxy

func (a *App) StartProxy() error

func (*App) Startup

func (a *App) Startup(ctx context.Context)

Startup is called by Wails when the app starts.

func (*App) StopProxy

func (a *App) StopProxy()

Jump to

Keyboard shortcuts

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