Join the Cyber Forum: Threat Intel on May 12, 2026 to learn how AI is reshaping threat defense.Join the Virtual Cyber Forum: Threat IntelRegister Now
Experiencing a Breach?Blog
Get StartedContact Us
SentinelOne
  • Platform
    Platform Overview
    • Singularity Platform
      Welcome to Integrated Enterprise Security
    • AI for Security
      Leading the Way in AI-Powered Security Solutions
    • Securing AI
      Accelerate AI Adoption with Secure AI Tools, Apps, and Agents.
    • How It Works
      The Singularity XDR Difference
    • Singularity Marketplace
      One-Click Integrations to Unlock the Power of XDR
    • Pricing & Packaging
      Comparisons and Guidance at a Glance
    Data & AI
    • Purple AI
      Accelerate SecOps with Generative AI
    • Singularity Hyperautomation
      Easily Automate Security Processes
    • AI-SIEM
      The AI SIEM for the Autonomous SOC
    • AI Data Pipelines
      Security Data Pipeline for AI SIEM and Data Optimization
    • Singularity Data Lake
      AI-Powered, Unified Data Lake
    • Singularity Data Lake for Log Analytics
      Seamlessly Ingest Data from On-Prem, Cloud or Hybrid Environments
    Endpoint Security
    • Singularity Endpoint
      Autonomous Prevention, Detection, and Response
    • Singularity XDR
      Native & Open Protection, Detection, and Response
    • Singularity RemoteOps Forensics
      Orchestrate Forensics at Scale
    • Singularity Threat Intelligence
      Comprehensive Adversary Intelligence
    • Singularity Vulnerability Management
      Application & OS Vulnerability Management
    • Singularity Identity
      Identity Threat Detection and Response
    Cloud Security
    • Singularity Cloud Security
      Block Attacks with an AI-Powered CNAPP
    • Singularity Cloud Native Security
      Secure Cloud and Development Resources
    • Singularity Cloud Workload Security
      Real-Time Cloud Workload Protection Platform
    • Singularity Cloud Data Security
      AI-Powered Threat Detection for Cloud Storage
    • Singularity Cloud Security Posture Management
      Detect and Remediate Cloud Misconfigurations
    Securing AI
    • Prompt Security
      Secure AI Tools Across Your Enterprise
  • Why SentinelOne?
    Why SentinelOne?
    • Why SentinelOne?
      Cybersecurity Built for What’s Next
    • Our Customers
      Trusted by the World’s Leading Enterprises
    • Industry Recognition
      Tested and Proven by the Experts
    • About Us
      The Industry Leader in Autonomous Cybersecurity
    Compare SentinelOne
    • Arctic Wolf
    • Broadcom
    • CrowdStrike
    • Cybereason
    • Microsoft
    • Palo Alto Networks
    • Sophos
    • Splunk
    • Trellix
    • Trend Micro
    • Wiz
    Verticals
    • Energy
    • Federal Government
    • Finance
    • Healthcare
    • Higher Education
    • K-12 Education
    • Manufacturing
    • Retail
    • State and Local Government
  • Services
    Managed Services
    • Managed Services Overview
      Wayfinder Threat Detection & Response
    • Threat Hunting
      World-Class Expertise and Threat Intelligence
    • Managed Detection & Response
      24/7/365 Expert MDR Across Your Entire Environment
    • Incident Readiness & Response
      DFIR, Breach Readiness, & Compromise Assessments
    Support, Deployment, & Health
    • Technical Account Management
      Customer Success with Personalized Service
    • SentinelOne GO
      Guided Onboarding & Deployment Advisory
    • SentinelOne University
      Live and On-Demand Training
    • Services Overview
      Comprehensive Solutions for Seamless Security Operations
    • SentinelOne Community
      Community Login
  • Partners
    Our Network
    • MSSP Partners
      Succeed Faster with SentinelOne
    • Singularity Marketplace
      Extend the Power of S1 Technology
    • Cyber Risk Partners
      Enlist Pro Response and Advisory Teams
    • Technology Alliances
      Integrated, Enterprise-Scale Solutions
    • SentinelOne for AWS
      Hosted in AWS Regions Around the World
    • Channel Partners
      Deliver the Right Solutions, Together
    • SentinelOne for Google Cloud
      Unified, Autonomous Security Giving Defenders the Advantage at Global Scale
    • Partner Locator
      Your Go-to Source for Our Top Partners in Your Region
    Partner Portal→
  • Resources
    Resource Center
    • Case Studies
    • Data Sheets
    • eBooks
    • Reports
    • Videos
    • Webinars
    • Whitepapers
    • Events
    View All Resources→
    Blog
    • Feature Spotlight
    • For CISO/CIO
    • From the Front Lines
    • Identity
    • Cloud
    • macOS
    • SentinelOne Blog
    Blog→
    Tech Resources
    • SentinelLABS
    • Ransomware Anthology
    • Cybersecurity 101
  • About
    About SentinelOne
    • About SentinelOne
      The Industry Leader in Cybersecurity
    • Investor Relations
      Financial Information & Events
    • SentinelLABS
      Threat Research for the Modern Threat Hunter
    • Careers
      The Latest Job Opportunities
    • Press & News
      Company Announcements
    • Cybersecurity Blog
      The Latest Cybersecurity Threats, News, & More
    • FAQ
      Get Answers to Our Most Frequently Asked Questions
    • DataSet
      The Live Data Platform
    • S Foundation
      Securing a Safer Future for All
    • S Ventures
      Investing in the Next Generation of Security, Data and AI
  • Pricing
Get StartedContact Us
CVE Vulnerability Database
Vulnerability Database/CVE-2026-4158

CVE-2026-4158: KeePassXC Privilege Escalation Vulnerability

CVE-2026-4158 is a local privilege escalation flaw in KeePassXC affecting its OpenSSL configuration. Attackers can exploit unsecured paths to execute code. This article covers technical details, impact, and mitigations.

Published: April 17, 2026

CVE-2026-4158 Overview

KeePassXC OpenSSL Configuration Uncontrolled Search Path Element Local Privilege Escalation Vulnerability. This vulnerability allows local attackers to escalate privileges on affected installations of KeePassXC. An attacker must first obtain the ability to execute low-privileged code on the target system in order to exploit this vulnerability.

The specific flaw exists within the configuration of OpenSSL. The product loads configuration from an unsecured location. An attacker can leverage this vulnerability to escalate privileges and execute arbitrary code in the context of KeePassXC when run by a target user on the system. This vulnerability was tracked as ZDI-CAN-29156.

Critical Impact

Local attackers with low-privilege access can escalate privileges and execute arbitrary code in the context of KeePassXC, potentially compromising password vaults and sensitive credentials stored within the application.

Affected Products

  • KeePassXC (all versions prior to patch)
  • Systems with KeePassXC installed where OpenSSL configuration paths are writable by low-privileged users
  • Windows installations of KeePassXC are likely at highest risk due to OpenSSL search path behavior

Discovery Timeline

  • 2026-04-11 - CVE-2026-4158 published to NVD
  • 2026-04-13 - Last updated in NVD database

Technical Details for CVE-2026-4158

Vulnerability Analysis

This vulnerability is classified as CWE-427: Uncontrolled Search Path Element. The flaw stems from KeePassXC's OpenSSL implementation loading configuration files from an unsecured location that may be writable by low-privileged users on the system.

When KeePassXC initializes its cryptographic functions through OpenSSL, the library searches for configuration files in a sequence of directories. If an attacker can place a malicious OpenSSL configuration file in one of these search paths before the legitimate configuration is found, they can hijack the execution flow.

The attack requires local access and the ability to execute low-privileged code, but successful exploitation leads to code execution with the privileges of the user running KeePassXC. Given that KeePassXC is a password manager, this represents a significant risk as attackers could potentially access stored credentials.

Root Cause

The root cause of this vulnerability lies in the insecure handling of the OpenSSL configuration search path within KeePassXC. The application does not properly validate or restrict the locations from which OpenSSL configuration files can be loaded. This allows a malicious configuration file placed in a user-writable directory to be loaded by the application, enabling arbitrary code execution through OpenSSL's engine loading capabilities.

Attack Vector

The attack vector is local, requiring the attacker to have initial low-privileged access to the target system. The exploitation process involves:

  1. The attacker gains low-privilege code execution on the target system
  2. The attacker identifies a writable directory within the OpenSSL configuration search path
  3. A malicious OpenSSL configuration file is crafted to load a malicious shared library or execute arbitrary code
  4. When a target user launches KeePassXC, the application loads the malicious configuration
  5. Arbitrary code executes in the context of the user running KeePassXC

The vulnerability requires user interaction (the target user must run KeePassXC) for successful exploitation. For detailed technical information, refer to the Zero Day Initiative Advisory ZDI-26-215 and the GitHub Security Advisory.

Detection Methods for CVE-2026-4158

Indicators of Compromise

  • Unexpected openssl.cnf files appearing in user-writable directories within the OpenSSL search path
  • Suspicious DLL or shared library files in directories commonly used for OpenSSL configuration
  • Process execution anomalies where KeePassXC spawns unexpected child processes
  • File system modifications to OpenSSL configuration directories by non-administrative users

Detection Strategies

  • Monitor file system activity for creation or modification of OpenSSL configuration files (openssl.cnf) in non-standard locations
  • Implement application whitelisting to detect unexpected code execution from KeePassXC processes
  • Use endpoint detection and response (EDR) solutions to identify privilege escalation patterns originating from password manager applications
  • Deploy file integrity monitoring on known OpenSSL configuration directories

Monitoring Recommendations

  • Enable detailed process creation logging to capture command-line arguments and parent process relationships for KeePassXC
  • Configure alerts for unusual file writes to directories in the system's library search paths
  • Monitor for engine loading events within OpenSSL that reference non-standard file paths
  • Implement behavioral analysis to detect anomalous KeePassXC process behavior indicative of code injection

How to Mitigate CVE-2026-4158

Immediate Actions Required

  • Update KeePassXC to the latest patched version as soon as it becomes available
  • Review and restrict write permissions on directories within the OpenSSL configuration search path
  • Implement application control policies to prevent unauthorized code execution within the context of KeePassXC
  • Audit system directories for unexpected OpenSSL configuration files or suspicious shared libraries

Patch Information

Security patches and remediation guidance are available through the official KeePassXC channels. Refer to the GitHub Security Advisory GHSA-4gr2-cr97-q9fx for detailed patch information and affected version details. Additional context is available in the Zero Day Initiative Advisory ZDI-26-215.

Workarounds

  • Ensure that all directories in the OpenSSL configuration search path have restrictive permissions, allowing writes only by administrative users
  • Set the OPENSSL_CONF environment variable explicitly to point to a secure, read-only configuration file location
  • Run KeePassXC in an isolated environment or sandbox to limit the impact of potential exploitation
  • Implement strict access controls on the system to minimize the risk of attackers gaining initial low-privilege access
bash
# Example: Set explicit OpenSSL configuration path (Windows)
# setx OPENSSL_CONF "C:\Program Files\OpenSSL\openssl.cnf"

# Example: Set explicit OpenSSL configuration path (Linux/macOS)
export OPENSSL_CONF="/etc/ssl/openssl.cnf"

# Verify permissions on OpenSSL configuration directories
# Linux/macOS: Ensure only root can write
ls -la /etc/ssl/
# Windows: Verify ACLs on OpenSSL directories

Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

  • Vulnerability Details
  • TypePrivilege Escalation

  • Vendor/TechKeepassxc

  • SeverityHIGH

  • CVSS Score7.3

  • EPSS Probability0.01%

  • Known ExploitedNo
  • CVSS Vector
  • CVSS:3.0/AV:L/AC:L/PR:L/UI:R/S:U/C:H/I:H/A:H
  • Impact Assessment
  • ConfidentialityLow
  • IntegrityHigh
  • AvailabilityHigh
  • CWE References
  • CWE-427
  • Technical References
  • GitHub Security Advisory

  • Zero Day Initiative Advisory ZDI-26-215
  • Related CVEs
  • CVE-2025-65203: KeePassXC-Browser XSS Vulnerability

  • CVE-2023-35866: KeePassXC Auth Bypass Vulnerability
Default Legacy - Prefooter | Experience the World’s Most Advanced Cybersecurity Platform

Experience the World’s Most Advanced Cybersecurity Platform

See how our intelligent, autonomous cybersecurity platform can protect your organization now and into the future.

Try SentinelOne
  • Get Started
  • Get a Demo
  • Product Tour
  • Why SentinelOne
  • Pricing & Packaging
  • FAQ
  • Contact
  • Contact Us
  • Customer Support
  • SentinelOne Status
  • Language
  • Platform
  • Singularity Platform
  • Singularity Endpoint
  • Singularity Cloud
  • Singularity AI-SIEM
  • Singularity Identity
  • Singularity Marketplace
  • Purple AI
  • Services
  • Wayfinder TDR
  • SentinelOne GO
  • Technical Account Management
  • Support Services
  • Verticals
  • Energy
  • Federal Government
  • Finance
  • Healthcare
  • Higher Education
  • K-12 Education
  • Manufacturing
  • Retail
  • State and Local Government
  • Cybersecurity for SMB
  • Resources
  • Blog
  • Labs
  • Case Studies
  • Videos
  • Product Tours
  • Events
  • Cybersecurity 101
  • eBooks
  • Webinars
  • Whitepapers
  • Press
  • News
  • Ransomware Anthology
  • Company
  • About Us
  • Our Customers
  • Careers
  • Partners
  • Legal & Compliance
  • Security & Compliance
  • Investor Relations
  • S Foundation
  • S Ventures

©2026 SentinelOne, All Rights Reserved.

Privacy Notice Terms of Use

English