CVE-2019-9854: Unsafe URL assembly flaw in allowed script location check
Last updated 25 August 2025
Other sources
LibreOffice has a feature where documents can specify that pre-installed macros can be executed on various script events such as mouse-over, document-open etc. Access is intended to be restricted to scripts under the share/Scripts/python, user/Scripts/python sub-directories of the LibreOffice install. Protection was added, to address CVE-2019-9852, to avoid a directory traversal attack where scripts in arbitrary locations on the file system could be executed by employing a URL encoding attack to defeat the path verification step. However this protection could be bypassed by taking advantage of a flaw in how LibreOffice assembled the final script URL location directly from components of the passed in path as opposed to solely from the sanitized output of the path verification step. This issue affects: Document Foundation LibreOffice 6.2 versions prior to 6.2.7; 6.3 versions prior to 6.3.1.
— Launchpad
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Upgrade
Upgrade
redhat/libreofficeto a version that resolves this vulnerability.Fixed in 6.2.7 - Upgrade
Upgrade
redhat/libreofficeto a version that resolves this vulnerability.Fixed in 6.3.1 - Upgrade
Upgrade
debian/libreofficeto a version that resolves this vulnerability.Fixed in 1:7.0.4-4+deb11u10Fixed in 1:7.0.4-4+deb11u13Fixed in 4:7.4.7-1+deb12u10Fixed in 4:7.4.7-1+deb12u8Fixed in 4:25.2.3-2+deb13u3Fixed in 4:26.2.0-1 - Upgrade
Upgrade
alpine/libreofficeto a version that resolves this vulnerability.Fixed in 6.2.7.1-r0 - Upgrade
Upgrade
alpine/libreofficeto a version that resolves this vulnerability.Fixed in 6.3.1.2-r0 - Upgrade
Upgrade
LibreOffice 6.2to a version that resolves this vulnerability.Fixed in 6.2.7 - Upgrade
Upgrade
LibreOffice 6.3to a version that resolves this vulnerability.Fixed in 6.3.1
Event History
Frequently Asked Questions
What is CVE-2019-9854?
CVE-2019-9854 is a vulnerability in LibreOffice that allows documents to execute pre-installed macros.
How severe is CVE-2019-9854?
CVE-2019-9854 has a severity score of 7.8, which is considered high.
Which versions of LibreOffice are affected by CVE-2019-9854?
CVE-2019-9854 affects LibreOffice versions 6.0.7-0ubuntu0.18.04.10, 6.2.7-0ubuntu0.19.04.1, and 5.1.6~.
How can I fix CVE-2019-9854?
To fix CVE-2019-9854, update LibreOffice to version 6.1.5-3+deb10u7, 6.1.5-3+deb10u10, 7.0.4-4+deb11u7, 4:7.4.7-1, or 4:7.5.8~rc1-2.
Where can I find more information about CVE-2019-9854?
You can find more information about CVE-2019-9854 at the following references: http://lists.opensuse.org/opensuse-security-announce/2019-09/msg00067.html, http://lists.opensuse.org/opensuse-security-announce/2019-10/msg00055.html, https://bugzilla.redhat.com/show_bug.cgi?id=1769907.