CVE Database›Document archive›CVE-2022-38745

CVE-2022-38745

libreoffice: Empty entry in Java class path

Loading…

Severity

Moderate

Red Hat Product Security

7.8

CVSS 3.1

Review impact separately from score.

Published · March 24, 2023

Updated · June 26, 2026

Description

A flaw was found in LibreOffice. When an empty Java class path entry is configured, LibreOffice will search for Java classes in the current working directory, allowing malicious Java classes to load when opening a document using the file manager, resulting in arbitrary code execution.

Statement

To exploit this flaw, an attacker would need to convince a user to extract an archive (tar, zip, etc) containing a LibreOffice document and a specific file with Java code inside it, and then the user would need to open the LibreOffice document normally. As user interaction is required to open an unstrusted file, this flaw was rated with a moderate security impact.

CVSS score applicability

The CVSS score(s) listed for this vulnerability do not reflect the associated product's status, and are included for informational purposes to better understand the severity of this vulnerability.

Mitigation

Disabling the Java runtime in LibreOffice will mitigate this issue. To disable it, uncheck the "Use a Java runtime environment" option box via: Tools, Options, LibreOffice/Advanced, Use a Java runtime environment.

CVSS / CWE

CVSS 3.1 · 7.8
CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H

CWE-427 · Uncontrolled Search Path Element