CVE-2026-4878

Libcap: libcap: privilege escalation via toctou race condition in cap_set_file()

6.7 medium EPSS 0.15%

Published 9 Apr 2026 Updated 4 Nov 2026 CNA: redhat

Check your servers for CVE-2026-4878

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-2026-4878 affects libcap, 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 libcap. A local unprivileged user can exploit a Time-of-check-to-time-of-use (TOCTOU) race condition in the `cap_set_file()` function. This allows an attacker with write access to a parent directory to redirect file capability updates to an attacker-controlled file. By doing so, capabilities can be injected into or stripped from unintended executables, leading to privilege escalation.

Severity (CVSS)

6.7 medium CVSS 3.1 from redhat (CNA)
CVSS:3.1/AV:L/AC:H/PR:L/UI:R/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
high: an attack depends on conditions outside the control of the attacker, such as a race
Privileges required
low: the attacker needs an ordinary user account
User interaction
required: a user has to do something, such as open a link or a file
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)
6.7 medium CVSS 3.1 from redhat-SADP
CVSS:3.1/AV:L/AC:H/PR:L/UI:R/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
high: an attack depends on conditions outside the control of the attacker, such as a race
Privileges required
low: the attacker needs an ordinary user account
User interaction
required: a user has to do something, such as open a link or a file
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.15%: the probability of exploitation activity in the next 30 days, from the EPSS model of FIRST. The score is higher than 2.17% of all scored CVEs. Scores of 29 Nov 2026.

The assessment of CISA (SSVC, 9 Apr 2026):

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-367 Time-of-check Time-of-use (TOCTOU) Race Condition

Affected products

As the CNA lists them.

ProductVersions
Red Hat Enterprise Linux 10
package libcap
unaffected 0:2.69-7.el10_1.1 and later
Other versions: affected
Red Hat Enterprise Linux 10
package libcap
unaffected 0:2.69-7.el10_2.1 and later
Other versions: affected
Red Hat Enterprise Linux 10.0 Extended Update Support
package libcap
unaffected 0:2.69-7.el10_0.1 and later
Other versions: affected
Red Hat Enterprise Linux 8
package libcap
unaffected 0:2.48-6.el8_10.1 and later
Other versions: affected
Red Hat Enterprise Linux 8.6 Advanced Mission Critical Update Support
package libcap
unaffected 0:2.48-4.el8_6.1 and later
Other versions: affected
Red Hat Enterprise Linux 8.6 Extended Update Support Long-Life Add-On
package libcap
unaffected 0:2.48-4.el8_6.1 and later
Other versions: affected
Red Hat Enterprise Linux 8.8 Telecommunications Update Service
package libcap
unaffected 0:2.48-5.el8_8.1 and later
Other versions: affected
Red Hat Enterprise Linux 8.8 Update Services for SAP Solutions
package libcap
unaffected 0:2.48-5.el8_8.1 and later
Other versions: affected
Red Hat Enterprise Linux 9
package libcap
unaffected 0:2.48-10.el9_7.1 and later
Other versions: affected
Red Hat Enterprise Linux 9
package libcap
unaffected 0:2.48-10.el9_8.1 and later
Other versions: affected
Red Hat Enterprise Linux 9
package libcap
unaffected 0:2.48-10.el9_7.1 and later
Other versions: affected
Red Hat Enterprise Linux 9
package libcap
unaffected 0:2.48-10.el9_8.1 and later
Other versions: affected
Red Hat Enterprise Linux 9.2 Update Services for SAP Solutions
package libcap
unaffected 0:2.48-9.el9_2.1 and later
Other versions: affected
Red Hat Enterprise Linux 9.4 Extended Update Support
package libcap
unaffected 0:2.48-9.el9_4.1 and later
Other versions: affected
Red Hat Enterprise Linux 9.6 Extended Update Support
package libcap
unaffected 0:2.48-9.el9_6.1 and later
Other versions: affected
Red Hat OpenShift Container Platform 4.12
package openshift/ose-rhel-coreos-8
unaffected 412.86.202608241157-0 and later
Other versions: affected
Red Hat OpenShift Container Platform 4.13
package openshift/ose-rhel-coreos-9
unaffected 413.92.202606160406-0 and later
Other versions: affected
Red Hat OpenShift Container Platform 4.14
package openshift/ose-rhel-coreos-9
unaffected 414.92.202606231112-0 and later
Other versions: affected
Red Hat OpenShift Container Platform 4.15
package openshift/ose-rhel-coreos-9
unaffected 415.92.202606030318-0 and later
Other versions: affected
Red Hat OpenShift Container Platform 4.16
package openshift/ose-rhel-coreos-9
unaffected 416.94.202606051757-0 and later
Other versions: affected
Red Hat OpenShift Container Platform 4.17
package openshift/ose-rhel-coreos-9
unaffected 417.94.202606250942-0 and later
Other versions: affected
Red Hat OpenShift Container Platform 4.18
package openshift/ose-rhel-coreos-9
unaffected 418.94.202606051320-0 and later
Other versions: affected
Red Hat OpenShift Container Platform 4.19
package openshift/ose-rhel-coreos-9
unaffected 4.19.9.6.202606031700-0 and later
Other versions: affected
Cert Manager support for Red Hat OpenShift release 1.17
package cert-manager/jetstack-cert-manager-acmesolver-rhel9
unaffected 1791371080 and later
Other versions: affected
Cert Manager support for Red Hat OpenShift release 1.17
package cert-manager/jetstack-cert-manager-rhel9
unaffected 1791371069 and later
Other versions: affected
Cert Manager support for Red Hat OpenShift release 1.17
package cert-manager/cert-manager-operator-rhel9
unaffected 1791788287 and later
Other versions: affected
Cert Manager support for Red Hat OpenShift release 1.17
package cert-manager/cert-manager-operator-bundle
unaffected 1791970484 and later
Other versions: affected
Cert Manager support for Red Hat OpenShift release 1.18
package cert-manager/jetstack-cert-manager-acmesolver-rhel9
unaffected 1791459707 and later
Other versions: affected
Cert Manager support for Red Hat OpenShift release 1.18
package cert-manager/jetstack-cert-manager-rhel9
unaffected 1791459711 and later
Other versions: affected
Cert Manager support for Red Hat OpenShift release 1.18
package cert-manager/cert-manager-istio-csr-rhel9
unaffected 1791459759 and later
Other versions: affected
Cert Manager support for Red Hat OpenShift release 1.18
package cert-manager/cert-manager-operator-rhel9
unaffected 1789029076 and later
Other versions: affected
Cert Manager support for Red Hat OpenShift release 1.18
package cert-manager/cert-manager-operator-bundle
unaffected 1791966259 and later
Other versions: affected
Cert Manager support for Red Hat OpenShift release 1.20
package cert-manager/cert-manager-trust-manager-rhel9
unaffected 1790598593 and later
Other versions: affected
Cost Management 4
package costmanagement/costmanagement-metrics-rhel9-operator
unaffected 1780946239 and later
Other versions: affected
Cost Management 4
package costmanagement/costmanagement-metrics-rhel9-operator
unaffected 1783539156 and later
Other versions: affected
Red Hat AI Inference Server 3.2
package rhaiis/model-opt-cuda-rhel9
unaffected 1780681984 and later
Other versions: affected
Red Hat AI Inference Server 3.3
package rhaiis/model-opt-cuda-rhel9
unaffected 1782352950 and later
Other versions: affected
Red Hat AI Inference Server 3.3
package rhaiis/vllm-spyre-rhel9
unaffected 1782352919 and later
Other versions: affected
Red Hat AI Inference Server 3.3
package rhaiis/vllm-rocm-rhel9
unaffected 1782353093 and later
Other versions: affected
Red Hat AI Inference Server 3.3
package rhaiis/vllm-cuda-rhel9
unaffected 1782352847 and later
Other versions: affected
Red Hat Discovery 2
package discovery/discovery-server-rhel9
unaffected 1778101579 and later
Other versions: affected
Red Hat Discovery 2
package discovery/discovery-ui-rhel9
unaffected 1778156756 and later
Other versions: affected
Red Hat Discovery 2
package discovery/discovery-server-rhel9
unaffected 1782159791 and later
Other versions: affected
Red Hat Discovery 2
package discovery/discovery-ui-rhel9
unaffected 1782166952 and later
Other versions: affected
Red Hat Hardened Images
package libcap-main
unaffected 2.78-1.1.hum1 and later
Other versions: affected
Red Hat Insights proxy 1.5
package insights-proxy/insights-proxy-container-rhel9
unaffected 1780420428 and later
Other versions: affected
Red Hat OpenShift AI 3.4
package rhai/base-image-neuron-rhel9
unaffected 1790703542 and later
Other versions: affected
Red Hat OpenShift distributed tracing 3.9.3
package rhosdt/opentelemetry-collector-rhel9
unaffected 1778056267 and later
Other versions: affected
Red Hat OpenShift distributed tracing 3.9.3
package rhosdt/opentelemetry-rhel9-operator
unaffected 1778056233 and later
Other versions: affected
Red Hat OpenShift distributed tracing 3.9.3
package rhosdt/opentelemetry-target-allocator-rhel9
unaffected 1778056245 and later
Other versions: affected
Red Hat Update Infrastructure 5
package rhui5/cds-rhel9
unaffected 1779798159 and later
Other versions: affected
Red Hat Update Infrastructure 5
package rhui5/haproxy-rhel9
unaffected 1779798164 and later
Other versions: affected
Red Hat Update Infrastructure 5
package rhui5/installer-rhel9
unaffected 1779798165 and later
Other versions: affected
Red Hat Update Infrastructure 5
package rhui5/rhua-rhel9
unaffected 1779798222 and later
Other versions: affected
Red Hat Update Infrastructure 5
package rhui5/cds-kubernetes-tp-rhel9
unaffected 1787241211 and later
Other versions: affected
Red Hat Update Infrastructure 5
package rhui5/installer-tp-rhel9
unaffected 1787135742 and later
Other versions: affected
Red Hat Update Infrastructure 5
package rhui5/rhua-tp-rhel9
unaffected 1787241260 and later
Other versions: affected
Red Hat Enterprise Linux 6
package compat-libcap1
unknown the record does not list versions
Red Hat Enterprise Linux 6
package libcap
unknown the record does not list versions
Red Hat Enterprise Linux 7
package compat-libcap1
unknown the record does not list versions
Red Hat Enterprise Linux 7
package libcap
unknown the record does not list versions
Red Hat OpenShift Container Platform 4
package openshift4/ose-hypershift-rhel9
unknown the record does not list versions

Is my server affected?

Find the installed version of libcap 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 libcap
# packages whose changelog names the CVE (fixed in the installed version)
zgrep -l CVE-2026-4878 /usr/share/doc/*/changelog.Debian.gz
# Ubuntu
pro fix CVE-2026-4878

RHEL, Rocky, Alma, Fedora

rpm -q libcap
# lists the advisory while the fix is not installed
dnf updateinfo list --cve CVE-2026-4878

Alpine

apk list --installed | grep -i libcap

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-2026-4878
trivy image --scanners vuln IMAGE | grep CVE-2026-4878

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

32 more

Other references

Source: the record CVE-2026-4878 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.