| name | auditing-nemoclaw-policies |
| description | Reviews NemoClaw sandbox security policies for gaps, overly permissive rules, and best practice violations. Use when auditing policy security, before deploying policies to production, or during security reviews. |
Auditing NemoClaw Policies
NemoClaw sandbox policies control filesystem access, network egress, process privileges, and enforcement behavior. The blueprint sets an initial policy at launch time; this skill audits runtime modifications to catch security regressions.
Audit Workflow
The audit follows a feedback loop: fetch, check, fix, re-validate, apply.
1. Fetch the current policy
openshell policy get <name>
This runs on the host and retrieves the active policy YAML for the named sandbox.
To inspect a previous revision:
openshell policy get <name> --rev N
2. Run the audit script
python scripts/audit_policy.py <policy.yaml>
The script reads the policy YAML and checks for common security issues. It produces a report with CRITICAL, WARNING, and INFO severity levels.
3. Review findings and fix issues
Address all CRITICAL findings before proceeding. WARNING findings should be reviewed and resolved where possible. INFO findings are informational and may be intentional.
4. Re-validate the updated policy
python scripts/audit_policy.py <policy.yaml>
Re-run the audit to confirm all CRITICAL issues are resolved and no new issues were introduced.
5. Apply the updated policy
openshell policy set <name> --policy <file> --wait
The --wait flag blocks until the sandbox confirms the policy is active. Use --timeout 120 for policies that take longer to propagate.
What the Audit Checks
The audit script inspects the following areas:
- Network policies: Wildcard or overly broad hostnames, missing TLS on port 443, shell binaries with network access,
access: full grants, wildcard HTTP methods (method: '*'), missing binary restrictions, duplicate endpoints across policies
- Filesystem policies: Read-write access on sensitive paths (
/etc, /usr, /lib, /proc)
- Process policies: Non-root sandbox user requirement
- Landlock: Missing landlock configuration
- Enforcement: Enforcement mode set to
audit instead of enforce
- Empty policies: Empty
network_policies (may be intentional for airgapped sandboxes)
Severity Levels
| Level | Meaning | Exit Code |
|---|
| CRITICAL | Must be fixed before deployment | 1 |
| WARNING | Should be reviewed and addressed | 0 |
| INFO | Informational, may be intentional | 0 |
The script exits with code 0 if no CRITICAL issues are found, and code 1 if any CRITICAL issue is present.
Detailed Reference
Security best practices checklist: See security-checklist.md