Policies · Mesh* policies

MeshTrafficPermission

Allows or denies inbound traffic to selected proxies, by client selector (from[]) or SPIFFE identity (rules[]).

Kuma

Behaviour per target

--to-latest v2 (2.x) warned

Output: MeshTrafficPermission

Passed through, with these checks:

  • spiffeId is renamed to spiffeID (auto-fixed).
  • action: ALLOW/DENY is reported; use Allow/Deny.
  • from[].targetRef.kind: MeshService is reported as deprecated since 2.7.
  • from[] is reported as deprecated in favour of rules[] and is not converted: rules[] matches clients by SPIFFE ID, needs a MeshIdentity and is default-deny, so a mechanical rewrite would fail or widen access.
  • A top-level MeshSubset, MeshService or MeshServiceSubset is reported; use Dataplane with labels.

A policy whose refs still use MeshSubset with kuma.io/service tags, or old <name>_<ns>_svc_<port> names, is rewritten first (Subset scenario): the top level becomes Dataplane with labels. from[] keeps MeshSubset with the kuma.io/service tag (the 2.7+ form); a from[] MeshService with an old _svc_ name is turned back into that MeshSubset.

--to-latest v3 (3.0) error

Output: MeshTrafficPermission

The v2 checks apply. A policy that keeps from[] is rejected by 3.0 as it stands (spec.from: unknown field, then "policy must define rules"), so it is written to _manual/ instead of the apply tree and listed under Action Items → Errors with the reason. Translate from[] to rules[], then apply it.

Also under v3:

  • Empty match entries ({}) in rules[].default.{allow,deny,allowWithShadowDeny} are reported; 3.0 rejects them.
  • A top-level MeshService ref is rewritten from name/namespace to labels, but the kind stays and 3.0 accepts only Mesh and Dataplane there, so the policy is reported as an error and written to _manual/.
  • Control-plane-owned labels are removed.

Timeline

VersionChange
2.7from[].targetRef.kind: MeshService deprecated; use MeshSubset with the kuma.io/service tag.
2.14from[] deprecated in favour of the SPIFFE-based rules[] API.
3.0spec.from removed. Empty match entries rejected. Top-level targetRef limited to Mesh and Dataplane.

Source files