Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessLure client to malicious/compromised SCP server
-
DeliveryClient initiates scp.py download (get)
-
ExploitServer sends crafted filename with ../ traversal
-
ExecutionReceive handler writes outside target dir
-
ImpactOverwrite sensitive local file
Vulnerability Assessment
| Weakness |
CWE
OWASP Top 10:2025
A01:2025 - Broken Access Control
ASVS 5.0
V5 - File Handling Path canonicalization, traversal prevention
MITRE ATT&CK
2 techniques across 2 tactics: Discovery, 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 use scp.py as a CLIENT to RECEIVE files (SCPClient.get, most impactfully a recursive get) from a server the attacker controls or has compromised; the malicious server then emits SCP protocol C/D (file/pushd) control messages whose names embed '../' traversal sequences that the _recv_file/_recv_pushd handlers write relative to the local directory without canonicalizing against the intended base (fixed via os.path.realpath + os.path.commonpath containment). LIMITING FACTORS: the attacker must already control the remote SCP endpoint and the victim must initiate a download (passive user interaction, UI:P) - it cannot be triggered against a passive/listening victim and is not exploitable on upload-only workflows; impact is limited to arbitrary file WRITE/overwrite on the client (integrity/availability), with no confidentiality disclosure. |
| Impact | This is a moderate, defense-in-depth-class issue rather than a high-priority emergency. The CVSS 4.0 base score is 5.3 (Medium) with vector AV:N/AC:L/PR:N/UI:P and only low integrity/availability impact (VI:L/VA:L, VC:N) - meaning no data disclosure and a bounded write-primitive, not code execution. The 'E:X' exploit-maturity value is 'Not Defined,' i.e. no exploitation signal was supplied. There is no CISA KEV listing, no EPSS score in the input, and no public POC referenced, so all exploitation-probability signals are absent or neutral; per the precision rules this is 'no public exploit identified at time of analysis.' Critically, AV:N is somewhat misleading in isolation: this is a client-side library flaw where a MALICIOUS OR COMPROMISED SCP SERVER abuses a client performing a download (the UI:P passive-interaction metric captures this). It is not a remotely reachable server-side vulnerability an attacker can scan for and mass-exploit. Net: a real but low-urgency bug - patch during normal maintenance; it is not a drop-everything scenario. |
| Exploit ScenarioDerived | A user runs a Python application that uses scp.py to download files (scp.get, especially recursive) from a server the attacker controls or has compromised. The malicious server responds with crafted SCP protocol file/directory-change (D/C) messages containing '../' sequences, and because the receive handler did not canonicalize or bound the target path, files are written outside the intended local download directory - for example overwriting a user config, SSH key, or startup script. No public exploit code is identified at time of analysis. |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – Oct 13, 2026
Path traversal in jbardin scp.py through 0.16.1 lets a malicious or compromised SCP server write or overwrite files outside the client's intended download directory when a client-side receive operation processes crafted SCP protocol file entries. This affects applications that use scp.py as a client to pull files, most impactfully during recursive gets, and requires the victim to initiate the download from an attacker-controlled endpoint (unauthenticated from the client's perspective, but dependent on passive user interaction). Impact is confined to integrity and availability of local files on the client through arbitrary write/overwrite, with no confidentiality disclosure; there is no confirmed active exploitation (CISA KEV) and no public exploit code identified at time of analysis, and the issue is best characterized as a moderate defense-in-depth-class weakness rather than an emergency. The vendor released a fixed version, 0.16.2.
RemediationAI
Vendor-released patch: upgrade to scp.py 0.16.2, published at https://github.com/jbardin/scp.py/releases/tag/v0.16.2 and containing commit 42fc3aaa71411daed60544e3b40179c1038bed5d, which switches the receive base to os.path.realpath and enforces os.path.commonpath containment before writing; this is the only supported fix and upgrading is advised. Where immediate upgrade is not possible, apply compensating controls: (1) do not use scp.py client receives, especially recursive gets, against SCP servers you do not fully control - the traversal is only reachable when the remote peer is attacker-controlled or compromised, and switching to a maintained SFTP/rsync implementation removes the exposure at the cost of reworking transfer automation; (2) if untrusted-source downloads are unavoidable, run the client in a sandbox, container, or unprivileged account whose writable filesystem is confined to the download directory, which bounds the blast radius to file writes within that sandbox at the cost of added operational complexity; (3) perform post-download validation that no files were created outside the intended destination (for example, checking realpaths and symlink status of every received entry) and monitor for unexpected overwrites of application binaries, cron entries, or configuration files, accepting that detection is after-the-fact rather than preventive; and (4) avoid running the transfer process with elevated privileges. Review the advisory at https://vuldb.com/vuln/416886/cti for the vendor's coordinated-disclosure timeline. Note that the fix relies on os.path.realpath/commonpath and thus on Python builds that expose those routines.
Affected VersionsENISA
Affected Packages
Source: OSV (Open Source Vulnerabilities)
Affects your stack
Affects 1 package in euvd
Checking this CVE against your own stacks and servers is part of the Basic plan and up.
Technical ContextAI · show details
scp.py is a Python implementation of a Secure Copy Protocol client/server library, and the flaw resides in its SCP Receive Handler, specifically the _recv_file and _recv_pushd functions. The SCP wire protocol conveys directory and file operations through 'C' (file) and 'D' (directory/pushd) control messages whose payloads carry the destination path; the vulnerable code accepted those server-supplied names and concatenated them onto the local download directory without resolving symlinks or verifying that the resulting path stayed inside the intended base directory. Because the traversal is driven entirely by server-controlled message content, a hostile or compromised SCP endpoint can embed '../' sequences (or rely on symlinked components) to escape the target directory and cause writes to arbitrary locations writable by the client process - a classic CWE-22 Improper Limitation of a Pathname to a Restricted Directory. The upstream fix (commit 42fc3aaa71411daed60544e3b40179c1038bed5d) canonicalizes the receive directory with os.path.realpath at initialization and at each _recv_pushd, and adds os.path.commonpath containment assertions before _recv_file writes, ensuring resolved destination paths remain under the real base directory. The CPE string cpe:2.3:a:jbardin:scp.py:*:*:*:*:*:*:*:* confirms jbardin's scp.py is the affected product component; no other products are implicated.
Know when Scp Py 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
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:N/VI:L/VA:L/SC:N/SI:N/SA:N
Attacker-controlled server reached over network (AV:N) but victim must start a download, so UI:R; no auth to the malicious server (PR:N); write-only primitive gives I:L/A:L and C:N.
Primary rating from Vendor (VulDB).
CVSS VectorVendor: VulDB
DescriptionCVE.org
A security vulnerability has been detected in jbardin scp.py up to 0.16.1. The impacted element is the function _recv_file/_recv_pushd of the component SCP Receive Handler. The manipulation leads to path traversal. Remote exploitation of the attack is possible. Upgrading to version 0.16.2 is sufficient to resolve this issue. The identifier of the patch is 42fc3aaa71411daed60544e3b40179c1038bed5d. Upgrading the affected component is advised. The vendor was contacted early, responded in a very professional manner and quickly released a fixed version of the affected product.
Threat Intelligence Overview
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.
What every action level means
SSVC AssessmentENISA
Priority Score
Attack Technique
Path traversal exploits occur when applications use user-controlled input to construct file system paths without proper validation.
EUVD-2026-98412
GHSA-3f22-449q-g7c5
NVD
CVE.org
EPSS
Vulnrichment
VulDB
Exploit-DB