# CVE-2025-62796: PrivateBin persistent HTML injection in attachment filename enables redirect and defacement

> Archived entry. Full-text search covers entries since 2026-11-10; exact IDs work for all years.

- **Severity:** MEDIUM 5.8
- **CVSS:** 5.8 (v3.1, CNA) `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:N/I:L/A:N`
- **CVSS metrics:** Attack vector: Network; Attack complexity: Low; Privileges required: None; User interaction: None; Scope: Changed (impact reaches other components); Confidentiality impact: None; Integrity impact: Low; Availability impact: None
- **Exploited in the wild:** Not in CISA KEV
- **Public exploit / PoC:** None known
- **Remote exploitation:** Remote, no login needed
- **EPSS:** 0.37% (percentile 23, 2026-11-26)
- **CWE:** CWE-79, CWE-80
- **Aliases:** GHSA-867c-p784-5q6g
- **Published:** 2025-10-28T20:14:09.000Z
- **Modified:** 2026-10-19T13:10:00.110Z

## Who should check

- Projects that depend on Packagist package privatebin/privatebin (\>= 1.7.7, \< 2.0.2)
- Anyone running PrivateBin \>= 1.7.7, \< 2.0.2

## Description

PrivateBin is an online pastebin where the server has zero knowledge of pasted data. Versions 1.7.7 through 2.0.1 allow persistent HTML injection via the unsanitized attachment filename (attachment\_name) when attachments are enabled. An attacker can modify attachment\_name before encryption so that, after decryption, arbitrary HTML is inserted unescaped into the page near the file size hint, enabling redirect (e.g., meta refresh) and site defacement and related phishing attacks. Script execution is normally blocked by the recommended Content Security Policy, limiting confidentiality impact. The issue was introduced in 1.7.7 and fixed in 2.0.2. Update to 2.0.2 or later. Workarounds include enforcing the recommended CSP, deploying PrivateBin on a separate domain, or disabling attachments.

## Affected and fixed versions

- Packagist `privatebin/privatebin`: affected \>= 1.7.7, \< 2.0.2; fixed 2.0.2 (osv)
- PrivateBin: \>= 1.7.7, \< 2.0.2 (cvelist)

## Mitigation

- Upgrade privatebin/privatebin to 2.0.2 or later.

## Check your systems with an agent

Paste this into a coding agent:

```text
Check whether anything I run is affected by CVE-2025-62796. Work read-only: do not install, upgrade, delete or change anything.

Details: https://flawdb.com/CVE-2025-62796.md
Affected: privatebin/privatebin >= 1.7.7, < 2.0.2
Fixed in: 2.0.2

Steps:
1. Search this machine and project for privatebin/privatebin (Packagist), PrivateBin: dependency manifests and lockfiles, installed packages, container images and running services.
2. For each match, note the installed version and whether it is inside the affected range.
3. Report a table: location, installed version, affected (yes / no / unsure), evidence. If affected, say which fixed version or mitigation from the details link applies, but don't apply it.
```

## FAQ

### Is CVE-2025-62796 being exploited?

There is no confirmed exploitation: CVE-2025-62796 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known. EPSS estimates a 0.37% chance of exploitation in the next 30 days (as of 2026-11-26).

### How serious is CVE-2025-62796?

Medium: CVSS 5.8 (v3.1, scored by CNA). Remote, no login needed.

### Which versions are affected by CVE-2025-62796?

privatebin/privatebin \>= 1.7.7, \< 2.0.2.

### Is there a fix for CVE-2025-62796?

Yes. Fixed in 2.0.2. Upgrade privatebin/privatebin to 2.0.2 or later.

### How do I check if I'm affected by CVE-2025-62796?

Find where you use the affected software (dependency lockfiles, installed packages, container images, servers) and compare the installed version with the affected range above. The agent prompt on this page does this read-only.

## References

- vendor: <https://github.com/PrivateBin/PrivateBin/security/advisories/GHSA-867c-p784-5q6g>
- vendor: <https://nvd.nist.gov/vuln/detail/CVE-2025-62796>
- patch: <https://github.com/PrivateBin/PrivateBin/pull/1550>
- patch: <https://github.com/PrivateBin/PrivateBin/commit/c4f8482b3072be7ae012cace1b3f5658dcc3b42e>
- other: <https://github.com/PrivateBin/PrivateBin>

## Attribution

- CVE Program: CVE® is a registered trademark of The MITRE Corporation. CVE records © 1999–2026 The MITRE Corporation. <https://www.cve.org/Legal/TermsOfUse>
- NVD: This product uses data from the NVD API but is not endorsed or certified by the NVD. <https://nvd.nist.gov/vuln/detail/CVE-2025-62796>
- OSV: CC-BY 4.0 <https://osv.dev/vulnerability/GHSA-867c-p784-5q6g> (license: <https://creativecommons.org/licenses/by/4.0/>)

HTML: <https://flawdb.com/CVE-2025-62796> · JSON: <https://flawdb.com/api/v1/entries/CVE-2025-62796>
