---
name: "istio-mutual-tls-strict-policy"
description: "Enforce zero-trust encrypted and authenticated mTLS communication between all mesh services."
metadata:
  author: "Istio"
  version: "1.0.0"
  runtime_compatibility:
    - "codex"
    - "claude-code"
    - "cursor"
    - "windsurf"
triggers:
  - "enforce strict mtls istio"
  - "write istio authorizationpolicy"
  - "verify istio tls certificates"
permissions:
  fs_read: true
  fs_write: "workspace"
  shell_exec: false
  net_access: false
---

# Istio PeerAuthentication Strict Mutual TLS (mTLS)

Configures Istio security policies: setting PeerAuthentication to STRICT mode, configuring AuthorizationPolicy with SPIFFE identities (principals), enforcing namespace isolation, and inspecting Envoy TLS certificates.

## When to Invoke
Invoke this skill whenever you need to:
- enforce strict mtls istio
- write istio authorizationpolicy
- verify istio tls certificates

## Execution SOP & Rules
1. Create PeerAuthentication resource with spec.mtls.mode: STRICT in istio-system or target namespace.
2. Define AuthorizationPolicy with rules.from.source.principals matching SPIFFE ID cluster.local/ns/.../sa/...
3. Inspect Envoy proxy certificate details: istioctl proxy-config secret <pod_name>.
4. Verify non-mesh external traffic is blocked unless explicitly permitted via Ingress Gateway.

## Verification Checklist
- Run local linting, syntax validation, and type-checks before reporting completion.
- Ensure all created or modified files adhere to workspace boundaries and avoid uncommitted secrets.
- Verify tests or build commands exit cleanly with return code 0.
