HackerReposA FIELD GUIDE TO OPEN SOURCE
ProSponsor the shelf♧ 0
← Back to top all-time
fencesandbox
fence
Go2026–2026
fencesandbox / fence

fence

Lightweight, container-free sandbox for running commands with network and filesystem restrictions

4Distinct people
8Mentions
0Explicit recommenders
1KGitHub stars
REPOSITORY AT A GLANCE

What to know before exploring

What it is

Lightweight, container-free sandbox for running commands with network and filesystem restrictions

GitHub

Where it is used

No documented product use has been verified yet.

What people are saying

No recommendation phrase was found in the indexed comments.

No classified warning is attached to this page. Read the discussions before treating silence as approval.

Also in these discussions

No other repository is repeatedly linked in the same discussions.

This week on Hacker News

Nov 7–Nov 14 UTC · Direct repository links and separately labeled related project stories. Indexed through 11/14/2026, 3:56:07 PM UTC.

No direct repository links were found in the indexed HN discussions over the past seven days. Older discussions are available below.

Mentions over time

HN mentions by week8 dated mentions

Observed mentions: 2026-01-20 18:05:03 UTC to 2026-04-22 05:04:39 UTC. Weeks start Monday, UTC.

01232026-01-19 00:00:00 UTC to 2026-01-26 00:00:00 UTC (exclusive): 3 mentions; 1 submissions, 2 commentsJan 192026-01-26 00:00:00 UTC to 2026-02-02 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2026-02-02 00:00:00 UTC to 2026-02-09 00:00:00 UTC (exclusive): 2 mentions; 0 submissions, 2 comments2026-02-09 00:00:00 UTC to 2026-02-16 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2026-02-16 00:00:00 UTC to 2026-02-23 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2026-02-23 00:00:00 UTC to 2026-03-02 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2026-03-02 00:00:00 UTC to 2026-03-09 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 commentsMar 22026-03-09 00:00:00 UTC to 2026-03-16 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2026-03-16 00:00:00 UTC to 2026-03-23 00:00:00 UTC (exclusive): 2 mentions; 0 submissions, 2 comments2026-03-23 00:00:00 UTC to 2026-03-30 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2026-03-30 00:00:00 UTC to 2026-04-06 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2026-04-06 00:00:00 UTC to 2026-04-13 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2026-04-13 00:00:00 UTC to 2026-04-20 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2026-04-20 00:00:00 UTC to 2026-04-27 00:00:00 UTC (exclusive): 1 mentions; 0 submissions, 1 commentsApr 20

Counts come from the repository’s dated source evidence. Index cutoff: 2026-11-02 08:16:59 UTC.

View mention counts and date ranges
UTC ranges include their start and exclude their end. Select a period to filter the source evidence.
PeriodStart (UTC)End (exclusive, UTC)MentionsSubmissionsComments
Jan 192026-01-19 00:00:00 UTC2026-01-26 00:00:00 UTC312
Jan 262026-01-26 00:00:00 UTC2026-02-02 00:00:00 UTC000
Feb 22026-02-02 00:00:00 UTC2026-02-09 00:00:00 UTC202
Feb 92026-02-09 00:00:00 UTC2026-02-16 00:00:00 UTC000
Feb 162026-02-16 00:00:00 UTC2026-02-23 00:00:00 UTC000
Feb 232026-02-23 00:00:00 UTC2026-03-02 00:00:00 UTC000
Mar 22026-03-02 00:00:00 UTC2026-03-09 00:00:00 UTC000
Mar 92026-03-09 00:00:00 UTC2026-03-16 00:00:00 UTC000
Mar 162026-03-16 00:00:00 UTC2026-03-23 00:00:00 UTC202
Mar 232026-03-23 00:00:00 UTC2026-03-30 00:00:00 UTC000
Mar 302026-03-30 00:00:00 UTC2026-04-06 00:00:00 UTC000
Apr 62026-04-06 00:00:00 UTC2026-04-13 00:00:00 UTC000
Apr 132026-04-13 00:00:00 UTC2026-04-20 00:00:00 UTC000
Apr 202026-04-20 00:00:00 UTC2026-04-27 00:00:00 UTC101

What Hacker News says

8 sources
I went down this rabbit hole a bit recently trying to use claude inside fence[0] and it seems that on macOS, claude stores this token inside Keychain. I'm not sure there's a way to expose that to a container... my guess would be no, especially since it seems the container is Linux, and also because keeping the Keychain out of reach of containers seems like it would be paramount. But someone might know better! 0: https://github.com/Use-Tusk/fence
In Show HN: NanoClaw – “Clawdbot” in 500 lines of TS with Apple container isolation
Fair point, it does raise the bar! The distinction I'm drawing is between "semi-trusted" and "actively malicious". Fence handles well supply-chain scripts that phone home, tools that write broadly across your filesystem, accidental secret leakage, the "opportunistic" stuff that makes up most real-world supply chain incidents. I hedge on malware because: (1) Domain filtering relies on programs respecting HTTP_PROXY, and malware could ignore it (though direct connections are blocked at the OS level, so they'd fail rather than succeed), (2) OS sandboxes (sandbox-exec, bubblewrap) aren't VM-level isolation and I believe determined attackers could exploit kernel bugs, (3) there are no resource limits or content inspection. The threat model is really "reduce blast radius from code you're running anyway". For a stronger containment boundary you'
Read the rest
d want a proper VM. More thoughts in the security model doc (https://github.com/Use-Tusk/fence/blob/main/docs/security-mo...) if you're curious!
In Show HN: Fence – Sandbox CLI commands with network/filesystem restrictions
jy-tan·Jan 20, 2026Submission

Show HN: Fence – Sandbox CLI commands with network/filesystem restrictions

Hi HN! Fence wraps any command in a sandbox that blocks network by default and restricts filesystem writes. Useful for running semi-trusted code (package installs, build scripts, unfamiliar repos) with controlled side effects, or even just blocking tools that phone home. > fence curl https://example.com # -> blocked > fence -t code -- npm install # -> template with registries allowed > fence -m -- npm install # -> monitor mode: see what gets blocked One use-case is to use it with AI coding agents to reduce the risk of running agents with fewer interactive permission prompts: > fence -t code -- claude --dangerously-skip-permissions You can import existing Claude Code permissions with `fence import --claude`. Fence uses OS-native sandboxing (macOS sandbox-exec, Linux bubblewrap) + local HTTP/SOCKS proxies for domain fi
Read the rest
ltering. Why I built this: I work on Tusk Drift, a system to record and replay real traffic as API tests (https://github.com/Use-Tusk/tusk-drift-cli). I needed a way to sandbox the service under test during replays to block localhost outbound connections (Postgres, Redis) and force the app to use mocks instead of real services. I quickly realized that this could be a general purpose tool that would also be useful as a permission manager across CLI agents. Limitations: Not strong containment against malware. Proxy-based filtering requires programs to respect `HTTP_PROXY`. Curious if others have run into similar needs, and happy to answer any questions!
78 points · Open discussion

MAKE YOURSELF AT HOME

A few shortcuts

/
Search the collection
?
Open this guide
Esc
Close dialogs and navigation

Your saved repositories and interests stay in this browser.