Class: Rex::Exploitation::OpcodeDb::Statistics

Inherits:
Object
  • Object
show all
Defined in:
lib/rex/exploitation/opcodedb.rb

Overview

Current statistics of the opcode database.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(hash) ⇒ Statistics

Returns a new instance of Statistics


464
465
466
467
468
469
470
471
472
473
474
# File 'lib/rex/exploitation/opcodedb.rb', line 464

def initialize(hash)
  @modules         = hash['modules'].to_i
  @opcodes         = hash['opcodes'].to_i
  @opcode_types    = hash['opcode_types'].to_i
  @platforms       = hash['platforms'].to_i
  @architectures   = hash['architectures'].to_i
  @module_segments = hash['module_segments'].to_i
  @module_imports  = hash['module_imports'].to_i
  @module_exports  = hash['module_exports'].to_i
  @last_update     = Time.at(hash['last_update'].to_i)
end

Instance Attribute Details

#architecturesObject (readonly)

The number of architectures supported by the database.


495
496
497
# File 'lib/rex/exploitation/opcodedb.rb', line 495

def architectures
  @architectures
end

#last_updateObject (readonly)

The time at which the last database update occurred.


511
512
513
# File 'lib/rex/exploitation/opcodedb.rb', line 511

def last_update
  @last_update
end

#module_exportsObject (readonly)

The number of module exports supported by the database.


507
508
509
# File 'lib/rex/exploitation/opcodedb.rb', line 507

def module_exports
  @module_exports
end

#module_importsObject (readonly)

The number of module imports supported by the database.


503
504
505
# File 'lib/rex/exploitation/opcodedb.rb', line 503

def module_imports
  @module_imports
end

#module_segmentsObject (readonly)

The number of module segments supported by the database.


499
500
501
# File 'lib/rex/exploitation/opcodedb.rb', line 499

def module_segments
  @module_segments
end

#modulesObject (readonly)

The number of modules found within the opcode database.


479
480
481
# File 'lib/rex/exploitation/opcodedb.rb', line 479

def modules
  @modules
end

#opcode_typesObject (readonly)

The number of opcode types supported by the database.


487
488
489
# File 'lib/rex/exploitation/opcodedb.rb', line 487

def opcode_types
  @opcode_types
end

#opcodesObject (readonly)

The number of opcodes supported by the opcode database.


483
484
485
# File 'lib/rex/exploitation/opcodedb.rb', line 483

def opcodes
  @opcodes
end

#platformsObject (readonly)

The number of platforms supported by the database.


491
492
493
# File 'lib/rex/exploitation/opcodedb.rb', line 491

def platforms
  @platforms
end