Skip to content

docs(plugin): policy examples — block outcomes, not just tools#4

Merged
Harihara04sudhan merged 1 commit into
mainfrom
docs/policy-examples-readme
May 29, 2026
Merged

docs(plugin): policy examples — block outcomes, not just tools#4
Harihara04sudhan merged 1 commit into
mainfrom
docs/policy-examples-readme

Conversation

@Harihara04sudhan

Copy link
Copy Markdown
Contributor

Adds a 'Writing effective policies' section to plugins/armorcopilot/README.md.

Captures the lesson from end-to-end testing: when you deny web_fetch alone, Copilot's planner routes around it via shell + curl to achieve the same outcome. The fix is policy authoring — write broader rules.

New content:

  • Real-world example showing the tool-vs-outcome gap (copy-paste from a real Copilot session)
  • 6-rule Recommended starter policy covering network egress (dedicated tools + shell-with-curl + shell-with-URL), destructive deletes, PCI auto-classification
  • Patterns at a glance table — 5 common block scenarios with one-liner rules
  • Cross-link to the full docs page at https://docs.armoriq.ai/armorcopilot/getting-started/policies (companion PR armoriq/armoriq-docs#34)

Refs #1.

Captures the lesson from end-to-end testing: blocking web_fetch alone
doesn't block the outcome because Copilot routes around via shell+curl.

Adds:
- Real-world example showing the tool-vs-outcome gap
- Recommended starter policy (6 rules covering network egress, shell
  routing, destructive deletes, PCI)
- Patterns-at-a-glance table for common block scenarios
- Link to full docs at docs.armoriq.ai/armorcopilot/getting-started/policies

Mirrors the content in armoriq-docs#34 (companion docs PR).
Copilot AI review requested due to automatic review settings May 29, 2026 08:03

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds guidance to the ArmorCopilot plugin README about writing outcome-focused policies instead of blocking only a single tool.

Changes:

  • Adds a “Writing effective policies” section with a planner bypass example.
  • Adds a recommended starter policy for network egress, destructive deletes, and payment data.
  • Adds a quick-reference table of common policy patterns plus a link to full policy docs.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Denying a single tool blocks that tool, but Copilot's planner can often achieve the same outcome with a different tool. Real example:

```
> Policy new: deny webfetch
### Recommended starter policy

```
> Policy new: deny webfetch
> Policy new: deny * for payment data
```

Six rules cover: network egress via dedicated tools, network egress via shell, destructive deletes, PCI exfiltration.

| Block | Rule |
|---|---|
| Network egress (any tool) | Deny webfetch + websearch + shell-with-curl + shell-with-URL |
| Block | Rule |
|---|---|
| Network egress (any tool) | Deny webfetch + websearch + shell-with-curl + shell-with-URL |
| Writes outside `/tmp` | `Policy new: deny write when path not starts with "/tmp"` |
|---|---|
| Network egress (any tool) | Deny webfetch + websearch + shell-with-curl + shell-with-URL |
| Writes outside `/tmp` | `Policy new: deny write when path not starts with "/tmp"` |
| Email exfiltration via shell | `Policy new: deny shell when args contain "@" and contain "."` |
@Harihara04sudhan Harihara04sudhan merged commit 6ec0385 into main May 29, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants