Skip to content
RCE Disclosed report Beginner

`settingcontent-ms` files lacks "mark of the web" => execute code by dbl click in Downloads toolbar

Brave browser did not add the 'mark of the web' to downloaded settingcontent-ms files, so a user double-clicking such a file in the Downloads toolbar could execute arbitrary code with user-level privileges.

metnew Follow

Originally disclosed on HackerOne

  • Disclosed after 3 months

Summary:

settingcontent-ms files allow launching any binary with any params. Brave doesn't mark settingcontent-ms files with "mark of the web", so the file could be executed by double click in "Downloads" toolbar. Launched settingcontent-ms file could lead to code execution with user-level privileges.

Products affected:

Brave: 0.23.19 Muon: 7.1.3 OS: 10.0.17134 (the image was downloaded today from the MS virtualbox images page) Chromium: 67.0.3396

Steps To Reproduce:

  1. Download twitter.settingcontent-ms from attachments.
  2. Dbl click on the item in "Downloads" toolbar.
  3. Calculator opens (but as I said, it's possible to launch anything).

PoC/Screencast additionally leverages #375259.

Supporting Material/References:

  1. FF patched this somewhere between 60-62 version
  2. This bug still works in Edge. As far as I know, that's 1-day.
  3. Chrome downloads settingcontent-ms files only after a confirmation from the user.
  4. This problem is already popular, so you could easily find more info.

PoC + screencast attached. Live PoC: (not sure that it works, it'd be better to test it locally)

Impact

Launched settingcontent-ms could lead to code execution with user-level privileges. Marked as "high", because it's a native OS feature, all Win users are affected.

Attachments

brave-win-settingcontent-ms.mp4 From the original on HackerOne

The original report as published on HackerOne, by metnew. 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 browser failed to apply the mark-of-the-web attribute to downloaded settingcontent-ms files, allowing them to be executed without the usual security prompt.

Impact

A downloaded settingcontent-ms file could lead to code execution with user-level privileges, and the issue is marked high because it affects all Windows users.

What the attacker needed

Windows OS; victim downloads a malicious file; victim double-clicks the file

How it was found

  1. Download a settingcontent-ms file from the provided attachment.
  2. Double-click the downloaded file in the Downloads toolbar.
  3. The calculator opens, demonstrating code execution.

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.

When you download a file, Windows can tag it with a 'mark of the web' to show it came from the internet. Some file types, like settingcontent-ms, can run programs when opened. Because Brave did not add that tag, a downloaded file could run code without the usual warning.

What is RCE?

Running the attacker's code on the target's servers: through command or code injection, unsafe deserialisation or template injection.

More by metnew

View all

25 more disclosed reports, best first.

More from Brave Software

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

Remote code execution

The lesson behind this report.

Running the attacker's code on the target's servers: through command or code injection, unsafe deserialisation or template injection.