Saltar al contenido
Skillpedia
Seguridad21 mil · #10367

generate-sandbox-policy

Qué hace

Esta skill hace que la IA convierta lo que quieres que alcance un sandbox en un archivo de política de red válido. Es para quienes configuran sandboxes de OpenShell y quieren controlar a qué sitios y llamadas de API se puede acceder.

Cuándo usarla

  • ✓Cuando quieres permitir que tu IA en el sandbox llegue a un sitio web o una API concreta.
  • ✓Cuando tienes documentación de una API y quieres una política limitada a ciertos métodos y rutas.
  • ✓Cuando necesitas cambiar cómo se conecta el middleware de red a un sandbox o qué pasa si falla.

Link de la skill

https://github.com/NVIDIA/OpenShell/blob/main/skills/generate-sandbox-policy/SKILL.md

Cópialo y pégalo en tu IA (Claude, ChatGPT o Cursor) pidiéndole que siga las instrucciones.

Cómo usar

La forma más fácil: copia el mensaje y pégalo en tu IA. Ella lee la skill y sigue las instrucciones.

Mensaje listo para pegar

Usa esta skill para ayudarme: https://github.com/NVIDIA/OpenShell/blob/main/skills/generate-sandbox-policy/SKILL.md Lee el archivo SKILL.md de ese link y sigue sus instrucciones en mi tarea.
¿Quieres que tu IA encuentre skills como esta por sí sola?Instala el MCP gratis de Skillpedia: una línea, y busca entre 15.000+ skills antes de cada tarea.Instalar en 1 minuto →

Ejemplo de qué pedirle a la IA

“Escribe una política de sandbox que permita a mi IA leer desde la API de GitHub, pero nada más.”

5 skills nuevas por semana. 1 minuto de lectura.

Cómo funciona

La IA reúne los hosts y el acceso que necesitas, elige el nivel de detalle que permite lo que le das y escribe una política en YAML que coincide con el formato de política del sandbox, para que la revises.

Contenido técnico (SKILL.md original)

Texto original del autor, en inglés, directo de GitHub.

Generate Sandbox Policy

Generate YAML sandbox network policies and network middleware configuration from API documentation and natural-language user requirements.

Overview

This skill translates a user's plain-language policy intent into a valid sandbox policy. The amount of detail the user provides determines the granularity of the generated policy — from broad L4 or preset-based policies (just a host:port) up to fine-grained per-endpoint L7 rules (full API docs).

The output is a network_policies YAML block, an optional network_middlewares block, and optionally a full policy file that conforms to the sandbox policy schema.

Step 1: Gather Inputs

Determine the Detail Tier

The user's input falls into one of three tiers. Work with whatever the user provides — do not require a higher tier than needed.

Tier User provides What you can generate
Minimal Host(s) and plain-language intent L4-only policies, or L7 with access presets (read-only, read-write, full)
Moderate Host(s) + some known URL paths or resources L7 with targeted glob rules for known paths, presets for the rest
Full Complete API docs (OpenAPI, Swagger, markdown, URL) Fine-grained per-endpoint L7 rules with specific method+path combinations

Minimal Tier (host + intent only)

The user provides API endpoints and a broad intent. No API docs needed.

Examples:

  • "Allow curl to hit api.github.com, read-only"
  • "Give claude full access to api.anthropic.com"
  • "Let /usr/bin/myapp talk to internal-svc:8080 but only for reading"

This is sufficient for:

  • L4-only policies (host:port + binary checks, no method or path rules)
  • Preset-based L7 policies (read-only, read-write, full on all paths)

For this tier, default to:

  • access: read-only when the user says "read", "browse", "view", "query", "fetch"
  • access: read-write when the user says "read-write", "create", "update" (but not "delete")
  • access: full when the user says "full access", "everything", "unrestricted"
  • L4-only when the user says "just allow it", "pass through", or "no inspection". Omit protocol for explicit-proxy clients. Use protocol: tcp only when the workload must use native DNS and direct socket calls, the endpoint has a valid DNS hostname, and the selected runtime support (currently Docker and Podman).

Moderate Tier (host + partial path knowledge)

The user knows some API paths but doesn't have full docs.

Examples:

  • "Allow GET on /api/v1/models and POST on /api/v1/completions at integrate.api.nvidia.com"
  • "Read-only on /repos/** at api.github.com, but also allow POST on /repos///issues"

Generate explicit rules for the known paths. If the user also wants broader access beyond the specific paths, combine with a catch-all rule or suggest a preset instead.

Full Tier (complete API docs)

The user provides full API documentation. Accepted formats:

Format How to consume
URL Fetch with the agent's web access and parse the endpoint list
File path Read the file (OpenAPI JSON/YAML, markdown, etc.)
Pasted text Parse inline from the conversation
OpenAPI/Swagger spec Extract paths object for all method+path combinations

From the API docs, build an endpoint inventory — a list of (method, path, description) tuples. Group them logically (e.g., by resource or tag). Then generate precise rules that allow only what the user's intent requires.

Policy Intent

Regardless of tier, extract (or infer) these from the user's description:

Aspect What to identify Required?
Scope Which API host(s) and port(s) Yes — always needed
Access level Broad intent: read-only, read-write, full, or custom Yes — ask if unclear
Methods Specific HTTP methods to allow Only for custom/fine-grained
Paths Specific URL paths or patterns Only for custom/fine-grained
Enforcement enforce or audit? Default to enforce. No — has a default
Binary Which binary/process should have access Yes — ask if not stated
Middleware Whether admitted HTTP requests, final HTTP responses, or client WebSocket text messages need an ordered built-in or operator-run processing stage No

If the host and access level are clear but binaries are not specified, ask the user w

Preguntas frecuentes

¿Necesito documentación de la API para usarla?

No. Con un host y una descripción sencilla basta para una política básica. Con la documentación completa de la API puede escribir reglas más precisas.

¿Qué es un preajuste de acceso?

Un preajuste es un nivel de acceso ya hecho, como solo lectura, lectura y escritura, o completo, que la IA puede usar cuando no hacen falta reglas detalladas.

¿Puede escribir reglas solo para algunas rutas?

Sí. Si conoce algunas rutas de URL, puede escribir reglas específicas para esas rutas y usar preajustes para el resto.

Detalles

Descripción original del autor

Generate sandbox security policies from plain-language requirements and optional REST API documentation. Produces L4 or fine-grained L7 network policies and ordered network middleware configuration. Use for API access rules, middleware host selection, failure behavior, or built-in and operator-run middleware attachment. Trigger keywords - generate policy, create policy, update policy, change policy, sandbox policy, network policy, API policy, security policy, allow API, restrict API, network middleware, supervisor middleware.

repo: NVIDIA/OpenShell

Popularidad

Estrellas en GitHub
21 mil
Posición en el ranking
#10367
Licencia
Apache-2.0
Actualizada
2/11/2026

¿Te sirve esta skill?

0

Entra para votar.

Comentarios

  • …

Más skills de este repositorio

Skills parecidas