Skip to content
File upload Disclosed report Beginner

Theme Assets uploader allows HTML content

The theme asset uploader accepted HTML files, which should not have been allowed because HTML can carry JavaScript, undermining the restriction of JavaScript to the blog network.

myominthu_sec Follow

Originally disclosed on HackerOne

  • Triaged in 10 hours
  • Fixed in 45 hours
  • Paid in 7 days
  • Disclosed after 7 days

Summary by the program

The reporter submitted a report highlighting that specially formatted yet valid HTML files were able to be uploaded as theme assets. Even though we allow for JavaScript on our blog network, we don't allow HTML files to be uploaded here so that we can restrict JavaScript execution to the blog network. Our fix involved whitelisting the specific files & mimetypes that are able to be uploaded as theme assets.

The original report as published on HackerOne, by myominthu_sec. Images and videos are our own copies; raw HTML is shown as text. View it on HackerOne.

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

How it worked

Root cause

Likely the uploader validated files by content or extension too loosely instead of enforcing a strict allowlist of permitted file types and MIME types.

Impact

An attacker could upload an HTML file as a theme asset, bypassing the restriction that JavaScript execution be confined to the blog network.

What the attacker needed

Ability to upload theme assets

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 report has not been written yet. The Original tab links to the source.

A website lets users upload theme files but blocks HTML because HTML can contain code that runs in a browser. The check was too loose, so a specially made HTML file got through, which the site wanted to prevent.

What is File upload?

An upload feature accepts a file that the server or other users' browsers then treat as code or as something trusted.

More by myominthu_sec

View all

2 more disclosed reports, best first.

More from Automattic

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

Unrestricted file upload

The lesson behind this report.

An upload feature accepts a file that the server or other users' browsers then treat as code or as something trusted.