CVEReports
CVEReports

Automated vulnerability intelligence platform. Comprehensive reports for high-severity CVEs generated by AI.

Product

  • Home
  • Sitemap
  • RSS Feed

Company

  • About
  • Contact
  • Privacy Policy
  • Terms of Service

© 2026 CVEReports. All rights reserved.

Made with love by Amit Schendel & Alon Barad



CVE-2026-61823

CVE-2026-61823: Stored Cross-Site Scripting (XSS) via iframe srcdoc Attribute in code16 Sharp

Amit Schendel
Amit Schendel
Senior Security Researcher

Sep 25, 2026·5 min read·18 visits

Executive Summary (TL;DR)

A stored cross-site scripting vulnerability in code16 Sharp allows authenticated users to inject arbitrary JavaScript via the 'srcdoc' attribute of an 'iframe' in rich-text fields. This bypasses backend sanitization because web browsers decode HTML entities within this attribute before execution.

A stored cross-site scripting (XSS) vulnerability was identified in the content-management and administrative framework code16 Sharp. The flaw stems from an overly permissive HTML sanitization configuration that whitelists the 'srcdoc' attribute on HTML 'iframe' tags. When processed and stored, browsers render the content of this attribute by decoding nested HTML entities, converting sanitized elements back into executable code.

Vulnerability Overview

The administrative and content-management framework code16 Sharp for Laravel utilizes a rich-text editor allowing content creators to format and structure HTML. To prevent security issues, the framework employs an HTML sanitizer on incoming submissions before storing them in the persistent database layer.

However, in versions prior to 9.22.5, the backend sanitization rules explicitly allowed the 'srcdoc' attribute on 'iframe' elements. This configuration creates a critical parsing vector due to the structural differences between how server-side libraries sanitize raw HTML and how client-side user agents render the nested documents of iframes.

Because the input is persistently stored, any user with permission to edit a rich-text field can introduce malicious scripts. When another administrative user views the edited content within the Sharp interface, the script executes, creating a significant privilege escalation risk.

Root Cause Analysis

The root cause of this vulnerability lies in the improper neutralization of input within nested browser rendering contexts (CWE-79). When a server-side HTML sanitizer processes an iframe with a 'srcdoc' attribute, it attempts to protect the page by HTML-encoding active tag markers inside the attribute. For example, the string <script> becomes &lt;script&gt;.

While this sanitization is sufficient for typical attribute contexts, the 'srcdoc' attribute defines the content of an embedded HTML document. Web browsers natively process this attribute by applying a standard decoding pass. During this pass, the browser converts all HTML entities (such as &lt; and &gt;) back into their literal characters before executing the DOM parser inside the frame.

Consequently, the browser reverses the safety measures applied by the sanitizer. The safe, encoded string is normalized back into an active script block inside the document. The browser then executes the script in the context of the parent domain unless isolated by a strict sandbox configuration.

Code Analysis

The configuration error was located within the backend formatting class at src/Utils/Sanitization/FormatsSanitizedValue.php. The sanitizer instances whitelisted several attributes on iframe elements, including the vulnerable 'srcdoc' attribute.

Below is the relevant code before the remediation was applied:

private function sanitizer(): HtmlSanitizer
{
    return (new HtmlSanitizer())
        // ...
        ->allowAttribute('srcdoc', 'iframe') // The vulnerable configuration
        // ...
}

The fix, implemented in commit ec509a22c808a5bd9dfad6a0a85c92ce6f411e21, removes 'srcdoc' from the allowed properties. Below is the patch details:

File: src/Utils/Sanitization/FormatsSanitizedValue.php
@@ -49,7 +49,6 @@ private function sanitizer(): HtmlSanitizer
                 'referrerpolicy',
                 'sandbox',
                 'src',
-                'srcdoc',
                 'width',
                 'height',
                 'id',

Additionally, the patch hardens data attributes (specifically 'data-html-content') to ensure they are only preserved if the RAW_HTML option is enabled in the rich-text field's toolbar. This prevents alternative bypass paths using unescaped data tags.

Exploitation Methodology

An attacker with authenticated access to edit rich-text fields within the admin panel constructs a payload targeting the nested parsing behavior of the iframe. This payload consists of an iframe tag whose 'srcdoc' attribute contains encoded scripting elements.

<iframe srcdoc="&lt;script&gt;alert('Stored XSS')&lt;/script&gt;"></iframe>

When the application processes this payload, the backend sanitizer evaluates the input. Because 'srcdoc' is whitelisted, the parser accepts the attribute without stripping it. The application saves the sanitized markup to the database.

Upon retrieval, the application renders the raw iframe within the DOM. The browser processes the 'srcdoc' attribute, decodes the HTML entities, and executes the payload inside the frame, bypassing standard sanitization filters.

Impact Assessment

A successful attack allows arbitrary JavaScript to execute in the security context of the victim's session. Since code16 Sharp is a Laravel-based administrative and content-management framework, the typical user of this interface holds elevated privileges (e.g., content managers, editors, and administrators).

The executing script can perform actions on behalf of the victim. This includes hijacking active sessions via cookie extraction (unless protected by HttpOnly flags), reading sensitive data exposed in the administrative console, or silently performing state-changing operations such as creating new administrative accounts, modifying application configurations, or deploying malicious templates.

Remediation and Defense-in-Depth

The primary remediation strategy is upgrading the code16/sharp package to version 9.22.5 or higher. This permanently removes 'srcdoc' from the whitelist of the underlying sanitizer.

If upgrading immediately is not possible, a temporary workaround can be achieved via a global Laravel middleware or custom validation rules. This layer should analyze incoming editor fields and remove 'srcdoc' attributes using an XML/HTML DOM parser before storing the content.

public function sanitizeIncomingContent(string $content): string
{
    // Temporary regular expression to strip the srcdoc attribute if DOM parsing is unavailable
    return preg_replace('/<iframe\b[^>]*\bsrcdoc\s*=\s*(["\'])(.*?)\1/is', '<iframe>', $content);
}

For defense-in-depth, configure a Content Security Policy (CSP) header that restricts iframe generation (frame-src 'self') and limits script execution domains to trusted sources.

Fix Analysis (1)

Technical Appendix

CVSS Score
7.3/ 10
CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:U/C:H/I:H/A:N
EPSS Probability
0.21%
Top 90% most exploited

Affected Systems

code16/sharp

Affected Versions Detail

Product
Affected Versions
Fixed Version
sharp
code16
< 9.22.59.22.5
AttributeDetail
CWE IDCWE-79
Attack VectorNetwork (N)
CVSS Score7.3
EPSS Score0.0021
EPSS Percentile10.08%
Exploit Statuspoc
KEV StatusNot Listed

MITRE ATT&CK Mapping

T1190Exploit Public-Facing Application
Initial Access
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')

References & Sources

  • [1]GitHub Security Advisory GHSA-qxg3-46rw-79j8
  • [2]NVD CVE-2026-61823 Reference Record

Attack Flow Diagram

Press enter or space to select a node. You can then use the arrow keys to move the node around. Press delete to remove it and escape to cancel.
Press enter or space to select an edge. You can then press delete to remove it or escape to cancel.

More Reports

•2 days ago•CVE-2026-16454
4.3

CVE-2026-16454: Object-Level Authorization Bypass in Eclipse hawkBit Direct Device Integration Controller

CVE-2026-16454 is an object-level authorization bypass vulnerability (CWE-284, CWE-862) in Eclipse hawkBit versions 1.0.3 and prior. The flaw exists within the Direct Device Integration (DDI) REST controller (hawkbit-ddi-resource), where endpoints responsible for enumerating software module metadata and serving firmware binaries fail to verify whether the requested software module is assigned to the authenticated device. Consequently, any device with valid credentials (such as a TargetToken or GatewayToken) can enumerate software module identifiers and download arbitrary firmware artifacts across the entire tenant namespace.

Amit Schendel
Amit Schendel
10 views•9 min read
•2 days ago•CVE-2026-62284
8.6

CVE-2026-62284: Remote Code Execution and SSRF via Unsanitized Kubeconfig in OSAC Operator

CVE-2026-62284 (GHSA-5w5g-j6hw-6p8f) is a code injection and server-side request forgery vulnerability in the console-proxy component of the OSAC Operator. The RemoteConfigResolver parses Kubernetes Secrets containing kubeconfig files via clientcmd.RESTConfigFromKubeConfig without sanitizing execution-related fields. An attacker with RBAC permissions to create or modify labeled Secrets in monitored namespaces can supply a malicious exec credential plugin, resulting in arbitrary command execution within the console-proxy pod.

Amit Schendel
Amit Schendel
8 views•8 min read
•2 days ago•CVE-2026-62361
5.5

CVE-2026-62361: Authenticated SQL Injection and Table Access Control Bypass in Listmonk Subscriber Export

CVE-2026-62361 (GHSA-xgjr-7j9q-2h4r) is an authenticated SQL injection and authorization bypass vulnerability in listmonk, an open-source, self-hosted newsletter and mailing list manager written in Go. In versions prior to 6.2.0, the subscriber export endpoint (GET /api/subscribers/export) directly interpolates user-supplied SQL filter expressions into a PostgreSQL query without invoking the table allowlist validation function (validateQueryTables). Consequently, authenticated users possessing the subscribers:sql_query and subscribers:get_all permissions can bypass relational access controls, execute arbitrary subqueries against restricted tables such as users and settings, and modify database state via writable Common Table Expressions (CTEs).

Alon Barad
Alon Barad
9 views•11 min read
•2 days ago•CVE-2026-28385
5.0

CVE-2026-28385: Server-Side Request Forgery in Canonical LXD Image Import

CVE-2026-28385 (GHSA-3gq2-x4qg-p4g6) is a Server-Side Request Forgery (SSRF) vulnerability in Canonical LXD versions 4.12 through 6.9. An authenticated user possessing the can_create_images entitlement can force the LXD daemon to execute arbitrary outbound HTTP and HTTPS requests via the /1.0/images API endpoint. Due to the absence of egress destination validation, an attacker can probe host loopback services, RFC 1918 private network segments, and cloud Instance Metadata Services (IMDS) from the network position of the privileged LXD daemon.

Amit Schendel
Amit Schendel
10 views•9 min read
•2 days ago•GHSA-9J25-MM2H-2F76
9.9

CVE-2026-48750: Arbitrary File Write on Host via exec-output Symlink in Canonical LXD and Incus

Canonical LXD and LXC Incus contain an arbitrary file write vulnerability (CWE-73 / CWE-59) in the `/1.0/instances/<name>/exec` REST API endpoint. When an instance is unpacked from an image archive, top-level symbolic links are extracted directly onto the host filesystem within the instance storage directory. If a crafted image includes a symbolic link named `exec-output` pointing to an arbitrary host path, invoking the execution endpoint with `record-output: true` causes the privileged host daemon to follow the symlink and write command output files directly to the target host directory. An authenticated attacker with permissions to import images and execute commands can exploit this flaw to write controlled content to sensitive host directories such as `/etc/cron.d`, resulting in arbitrary code execution on the host as `root`.

Alon Barad
Alon Barad
8 views•12 min read
•2 days ago•GHSA-VGHH-5RFX-XHQ8
9.9

CVE-2026-48749: Arbitrary Host File Read and Write via Malicious Image Symlink in Canonical LXD and Incus

CVE-2026-48749 (tracked as GHSA-vghh-5rfx-xhq8 for LXD and GHSA-2q3f-q5pq-g8wv for Incus) is a critical container escape vulnerability in the Canonical LXD and Linux Containers Incus system container managers. By importing a specially crafted container image archive containing duplicate tar member headers, an authenticated attacker can replace the instance rootfs directory with a symbolic link pointing to the underlying host root filesystem. When performing file operations on a stopped container, the privileged forkfile helper binary resolves the symbolic link without confinement and chroots directly into the host filesystem, granting arbitrary root-level file read and write access.

Amit Schendel
Amit Schendel
8 views•9 min read