Cross site scripting - XSRF Token
A form on the Nextcloud enterprise purchase page did not sanitise user input, so an attacker could submit an image or SVG tag with an onload handler that executed in the confirmation email. The report claims the email exposed an XSRF token, which the attacker could then use in a later CSRF attack.
- Triaged in 21 days
- Fixed in 21 days
- Disclosed after 51 days
Please follow below mentioned steps for reproducing the vulnerability.
-
Open URL: https://nextcloud.com/enterprise/buy/
-
Fill up valid name and email address and put payload in other fields.
Payload/s:
{{media:0}} <svg/onload=alert(document.cookie);> -
Submit it
-
Open email address you mentioned in the email field.
-
Open up the email source.
-
You will be prompted with xsrf-token.
Impact
As an attacker is getting the xsrf-token, he can utilize it in later attack such as, CSRF.
Attachments
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 form input was stored and inserted into the confirmation email without HTML encoding or sanitisation.
Impact
The attacker could obtain an XSRF token from the email and potentially use it in a later CSRF attack, though the report does not demonstrate a full exploit.
What the attacker needed
Access to the public purchase form; a valid email address to receive the confirmation
How it was found
- Open the enterprise purchase page.
- Fill in a valid name and email address and put the payload in the other fields.
- Submit the form.
- Open the email address used in the form.
- View the email source.
- Observe the XSRF token in the email.
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.
What is XSS?
Script an attacker supplies runs in another user's browser, on the target's origin, with that user's session.