Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
beefproject
GitHub Repository: beefproject/beef
Path: blob/master/modules/ipec/inter_protocol_redis/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
class Inter_protocol_redis < BeEF::Core::Command
7
def self.options
8
cmd = 'set server:name "BeEF says:\\\\nm00!"\\nquit\\n'
9
[
10
{ 'name' => 'rhost', 'ui_label' => 'Target Address', 'value' => '127.0.0.1' },
11
{ 'name' => 'rport', 'ui_label' => 'Target Port', 'value' => '6379' },
12
{ 'name' => 'timeout', 'ui_label' => 'Timeout (s)', 'value' => '15' },
13
{ 'name' => 'commands', 'ui_label' => 'Redis commands', 'description' => "Enter Redis commands to execute. Note: Use '\\n' to seperate Redis commands and '\\\\n' for new lines.",
14
'type' => 'textarea', 'value' => cmd, 'width' => '200px' }
15
]
16
end
17
18
def post_execute
19
content = {}
20
content['result'] = @datastore['result'] unless @datastore['result'].nil?
21
content['fail'] = @datastore['fail'] unless @datastore['fail'].nil?
22
save content
23
end
24
end
25
26