MCPcopy Create free account
hub / github.com/diillson/chatcli / activeInputGuard

Function activeInputGuard

cli/coder/security_prompt_guarded.go:40–45  ·  view source on GitHub ↗

activeInputGuard returns the package-level guard, lazily instantiated with the most recently configured logger (or a no-op when nothing was wired). Used by the Guarded* wrappers below.

()

Source from the content-addressed store, hash-verified

38// with the most recently configured logger (or a no-op when nothing was
39// wired). Used by the Guarded* wrappers below.
40func activeInputGuard() *InputGuard {
41 if promptInputGuard == nil {
42 promptInputGuard = NewInputGuard(promptInputGuardLogger)
43 }
44 return promptInputGuard
45}
46
47// PromptSecurityCheckGuarded wraps PromptSecurityCheck with the
48// typeahead defense layers from InputGuard: kernel TTY flush, channel

Calls 1

NewInputGuardFunction · 0.85

Tested by

no test coverage detected