create-ringfence
Create a ringfencing policy for an application by analyzing traffic flows and generating rules that allow only discovered communication partners, reducing segmentation risk without per-port policies.
Instructions
Create a ringfencing policy for an application. This analyzes traffic flows to discover which other apps communicate with this app, then creates a ruleset with:
An intra-scope rule allowing all workloads within the app to communicate on All Services
Extra-scope rules for each remote app+env discovered in traffic, allowing them in on All Services The result is a coarse-grained segmentation that controls which apps can talk to each other, reducing risk without requiring per-port policies. WRITE OPERATION: changes PCE state. In clients that gate tool calls (Claude Desktop, Claude Code), this pauses for the user to approve it -- the call has not failed and must not be retried while waiting.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| dry_run | No | If true, analyze traffic and report what would be created without actually creating anything (default: false) | |
| app_name | Yes | Application label value (e.g., 'CRM', 'Ordering', 'ELK') | |
| env_name | Yes | Environment label value (e.g., 'Production', 'Staging', 'Development') | |
| selective | No | If true, adds a deny rule blocking all inbound traffic to the app. In selective enforcement mode the default action is allow-all, so without this deny rule the ringfence has no teeth. Allow rules for known remote apps are processed before the deny rule (rule order: override_deny > allow > deny > default), so known apps pass through and everything else hits the deny. This gets you to enforcement faster than full enforcement mode. | |
| deny_service | No | Service the selective-mode deny rule covers. Defaults to All Services ('deny everything except the allows above'). Narrow it to deny only specific ports. | |
| ruleset_name | No | Custom name for the ringfence ruleset (default: 'RF-<app_name>-<env_name>') | |
| skip_allowed | No | If true, skip creating rules for remote apps whose traffic is already fully allowed by existing policy. Default is false, meaning rules are created for all observed traffic regardless of policy decision. This makes the ringfence ruleset self-documenting — it shows the complete picture of app connectivity. Set to true for minimal rulesets that only fill policy gaps. | |
| deny_consumer | No | Controls which consumers the deny rule targets (only used with selective=true). Illumio pushes deny rules to the source workload, so this choice matters: 'any' (default) = IP list Any (0.0.0.0/0) as consumer, deny rule only written to destination workloads inside the scope. Safest, no impact on remote workloads. 'ams' = All Workloads as consumer, deny rule pushed to every managed workload outside the scope. Broader enforcement but wider blast radius. 'ams_and_any' = both All Workloads and Any IP list, maximum coverage for managed and unmanaged sources. | any |
| lookback_days | No | Number of days to look back for traffic flows (default: 30) |