Skip to content

[Feature] Audio enforcement layer — mic grants, recording rules, audio egress policies #1693

@amargolin78

Description

@amargolin78

Description

OpenShell's policy engine enforces four protection layers (network, filesystem, process, inference) but has no concept of audio. As NemoClaw adds speech capabilities (see #1520 for /v1/audio/* gateway routes), we need policy controls for how audio flows through the sandbox.

Without this, NemoClaw agents can access speech services but operators have no way to control microphone access, audio storage, or whether audio leaves the local environment.

Enterprise voice agent deployments require answers to:

Which agents can access the microphone? (today: blocked globally by Permissions-Policy header — openclaw/openclaw#51085)
Can audio be recorded or stored? Where? For how long?
Can audio egress to a cloud endpoint, or must it stay local? (e.g., force all audio to a local PersonaPlex sidecar, never to an external API)
This is the gap between "voice agent" and "secure voice agent" — which is NemoClaw's differentiator.

Example: openclaw-sandbox.yaml

audio:
microphone:
grant: per-agent # "none" | "per-agent" | "all"
allowed_agents:
- voice-assistant
recording:
allow: false # Can audio be written to disk?
retention: 0 # Max seconds to retain (0 = no storage)
allowed_paths: [] # If allow: true, restrict to these dirs
egress:
mode: local-only # "local-only" | "allowlist" | "any"
allowlist: # Used when mode: allowlist
- host: personaplex.local
port: 8998
- host: inference.local
port: 8000

Dependencies:
#1520 — /v1/audio/transcriptions and /v1/audio/speech gateway routes (audio can't flow at all until this ships)
#409 — WebSocket egress timeout (voice sessions are long-lived WS; currently killed at ~2 min)
openclaw/openclaw#51085 — Permissions-Policy: microphone=() blocks mic by default

Suggested steps:

  1. Per-agent mic grant in policy YAML + microphone=(self) header fix
  2. Audio egress allowlist (reuse existing network policy structure, add media-type: audio filter)
  3. Recording rules (storage path restriction, retention enforcement, audit log for audio writes)
  4. Audio encryption enforcement (require TLS/DTLS on audio streams)

Reproduction Steps

This is a feature request, not a bug. To observe the gap:

  1. Deploy NemoClaw with a voice agent that needs mic access and audio streaming
  2. Attempt to configure per-agent microphone grants in openclaw-sandbox.yaml → no audio section exists
  3. Attempt to set recording rules or audio egress restrictions → no policy surface available
  4. Note that the only current audio-related control is the Permissions-Policy HTTP header, which is global (all-or-nothing) and blocks mic by default

Environment

Debug Output

Logs

Checklist

  • I confirmed this bug is reproducible
  • I searched existing issues and this is not a duplicate

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingenhancement: featureUse this label to identify requests for new capabilities in NemoClaw.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions