USN-9358-1: Apache Log4cxx vulnerabilities
It was discovered that Apache Log4cxx did not properly escape logger names when using HTMLLayout. If an application used untrusted data as a logger name, an attacker could possibly use this issue to perform cross-site scripting attacks when a user viewed the generated HTML log file. (CVE-2025-54812) It was discovered that Apache Log4cxx did not properly escape certain non-printable characters when using JSONLayout. An attacker could possibly use this issue to cause applications that consume the logs to misinterpret the logged information. This issue only affected Ubuntu 22.04 LTS and Ubuntu 24.04 LTS. (CVE-2025-54813)
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Upgrade
Upgrade
ubuntu/liblog4cxx15to a version that resolves this vulnerability.Fixed in Ubuntu Pro - Upgrade
Upgrade
ubuntu/liblog4cxx12to a version that resolves this vulnerability.Fixed in Ubuntu Pro - Upgrade
Upgrade
ubuntu/liblog4cxx10v5to a version that resolves this vulnerability.Fixed in Ubuntu Pro - Upgrade
Upgrade
ubuntu/liblog4cxx10v5to a version that resolves this vulnerability.Fixed in 0.10.0-10ubuntu1+esm1 - Upgrade
Upgrade
ubuntu/liblog4cxx10to a version that resolves this vulnerability.Fixed in Ubuntu Pro
Event History
Frequently Asked Questions
What conditions are required for the HTML log issue to be exploitable?
An application must use HTMLLayout and include untrusted data in a logger name. Exploitation occurs when someone views the generated HTML log file, enabling a possible cross-site scripting attack.
Which systems are affected by the JSON log parsing issue?
The JSONLayout issue affected Ubuntu 22.04 LTS and Ubuntu 24.04 LTS only. It involves non-printable characters that can cause applications consuming JSON logs to misinterpret logged information.
What should teams review while applying this update?
Review applications that use HTMLLayout with logger names derived from untrusted input, and identify generated HTML log files that may be viewed by users. Also review JSONLayout log consumers on Ubuntu 22.04 LTS and 24.04 LTS for reliance on unescaped log content.