# Nsjail

> Use when configuring Linux sandboxing with nsjail, generating security profiles, or configuring process isolation for skills.

- Skill: `tao3k/nsjail` (Agent Skill, multi-file: 5 files)
- Install (CLI): `npx skillmds@latest add tao3k/nsjail`
- Raw SKILL.md: https://api.skillmd.com/api/skills/tao3k/nsjail/raw
- Safety review: pending
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: Security
- Author: tao3k (https://skillmd.com/u/tao3k)
- Updated: 2026-09-17
- Page: https://skillmd.com/skills/tao3k/nsjail

---


# Nsjail Skill

Linux sandboxing and process isolation using nsjail.

## Commands

| Command | Description |
|---------|-------------|
| [`nsjail_config`](#nsjail_config) | Generate nsjail configuration |
| [`nsjail_profile`](#nsjail_profile) | Generate nsjail profile |
| [`nsjail_run`](#nsjail_run) | Run command in nsjail |

### nsjail_config

Generate an nsjail configuration.

### nsjail_profile

Generate an nsjail profile.

### nsjail_run

Run a command in nsjail.

## Usage Examples

```python
# Generate minimal nsjail config
@omni("nsjail.nsjail_config", {"skill_id": "data-processor", "mode": "local"})

# Generate standard profile
@omni("nsjail.nsjail_profile", {"profile_type": "standard", "skill_id": "web-scraper"})

# Run command in nsjail
@omni("nsjail.nsjail_run", {"cmd": ["python3", "script.py"], "mode": "local"})
```

## Concepts

| Topic | Description | Reference |
|-------|-------------|-----------|
| Profile Types | Sandbox profiles | [profiles.md](references/profiles.md) |
| Resource Limits | CPU/memory limits | [rlimits.md](references/rlimits.md) |
| Network Policies | Network isolation | [network.md](references/network.md) |

## Best Practices

- Start with minimal profile, escalate as needed
- Use network deny unless required
- Set appropriate timeouts
- Use cgroups for resource control

## Related Skills

| Topic | Description | Reference |
|-------|-------------|-----------|
| Seatbelt | macOS sandboxing | [seatbelt](../seatbelt/SKILL.md) |
| NCL Modules | Nickel module patterns | [nickel-modules.md](packages/ncl/nickel-modules.md) |

