Real-time collaboration for Jupyter Notebooks, Linux Terminals, LaTeX, VS Code, R IDE, and more,
all in one place.
Real-time collaboration for Jupyter Notebooks, Linux Terminals, LaTeX, VS Code, R IDE, and more,
all in one place.
Path: blob/master/lib/msf/base/simple/statistics.rb
Views: 11623
# -*- coding: binary -*-1module Msf2module Simple34###5#6# This class provides an interface to various statistics about the7# framework instance.8#9###10class Statistics11include Msf::Framework::Offspring1213#14# Initializes the framework statistics.15#16def initialize(framework)17self.framework = framework18Msf::Modules::Metadata::Cache.instance.update_stats19end2021#22# Returns the number of encoders in the framework.23#24def num_encoders25Msf::Modules::Metadata::Cache.instance.module_counts[:encoder]26end2728#29# Returns the number of exploits in the framework.30#31def num_exploits32Msf::Modules::Metadata::Cache.instance.module_counts[:exploit]33end3435#36# Returns the number of NOP generators in the framework.37#38def num_nops39Msf::Modules::Metadata::Cache.instance.module_counts[:nop]40end4142#43# Returns the number of payloads in the framework.44#45def num_payloads46Msf::Modules::Metadata::Cache.instance.module_counts[:payload]47end4849#50# Returns the number of auxiliary modules in the framework.51#52def num_auxiliary53Msf::Modules::Metadata::Cache.instance.module_counts[:auxiliary]54end5556#57# Returns the number of post modules in the framework.58#59def num_post60Msf::Modules::Metadata::Cache.instance.module_counts[:post]61end6263def num_evasion64Msf::Modules::Metadata::Cache.instance.module_counts[:evasion]65end66end6768end69end707172