Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
rapid7
GitHub Repository: rapid7/metasploit-framework
Path: blob/master/lib/msf/util/exe/bsd/x64.rb
57477 views
1
# -*- coding: binary -*-
2
module Msf::Util::EXE::Bsd::X64
3
include Msf::Util::EXE::Common
4
5
def self.included(base)
6
base.extend(ClassMethods)
7
end
8
9
module ClassMethods
10
# Create a 64-bit Linux ELF containing the payload provided in +code+
11
#
12
# @param framework [Msf::Framework]
13
# @param code [String]
14
# @param opts [Hash]
15
# @option [String] :template
16
# @return [String] Returns an elf
17
def to_bsd_x64_elf(framework, code, opts = {})
18
to_exe_elf(framework, opts, "template_x64_bsd.bin", code)
19
end
20
end
21
22
class << self
23
include ClassMethods
24
end
25
end
26
27