Path: blob/master/lib/msf/util/exe/linux/x64.rb
57477 views
# -*- coding: binary -*-1module Msf::Util::EXE::Linux::X642include Msf::Util::EXE::Linux::Common34def self.included(base)5base.extend(ClassMethods)6end78module ClassMethods910# Create a 64-bit Linux ELF containing the payload provided in +code+11# to_linux_x64_elf12#13# @param framework [Msf::Framework]14# @param code [String]15# @param opts [Hash]16# @option [String] :template17# @return [String] Returns an elf18def to_linux_x64_elf(framework, code, opts = {})19Msf::Util::EXE::Common.to_exe_elf(framework, opts, "template_x64_linux.bin", code)20end2122# Create a 64-bit Linux ELF_DYN containing the payload provided in +code+23# to_linux_x64_elf_dll24#25# @param framework [Msf::Framework]26# @param code [String]27# @param opts [Hash]28# @option [String] :template29# @return [String] Returns an elf30def to_linux_x64_elf_dll(framework, code, opts = {})31Msf::Util::EXE::Common.to_exe_elf(framework, opts, "template_x64_linux_dll.bin", code)32end3334# Create a 64-bit Linux ELF containing the payload provided in +code+35# to_linux_x64_elf36#37# @param framework [Msf::Framework]38# @param code [String]39# @param opts [Hash]40# @option [String] :template41# @return [String] Returns an elf42def to_linux_x64_elf(framework, code, opts = {})43to_exe_elf(framework, opts, "template_x64_linux.bin", code)44end45end4647class << self48include ClassMethods49end50end515253