GHSA-C33X-VCV4-VG3G

GHSA-C33X-VCV4-VG3G is a low-severity improper input validation vulnerability in cedar-policy (rust), affecting versions >= 4.0.0, < 4.11.1. It is fixed in 4.11.1, 3.4.3.

Does this CVE actually affect you?

Kodem shows which CVEs are reachable and running in your applications, so you fix what's exploitable, not just what's listed.

Thank you! Your submission has been received!
Oops! Something went wrong while submitting the form.

Runtime intelligence, not another scanner.

Summary

Cedar: JSON template is in scope missing slot-id validation allows link panic and decision divergence

Cedar users must be using all of the following features to be affected by this advisory: JSON format policies, policy templates, and the is in scope condition. This advisory only affects JSON-formatted Cedar policy templates containing is in scope conditions that are malformed according to the Cedar syntax. It does not affect syntactically well-formed policies.

Users of Cedar who author policies in the JSON format were able to write Cedar policies using the is in condition with an incorrect slot identifier in the principal and resource scope constraints (e.g., ?principal in the resource scope constraint) even though this is not allowed when parsing policies from the Cedar policy syntax. Internally, the slot identifiers were silently corrected (e.g. ?resource is placed in the resource scope constraint).

If the policy contains exactly one slot in either the principal or resource position, then any attempt to create a linked policy from the template results in an error: the internal representation of the template does not contain the slot identifier as written in the malformed JSON policy (it has been corrected silently), so attempting to fill that slot is an error. If instead the template is linked using slot identifier expected internally (i.e., not what is written in the JSON template), the linking will initially succeed, but a subsequent invariant violation will cause a panic.

When the template contains slots in both the principal and resource position, then both slots will be present in the internal representation: linking succeeds, but with each slot bound to the value intended for the other (the silent correction). The linked policy is then semantically different from the malformed policy the user intended, and any subsequent authorization decision made against that policy may lead to accesses being unintentionally allowed or denied.

Concretely, consider the following JSON format policy template intended to deny users in a particular project from accessing documents with a particular classification.

{
  "effect": "forbid",
  "principal": {
    "op": "is",
    "entity_type": "User",
    "in": { "slot": "?resource" }
  },
  "action": { "op": "All" },
  "resource": {
    "op": "is",
    "entity_type": "Doc",
    "in": { "slot": "?principal" }
  },
  "conditions": []
}

Linked with ?principal = Classification::"topsecret" and ?resource = Project::"alpha", the author expects to create the policy:

forbid(principal is User in Project::"alpha", action, resource is Doc in Classification::"topsecret");

But because Cedar internally links slots by scope position (not by name), the actual policy evaluated by the engine is:

forbid(principal is User in Classification::"topsecret", action, resource is Doc in Project::"alpha");

If a user is in Project::"alpha" but not Classification::"topsecret", the forbid policy does not apply, and access is unintentionally allowed.

Workarounds

If you cannot update to a patched version, you can determine if you are affected by checking your JSON format policy templates for the following two patterns.

  "principal": {
    "op": "is",
    "entity_type": "User",
    "in": { "slot": "?resource" }
  }

and

  "resource": {
    "op": "is",
    "entity_type": "Doc",
    "in": { "slot": "?principal" }
  }

References

Impact

The application does not adequately validate input before processing it, allowing unexpected values to reach sensitive code paths. Typical impact: varies by context: data corruption, logic bypass, or denial of service.

Affected versions

cedar-policy (>= 4.0.0, < 4.11.1) cedar-policy (>= 3.0.0, < 3.4.3) @cedar-policy/cedar-wasm (>= 4.0.1, < 4.11.1) @cedar-policy/cedar-wasm (>= 3.2.0, < 3.4.3)

Security releases

cedar-policy → 4.11.1 (rust) cedar-policy → 3.4.3 (rust) @cedar-policy/cedar-wasm → 4.11.1 (npm) @cedar-policy/cedar-wasm → 3.4.3 (npm)

Kodem intelligence

Severity tells you how bad this could be in the worst case. It does not tell you whether you are exposed. Exploitability and impact are functions of runtime truth: whether the vulnerable code is present, reachable, and actually executes in your application. A vulnerable package can sit in your dependency tree and never run.

Kodem, an Intelligent Application Security platform, uses runtime intelligence to reveal which vulnerabilities actually execute in production, so teams prioritize the ones that genuinely matter. Kodem's runtime-powered SCA identifies whether this CVE is reachable in your applications.

Already deployed Kodem?

See it in your environmentNew to Kodem? Get a demo →

Remediation advice

This advisory is patched in version 4.11.1 and 3.4.3, both available on Crates.io and NPM.

Frequently Asked Questions

  1. What is GHSA-C33X-VCV4-VG3G? GHSA-C33X-VCV4-VG3G is a low-severity improper input validation vulnerability in cedar-policy (rust), affecting versions >= 4.0.0, < 4.11.1. It is fixed in 4.11.1, 3.4.3. The application does not adequately validate input before processing it, allowing unexpected values to reach sensitive code paths.
  2. Which packages are affected by GHSA-C33X-VCV4-VG3G?
    • cedar-policy (rust) (versions >= 4.0.0, < 4.11.1)
    • @cedar-policy/cedar-wasm (npm) (versions >= 4.0.1, < 4.11.1)
  3. Is there a fix for GHSA-C33X-VCV4-VG3G? Yes. GHSA-C33X-VCV4-VG3G is fixed in 4.11.1, 3.4.3. Upgrade to this version or later.
  4. Is GHSA-C33X-VCV4-VG3G exploitable, and should I be worried? Whether GHSA-C33X-VCV4-VG3G is exploitable in your environment depends on whether the vulnerable code is present and reachable. A CVSS score is a worst-case rating; it does not account for your specific deployment, configuration, or usage patterns. Kodem, an Intelligent Application Security platform, uses runtime intelligence to show which vulnerabilities actually execute in production, so you can focus on the ones that represent real risk. Get a demo
  5. What actually determines whether GHSA-C33X-VCV4-VG3G is exploitable, and how bad it is? Exploitability and impact are not fixed properties of a CVE. They depend on runtime truth: whether the vulnerable code is present, reachable, and actually executes in your application. A high CVSS score on a dependency that never runs is not the same as real risk. Kodem, an Intelligent Application Security platform, uses runtime intelligence to reveal which vulnerabilities actually execute in production, so teams prioritize the ones that genuinely matter.
  6. How do I fix GHSA-C33X-VCV4-VG3G?
    • Upgrade cedar-policy to 4.11.1 or later
    • Upgrade cedar-policy to 3.4.3 or later
    • Upgrade @cedar-policy/cedar-wasm to 4.11.1 or later
    • Upgrade @cedar-policy/cedar-wasm to 3.4.3 or later

Stop the waste.
Protect your environment with Kodem.