CVE-2024-9050

Networkmanager-libreswan: local privilege escalation via leftupdown

7.8 high EPSS 0.57%

Published 22 Oct 2024 Updated 23 Nov 2026 CNA: redhat

Check your servers for CVE-2024-9050

The Vulnpocalypse collector sends the package list of each Linux server and of its container images once a day. Vulnpocalypse shows every server where CVE-2024-9050 affects networkmanager-libreswan, with the command that installs the fix. The free plan covers one server and one domain and does not need a credit card.

Check my servers

Description

A flaw was found in the libreswan client plugin for NetworkManager (NetkworkManager-libreswan), where it fails to properly sanitize the VPN configuration from the local unprivileged user. In this configuration, composed by a key-value format, the plugin fails to escape special characters, leading the application to interpret values as keys. One of the most critical parameters that could be abused by a malicious user is the `leftupdown`key. This key takes an executable command as a value and is used to specify what executes as a callback in NetworkManager-libreswan to retrieve configuration settings back to NetworkManager. As NetworkManager uses Polkit to allow an unprivileged user to control the system's network configuration, a malicious actor could achieve local privilege escalation and potential code execution as root in the targeted machine by creating a malicious configuration.

Severity (CVSS)

7.8 high CVSS 3.1 from redhat (CNA)
CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
Attack vector
local: the attacker needs local access, or a user has to open a prepared file
Attack complexity
low: an attack works without special conditions
Privileges required
low: the attacker needs an ordinary user account
User interaction
none: nobody has to click or open anything
Scope
unchanged: the damage stays inside the vulnerable component
Impact
confidentiality high, integrity high, availability high: what an attacker can read (confidentiality), change (integrity) or stop (availability)

Exploitation

EPSS 0.57%: the probability of exploitation activity in the next 30 days, from the EPSS model of FIRST. The score is higher than 41.2% of all scored CVEs. Scores of 29 Nov 2026.

The assessment of CISA (SSVC, 22 Oct 2024):

Exploitation
none: CISA did not find evidence of exploitation or a public proof of concept
Automatable
no: each attack takes manual steps
Technical impact
total: full control of the component or of its data

Weakness

  • CWE-94 Improper Control of Generation of Code

Affected products

As the CNA lists them.

ProductVersions
NetworkManager-libreswan
package NetworkManager-libreswan
affected before 1.2.24
Other versions: unaffected
Red Hat Enterprise Linux 7.7 Advanced Update Support
package NetworkManager-libreswan
unaffected 0:1.2.4-4.el7_7 and later
Other versions: affected
Red Hat Enterprise Linux 7 Extended Lifecycle Support
package NetworkManager-libreswan
unaffected 0:1.2.4-4.el7_9 and later
Other versions: affected
Red Hat Enterprise Linux 8
package NetworkManager-libreswan
unaffected 0:1.2.10-7.el8_10 and later
Other versions: affected
Red Hat Enterprise Linux 8.2 Advanced Update Support
package NetworkManager-libreswan
unaffected 0:1.2.10-6.el8_2 and later
Other versions: affected
Red Hat Enterprise Linux 8.4 Advanced Mission Critical Update Support
package NetworkManager-libreswan
unaffected 0:1.2.10-6.el8_4 and later
Other versions: affected
Red Hat Enterprise Linux 8.4 Telecommunications Update Service
package NetworkManager-libreswan
unaffected 0:1.2.10-6.el8_4 and later
Other versions: affected
Red Hat Enterprise Linux 8.4 Update Services for SAP Solutions
package NetworkManager-libreswan
unaffected 0:1.2.10-6.el8_4 and later
Other versions: affected
Red Hat Enterprise Linux 8.6 Advanced Mission Critical Update Support
package NetworkManager-libreswan
unaffected 0:1.2.10-6.el8_6 and later
Other versions: affected
Red Hat Enterprise Linux 8.6 Telecommunications Update Service
package NetworkManager-libreswan
unaffected 0:1.2.10-6.el8_6 and later
Other versions: affected
Red Hat Enterprise Linux 8.6 Update Services for SAP Solutions
package NetworkManager-libreswan
unaffected 0:1.2.10-6.el8_6 and later
Other versions: affected
Red Hat Enterprise Linux 8.8 Extended Update Support
package NetworkManager-libreswan
unaffected 0:1.2.10-6.el8_8 and later
Other versions: affected
Red Hat Enterprise Linux 9
package NetworkManager-libreswan
unaffected 0:1.2.22-4.el9_5 and later
Other versions: affected
Red Hat Enterprise Linux 9.0 Update Services for SAP Solutions
package NetworkManager-libreswan
unaffected 0:1.2.14-3.el9_0 and later
Other versions: affected
Red Hat Enterprise Linux 9.2 Extended Update Support
package NetworkManager-libreswan
unaffected 0:1.2.14-6.el9_2 and later
Other versions: affected
Red Hat Enterprise Linux 9.4 Extended Update Support
package NetworkManager-libreswan
unaffected 0:1.2.18-6.el9_4 and later
Other versions: affected
Red Hat Enterprise Linux 10
package NetworkManager-libreswan
affected the record does not list versions

Is my server affected?

Find the installed version of networkmanager-libreswan and compare it with the fixed version of your distribution. Distributions often fix a CVE in a package version of their own, so the version number of the upstream project can mislead.

Debian, Ubuntu

dpkg -l | grep -i networkmanager-libreswan
# packages whose changelog names the CVE (fixed in the installed version)
zgrep -l CVE-2024-9050 /usr/share/doc/*/changelog.Debian.gz
# Ubuntu
pro fix CVE-2024-9050

RHEL, Rocky, Alma, Fedora

rpm -q networkmanager-libreswan
# lists the advisory while the fix is not installed
dnf updateinfo list --cve CVE-2024-9050

Alpine

apk list --installed | grep -i networkmanager-libreswan

With Trivy, on the host and for a container image. When a package is affected, it prints the installed and the fixed version:

trivy rootfs --scanners vuln / | grep CVE-2024-9050
trivy image --scanners vuln IMAGE | grep CVE-2024-9050

Vulnpocalypse makes this comparison every day for the package lists of your servers and container images, including language packages (npm, PyPI, Go, Maven and others), and sends the command that installs the fix. Start free with one server and one domain or read how to install the collector.

References

Advisories

Other references

Source: the record CVE-2024-9050 of the CVE List (CVE Program), CVE Terms of Use; the CISA KEV catalog and the CISA ADP container; EPSS of FIRST; the CWE catalog of MITRE, CWE Terms of Use. The text of the record is shown as published. Data sources and licences.