Sep 24, 2026·7 min read·25 visits
An oversight in Podman's configuration-overwriting mechanism fails to truncate files on standard filesystems. When an administrator attempts to reduce container privileges or remove volume mounts by installing a shorter configuration file, the old security-critical lines remain at the end of the file and are still parsed, causing the privileges to persist silently.
CVE-2026-19730 is a local security vulnerability in the Podman container engine's Quadlet systemd generator. When updating existing configurations using 'podman quadlet install --replace' on filesystems that do not support reflink operations (such as standard ext4), the file is opened without the O_TRUNC flag. If the new configuration file is shorter than the pre-existing file, the trailing lines of the old file remain intact and are successfully parsed by systemd, leading to a failure to remove security-critical parameters like AddCapability, User, or host storage mounts.
The affected component is Podman's systemd integration tool, Quadlet. Quadlet reads specialized configuration files ending in .container, .volume, or .network and dynamically generates standard systemd service units. This mechanism allows declarative, unit-based container lifecycle management on the host system. The attack surface of this utility is localized to systems where administrator or automated deployment tools manage and update systemd configurations using the podman quadlet install subcommand.
The vulnerability is classified under CWE-459: Incomplete Cleanup. When an administrator modifies an existing container configuration to reduce its capabilities and runs the install command with the --replace (or -r) flag, the application attempts to overwrite the existing file. If the updated configuration is shorter in length than the previous version, and the underlying filesystem does not support copy-on-write 'reflink' copies, the write fails to truncate the pre-existing file payload.
The resulting system state is highly counter-intuitive. Because the trailing lines of the previous configuration are not removed, they remain syntactically valid within systemd's INI-style parser. Consequently, any security reductions, volume removal directives, or user changes are silently ignored as the obsolete directives continue to be parsed and enforced, maintaining the container's previous high-privilege configuration.
The fundamental flaw lies in how the target file descriptor is opened during the file replacement operation in the Go implementation. Within the installQuadlet sequence, Podman attempts to open the destination path with the flags os.O_CREATE | os.O_WRONLY when the replace argument is set to true. Crucially, the flag os.O_TRUNC is completely omitted from this operation, which instructs the kernel to open the file at offset 0 without shrinking the file size to zero.
To write the new payload, Podman calls fileutils.ReflinkOrCopy. On copy-on-write filesystems such as Btrfs or modern XFS configured with reflink capability, the operating system executes an atomic block-sharing clone. However, on non-reflink filesystems such as standard ext4, this system call returns an unsupported error code. The execution path transparently falls back to a user-space buffer copy using Go's io.Copy(dst, src).
The io.Copy function sequentially reads blocks from the source configuration file and writes them into the target file descriptor. Because the destination file descriptor was never truncated to zero, the write sequence terminates once the end of the shorter source file is reached. The leftover bytes at the end of the original file remain physically present on disk. Since systemd and Quadlet parse files line-by-line, these trailing parameters are interpreted as active, overriding or appending to the new configuration.
The vulnerability is located in the Go implementation files pkg/domain/infra/abi/quadlet.go and the storage utility fallback in vendor/go.podman.io/storage/pkg/fileutils/reflink_linux.go. In the vulnerable code, the application failed to ensure truncation when creating or opening the target unit file.
// Vulnerable Implementation
osFlags := os.O_CREATE | os.O_WRONLY
if !replace {
osFlags |= os.O_EXCL
}
// Bug: O_TRUNC is missing when replace is true
file, err := os.OpenFile(finalPath, osFlags, 0o644)
if err != nil {
return "", err
}
defer file.Close()
// Fallback logic inside reflink_linux.go
func ReflinkOrCopy(src, dst *os.File) error {
// ... Attempt Btrfs/XFS reflink ioctl ...
// If ioctl returns ENOTTY or EXDEV, transparent fallback occurs:
_, err := io.Copy(dst, src)
return err
}If the replacement configuration removes an administrative configuration (for example, shrinking the file from 15 lines to 10 lines), only the first 10 lines of the file are overwritten on disk. The remaining 5 lines, which reside after the new EOF offset of the source file, are left completely intact.
// Remediation Implementation (Atomic replacement via temporary file)
var destFile *os.File
var tempPath string
if !replace {
var err error
// Open with O_EXCL to prevent race conditions during fresh installs
destFile, err = os.OpenFile(finalPath, os.O_CREATE|os.O_WRONLY|os.O_EXCL, 0o644)
} else {
var err error
// Create a temporary file in the destination directory
destFile, err = os.CreateTemp(filepath.Dir(finalPath), ".quadlet-install-*")
if err != nil {
return "", err
}
tempPath = destFile.Name()
}By generating a clean temporary file via os.CreateTemp, the patched version ensures that the payload starts with a pristine allocation size of 0 bytes, completely mitigating any risk of residual trailing bytes. Once the write completes, the temporary file is closed, permissions are set to 0o644, and the old configuration is atomically replaced using os.Rename.
To execute this bypass, several target criteria must be met. The administrative system must be configured to use a filesystem lacking reflink copy capability, such as ext4 or standard Red Hat Enterprise Linux default XFS configurations where reflinks were not formatted. Additionally, the administrator must modify an existing, long Quadlet file to be physically shorter by deleting lines from the bottom of the file.
Assume a baseline scenario where a database container is configured with high-privilege access and system mounts. The administrator executes the initial deployment, which installs the configuration under /etc/containers/systemd/db.container. The configuration contains a volume mount linking critical host binaries to the container: Volume=/sbin:/sbin:ro.
To restrict this container's access, the administrator edits the master template to delete the Volume parameter, reducing the configuration size by 25 bytes. The administrator then executes podman quadlet install --replace. The new 100-byte file is written over the 125-byte file. The trailing 25 bytes, containing Volume=/sbin:/sbin:ro, survive intact. Upon systemd reload, the unit is parsed, and the container continues to launch with the host filesystem mount active.
The impact of CVE-2026-19730 is primarily focused on the security posture and privilege boundaries of container workloads. Although rated as Medium severity (CVSS 4.2), the silent nature of the failure means security configurations and compliance requirements are bypassed without raising errors or logs.
In multi-tenant or highly secured container hosts, developers use Quadlet configuration directives to enforce boundaries. The inability to cleanly remove administrative privileges (such as AddCapability=CAP_SYS_ADMIN), custom network routes, or host file system paths means containers remain in an over-privileged state indefinitely. A low-privileged local attacker or compromised container application can abuse these lingering configurations to escalate privileges to the host.
No active exploitation or automated malware campaigns target this vulnerability in the wild, which aligns with its low EPSS score. The exploit mechanism is fundamentally a localized logical race or persistence issue, which means threat actors cannot trigger it remotely unless they have a mechanism to manipulate local Quadlet files or induce administrators into running replacement routines.
To fully resolve CVE-2026-19730, administrators must update Podman on their host systems to the patched versions. The official fix is included in upstream versions 5.8.6 and 6.0.0 or later. Red Hat has released security updates backporting the fix to RHEL 9 and RHEL 10 platforms.
If patching cannot be executed immediately, administrators must avoid using the --replace or -r options directly on active installations. Instead, a manual delete-then-install workflow should be implemented. This ensures that the destination file descriptor is entirely removed, forcing Podman to open a brand-new file with a clean size of 0 bytes:
# Mitigation: Manual clean before installation
TARGET_PATH="/etc/containers/systemd/vulnerable.container"
if [ -f "$TARGET_PATH" ]; then
rm -f "$TARGET_PATH"
fi
podman quadlet install /source/vulnerable.containerSecurity teams can audit their existing directories using automated scripts to verify that systemd service configurations do not contain duplicated directives or unexpected parameters matching the tail of previous versions. Filesystems supporting reflink, such as Btrfs or modern XFS, are not vulnerable to this bug class and can be utilized as a structural mitigation.
CVSS:3.1/AV:L/AC:H/PR:L/UI:R/S:U/C:L/I:L/A:L| Product | Affected Versions | Fixed Version |
|---|---|---|
Podman Red Hat | < 5.8.6 | 5.8.6 |
Podman Red Hat | >= 5.9.0, < 6.0.0 | 6.0.0 |
| Attribute | Detail |
|---|---|
| CWE ID | CWE-459 (Incomplete Cleanup) |
| Attack Vector | Local (AV:L) |
| CVSS v3.1 Score | 4.2 (Medium) |
| EPSS Score | 0.00163 (Percentile: 4.85%) |
| Impact Type | Security Bypass / Privilege Persistence |
| Exploit Status | Proof-of-Concept Available |
| CISA KEV Status | Not Listed |
The software does not clean up all of its temporary or older resources, leaving obsolete configuration records that are subsequently executed or parsed as valid options.
CVE-2026-9639 (GHSA-j93m-3j9p-m5m8) is a null pointer dereference vulnerability in Canonical LXD affecting versions 5.0.0 through 5.21.4 and 6.0 through 6.8. The flaw resides in the (*lxdBackend).CreateCustomVolumeFromBackup method within lxd/storage/backend_lxd.go. An authenticated attacker with the can_create_storage_volumes permission can upload a crafted custom volume backup tarball that omits the expires_at field on a snapshot entry, triggering an unhandled SIGSEGV panic and terminating the LXD daemon.
An operating system command injection vulnerability (CWE-78) exists in GeoNode versions prior to 5.1.0. The vulnerability occurs in the vector upload processing pipeline when handling user-supplied geospatial files. By supplying a crafted layer name containing shell metacharacters, an authenticated attacker with basic data upload privileges can execute arbitrary commands on the underlying server or container hosting the GeoNode application and Celery worker processes.
GeoNode versions prior to 5.0.3 contain an unrestricted file upload vulnerability (CWE-434) within the document and dataset ingestion architecture. Authenticated low-privileged users can bypass upload validation via direct REST API interactions, file extension masquerading, metadata mutation via PATCH requests, or malicious archive submissions. This allows attackers to store and serve dangerous file types, alter on-disk file references, or trigger path traversal and resource exhaustion during archive extraction.
CVE-2026-55649 is a stored Cross-Site Scripting (XSS) vulnerability in GeoNode versions prior to 5.0.3. The flaw exists because document abstract metadata fields are ingested via the metadata management pipeline and stored in the backend database without HTML sanitization or input neutralization. An authenticated attacker with privileges to create or edit document metadata can inject arbitrary HTML and JavaScript payloads into these fields. When another user, such as an administrator, views the affected document page or catalog listing, the unencoded payload is rendered into the Document Object Model (DOM) and executes within the victim's browser session.
CVE-2026-55622 (GHSA-qx75-2p3r-pwm5) is an improper access control vulnerability (CWE-284) in Canonical LXD and LXC Incus (tracked as GHSA-c9f5-j9c3-mhrg). In multi-tenant deployments utilizing project-based isolation, the REST API handler for instance creation via POST /1.0/instances verifies that the authenticated user has authorization in the destination project specified by the query parameter, but fails to verify whether the user holds read or view permissions for the source instance when executing a copy operation across projects. Consequently, an authenticated client restricted to a single project can clone instances or snapshots from unauthorized projects into their own project, resulting in complete disclosure of the target instance filesystem and embedded credentials.
An authorization bypass vulnerability in Canonical LXD (tracked as GHSA-7mr3-28h5-m5vx and CVE-2026-55621, and as GHSA-64f3-v33m-w89f in Linux Containers Incus) allows an authenticated user with restricted project access to copy custom storage volumes and volume snapshots from unauthorized projects. The flaw resides in the storagePoolVolumesPost REST API handler, which verifies permissions on the destination project but fails to check whether the caller holds view entitlements on the source project or volume specified in the request body.