mythril.plugin package
Submodules
mythril.plugin.discovery module
- class mythril.plugin.discovery.PluginDiscovery(*args, **kwargs)[source]
Bases:
object
PluginDiscovery class
This plugin implements the logic to discover and build plugins in installed python packages
- build_plugin(plugin_name: str, plugin_args: Dict) MythrilPlugin [source]
Returns the plugin for the given plugin_name if it is installed
- get_plugins(default_enabled=None) List[str] [source]
Gets a list of installed mythril plugins
- Parameters:
default_enabled – Select plugins that are enabled by default
- Returns:
List of plugin names
- property installed_plugins
mythril.plugin.interface module
- class mythril.plugin.interface.MythrilCLIPlugin(**kwargs)[source]
Bases:
MythrilPlugin
MythrilCLIPlugin interface
This interface should be implemented by mythril plugins that aim to add commands to the mythril cli
- class mythril.plugin.interface.MythrilLaserPlugin(**kwargs)[source]
Bases:
MythrilPlugin
,PluginBuilder
,ABC
Mythril Laser Plugin interface
Plugins of this type are used to instrument the laser EVM
- class mythril.plugin.interface.MythrilPlugin(**kwargs)[source]
Bases:
object
MythrilPlugin interface
Mythril Plugins can be used to extend Mythril in different ways: 1. Extend Laser, in which case the LaserPlugin interface must also be extended 2. Extend Laser with a new search strategy in which case the SearchStrategy needs to be implemented 3. Add an analysis module, in this case the AnalysisModule interface needs to be implemented 4. Add new commands to the Mythril cli, using the MythrilCLIPlugin Interface
- author = 'Default Author'
- name = 'Plugin Name'
- plugin_description = 'This is an example plugin description'
- plugin_license = 'All rights reserved.'
- plugin_type = 'Mythril Plugin'
- plugin_version = '0.0.1 '
mythril.plugin.loader module
- class mythril.plugin.loader.MythrilPluginLoader(*args, **kwargs)[source]
Bases:
object
MythrilPluginLoader singleton
This object permits loading MythrilPlugin’s
- load(plugin: MythrilPlugin)[source]
Loads the passed plugin
This function handles input validation and dispatches loading to type specific loaders. Supported plugin types:
laser plugins
detection modules