mirror of
https://github.com/jayateertha043/goshod.git
synced 2026-07-21 20:11:02 +00:00
25 lines
No EOL
743 B
JavaScript
25 lines
No EOL
743 B
JavaScript
function shodanSearch(){
|
|
|
|
searchbar = document.getElementById("search").value;
|
|
search = document.getElementById("search").value;
|
|
console.log("Executing shodanSearch ...")
|
|
console.log(searchbar)
|
|
|
|
|
|
var xhttp = new XMLHttpRequest();
|
|
var url = '/shodansearch';
|
|
|
|
xhttp.open("POST", url, true);
|
|
xhttp.setRequestHeader('Content-Type', 'application/x-www-form-urlencoded');
|
|
var response_body="";
|
|
xhttp.onreadystatechange = function() {
|
|
if (this.readyState == 4 && this.status == 200) {
|
|
// Typical action to be performed when the document is ready:
|
|
response_body = xhttp.responseText
|
|
console.log(response_body);
|
|
}
|
|
};
|
|
xhttp.send("search="+search);
|
|
|
|
|
|
} |