Skip to content
XSS Disclosed report Beginner

Stored XSS at https://www.█████████.mil

A stored cross-site scripting vulnerability exists on a .mil website because the file upload form allows users to upload files containing JavaScript code. An attacker could upload a malicious file that executes script when viewed, potentially stealing cookies or defacing the site.

5050thepiguy Follow

Originally disclosed on HackerOne

  • Triaged in 13 hours
  • Fixed in 8 days
  • Disclosed after 13 days

Summary: Stored XSS exists at https://www.██████.mil. A user can fill out the form and upload a file containing javascript code to trigger XSS.

Description: Stored XSS exists at https://www.████.mil. A user can fill out the form and upload a file containing javascript code to trigger XSS.

Impact

A user can steal cookies, deface a site, etc.

Step-by-step Reproduction Instructions

(1) Go to https://www.██████.mil/jppso/vendor/WFDPMMiscInvoicingDocuments.aspx (2) Fill out the form, upload a file, and add the file (3) Once the file is uploaded right click to get to the Developer Tools. (4) Inspect the page and find the path for the file -- █████\file.txt. For example, the file path for the file I uploaded is as follows: https://www.██████.mil/jppso/vendor/Data/cme1rjjcnjhnvdzhf5lgfbge-01192021-065856_testing-new.html (5) Observe that XSS is triggered.

Product, Version, and Configuration (If applicable)

https://www.████████.mil Tested in Firefox

Suggested Mitigation/Remediation Actions

Impact

Stored XSS exists at https://www.█████.mil. A user can fill out the form and upload a file containing javascript code to trigger XSS.

The original report as published on HackerOne, by 5050thepiguy. 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 file upload feature does not validate or sanitise uploaded files, allowing HTML or JavaScript content to be stored and later executed in a user's browser.

Impact

An attacker could steal cookies or deface the site, though the report does not demonstrate these actions beyond stating the possibility.

What the attacker needed

Access to the upload form; victim views the uploaded file

How it was found

  1. Go to the specified .mil file upload page.
  2. Fill out the form, upload a file, and add the file.
  3. Open the browser's Developer Tools and inspect the page to find the uploaded file's path.
  4. Observe that the JavaScript in the uploaded file executes.

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.

This report describes a stored cross-site scripting (XSS) bug. XSS happens when a website lets someone put harmful code (like JavaScript) into a page that other people later view, so the code runs in their browser. Here, the upload form accepted a file with JavaScript inside, and when the file was opened, the code ran.

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 5050thepiguy

View all

4 more disclosed reports, best first.

More from U.S. Dept Of Defense

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.