Vulnerabilities in pkg:maven/org.apache.nifi/nifi-mongodb-services

PACKAGE
Advisory Identifier: GHSA-35gq-cvrm-xf94
Advisory Summary

CVE-2025-27017 is a MODERATE (CVSS 6.5) potential insertion of mongodb password vulnerability (CWE-538: Insertion of Sensitive Information into Externally-Accessible File or Directory) affecting Apache NiFi libraries in the Maven ecosystem. The issue involves potential insertion of mongodb password in provenance record. Remediation is available by upgrading affected packages to version 2.3.0.

1 Known Advisory Record(s)
Package Vulnerability Intelligence

pkg:maven/org.apache.nifi/nifi-mongodb-services

1 Known Advisory Record(s)

Vulnerability advisories affecting package pkg:maven/org.apache.nifi/nifi-mongodb-services. Select an advisory below to view technical details or fixes.

Advisory ID CVE / NVD Severity Summary
GHSA-35gq-cvrm-xf94 CVE-2025-27017 MODERATE Apache NiFi: Potential Insertion of MongoDB Password in Provenance Record

CVE-2025-27017 at a Glance

CVE Identifier CVE-2025-27017
GHSA Identifier GHSA-35gq-cvrm-xf94
Severity MODERATE
CVSS v3.1 Base Score 6.5
CWE Classification CWE-538: Insertion of Sensitive Information into Externally-Accessible File or Directory
Affected Product Apache NiFi
Package Ecosystem Maven
Published Date
Last Updated

Security Impact

CVSS: 6.5

The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:N).

Attack Vector Network (AV:N)
Attack Complexity Low (AC:L)
Privileges Required Low (PR:L)
User Interaction None (UI:N)
Scope Unchanged (S:U)
Confidentiality High (C:H)
Integrity None (I:N)
Availability None (A:N)

How to Fix CVE-2025-27017

To remediate this vulnerability, upgrade all affected Apache NiFi dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

org.apache.nifi:nifi-mongodb-services fixed: 2.3.0
<dependency>
    <groupId>org.apache.nifi</groupId>
    <artifactId>nifi-mongodb-services</artifactId>
    <version>2.3.0</version>
</dependency>
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

mvn dependency:tree -Dincludes=org.apache.nifi

How to Check if You Are Affected

To determine whether your Java application is affected by CVE-2025-27017, inspect your build dependencies using the Maven Dependency Plugin:

mvn dependency:tree -Dincludes=org.apache.nifi

Analyze the terminal output to locate any version of Apache NiFi in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 2.3.0), your application is affected.

Note: The mvn dependency:tree -Dincludes=org.apache.nifi command inspects the resolved dependency graph declared in your project's POM files; it does not perform automated security scanning or inspect runtime dynamic classpaths. Always verify runtime container classpaths and shaded JARs.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-538: Insertion of Sensitive Information into Externally-Accessible File or Directory, where the product places sensitive information into files or directories that are accessible to actors who are allowed to have access to the files, but not to the sensitive information. In Apache NiFi, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

Apache NiFi 1.13.0 through 2.2.0 includes the username and password used to authenticate with MongoDB in the NiFi provenance events that MongoDB components generate during processing. An authorized user with read access to the provenance events of those processors may see the credentials information. Upgrading to Apache NiFi 2.3.0 is the recommended mitigation, which removes the credentials from provenance event records.

CVE-2025-27017 Affected Apache NiFi Versions

1 component(s)
Fixed Versions:
2.3.0
Product / Package Ecosystem Affected Versions Fixed Version
org.apache.nifi:nifi-mongodb-services
Maven
≥ 1.13.0
< 2.3.0
2.3.0

References

Frequently Asked Questions

What is CVE-2025-27017?
CVE-2025-27017 is a security vulnerability in Apache NiFi involving Potential Insertion of MongoDB Password in Provenance Record under CWE-538: Insertion of Sensitive Information into Externally-Accessible File or Directory.
Which Apache NiFi versions are affected?
Affected versions include releases prior to 2.3.0 across affected packages: org.apache.nifi:nifi-mongodb-services.
What version fixes CVE-2025-27017?
Upgrading to 2.3.0 (or the latest patched release for your respective branch) resolves the vulnerability.
Is nifi-mongodb-services affected?
Yes, org.apache.nifi:nifi-mongodb-services is affected in releases prior to 2.3.0. Upgrade your dependency to 2.3.0 or later.
What is the CVSS score of CVE-2025-27017?
CVE-2025-27017 has a CVSS v3.1 base score of 6.5 (MODERATE) with vector string CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:N.
What CWE is associated with CVE-2025-27017?
CVE-2025-27017 is classified under CWE-538: Insertion of Sensitive Information into Externally-Accessible File or Directory (The product places sensitive information into files or directories that are accessible to actors who are allowed to have access to the files, but not to the sensitive information.).
How can I check Maven dependencies for CVE-2025-27017?
Run the dependency tree command: 'mvn dependency:tree -Dincludes=org.apache.nifi'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-35gq-cvrm-xf94",
  "modified" : "2025-07-16T21:02:25Z",
  "published" : "2025-03-12T18:32:53Z",
  "aliases" : [ "CVE-2025-27017" ],
  "summary" : "Apache NiFi: Potential Insertion of MongoDB Password in Provenance Record",
  "details" : "Apache NiFi 1.13.0 through 2.2.0 includes the username and password used to authenticate with MongoDB in the NiFi provenance events that MongoDB components generate during processing. An authorized user with read access to the provenance events of those processors may see the credentials information. Upgrading to Apache NiFi 2.3.0 is the recommended mitigation, which removes the credentials from provenance event records.",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:N"
  }, {
    "type" : "CVSS_V4",
    "score" : "CVSS:4.0/AV:N/AC:L/AT:P/PR:H/UI:N/VC:H/VI:N/VA:N/SC:H/SI:N/SA:N/S:P/AU:Y/R:U/V:C/RE:L/U:Green"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "Maven",
      "name" : "org.apache.nifi:nifi-mongodb-services"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "1.13.0"
      }, {
        "fixed" : "2.3.0"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2025-27017"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/apache/nifi/commit/48d684500f6ad70f65bfd510db054590c5bc74a9"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/apache/nifi"
  }, {
    "type" : "WEB",
    "url" : "https://issues.apache.org/jira/browse/NIFI-14272"
  }, {
    "type" : "WEB",
    "url" : "https://lists.apache.org/thread/d4n5474jkhp82dvnht13pjtlfx7bhn5q"
  }, {
    "type" : "WEB",
    "url" : "http://www.openwall.com/lists/oss-security/2025/03/11/1"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-538" ],
    "severity" : "MODERATE",
    "github_reviewed" : true,
    "github_reviewed_at" : "2025-03-12T22:08:29Z",
    "nvd_published_at" : "2025-03-12T17:15:50Z"
  }
}