CVE-2022-41954: Mpxj Temporary File Information Disclosure Vulnerability Vulnerability
LOWCVE-2022-41954 is a LOW (CVSS 2.8) temporary file information disclosure vulnerability vulnerability (CWE-668: Exposure of Resource to Wrong Sphere) affecting Mpxj libraries in the Maven ecosystem. The issue involves temporary file information disclosure vulnerability in mpxj. Remediation is available by upgrading affected packages to version 10.14.1.
CVE-2022-41954 at a Glance
Security Impact
CVSS: 2.8
The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:L/AC:L/PR:L/UI:R/S:U/C:L/I:N/A:N).
How to Fix CVE-2022-41954
To remediate this vulnerability, upgrade all affected Mpxj dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
<dependency>
<groupId>net.sf.mpxj</groupId>
<artifactId>mpxj</artifactId>
<version>10.14.1</version>
</dependency>
Upgrade net.sf.mpxj to 10.14.1
Upgrade net.sf.mpxj-for-csharp to 10.14.1
Upgrade net.sf.mpxj-for-vb to 10.14.1
pip install mpxj>=10.14.1
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
mvn dependency:tree -Dincludes=net.sf.mpxj
How to Check if You Are Affected
To determine whether your Java application is affected by CVE-2022-41954, inspect your build dependencies using the Maven Dependency Plugin:
mvn dependency:tree -Dincludes=net.sf.mpxj
Analyze the terminal output to locate any version of Mpxj in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 10.14.1), your application is affected.
Note: The mvn dependency:tree -Dincludes=net.sf.mpxj 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-668: Exposure of Resource to Wrong Sphere, where the product exposes a resource to the wrong control sphere, providing unintended actors with inappropriate access to the resource. In Mpxj, 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
CVE-2022-41954 Affected Mpxj Versions
5 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
net.sf.mpxj:mpxj
|
Maven |
< 10.14.1
|
10.14.1
|
|
net.sf.mpxj
|
NuGet |
< 10.14.1
|
10.14.1
|
|
net.sf.mpxj-for-csharp
|
NuGet |
< 10.14.1
|
10.14.1
|
|
net.sf.mpxj-for-vb
|
NuGet |
< 10.14.1
|
10.14.1
|
|
mpxj
|
PyPI |
< 10.14.1
|
10.14.1
|
References
Frequently Asked Questions
What is CVE-2022-41954?
Which Mpxj versions are affected?
What version fixes CVE-2022-41954?
Is mpxj affected?
Is net.sf.mpxj affected?
What is the CVSS score of CVE-2022-41954?
What CWE is associated with CVE-2022-41954?
How can I check Maven dependencies for CVE-2022-41954?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-jf2p-4gqj-849g",
"modified" : "2024-09-26T14:24:09Z",
"published" : "2022-11-28T22:09:09Z",
"aliases" : [ "CVE-2022-41954" ],
"summary" : "Temporary File Information Disclosure vulnerability in MPXJ",
"details" : "### Impact\nOn Unix-like operating systems (not Windows or macos), MPXJ's use of `File.createTempFile(..)` results in temporary files being created with the permissions `-rw-r--r--`. This means that any other user on the system can read the contents of this file. When MPXJ is reading a type of schedule file which requires the creation of a temporary file or directory, a knowledgeable local user could locate these transient files while they are in use and would then be able to read the schedule being processed by MPXJ.\n\n### Patches\nThe problem has been patched, MPXJ version 10.14.1 and later includes the necessary changes.\n\n### Workarounds\nSetting `java.io.tmpdir` to a directory to which only the user running the application has access will prevent other users from accessing these temporary files.\n\n### For more information\nIf you have any questions or comments about this advisory\n* Open an issue in https://github.com/joniles/mpxj\n",
"severity" : [ {
"type" : "CVSS_V3",
"score" : "CVSS:3.1/AV:L/AC:L/PR:L/UI:R/S:U/C:L/I:N/A:N"
}, {
"type" : "CVSS_V4",
"score" : "CVSS:4.0/AV:L/AC:L/AT:P/PR:L/UI:N/VC:L/VI:N/VA:N/SC:N/SI:N/SA:N"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "Maven",
"name" : "net.sf.mpxj:mpxj"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "10.14.1"
} ]
} ]
}, {
"package" : {
"ecosystem" : "NuGet",
"name" : "net.sf.mpxj"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "10.14.1"
} ]
} ]
}, {
"package" : {
"ecosystem" : "NuGet",
"name" : "net.sf.mpxj-for-csharp"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "10.14.1"
} ]
} ]
}, {
"package" : {
"ecosystem" : "NuGet",
"name" : "net.sf.mpxj-for-vb"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "10.14.1"
} ]
} ]
}, {
"package" : {
"ecosystem" : "PyPI",
"name" : "mpxj"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "10.14.1"
} ]
} ]
} ],
"references" : [ {
"type" : "WEB",
"url" : "https://github.com/joniles/mpxj/security/advisories/GHSA-jf2p-4gqj-849g"
}, {
"type" : "ADVISORY",
"url" : "https://nvd.nist.gov/vuln/detail/CVE-2022-41954"
}, {
"type" : "WEB",
"url" : "https://github.com/joniles/mpxj/commit/287ad0234213c52b0638565e14bd9cf3ed44cedd"
}, {
"type" : "WEB",
"url" : "https://github.com/joniles/mpxj/commit/ae0af24345d79ad45705265d9927fe55e94a5721"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/joniles/mpxj"
}, {
"type" : "WEB",
"url" : "https://github.com/pypa/advisory-database/tree/main/vulns/mpxj/PYSEC-2022-42996.yaml"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-200", "CWE-668" ],
"severity" : "LOW",
"github_reviewed" : true,
"github_reviewed_at" : "2022-11-28T22:09:09Z",
"nvd_published_at" : "2022-11-25T19:15:00Z"
}
}