Skip to content
OpenAdvisories
Medium · 5.5 Public exploit CVE-2022-4065 EUVD-2022-7421GHSA-rc2q-x9mf-w3vf

cbeust testng XML File Parser JarFileUtils.java testngXmlExistsInJar path traversal

Published Nov 19, 2022 · Updated Aug 3, 2024 · Assigned by VulDB

Description

A vulnerability was found in cbeust testng 7.5.0/7.6.0/7.6.1/7.7.0. It has been declared as critical. Affected by this vulnerability is the function testngXmlExistsInJar of the file testng-core/src/main/java/org/testng/JarFileUtils.java of the component XML File Parser. The manipulation leads to path traversal. The attack can be launched remotely. Upgrading to version 7.5.1 and 7.7.1 is able to address this issue. The patch is named 9150736cd2c123a6a3b60e6193630859f9f0422b. It is recommended to upgrade the affected component. The associated identifier of this vulnerability is VDB-214027.

Affected products

VendorProductAffectedFixed
cbeust testng 7.5.0, 7.6.0, 7.6.1, 7.7.0 —

Fixed in Linux distributions

Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.

ReleasePackageFixed inAdvisory
Ubuntu 26.10 testng No fix yet —
Ubuntu 26.04 LTS testng No fix yet —
Ubuntu 25.10 testng No fix yet —
Ubuntu 24.04 LTS testng No fix yet —
Ubuntu 22.04 LTS testng No fix yet —
Show 4 more (older releases, extended support, other products)
ReleasePackageFixed inAdvisory
Ubuntu 20.04 LTS testng No fix yet —
Ubuntu 18.04 LTS testng No fix yet —
Ubuntu 16.04 LTS testng No fix yet —
Ubuntu 14.04 LTS testng No fix yet —
ReleasePackageFixed inAdvisory
SLES 15 SP6 mockito 5.11.0-150200.3.7.1 SUSE-SU-2024:2568-1
SLES 15 SP6 snakeyaml 2.2-150200.3.15.1 SUSE-SU-2024:2568-1
SLES 15 SP6 testng 7.10.1-150200.3.10.1 SUSE-SU-2024:2568-1
SLES 15 SP5 snakeyaml 2.2-150200.3.15.1 SUSE-SU-2024:2568-1
SLES 15 SP5 testng 7.10.1-150200.3.10.1 SUSE-SU-2024:2568-1
SLES 15 SP4 snakeyaml 2.2-150200.3.15.1 SUSE-SU-2024:2568-1
SLES 15 SP4 testng 7.4.0-150200.3.7.1 SUSE-SU-2024:2568-1, SUSE-SU-2023:1690-1
SLES 15 SP3 snakeyaml 2.2-150200.3.15.1 SUSE-SU-2024:2568-1
SLES 15 SP3 testng 7.4.0-150200.3.7.1 SUSE-SU-2024:2568-1, SUSE-SU-2023:1690-1
SLES 15 SP2 snakeyaml 2.2-150200.3.15.1 SUSE-SU-2024:2568-1
SLES 15 SP2 testng 7.4.0-150200.3.7.1 SUSE-SU-2024:2568-1, SUSE-SU-2023:1690-1
Show 10 more (older releases, extended support, other products)
ReleasePackageFixed inAdvisory
SLES for SAP 15 SP4 snakeyaml 2.2-150200.3.15.1 SUSE-SU-2024:2568-1
SLES for SAP 15 SP4 testng 7.10.1-150200.3.10.1 SUSE-SU-2024:2568-1
SLES for SAP 15 SP3 snakeyaml 2.2-150200.3.15.1 SUSE-SU-2024:2568-1
SLES for SAP 15 SP3 testng 7.4.0-150200.3.7.1 SUSE-SU-2024:2568-1, SUSE-SU-2023:1690-1
SLES for SAP 15 SP2 snakeyaml 2.2-150200.3.15.1 SUSE-SU-2024:2568-1
SLES for SAP 15 SP2 testng 7.4.0-150200.3.7.1 SUSE-SU-2024:2568-1, SUSE-SU-2023:1690-1
SLE Real Time 15 SP3 testng 7.4.0-150200.3.7.1 SUSE-SU-2023:1690-1
SLE HPC 15 SP4 snakeyaml 2.2-150200.3.15.1 SUSE-SU-2024:2568-1
SLE HPC 15 SP4 testng 7.10.1-150200.3.10.1 SUSE-SU-2024:2568-1
SLE HPC 15 SP3 snakeyaml 2.2-150200.3.15.1 SUSE-SU-2024:2568-1
SLE HPC 15 SP3 testng 7.4.0-150200.3.7.1 SUSE-SU-2024:2568-1, SUSE-SU-2023:1690-1
SLE HPC 15 SP2 snakeyaml 2.2-150200.3.15.1 SUSE-SU-2024:2568-1
SLE HPC 15 SP2 testng 7.4.0-150200.3.7.1 SUSE-SU-2024:2568-1, SUSE-SU-2023:1690-1
SUSE Manager Server Module 4.3 snakeyaml 2.2-150200.3.15.1 SUSE-SU-2024:2568-1
SUSE Enterprise Storage 7.1 snakeyaml 2.2-150200.3.15.1 SUSE-SU-2024:2568-1
SUSE Enterprise Storage 7.1 testng 7.4.0-150200.3.7.1 SUSE-SU-2024:2568-1, SUSE-SU-2023:1690-1
SUSE Enterprise Storage 7 testng 7.4.0-150200.3.7.1 SUSE-SU-2023:1690-1
ReleasePackageFixed inAdvisory
openSUSE Leap 15.6 mockito 5.11.0-150200.3.7.1 SUSE-SU-2024:2568-1
openSUSE Leap 15.6 snakeyaml 2.2-150200.3.15.1 SUSE-SU-2024:2568-1
openSUSE Leap 15.6 testng 7.10.1-150200.3.10.1 SUSE-SU-2024:2568-1
openSUSE Leap 15.5 mockito 5.11.0-150200.3.7.1 SUSE-SU-2024:2568-1
openSUSE Leap 15.5 snakeyaml 2.2-150200.3.15.1 SUSE-SU-2024:2568-1
openSUSE Leap 15.5 testng 7.10.1-150200.3.10.1 SUSE-SU-2024:2568-1
openSUSE Leap 15.4 testng 7.4.0-150200.3.7.1 SUSE-SU-2023:1690-1

Public exploits

Exploit or proof-of-concept code for this vulnerability is publicly available, which lowers the bar for attackers. Treat it as a reason to patch sooner.

Third-party code, not reviewed by us. Public PoCs are sometimes fake or contain malware. Read the code first and run it only in an isolated lab, against systems you are authorised to test.

GitHub 1 repository

Sources: PoC-in-GitHub, Metasploit Framework, Exploit-DB — updated daily. Only links are listed; no exploit code is hosted here.

Affected packages

EcosystemPackageAffectedFixedRecord
Maven org.testng:testng >= 6.13, < 7.5.1 7.5.1 GHSA-rc2q-x9mf-w3vf
Maven org.testng:testng >= 7.6.0, < 7.7.0 7.7.0 GHSA-rc2q-x9mf-w3vf

Advisories 2

References