Self-XSS on Suggest Tag dialog box
The report claims a stored cross-site scripting issue in the add-tag dialog, where entering a script tag causes a JavaScript popup. The author also states there is no real security impact for the user.
- Triaged in 3 hours
- Fixed in 5 days
- Paid in 5 days
- Disclosed after 5 days
Summary by the program
We had a Self XSS on the suggest tag and model dialog box. No real security impact for user.
The report
Summary:
Stored cross-site scripting arises when an application receives data from an untrusted source and includes that data within its later HTTP responses in an unsafe way.
vulnerable URL : https://www.xvideos.com/video57921571/friend_b._if_d.
Vulnerability Description : Application have a add tag functionality when i put java script like <script>alert(1)</script> after that stored XSS vulnerability arise.
Step to Reproduce : Step 1 : Go to following URL https://www.xvideos.com/video53284603/b. Note : you don't need an account to do this Step 2 : There is a add tag functionality insert the following information : <script>alert(1)</script> Step 3 : Click the add button Step 4 : you will see a java script popup box showing your domain
Check the attached Video POC to see the actual XSS vulnerability
Impact
If an attacker can control a script that is executed in the victim's browser, then they can typically fully compromise that user. When the victim accesses the page containing the JavaScript payload, their browser will make a HTTP request to the attacker’s server
Context
XVIDEOS is a video sharing site. The feature involved here is the "add tag" control on a video page, which lets a visitor suggest a tag for a video. The report's own summary describes the issue as a Self XSS in the suggest tag and model dialog box, with no real security impact for the user. The platform classified it as stored cross-site scripting on www.xvideos.com, rated it low severity and paid a 50.00 USD bounty. It was disclosed on 2022-11-08.
Setup
The researcher states that no account is needed to reach the vulnerable functionality. No tools, versions or browser details are given. The only precondition is access to a video page that exposes the add tag control.
Finding it
The researcher describes stored cross-site scripting as arising when an application receives data from an untrusted source and includes that data within its later HTTP responses in an unsafe way. The researcher put a script tag into the add tag functionality. The report names this URL as the vulnerable one:
https://www.xvideos.com/video57921571/friend_b._if_d.
The reproduction steps use a different video URL, which is the one to follow when repeating the test.
Exploitation
Step 1: open the video page
https://www.xvideos.com/video53284603/b.
The researcher notes that you do not need an account to do this.
Step 2: enter the payload in the add tag field
The add tag functionality is present on the page. The following is inserted as the tag:
<script>alert(1)</script>
This is a plain script element carrying a call to alert(1). If the value is later written into the page as HTML rather than as text, the browser parses it as a script and executes it.
Step 3: submit
The researcher clicks the add button.
Step 4: observe execution
A JavaScript popup box appears, showing the domain. The report refers to an attached video proof of concept for the actual execution; that video is not reproduced here.
The report does not show the underlying HTTP request or response for the tag submission, so the exact parameter name, encoding and server response are not documented.
Root cause
The report attributes the behaviour to the application receiving data from an untrusted source and including it in later HTTP responses in an unsafe way. The report attributes the behaviour to the application including untrusted data in later HTTP responses in an unsafe way. The report does not identify the specific output context, escaping routine or template responsible, so the precise coding mistake is not established. Why existing defences did not stop it is likewise not described.
The program's summary frames the result as Self XSS: the script runs in the browser of the person who entered it, not in another user's session.
Impact
The report's impact section is generic: if an attacker can control a script that is executed in the victim's browser, they can typically fully compromise that user, and when the victim accesses the page containing the JavaScript payload their browser will make an HTTP request to the attacker's server.
The program's assessment narrows this considerably: no real security impact for the user. The payload executes for the person who submitted it, so there is no cross-user delivery demonstrated in the report. The platform rated it low severity and paid a 50.00 USD bounty.
Fix
The report does not state what was changed.
Variants to test
- A positive result is the payload executing in your own browser after submission.
- The same add tag control on other video pages, to see whether the behaviour is tied to one page or to the feature as a whole. A positive result is the same popup on a different video URL.
- Different output contexts: a tag rendered inside an attribute, a URL or a script block needs different syntax from a plain
<script>element. A positive result is execution with a payload shaped for that context. - Whether a submitted tag is visible to other visitors, for example on a public tag listing or on the video page for a different session. A positive result is the stored value being served to someone other than the submitter, which would move the issue beyond Self XSS.
Hunting notes
This kind of bug tends to sit in small, low-friction input features: tag suggestions, labels, nicknames and similar fields that are echoed back immediately. The signal during recon is a feature that accepts free text without an account and displays the value again on the same page. The researcher showed execution with a minimal alert(1) payload and a short numbered reproduction path. Demonstrating that the stored value reaches another user's browser is what would raise the severity beyond that.
What happened, in plain words
XVIDEOS is a website where people upload and watch videos. Each video page has a small control called "add tag", which lets a visitor suggest a tag (a short label) for that video.
The researcher typed a piece of JavaScript code into that tag field instead of a normal word. JavaScript is the programming language that web pages use to make things happen in your browser: pop-ups, buttons that react, content that changes without reloading. When the researcher clicked the add button, the browser ran that code and showed a popup box.
This class of bug is called cross-site scripting, usually shortened to XSS. The everyday comparison: imagine a noticeboard where visitors can pin notes. If the person in charge of the board copies whatever is written on a note straight onto the wall as instructions for staff, then a note saying "give this person the keys" gets followed like a real order. XSS is the same idea for web pages: text that should be shown as plain text gets treated as instructions by the browser.
The program that runs the bug bounty (the scheme where researchers report security problems and get paid) summarised the finding as a Self XSS in the suggest tag and model dialog box, with no real security impact for the user. "Self" means the code only ran in the browser of the person who typed it, not in anyone else's. The platform recorded it as stored cross-site scripting on www.xvideos.com, rated it low severity and paid a 50.00 USD bounty. It was disclosed on 2022-11-08.
The feature involved
The add tag control sits on a video page and lets a visitor suggest a tag for that video. The report's own summary calls the issue a Self XSS in the suggest tag and model dialog box. The researcher says no account is needed to use the feature.
Getting ready
The researcher states that no account is needed to reach the vulnerable functionality. No tools, versions or browser details are given. The only precondition is access to a video page that shows the add tag control. In other words, you just need a browser and a video page.
Finding it
The researcher describes stored cross-site scripting as arising when an application receives data from an untrusted source and includes that data within its later HTTP responses in an unsafe way. Breaking that down for a beginner:
- An application here is the website, the software running on XVIDEOS's servers that builds the pages you see.
- An untrusted source is anyone whose input the site does not control, which in practice means you, the visitor typing into a form.
- An HTTP response is what the server sends back to your browser when you ask for a page. Your browser sends a request, the server sends a response containing the page's HTML (the markup that describes the page), and the browser draws it on screen.
- Unsafe way means the server puts your text into that response without marking it as "just text". If the browser sees
<script>in the page and it has not been marked as text, it treats it as a real script and runs it.
The add tag functionality accepts free text, and the researcher tried putting a script tag into it. The report names this URL as the vulnerable one:
https://www.xvideos.com/video57921571/friend_b._if_d.
Line by line: https:// is the secure version of the protocol browsers use to fetch pages. www.xvideos.com is the site. video57921571 is the identifier of one particular video, and friend_b._if_d. is the readable part of that video's address. This is the page the report points at as vulnerable.
The reproduction steps use a different video URL, which is the one to follow when repeating the test.
Reproducing it
Step 1: open the video page
https://www.xvideos.com/video53284603/b.
This is the same kind of address as before: the site, then video53284603 identifying a specific video, then b. as the readable part. The researcher notes that you do not need an account to do this. That matters because it means the feature is open to anonymous visitors, so there is no login step to work around.
Step 2: enter the payload in the add tag field
The add tag functionality is present on the page. The following is inserted as the tag:
<script>alert(1)</script>
Line by line: <script> is the HTML tag that tells a browser "everything until the closing tag is JavaScript, please run it". alert(1) is a built-in JavaScript function that opens a small popup box showing the value you give it, here the number 1. </script> closes the script block. On its own this is harmless: it just makes a popup. Researchers use it because it is the simplest visible proof that code ran. If the value is later written into the page as HTML rather than as text, the browser parses it as a script and executes it. If it were written as text, you would simply see the characters <script>alert(1)</script> printed on the page, which is the safe behaviour.
Step 3: submit
The researcher clicks the add button. The researcher clicks the add button.
Step 4: observe execution
A JavaScript popup box appears, showing the domain. That popup is the proof: the browser did not display your text, it ran it. The report refers to an attached video proof of concept for the actual execution; that video is not reproduced here.
The report does not show the underlying HTTP request or response for the tag submission, so the exact parameter name, encoding and server response are not documented. In plain terms: we do not know the name of the field the browser sent, how it was encoded, or exactly what the server replied with.
Why it happens
The report attributes the behaviour to the application receiving data from an untrusted source and including it in later HTTP responses in an unsafe way. The report attributes the behaviour to the application including untrusted data in later HTTP responses in an unsafe way. "Reflected" here means your input comes back to you in the page the server builds.
The report does not identify the specific output context, escaping routine or template responsible, so the precise coding mistake is not established. Why existing defences did not stop it is likewise not described. In everyday terms: we know the site put the text back without a safety wrapper, but not which piece of code did it or why the usual safeguards were missing.
The program's summary frames the result as Self XSS: the script runs in the browser of the person who entered it, not in another user's session. That is the key limitation. For the bug to hurt someone else, the stored text would have to be shown to a different visitor, and the report does not demonstrate that.
What the impact would be
The report's impact section is generic: if an attacker can control a script that is executed in the victim's browser, they can typically fully compromise that user, and when the victim accesses the page containing the JavaScript payload their browser will make an HTTP request to the attacker's server. Unpacking that: a script running in someone's browser can act as that person on the site, and it can quietly send data to a server the attacker controls, which is just another computer somewhere on the internet that the attacker can watch.
The program's assessment narrows this considerably: no real security impact for the user. The payload executes for the person who submitted it, so there is no cross-user delivery demonstrated in the report. The platform rated it low severity and paid a 50.00 USD bounty. In short, you can only make a popup appear in your own browser, which is not an attack on anyone.
How it would be fixed
The report does not state what was changed. Output encoding means converting characters that have special meaning in HTML into safe stand-ins, so the browser shows them instead of acting on them.
Other places to look
- A positive result is the payload executing in your own browser after submission.
- The same add tag control on other video pages, to see whether the behaviour is tied to one page or to the feature as a whole. A positive result is the same popup on a different video URL.
- Different output contexts: a tag rendered inside an attribute, a URL or a script block needs different syntax from a plain
<script>element. A positive result is execution with a payload shaped for that context. - Whether a submitted tag is visible to other visitors, for example on a public tag listing or on the video page for a different session. A positive result is the stored value being served to someone other than the submitter, which would move the issue beyond Self XSS.
Notes for anyone hunting this
This kind of bug tends to sit in small, low-friction input features: tag suggestions, labels, nicknames and similar fields that are echoed back immediately. The signal during recon (the early look around a site to spot interesting features) is a feature that accepts free text without an account and displays the value again on the same page. The researcher showed execution with a minimal alert(1) payload and a short numbered reproduction path. Demonstrating that the stored value reaches another user's browser is what would raise the severity beyond that.
Glossary
- XSS (cross-site scripting): a bug where text supplied by a user is treated by the browser as code and run, instead of being shown as plain text.
- Self XSS: an XSS where the code only runs in the browser of the person who typed it, so no other user is affected.
- Stored XSS: an XSS where the malicious text is saved by the server and served back later, rather than only appearing once in the immediate reply.
- JavaScript: the programming language browsers run to make pages interactive.
- HTML: the markup language that describes the structure of a web page, using tags such as
<script>. - Script tag: the HTML element
<script>that marks a block of code for the browser to execute. alert(1): a JavaScript function that opens a popup showing the value 1; used as simple proof that code ran.- Payload: the piece of input a researcher sends to try to trigger a bug.
- HTTP request: the message your browser sends to a server asking for a page or sending data.
- HTTP response: the message the server sends back, containing the page or a result.
- Server: the computer that runs the website and answers requests.
- Application: the software on the server that builds pages and handles input.
- Untrusted source: any input the site does not control, such as text typed by a visitor.
- Output encoding / escaping: converting special characters into safe stand-ins so the browser displays them as text instead of acting on them.
- Output context: the place in the page where a value is inserted (plain text, an attribute, a URL, a script block), which determines what encoding is needed.
- Reflected input: input that comes straight back to you in the page the server builds.
- Parameter: a named field in a request that carries a value, such as the text of a tag.
- Session: the state that ties a series of requests to one logged-in (or anonymous) visitor.
- Bug bounty: a scheme where organisations pay researchers for reporting security problems.
- Severity: a rating of how serious a bug is, here low.
- Bounty: the money paid for a valid report, here 50.00 USD.
- Proof of concept (POC): a demonstration that a bug really works, here a video.
- Recon: the early exploration of a site to find features worth testing.
- Domain: the site's name in an address, such as
www.xvideos.com.