Skip to content
XSS Write-up Intermediate

How Was My First Web Application Penetration Test

The web application had weak TLS configurations, session management flaws, and a stored XSS vulnerability that could be triggered by bypassing a crash with Unicode encoding. An attacker could exploit these to hijack sessions or execute scripts in victims' browsers.

Mattia Zignale Follow

Published on infosecwriteups.com

A while ago a client of mine asked for a WAPT (Web Application Penetration Test) for his company; the web application was built in Microsoft environment, so with all the ASP.NET and .NET framework stuffs that Linux boys always pass: this was the first real WAPT I have ever done.

Mattia Zignale, on infosecwriteups.com

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.

Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.

How it worked

Root cause

Likely the application failed to properly encode user input and used outdated TLS configurations, while also mishandling password fields and session tokens.

Impact

An attacker could execute arbitrary scripts in victims' browsers via stored XSS, potentially leading to session hijacking, and could exploit weak TLS to intercept communications.

What the attacker needed

Admin account for internal testing; victim interacts with stored XSS payload

The fix

The report recommends disabling SSLv3 and TLS 1.0/1.1, using secure cipher suites, properly managing sessions, fixing the password input handling, and implementing proper encoding and exception handling to prevent XSS.

How it was found

  1. Performed DNS lookup and NMAP scan to gather information about the target.
  2. Ran an SSL scan and found SSLv3, TLSv1.0, and weak cipher suites enabled.
  3. Analysed the HTML and found vulnerable or unmaintained JavaScript libraries.
  4. Tested the login form and found session ID not refreshed, cookies valid after logout, and password input type was text.
  5. Tried a simple XSS payload which caused a crash revealing framework version and stack trace.
  6. Bypassed the crash using Unicode encoding and achieved stored XSS.

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 write-up has not been written yet. The Original tab links to the source.

This is a story about a penetration test where the tester found several security problems. The most serious was a cross-site scripting (XSS) bug, which lets an attacker run their own code in another user's browser. The tester also found that the login page handled passwords badly and that old, insecure encryption was still enabled.

What is XSS?

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

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.