Skip to content
XSS Write-up Intermediate

Stored XSS in LibreOffice

A researcher uploaded a PNG file containing script markup in its metadata to an extension-screenshot upload feature on a LibreOffice web asset. When the uploaded image was later rendered at a particular location, the embedded script executed, demonstrating stored cross-site scripting.

Aayush kumar Follow

Published on bunny0417.medium.com

Without wasting any time, let’s dive in. Over time, I’ve realized that bug bounty hunting is a blend of luck and hard work.

Aayush kumar, on bunny0417.medium.com

The full write-up lives on its author's site

It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.

Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.

How it worked

Root cause

Likely the upload feature stored image metadata without sanitising it, and a later page rendered that metadata as HTML rather than as inert text.

Impact

An attacker could store script that runs in the browser of anyone who views the affected page, though the report does not describe what data or actions that script could reach.

What the attacker needed

Ability to upload extension screenshots

Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.

Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.

Websites sometimes let you upload pictures, and they store them for later display. If the site does not clean the hidden data inside the picture file, a script hidden there can run in a visitor's browser when the picture is shown. That lets an attacker run code in someone else's session.

What is XSS?

Script an attacker supplies runs in another user's browser, on the target's origin, with that user's session.

More from LibreOffice

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

Cross-site scripting (XSS)

The lesson behind this report.

Script an attacker supplies runs in another user's browser, on the target's origin, with that user's session.