CVE-2022-0776: Cross-Site Scripting in reveal.js

reveal.js Updated 02 Oct 2025

Summary

02/03/2022
Yes i
Moderate
6.1

CVE-2022-0776: Cross site scripting in reveal.js. Affects reveal.js versions < 4.3.0. Fixed in 4.3.0. How to fix ↓

Free scan

Check if this vulnerability affects your application

Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.

Check my app free

No signup required · Results in about 60 seconds

Upload your dependency manifest or SBOM

Drag & drop your file here or

Java Javascript PHP Python Go Rust Ruby Dart C/C++ Elixir CycloneDX SPDX

Upload a supported dependency manifest or SBOM. No installation or source-code access required.

See supported files and SBOM formats
SBOM sbom.json · bom.json · bom.xml · *.spdx.json · *.cdx.json · *.cdx.xml
Java pom.xml · gradle.lockfile · buildscript-gradle.lockfile
Javascript package-lock.json · yarn.lock · pnpm-lock.yaml
PHP composer.lock
Python poetry.lock · requirements.txt · Pipfile.lock
Go go.mod
Rust Cargo.lock
Ruby Gemfile.lock
Dart pubspec.lock
C/C++ conan.lock
Elixir mix.lock
Enter your work email to receive your report link.

Verify your email to view the full report and start 30 days of continuous monitoring. No credit card required.

Sponsored Devnack Your last release was probably never penetration tested Manual testing by engineers who build software, not an auditor's checklist. Trusted by teams at Swift and Google Talk to Devnack

Background

reveal.js is an open-source HTML presentation framework that allows users to create interactive and visually appealing slideshows. It is widely used for presentations, conferences, and educational purposes. The vulnerability identified as CVE-2022-0776 affects reveal.js versions prior to 4.3.0. This vulnerability allows an attacker to execute arbitrary JavaScript code on a victim's browser window hosting reveal.js by exploiting a cross-site scripting (XSS) vulnerability in the onmessage event listener in /plugin/notes/speaker-view.html.

Vulnerability Detail

The onmessage event listener in /plugin/notes/speaker-view.html does not properly validate the origin of postMessage requests before adding the content to the webpage. This allows any origin to postMessage on the browser window, enabling an attacker to inject malicious JavaScript code into the victim's browser. By exploiting this vulnerability, an attacker can potentially steal sensitive information, perform actions on behalf of the victim, or manipulate the content displayed in the reveal.js presentation.

How To Fix

Minimum fixed version

4.3.0

This is the first release that contains the fix.

npm install reveal.js@4.3.0

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Workaround

As a temporary workaround, users can disable the speaker view plugin in reveal.js to mitigate the risk of exploitation. This can be done by removing or commenting out the 'speaker' plugin from the list of plugins in the reveal.js configuration file.

Conclusion

CVE-2022-0776 is a cross-site scripting vulnerability in reveal.js that allows an attacker to execute arbitrary JavaScript code on a victim's browser window. Users are advised to upgrade to reveal.js version 4.3.0 or later to fix this vulnerability. A temporary workaround is available by disabling the speaker view plugin. For further assistance or support in vulnerability remediation, please contact DevNack.com.

See every vulnerability recorded for reveal.js →

Share this vulnerability

FAQ

reveal.js is an open-source HTML presentation framework used for creating interactive slideshows.

This vulnerability allows an attacker to execute arbitrary JavaScript code on a victim's browser window hosting reveal.js, potentially leading to information theft, unauthorized actions, or content manipulation.

reveal.js versions prior to 4.3.0 are affected by this vulnerability.

To fix this vulnerability, it is recommended to upgrade to reveal.js version 4.3.0 or later.

Yes, users can disable the speaker view plugin in reveal.js as a temporary workaround.

Related vulnerabilities

Recent vulnerabilities recorded for reveal.js.

How To Fix

Minimum fixed version

4.3.0

This is the first release that contains the fix.

npm install reveal.js@4.3.0

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Subscribe to Vulert on Telegram
Daily digest of new CVEs, critical and high severity, affected packages and fixes — plus a weekly roundup.
Join the channel →
Help improve this record
Report an issue or send feedback