From 771aa747a87af070a5227570c02d9ce71c782fa4 Mon Sep 17 00:00:00 2001 From: Mike Salvatore Date: Wed, 30 Jun 2021 06:53:27 -0400 Subject: [PATCH] Agent: encryption_enabled renamed using "private" naming convention --- monkey/infection_monkey/ransomware/ransomware_payload.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/monkey/infection_monkey/ransomware/ransomware_payload.py b/monkey/infection_monkey/ransomware/ransomware_payload.py index d252db389..6486fb4d8 100644 --- a/monkey/infection_monkey/ransomware/ransomware_payload.py +++ b/monkey/infection_monkey/ransomware/ransomware_payload.py @@ -21,8 +21,10 @@ README_DEST = "README.txt" class RansomwarePayload: def __init__(self, config: dict, telemetry_messenger: ITelemetryMessenger): - self.encryption_enabled = config["encryption"]["enabled"] - LOG.info(f"Encryption routine for ransomware simulation enabled: {self.encryption_enabled}") + self._encryption_enabled = config["encryption"]["enabled"] + LOG.info( + f"Encryption routine for ransomware simulation enabled: {self._encryption_enabled}" + ) target_directories = config["encryption"]["directories"] LOG.info( @@ -47,7 +49,7 @@ class RansomwarePayload: self._telemetry_messenger = telemetry_messenger def run_payload(self): - if self.encryption_enabled: + if self._encryption_enabled: LOG.info("Running ransomware payload") file_list = self._find_files() self._encrypt_files(file_list)