Description
Readest is an open-source e-book reader built on Tauri. In versions prior to 0.11.16, EPUB chapter HTML is sanitized with DOMPurify using a configuration that forbade only the <script> tag (FORBID_TAGS: ['script']) in apps/readest-app/src/services/transformers/sanitizer.ts. DOMPurify does not parse the contents of the srcdoc attribute on <iframe> elements, treating it as an opaque string attribute, so an attacker who can get an <iframe> element to survive sanitization can embed a complete HTML document containing a <script> tag inside srcdoc and have it execute when the browser renders the iframe. The content iframe is configured with sandbox="allow-same-origin allow-scripts", so script executing inside it shares the parent origin and can reach parent.parent.__TAURI_INTERNALS__.invoke(...), giving access to every Tauri IPC command the application is permitted to use, which escalates to arbitrary code execution. The payload can be made invisible (zero-size, transparent iframe) so the reader sees only normal book text. Version 0.11.16 hardened the sanitizer configuration by adding 'iframe', 'object' and 'embed' to FORBID_TAGS and adding 'srcdoc' to FORBID_ATTR.
Published: 2026-08-30
Score: 8.8 High
EPSS: n/a
KEV: No
Impact: n/a
Action: n/a
AI Analysis

Impact

Readest EPUB files are processed through DOMPurify, which in versions before 0.11.16 only disallows the <script> tag. DOMPurify treats the srcdoc attribute of <iframe> elements as opaque, so an attacker can embed an entire HTML document with a <script> tag inside a maliciously crafted srcdoc. When the reader renders the iframe – which is sandboxed with allow-same-origin allow-scripts – the embedded script runs with the same origin as the host application and can call parent.parent.__TAURI_INTERNALS__.invoke(...), granting access to any Tauri IPC command the application is allowed to use. This chain of effects allows the attacker to execute arbitrary code on the host system. The vulnerability is a classic DOM-based XSS / injection flaw, classified as CWE‑79. An unverified EPUB file that contains the crafted iframe can trigger the vulnerability without user interaction beyond opening the file. The integrity of the sandbox does not prevent the script from calling the exposed Tauri API, and the attacker can hide the iframe to remain invisible to the reader. In the absence of an applied patch, exploitation remains limited to a local user who can supply or modify EPUB files. However, the severity is high (CVSS 8.8), the issue is not yet listed in the KEV catalog, and the EPSS score is not available, indicating that the exploitation probability is uncertain but that vulnerability remains significant because it can affect any user who opens the application with a malicious e‑book.

Affected Systems

All Readest open‑source e‑book reader installations using the legacy sanitizer configuration—i.e., versions prior to 0.11.16 of the Readest product. The affected component is the EPUB sanitizer located in apps/readest-app/src/services/transformers/sanitizer.ts, which in those versions only forbids the <script> tag. The fix adds 'iframe', 'object' and 'embed' to the FORBID_TAGS list and 'srcdoc' to the FORBID_ATTR list, ensuring that any iframe element is removed or sanitized before rendering.

Risk and Exploitability

The CVSS score of 8.8 places the vulnerability in the high severity range. With EPSS not available, the exploitation probability is unknown, but the fact that the issue is not yet in the CISA KEV catalog suggests it is not actively exploited at a large scale. The likely attack vector involves a local user or an attacker who can place a crafted EPUB file on a target’s machine. Once opened in Readest, the malicious srcdoc payload will execute, giving the attacker arbitrary code execution privileges within the host environment.

Generated by OpenCVE AI on August 30, 2026 at 15:26 UTC.

Remediation

Vendor Solution

Upgrade to Readest 0.11.16 or later. The fix adds 'srcdoc' to the DOMPurify FORBID_ATTR list and 'iframe', 'object' and 'embed' to FORBID_TAGS in apps/readest-app/src/services/transformers/sanitizer.ts.


Vendor Workaround

Only open EPUB files from trusted sources. Ensure the 'allow script' view setting remains disabled, as enabling it bypasses sanitization entirely.


OpenCVE Recommended Actions

  • Upgrade Readest to version 0.11.16 or later, which blocks iframe, object, and embed tags and removes the srcdoc attribute from allowed attributes.
  • If an upgrade is not immediately feasible, only open EPUB files from trusted sources and keep the "allow script" view setting disabled, as enabling it bypasses the sanitizer entirely.
  • Avoid opening EPUB files from unverified or public repositories until the application is updated; consider using an alternative e‑book reader that implements stricter sanitization or blocking of iframe elements until a fix is released.

Generated by OpenCVE AI on August 30, 2026 at 15:26 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories yet.

History

Sun, 30 Aug 2026 14:00:00 +0000

Type Values Removed Values Added
Description Readest is an open-source e-book reader built on Tauri. In versions prior to 0.11.16, EPUB chapter HTML is sanitized with DOMPurify using a configuration that forbade only the <script> tag (FORBID_TAGS: ['script']) in apps/readest-app/src/services/transformers/sanitizer.ts. DOMPurify does not parse the contents of the srcdoc attribute on <iframe> elements, treating it as an opaque string attribute, so an attacker who can get an <iframe> element to survive sanitization can embed a complete HTML document containing a <script> tag inside srcdoc and have it execute when the browser renders the iframe. The content iframe is configured with sandbox="allow-same-origin allow-scripts", so script executing inside it shares the parent origin and can reach parent.parent.__TAURI_INTERNALS__.invoke(...), giving access to every Tauri IPC command the application is permitted to use, which escalates to arbitrary code execution. The payload can be made invisible (zero-size, transparent iframe) so the reader sees only normal book text. Version 0.11.16 hardened the sanitizer configuration by adding 'iframe', 'object' and 'embed' to FORBID_TAGS and adding 'srcdoc' to FORBID_ATTR.
Title Readest: unsanitized iframe srcdoc attribute in the EPUB sanitizer can lead to arbitrary code execution
Weaknesses CWE-79
References
Metrics cvssV3_1

{'score': 8.8, 'vector': 'CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H'}


Subscriptions

No data.

cve-icon MITRE

Status: PUBLISHED

Assigner: JFROG

Published:

Updated: 2026-08-30T13:44:34.109Z

Reserved: 2026-08-30T13:32:39.506Z

Link: CVE-2026-82642

cve-icon Vulnrichment

No data.

cve-icon NVD

Status : Received

Published: 2026-08-30T14:17:04.193

Modified: 2026-08-30T14:17:04.193

Link: CVE-2026-82642

cve-icon Redhat

No data.

cve-icon OpenCVE Enrichment

Updated: 2026-08-30T15:30:18Z

Weaknesses
  • CWE-79

    Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')