CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutSign UpSign In
rapid7

Real-time collaboration for Jupyter Notebooks, Linux Terminals, LaTeX, VS Code, R IDE, and more,
all in one place.

GitHub Repository: rapid7/metasploit-framework
Path: blob/master/modules/nops/cmd/generic.rb
Views: 11780
1
##
2
# This module requires Metasploit: https://metasploit.com/download
3
# Current source: https://github.com/rapid7/metasploit-framework
4
##
5
6
class MetasploitModule < Msf::Nop
7
def initialize
8
super(
9
'Name' => 'Generic Command Nop Generator',
10
'Alias' => 'cmd_generic',
11
'Description' => 'Generates harmless padding for command payloads.',
12
'Author' => ['hdm', 'bcoles'],
13
'License' => MSF_LICENSE,
14
'Arch' => ARCH_CMD)
15
end
16
17
# Generate valid commands up to the requested length
18
def generate_sled(length, _opts = {})
19
# Default to just spaces for now
20
' ' * length
21
end
22
end
23
24