{"id":62,"date":"2021-04-30T01:21:00","date_gmt":"2021-04-29T18:21:00","guid":{"rendered":"https:\/\/n45ht.or.id\/blog\/?p=62"},"modified":"2024-12-14T01:26:23","modified_gmt":"2024-12-13T18:26:23","slug":"reflected-dom-based-xss-on-domainesia","status":"publish","type":"post","link":"https:\/\/n45ht.or.id\/blog\/reflected-dom-based-xss-on-domainesia\/","title":{"rendered":"Reflected DOM-based XSS on DomaiNesia"},"content":{"rendered":"\n<p>In this article, I\u2019ll walk you through how I discovered a <strong>Reflected DOM-based Cross-site Scripting (XSS)<\/strong> vulnerability on the <strong>DomaiNesia<\/strong> website using <strong>BurpSuite<\/strong>. DOM-based XSS vulnerabilities occur when malicious scripts are executed as a result of user input being reflected directly in the Document Object Model (DOM) without proper sanitization or escaping.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Step 1: Scanning the Target<\/h3>\n\n\n\n<p>To begin, I opened <strong>BurpSuite<\/strong> and configured it to scan the <strong>DomaiNesia<\/strong> website. BurpSuite is a powerful web vulnerability scanner that helps identify potential security issues on web applications. I started by navigating to the Burp Scanner tab and running a scan on the target domain: <code>domainesia.com<\/code>.<\/p>\n\n\n\n<p><strong>Initial Scan:<\/strong> After a few moments of scanning, BurpSuite displayed an alert showing a potential <strong>Cross-site Scripting (XSS)<\/strong> vulnerability on the website.<\/p>\n\n\n\n<figure class=\"wp-block-image aligncenter size-full is-resized\"><img loading=\"lazy\" decoding=\"async\" width=\"739\" height=\"672\" src=\"https:\/\/n45ht.or.id\/blog\/wp-content\/uploads\/2024\/12\/writeup-domainesia1-1.png\" alt=\"\" class=\"wp-image-64\" style=\"width:564px;height:auto\" srcset=\"https:\/\/n45ht.or.id\/blog\/wp-content\/uploads\/2024\/12\/writeup-domainesia1-1.png 739w, https:\/\/n45ht.or.id\/blog\/wp-content\/uploads\/2024\/12\/writeup-domainesia1-1-300x273.png 300w\" sizes=\"auto, (max-width: 739px) 100vw, 739px\" \/><\/figure>\n\n\n\n<h3 class=\"wp-block-heading\">Step 2: Reviewing the XSS Vulnerability<\/h3>\n\n\n\n<p>BurpSuite\u2019s scanner provided detailed information about the vulnerability, including the affected page and the nature of the XSS issue. The vulnerability was identified as a <strong>Reflected DOM-based XSS<\/strong>, meaning that user input (such as URL parameters) was being reflected in the page&#8217;s DOM and executed as JavaScript without being properly sanitized.<\/p>\n\n\n\n<figure class=\"wp-block-image aligncenter size-full is-resized\"><img loading=\"lazy\" decoding=\"async\" width=\"608\" height=\"626\" src=\"https:\/\/n45ht.or.id\/blog\/wp-content\/uploads\/2024\/12\/writeup-domainesia1-2.png\" alt=\"\" class=\"wp-image-65\" style=\"width:562px;height:auto\" srcset=\"https:\/\/n45ht.or.id\/blog\/wp-content\/uploads\/2024\/12\/writeup-domainesia1-2.png 608w, https:\/\/n45ht.or.id\/blog\/wp-content\/uploads\/2024\/12\/writeup-domainesia1-2-291x300.png 291w\" sizes=\"auto, (max-width: 608px) 100vw, 608px\" \/><\/figure>\n\n\n\n<h3 class=\"wp-block-heading\">Step 3: Server Response<\/h3>\n\n\n\n<p>Here\u2019s the response I received from the DomaiNesia server. It confirmed that user input was being reflected back to the browser without proper escaping or validation, creating the opportunity for XSS attacks.<\/p>\n\n\n\n<figure class=\"wp-block-image aligncenter size-full is-resized\"><img loading=\"lazy\" decoding=\"async\" width=\"607\" height=\"322\" src=\"https:\/\/n45ht.or.id\/blog\/wp-content\/uploads\/2024\/12\/writeup-domainesia1-3.png\" alt=\"\" class=\"wp-image-66\" style=\"width:551px;height:auto\" srcset=\"https:\/\/n45ht.or.id\/blog\/wp-content\/uploads\/2024\/12\/writeup-domainesia1-3.png 607w, https:\/\/n45ht.or.id\/blog\/wp-content\/uploads\/2024\/12\/writeup-domainesia1-3-300x159.png 300w\" sizes=\"auto, (max-width: 607px) 100vw, 607px\" \/><\/figure>\n\n\n\n<h3 class=\"wp-block-heading\">Step 4: Testing the Vulnerability<\/h3>\n\n\n\n<p>To test the vulnerability further, I opened the URL directly in my browser. This helped me confirm that the XSS was indeed reflected in the DOM when the page was loaded with a malicious payload in the URL. This means that any user who visits the URL with the payload could have JavaScript executed in their browser, potentially leading to session hijacking, phishing attacks, or data exfiltration.<\/p>\n\n\n\n<figure class=\"wp-block-image aligncenter size-full is-resized\"><img loading=\"lazy\" decoding=\"async\" width=\"1014\" height=\"588\" src=\"https:\/\/n45ht.or.id\/blog\/wp-content\/uploads\/2024\/12\/writeup-domainesia1-4.png\" alt=\"\" class=\"wp-image-67\" style=\"width:542px;height:auto\" srcset=\"https:\/\/n45ht.or.id\/blog\/wp-content\/uploads\/2024\/12\/writeup-domainesia1-4.png 1014w, https:\/\/n45ht.or.id\/blog\/wp-content\/uploads\/2024\/12\/writeup-domainesia1-4-300x174.png 300w, https:\/\/n45ht.or.id\/blog\/wp-content\/uploads\/2024\/12\/writeup-domainesia1-4-768x445.png 768w\" sizes=\"auto, (max-width: 1014px) 100vw, 1014px\" \/><\/figure>\n\n\n\n<p>By using BurpSuite\u2019s scanning features and manually validating the response, I was able to identify and confirm the <strong>Reflected DOM-based XSS vulnerability<\/strong> on DomaiNesia. This type of vulnerability is critical because it allows attackers to inject arbitrary JavaScript into a page, which can then be executed in the context of other users&#8217; browsers.<\/p>\n\n\n\n<p>I have reported the issue to the DomaiNesia team, and I hope they address it promptly to improve the security of their platform.<\/p>\n\n\n\n<p>#HappyHacking<\/p>\n","protected":false},"excerpt":{"rendered":"<p>In this article, I\u2019ll walk you through how I discovered a Reflected DOM-based Cross-site Scripting (XSS) vulnerability on the DomaiNesia website using BurpSuite. DOM-based XSS vulnerabilities occur when malicious scripts are executed as a result of user input being reflected directly in the Document Object Model (DOM) without proper sanitization or escaping. Step 1: Scanning [&hellip;]<\/p>\n","protected":false},"author":3,"featured_media":63,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[21],"tags":[23,9,8],"class_list":["post-62","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-research","tag-bug-bounty","tag-cross-site-scripting","tag-xss"],"_links":{"self":[{"href":"https:\/\/n45ht.or.id\/blog\/wp-json\/wp\/v2\/posts\/62","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/n45ht.or.id\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/n45ht.or.id\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/n45ht.or.id\/blog\/wp-json\/wp\/v2\/users\/3"}],"replies":[{"embeddable":true,"href":"https:\/\/n45ht.or.id\/blog\/wp-json\/wp\/v2\/comments?post=62"}],"version-history":[{"count":1,"href":"https:\/\/n45ht.or.id\/blog\/wp-json\/wp\/v2\/posts\/62\/revisions"}],"predecessor-version":[{"id":68,"href":"https:\/\/n45ht.or.id\/blog\/wp-json\/wp\/v2\/posts\/62\/revisions\/68"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/n45ht.or.id\/blog\/wp-json\/wp\/v2\/media\/63"}],"wp:attachment":[{"href":"https:\/\/n45ht.or.id\/blog\/wp-json\/wp\/v2\/media?parent=62"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/n45ht.or.id\/blog\/wp-json\/wp\/v2\/categories?post=62"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/n45ht.or.id\/blog\/wp-json\/wp\/v2\/tags?post=62"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}