MEDIUM 4.4

CVE-2026-47733: Rocket.Chat ImageElement Protocol Validation Bypass

Rocket.Chat versions before 8.5.0 contain a flaw in how the ImageElement component processes user-supplied image URLs in markdown content. When rendering image links, the component fails to filter dangerous protocol prefixes like javascript: and data:, allowing an authenticated attacker to craft a malicious markdown image that executes arbitrary JavaScript when clicked by another user. The vulnerability requires user interaction (clicking the link) and works primarily on older browsers, but poses a real risk in environments where users share untrusted markdown content or where attackers have internal access.

Source data · NVD / CISA · public domain

CVSS
3.1 · 4.4 MEDIUM · CVSS:3.1/AV:N/AC:H/PR:L/UI:R/S:C/C:L/I:L/A:N
Weaknesses (CWE)
CWE-79
Affected products
0 configuration(s)
Published / Modified
2026-06-24 / 2026-06-25

NVD description (verbatim)

Rocket.Chat is an open-source, secure, fully customizable communications platform. Prior to 8.5.0, the ImageElement component in packages/gazzodown renders user-controlled src values directly into <a href> and <img src> attributes without protocol sanitization. Unlike the analogous LinkSpan component — which uses sanitizeUrl to block javascript:, data:, and vbscript: protocols — ImageElement passes the raw URL through unchanged. An authenticated user can post a markdown image with a javascript: URL that, if clicked on an older browser, would execute arbitrary JavaScript in the viewer's session. This vulnerability is fixed in 8.5.0.

2 reference(s) · View on NVD →

SEC.co analysis · AI-assisted, reviewed against source

Technical summary

The ImageElement component in packages/gazzodown renders markdown image syntax without protocol sanitization on the src attribute passed to <img> and <a href> tags. While Rocket.Chat's analogous LinkSpan component correctly invokes sanitizeUrl() to strip javascript:, data:, and vbscript: protocols, ImageElement bypasses this security control entirely. An authenticated user can inject a markdown image with a malicious protocol—for example ![alt](javascript:alert(document.cookie))—which, when clicked by a recipient in a vulnerable browser, will execute the embedded script in that viewer's security context. The fix in 8.5.0 applies protocol sanitization to ImageElement, bringing it in line with LinkSpan's existing defenses.

Business impact

This vulnerability enables session hijacking and credential theft within Rocket.Chat conversations. An attacker with platform access can distribute malicious markdown to other users; if those users click the crafted image link, the attacker's JavaScript runs with the victim's permissions, potentially exfiltrating session tokens, performing unauthorized actions, or harvesting sensitive data shared in the chat. The impact is amplified in organizations where Rocket.Chat is used for sensitive communications or where user bases include less security-aware staff. Older browsers and environments with lenient Content Security Policy settings face higher risk.

Affected systems

Rocket.Chat versions prior to 8.5.0 are affected. The vulnerability requires authentication and user interaction, so exposure is limited to internal users or invited participants. Self-hosted and SaaS Rocket.Chat deployments running versions 8.4.x and earlier should be considered at risk. Community-driven integrations and forks that have not backported the fix may also be vulnerable.

Exploitability

Exploitability is moderate. An attacker must be an authenticated user on the platform, and the victim must click the malicious image link for code execution to occur. The reliance on older browser behavior (modern browsers have increasingly strict URL protocol handling) reduces but does not eliminate the risk. No exploit kit or advanced tooling is required—a simple markdown injection suffices. Internal threat actors or users with compromised credentials pose the primary risk vector.

Remediation

Upgrade Rocket.Chat to version 8.5.0 or later. This release patches the ImageElement component to apply protocol sanitization consistent with LinkSpan, blocking javascript:, data:, and vbscript: URLs. Organizations unable to upgrade immediately should audit markdown content for suspicious image links and consider network controls or browser security policies that restrict javascript: protocol execution. Review user access logs for any evidence of click-based exploitation attempts.

Patch guidance

Apply the 8.5.0 release or any subsequent version as soon as practical. Verify the upgrade in a staging environment to confirm backward compatibility with custom markdown extensions or third-party integrations. No configuration workarounds are available; patching is the definitive remediation. Organizations on extended support timelines should contact Rocket.Chat for guidance on backported patches for older release branches.

Detection guidance

Monitor Rocket.Chat logs for markdown containing suspicious URL schemes (javascript:, data:, vbscript:) embedded in image or link syntax. Hunt for image elements in messages posted by users with escalated privileges or those showing lateral movement patterns. Examine browser console logs and CSP violation reports for attempts to execute inline scripts. Network telemetry showing connections initiated from Rocket.Chat browser clients to unexpected external hosts may indicate successful exploitation.

Why prioritize this

While the CVSS score of 4.4 (Medium) reflects the requirement for authentication and user interaction, the attack's simplicity, the likelihood of social engineering, and the sensitivity of data typically flowing through team communication platforms warrants prioritization above the base score. Organizations with highly engaged user bases and those managing sensitive projects should treat this as a higher-priority patch. The vulnerability is not yet in the CISA KEV catalog, but that reflects publication recency rather than actual risk.

Risk score, explained

CVSS 4.4 reflects a Network vector (reachable over the internet), High complexity (limited to older browsers, user interaction required), Low privilege requirement (any authenticated user), Required user interaction, and limited scope of impact (Low confidentiality and integrity, no availability loss). The score appropriately discounts for browser-level mitigations in modern clients, but does not fully account for the social engineering component or the high-value targets in team communication workflows. Security teams should layer this score with organizational context: communication platforms often serve as attack amplifiers, making this a good candidate for above-base-score prioritization in sensitive environments.

Frequently asked questions

Does this affect Rocket.Chat on-premises deployments only, or SaaS too?

Both. Any Rocket.Chat instance (self-hosted, SaaS, or hybrid) running versions before 8.5.0 is affected. SaaS providers hosting Rocket.Chat should prioritize patching to protect all customers. Self-hosted operators are responsible for their own patching schedule.

Can this be exploited without the victim clicking the image?

No. The vulnerability requires the victim to click the malicious image link for JavaScript execution. Simply viewing or having the message in the chat does not trigger the exploit. This is a significant limiting factor and depends on social engineering to succeed.

Are there temporary mitigations if we cannot upgrade immediately?

Partial mitigations exist: enforce strict Content Security Policies that block unsafe-inline and javascript: protocol execution, restrict user markdown permissions where feasible, and educate users not to click unfamiliar image links. However, these are compensating controls, not substitutes for patching. Upgrade as soon as your change control process permits.

How does this differ from typical XSS vulnerabilities?

This is a stored XSS variant specific to markdown image rendering. Unlike many XSS flaws that require the attacker to control page HTML directly, this attack leverages the markdown parser's failure to sanitize protocols in image attributes. It is narrower than DOM-based XSS but remains dangerous in collaborative platforms where user-generated content is the primary product.

This analysis is provided for informational purposes and reflects publicly available information as of the publication date. Organizations should verify patch availability and applicability to their specific Rocket.Chat configuration and deployment model. Consult official Rocket.Chat security advisories and release notes for authoritative remediation guidance. SEC.co does not warrant the completeness or real-time accuracy of this content, and security teams must conduct their own risk assessments based on their environment and threat model. Source: NVD (public-domain), retrieved 2026-08-02. Analysis generated by SEC.co (claude-haiku-4-5).