CVE-2021-42135: HashiCorp Vault and Vault Enterprise Privilege Escalation

vault Updated 02 Oct 2025

Summary

06/03/2024
Yes i
High
Not published

CVE-2021-42135: HashiCorp Vault and Vault Enterprise 1.8.x through 1.8.4 may have an unexpected interaction between glob-related policies and the Google Cloud secrets engine. Affects vault versions >= 1.8.0, < 1.8.5. Fixed in 1.8.5. How to fix ↓

Also tracked for

The same CVE-2021-42135 is tracked separately for each ecosystem and vendor. Its fix information is the same; the package and affected versions differ.

Free scan

Check if this vulnerability affects your application

Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.

Check my app free

No signup required · Results in about 60 seconds

Sponsored Devnack Penetration testing for web, API and mobile Manual testing by engineers who build software, not an auditor's checklist. Trusted by teams at Swift and Google Talk to Devnack

Background

HashiCorp Vault is an open-source tool designed to securely store and manage secrets, such as API keys, passwords, and certificates. It provides a centralized solution for access control and encryption of sensitive data. Vault Enterprise is the commercial version of Vault, offering additional features and support. However, versions 1.8.x through 1.8.4 of both Vault and Vault Enterprise are susceptible to a privilege escalation vulnerability.

Vulnerability Detail

The vulnerability (CVE-2021-42135) arises from an unexpected interaction between glob-related policies and the Google Cloud secrets engine in HashiCorp Vault and Vault Enterprise. In certain scenarios, users may obtain more privileges than intended. For instance, a user with read permission for the '/gcp/roleset/*' path could potentially issue Google Cloud service account credentials. This vulnerability poses a significant risk as it allows unauthorized access to sensitive resources and potentially compromises the security of the system.

How To Fix

Minimum fixed version

1.8.5

This is the first release that contains the fix.

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Workaround

At present, there is no known workaround for this vulnerability. It is crucial to apply the recommended fix by upgrading to the patched version as soon as possible.

Conclusion

The privilege escalation vulnerability in HashiCorp Vault and Vault Enterprise (CVE-2021-42135) poses a significant risk to the security of sensitive resources. It is crucial to upgrade to the fixed version (1.8.5 or later) to mitigate this vulnerability. For further assistance and support in addressing this vulnerability, please contact DevNack.com.

See every vulnerability recorded for vault →

Share this vulnerability

FAQ

HashiCorp Vault is an open-source tool for securely storing and managing secrets, such as API keys, passwords, and certificates. It provides a centralized solution for access control and encryption of sensitive data.

This vulnerability allows users to obtain more privileges than intended, potentially leading to unauthorized access to sensitive resources and compromising system security.

Versions 1.8.x through 1.8.4 of both HashiCorp Vault and Vault Enterprise are affected by this vulnerability.

To fix this vulnerability, it is recommended to upgrade to version 1.8.5 or later of HashiCorp Vault or Vault Enterprise.

Currently, there is no known workaround for this vulnerability. Upgrading to the patched version is the recommended solution.

Related vulnerabilities

Recent vulnerabilities recorded for vault.

How To Fix

Minimum fixed version

1.8.5

This is the first release that contains the fix.

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Subscribe to Vulert on Telegram
Daily digest of new CVEs, critical and high severity, affected packages and fixes — plus a weekly roundup.
Join the channel →
Help improve this record
Report an issue or send feedback