# CVE-2026-42999: OpenStack Keystone RBAC policy bypass via JSON request body injection

Source: https://junglewise.ai/threats/cve-2026-42999-openstack-keystone-rbac-policy-bypass-via-json-request-body  
Publisher: Junglewise Threat Intelligence, https://junglewise.ai/threats  
Published: 2026-05-28. Updated: 2026-07-02  
License: CC BY 4.0 with a link back

CVE-2026-42999 · Severity: medium · CVSS 6 · Published 2026-05-28

OpenStack Keystone, the identity service for OpenStack cloud environments, contains a critical security flaw that allows any authenticated user to bypass access controls. By including specific data in a request, an attacker can trick the system into granting them permissions they should not have. This could allow a low-privileged user to steal administrative credentials, access private data belonging to other users, or take full control of the entire cloud infrastructure.

Technologies: [keystone (PyPI)](https://junglewise.ai/threats/technologies/keystone). Vendors: [PyPI](https://junglewise.ai/threats/vendors/pypi).

## Quick answers

**Is CVE-2026-42999 exploited in the wild?** No. Junglewise Threat Intelligence has no report of CVE-2026-42999 being exploited in the wild.

**How severe is CVE-2026-42999?** Medium severity, with a CVSS score of 6, published 28 May 2026.

**Which products and versions are affected?** keystone (PyPI) ECOSYSTEM:introduced=14.0.0,fixed=27.0.2, ECOSYSTEM:introduced=14.0.0,fixed=27.0.2,introduced=28.0.0,fixed=28.0.2,introduced=29.0.0,fixed=29.0.2.

**Is there a fix for CVE-2026-42999?** Yes. keystone (PyPI): upgrade to 27.0.2, 29.0.2 or later. Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.

**How is CVE-2026-42999 attacked?** It is attacked over the network, in a software library.

**Am I affected by CVE-2026-42999?** Check whether you run keystone (PyPI) at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

## How to fix

- keystone (PyPI): upgrade to 27.0.2, 29.0.2 or later

  ```sh
  pip install "keystone>=29.0.2"
  ```


## Technical details

An authorization bypass exists in OpenStack Keystone's RBAC policy enforcer (`enforce_call` in `keystone/common/rbac_enforcer/enforcer.py`). The vulnerability occurs because the enforcer unconditionally merges the raw JSON request body into the policy enforcement dictionary using `policy_dict.update(json_input.copy())`. This action overwrites trusted target data previously retrieved from the database. Because `flask.request.get_json` is called with `force=True`, this injection is possible regardless of the HTTP method (e.g., GET, POST) or Content-Type. An authenticated attacker can inject arbitrary `target` attributes (like `user_id` or `project_id`) to satisfy `oslo.policy` rules, effectively bypassing RBAC checks while the API handler executes the operation against the resource ID specified in the URL path. This can lead to full cloud compromise, including the harvesting of EC2 credentials and unauthorized role assignments. Fixes are available in versions 27.0.2, 28.0.2, and 29.0.2.

## Affected products

- OpenStack Keystone >= 14.0.0, < 27.0.2
- OpenStack Keystone >= 28.0.0, < 28.0.2
- OpenStack, Keystone >= 29.0.0, < 29.0.2
- Red Hat Red Hat OpenStack Platform 13, 16.2, 17.1, 18.0

## Identifiers

- CVE-2026-42999
- GHSA-2r23-2g6v-2m5f
- PYSEC-2026-600

## Timeline

- 2026-04-15: disclosed: Bug reported to OpenStack Launchpad
- 2026-05-28: advisory: GitHub Advisory and NVD record published
- 2026-07-02: patched: Advisory updated with reviewed status and patch details

## References

- [https://bugs.launchpad.net/keystone/+bug/2148398](https://bugs.launchpad.net/keystone/+bug/2148398)
- [https://security.openstack.org/ossa/OSSA-2026-015.html](https://security.openstack.org/ossa/OSSA-2026-015.html)
- [https://access.redhat.com/security/cve/CVE-2026-42999](https://access.redhat.com/security/cve/CVE-2026-42999)
- [https://bugzilla.redhat.com/show_bug.cgi?id=2482840](https://bugzilla.redhat.com/show_bug.cgi?id=2482840)
- [https://security.access.redhat.com/data/csaf/v2/vex/2026/cve-2026-42999.json](https://security.access.redhat.com/data/csaf/v2/vex/2026/cve-2026-42999.json)

## Related threats

- [PYSEC-2026-2549 - OpenStack Identity Keystone and keystonemiddleware Insufficiently Protected Credentials](https://junglewise.ai/threats/cve-2015-7546-openstack-identity-keystone-and-keystonemiddleware-insufficiently)
- [PYSEC-2026-830 - OpenStack Keystone allows information disclosure during account locking](https://junglewise.ai/threats/cve-2021-38155-openstack-keystone-allows-information-disclosure-during-account)
- [PYSEC-2026-831 - OpenStack Identity Keystone Privilege Escalation vulnerability](https://junglewise.ai/threats/cve-2013-4477-openstack-identity-keystone-privilege-escalation-vulnerability)
- [PYSEC-2026-833 - OpenStack Keystone does not invalidate existing tokens when granting or revoking roles](https://junglewise.ai/threats/cve-2012-4413-openstack-keystone-does-not-invalidate-existing-tokens-when)
- [PYSEC-2026-832 - OpenStack Keystone Improper Authentication vulnerability](https://junglewise.ai/threats/cve-2012-4456-openstack-keystone-improper-authentication-vulnerability)
