childenv

package
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Jul 5, 2026 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AgentAllowlist

func AgentAllowlist() []string

AgentAllowlist returns the environment allowlist for agent subprocesses. It excludes SSH_AUTH_SOCK (and SSH_ASKPASS) so a semi-trusted agent command cannot use the user's ssh-agent to authenticate as the user (AGEN-02/SECU-02). HOME is also excluded from inheritance; the caller must set HOME to the worktree path so agent tooling that needs $HOME does not reach the user's real dotfiles (~/.ssh, ~/.aws, ~/.config/gh, etc.) (SECU-02). Git/editor/gh launches continue to use BasicAllowlist for legitimate SSH auth.

func BasicAllowlist

func BasicAllowlist() []string

func Build

func Build(opts Options) ([]string, error)

func Dangerous

func Dangerous(name string) bool

func FromOS

func FromOS(allow []string, set map[string]string) ([]string, error)

Types

type Options

type Options struct {
	Base  []string
	Allow []string
	Set   map[string]string
}

Jump to

Keyboard shortcuts

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