Agent: Improve log messages in RansomwarePayload.cleanup()

This commit is contained in:
Mike Salvatore 2021-11-30 11:34:45 -05:00
parent 62a6b09e00
commit 789a6691c1
1 changed files with 5 additions and 5 deletions

View File

@ -76,14 +76,14 @@ class RansomwarePayload:
def cleanup(self):
if self._readme_incomplete:
logger.info(
"README.txt file dropping was interrupted. Removing corrupt file and "
"trying again."
"The process of leaving a README.txt was interrupted. Removing the corrupt file "
"and trying again."
)
try:
self._readme_file_path.unlink()
self._leave_readme_in_target_directory()
except Exception as ex:
logger.info(
f"An exception occurred: {str(ex)}. README.txt file dropping was "
"unsuccessful."
logger.error(
"An error occurred while trying to remove the corrupt or incomplete README.txt "
f"file: {ex}"
)