
Research
Two Malicious Rust Crates Impersonate Popular Logger to Steal Wallet Keys
Socket uncovers malicious Rust crates impersonating fast_log to steal Solana and Ethereum wallet keys from source code.
simple-plugin-loader
Advanced tools
This module provides a simple way to dynamically load other Python modules as Plugins to your current project.
You can install this python module via pip:
pip install simple-plugin-loader
Otherwise the module can be downloaded from PyPI: https://pypi.org/project/simple-plugin-loader/
from simple_plugin_loader import Loader
# initialize the loader
loader = Loader()
# load your plugins
plugins = loader.load_plugins(<plugin_path>, <plugin_base_class>, <specific_plugins>, <recursive>)
plugins
property of the loader instance:
plugins = loader.plugins
load_plugins(...)
MethodThis method does the actual plugin loading.
It loads only Python modules that can be executed in the current environment. For every successfully loaded module a message is populated through the Python logging
library (log level: INFO
).
If a module e.g. contains syntax errors or depends on other not installed Python modules, it will be skipped. So the main program does not fail completely. An error message is populated through the Python logging
library (log level: ERROR
).
<plugin_path>
: str<plugin_base_class>
: class (Default: SamplePlugin
)SamplePlugin
class. You can use this class as the base class for your plugins:
from simple_plugin_loader.sample_plugin import SamplePlugin
class YourPlugin(SamplePlugin):
pass
<specific_plugins>
: List[str] (Default: []
)<plugin_base_class>
will also be ignored, so any class can be loaded.<recursive>
: bool (Default: False
)True
if you wish to load plugins/modules recursively to the above directory.The method returns a dictionary that has the following structure:
FAQs
Dynamically load other python modules to your project.
We found that simple-plugin-loader demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Socket uncovers malicious Rust crates impersonating fast_log to steal Solana and Ethereum wallet keys from source code.
Research
A malicious package uses a QR code as steganography in an innovative technique.
Research
/Security News
Socket identified 80 fake candidates targeting engineering roles, including suspected North Korean operators, exposing the new reality of hiring as a security function.