Skip to content
XSS Disclosed report Intermediate

apps.owncloud.com: XSS via referrer

The Referer header was inserted unescaped into an onclick attribute of a cancel button, allowing an attacker to inject JavaScript that executes when the button is clicked. An attacker could craft a link with a malicious Referer value to run script in the victim's browser.

Igor Sak-Sakovskiy Follow

Originally disclosed on HackerOne

  • Triaged in 4 hours
  • Fixed in 15 days
  • Disclosed after 53 days

Look at next request:

Host: apps.owncloud.com User-Agent: Mozilla/5.0 (Windows NT 6.3; WOW64; rv:40.0) Gecko/20100101 Firefox/40.0 Accept: text/html,application/xhtml+xml,application/xml;q=0.9,/;q=0.8 Accept-Language: ru-RU,ru;q=0.8,en-US;q=0.5,en;q=0.3 Accept-Encoding: gzip, deflate Referer: http://www.myevilsite.com/qwe';alert(1)+'

in response page referrer pasts into onclick event of a cancel button

onclick="location.href='http://www.myevilsite.com/qwe';alert(1)+'?PHPSESSID=icqgmh3h639vn6a75j6idmj935'" />

The original report as published on HackerOne, by psych0tr1a. 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

Impact

An attacker could execute JavaScript in a victim's browser if the victim clicks the affected button.

What the attacker needed

Victim clicks the cancel button; attacker can control the Referer header

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 visit a website, your browser sends a 'Referer' header telling the site where you came from. This site put that header value directly into a button's click action without cleaning it, so an attacker could make the button run their own code. That is cross-site scripting (XSS): running attacker-controlled JavaScript in a victim's browser.

What is XSS?

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

More by Igor Sak-Sakovskiy

View all

4 more disclosed reports, best first.

More from ownCloud

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.