Class: Metasploit::Framework::Obfuscation::CRandomizer::CodeFactory::Printf

Inherits:
Base
  • Object
show all
Defined in:
lib/metasploit/framework/obfuscation/crandomizer/code_factory/printf.rb

Instance Attribute Summary

Attributes inherited from Base

#code, #dep

Instance Method Summary collapse

Methods inherited from Base

#good_dep?, #normalized_stub

Constructor Details

#initializePrintf

Returns a new instance of Printf.



11
12
13
14
# File 'lib/metasploit/framework/obfuscation/crandomizer/code_factory/printf.rb', line 11

def initialize
  super
  @dep = ['printf']
end

Instance Method Details

#stubObject



16
17
18
19
20
21
22
# File 'lib/metasploit/framework/obfuscation/crandomizer/code_factory/printf.rb', line 16

def stub
  %Q|
  int printf(const char*);
  void stub() {
    printf("#{Metasploit::Framework::Obfuscation::CRandomizer::Utility.rand_string}");
  }|
end