forked from p15670423/monkey
Agent: encryption_enabled renamed using "private" naming convention
This commit is contained in:
parent
aecb80566b
commit
771aa747a8
|
@ -21,8 +21,10 @@ README_DEST = "README.txt"
|
||||||
|
|
||||||
class RansomwarePayload:
|
class RansomwarePayload:
|
||||||
def __init__(self, config: dict, telemetry_messenger: ITelemetryMessenger):
|
def __init__(self, config: dict, telemetry_messenger: ITelemetryMessenger):
|
||||||
self.encryption_enabled = config["encryption"]["enabled"]
|
self._encryption_enabled = config["encryption"]["enabled"]
|
||||||
LOG.info(f"Encryption routine for ransomware simulation enabled: {self.encryption_enabled}")
|
LOG.info(
|
||||||
|
f"Encryption routine for ransomware simulation enabled: {self._encryption_enabled}"
|
||||||
|
)
|
||||||
|
|
||||||
target_directories = config["encryption"]["directories"]
|
target_directories = config["encryption"]["directories"]
|
||||||
LOG.info(
|
LOG.info(
|
||||||
|
@ -47,7 +49,7 @@ class RansomwarePayload:
|
||||||
self._telemetry_messenger = telemetry_messenger
|
self._telemetry_messenger = telemetry_messenger
|
||||||
|
|
||||||
def run_payload(self):
|
def run_payload(self):
|
||||||
if self.encryption_enabled:
|
if self._encryption_enabled:
|
||||||
LOG.info("Running ransomware payload")
|
LOG.info("Running ransomware payload")
|
||||||
file_list = self._find_files()
|
file_list = self._find_files()
|
||||||
self._encrypt_files(file_list)
|
self._encrypt_files(file_list)
|
||||||
|
|
Loading…
Reference in New Issue