Skip to main content

PrivateBin CVE-2025-62796

MEDIUM
Cross-site Scripting (XSS) (CWE-79)
2025-10-28 security-advisories@github.com
5.8
CVSS 3.1 · Vendor: github
View

Attack ChainAIDerived

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

  1. Access
    Craft paste with malicious HTML in attachment_name
  2. Delivery
    Share paste link with target victim
  3. Exploit
    Victim opens paste, client decrypts filename
  4. Execution
    Unescaped HTML rendered near file-size hint
  5. Impact
    Redirect to phishing clone or deface page

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V1 - Encoding and Sanitization Output encoding, context-aware escaping
MITRE ATT&CK

2 techniques across 2 tactics: Initial Access, Execution

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

Exploitation Conditions

Exploitation requires that attachments are ENABLED on the target PrivateBin instance (a non-default-dependent feature) and that the attacker can create a paste and modify the attachment_name field before client-side encryption, which is possible for any user able to submit pastes. The decisive limiting factor is the Content Security Policy: with PrivateBin's recommended CSP, inline script execution is blocked, so impact is confined to HTML injection (meta-refresh redirect, defacement, phishing) and paste confidentiality is NOT affected; on instances with a weaker/missing CSP or a browser lacking protections, this can escalate to full XSS with confidentiality impact. Exploitation also depends on a victim opening the attacker-shared paste link (user interaction), and affected versions are 1.7.7 through 2.0.1.

Impact

This is a medium-severity persistent HTML injection (NVD CWE-79; the GHSA advisory frames it primarily as CWE-80) rated CVSS 5.8 with vector AV:N/AC:L/PR:N/UI:N/S:C/C:N/I:L/A:N. The signals are largely consistent in pointing to a limited-impact defacement/redirect issue rather than a critical breach: confidentiality is explicitly N because the recommended Content Security Policy blocks inline script execution, and impact is capped at Integrity:Low (I:L) covering defacement, meta-refresh redirect, and phishing. No EPSS score and no CISA KEV entry were provided, so there is no evidence of active or widespread exploitation; however a working proof-of-concept is documented in the GHSA advisory, so publicly available exploit code exists. A key conflict to verify: the CVSS vector claims UI:N (no user interaction), but the description makes clear a victim must open an attacker-shared paste for the injected HTML to render - this is effectively UI:R, which means real-world exploitation is more constrained than the raw vector suggests. The S:C (scope change) reflects that injected content can affect the surrounding page and potentially other services on the same domain. Critically, the advisory warns that on instances with a weak or missing CSP the impact escalates to full XSS and paste-confidentiality compromise, so real risk is deployment-dependent: default/recommended-CSP installs face a genuine but bounded phishing/defacement risk, while misconfigured installs face a materially higher threat.

Exploit ScenarioDerived

An attacker creates a paste with an attachment and tampers with the attachment_name field before client-side encryption so it contains malicious HTML (e.g. a meta-refresh tag), then shares the paste URL with a target. When the victim opens the link, the filename is decrypted and rendered unescaped next to the file-size hint, redirecting the victim to an attacker-controlled phishing clone or defacing the page. A proof-of-concept is documented in the GHSA-867c-p784-5q6g advisory.

This Month Plan within 30 days. Why: MEDIUM severity (CVSS 4.0-6.9).
Patch available 0.3% exploitation probability (EPSS)

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

Alert me

AnalysisAIv1 – Oct 19, 2026

Persistent HTML injection in PrivateBin 1.7.7 through 2.0.1 lets any paste author place arbitrary HTML in an attachment filename, which is rendered unescaped near the file-size hint when a victim opens the paste, enabling meta-refresh redirects, defacement, and phishing. Exploitation requires attachments to be enabled and victim interaction, and PrivateBin's recommended CSP normally blocks inline script execution, so paste confidentiality is not affected unless the deployment uses a weaker or missing CSP. The issue is fixed in 2.0.2; no CISA KEV entry is present, but the GHSA advisory includes proof-of-concept reproduction details, so publicly available exploit code exists.

RemediationAI

Upgrade PrivateBin to 2.0.2 or later; the vendor advisory and fix commit c4f8482b3072be7ae012cace1b3f5658dcc3b42e are at https://github.com/PrivateBin/PrivateBin/security/advisories/GHSA-867c-p784-5q6g and https://github.com/PrivateBin/PrivateBin/commit/c4f8482b3072be7ae012cace1b3f5658dcc3b42e. If immediate upgrade is not possible, enforce PrivateBin's recommended Content Security Policy (verify delivery via https://privatebin.info/directory/check), which blocks inline script execution and limits the issue to HTML injection such as meta-refresh redirects and defacement; deploying PrivateBin on a separate domain reduces cross-service impact; disabling attachments removes the attack vector but changes product functionality. Note that CSP does not prevent all HTML injection effects, so upgrade remains the primary fix.

Affected Packages

composer privatebin/privatebin fix: 2.0.2

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in composer

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

Technical ContextAI · show details

PrivateBin is a zero-knowledge pastebin: paste content and metadata are encrypted client-side before upload, so the server cannot sanitize the encrypted attachment_name field. The attachment_name is included in the encrypted object and, in affected versions, is concatenated into an HTML template string and appended via jQuery when rendering the attachment size hint; because the filename is treated as markup rather than text, an attacker who modifies attachment_name before encryption can inject HTML (CWE-79; the GHSA frames it as CWE-80) into the decrypting victim's page. The fix in commit c4f8482b3072be7ae012cace1b3f5658dcc3b42e replaces jQuery DOM construction with document.createTextNode/createElement, so the filename is inserted as text; the same commit updates the SRI hash for js/privatebin.js and is tracked via PR #1550. Assessed CVSS is 5.8 with AV:N/AC:L/PR:N/UI:R/S:C/C:N/I:L/A:N; impact is limited to HTML injection when the recommended CSP is enforced, but can escalate to script execution on deployments with weaker CSP or browsers lacking protections.

Know when the next one hits your stack

  • 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 (github) PRIMARY 5.8 MEDIUM
AV:N/AC:L/PR:N/UI:N/S:C/C:N/I:L/A:N
vuln.today AI 4.7 MEDIUM

Remotely reachable with no privileges (anonymous pasting), but a victim must open the crafted paste so UI:R; S:C as injected HTML affects the page/domain context; CSP blocks script so C:N, only I:L.

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

Primary rating from Vendor (github).

CVSS VectorVendor: github

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

DescriptionCVE.org

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.

Threat Intelligence Overview

EPSS Score
0.3%
Top 79% exploitable
Prevalence
Low
niche self-hosted privacy pastebin, limited production deployment footprint
Data Quality
3 sources
Confidence: Low

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 MEDIUM
CISA KEV No
Public POC No
EPSS 0.3%
Patch available Yes
Active threat No
Deciding rule
MEDIUM severity (CVSS 4.0-6.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· derived
Scheduled
Exploitation· derived
None
System Exposure· derived
Open
Automatable· derived
Yes
Human Impact· derived
Medium

Priority Score

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

Attack Technique

Cross-Site Scripting occurs when an application accepts untrusted data and sends it to a web browser without proper validation or encoding.

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