- Notifications
You must be signed in to change notification settings - Fork 0
Add pi-ssh.sh wrapper to scope SSH access to the Raspberry Pi #2
Copy link
Copy link
Open
Labels
effort/mediumModerate implementation effort.Moderate implementation effort.priority/normalNormal priority.Normal priority.status/acceptedAccepted and ready to be worked.Accepted and ready to be worked.type/featureNew feature or capability request.New feature or capability request.
Description
Metadata
Metadata
Assignees
Labels
effort/mediumModerate implementation effort.Moderate implementation effort.priority/normalNormal priority.Normal priority.status/acceptedAccepted and ready to be worked.Accepted and ready to be worked.type/featureNew feature or capability request.New feature or capability request.
Summary
Create a
pi-ssh.shwrapper script in~/code/scripts/agent/that wraps SSH access to the Raspberry Pi network server (hunter@100.86.205.116, used by the~/code/pi-network-serverproject).Motivation
A permission audit of opencode bash prompts showed
ssh *triggered 54 prompts in a ~1.3-day window — the single largest unscoped prompt family. Becausessh *is too broad to safely allow wholesale, the fix is a scoped wrapper script that can be allow-listed by anchored absolute path (the same pattern used by every otheragent/script).Scope
hunter@100.86.205.116).Design requirements (
~/code/scriptsconventions)/Users/hunter/code/scripts/agent/pi-ssh.sh.-h/--helpusage.lib/common.sh; use the standard exit-code helpers (die,die_usage,die_missing_dep, …).Follow-up
Once the wrapper exists and is tested, add a scoped allow rule to
~/.config/opencode/opencode.jsonc:This routes Pi access through the wrapper instead of prompting on raw
ssh *.Acceptance criteria
pi-ssh.shexists in~/code/scripts/agent/, follows repo design rules.ssh *to the Pi no longer prompts when routed through the wrapper).