Skip to content

Commit 33aa8d1

Browse files
committed
Agent: Skip ransomware payload if monkey has been killed
1 parent 57d97d0 commit 33aa8d1

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

monkey/infection_monkey/monkey.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -156,7 +156,8 @@ def start(self):
156156
LOG.info("Maximum propagation depth has been reached; monkey will not propagate.")
157157
TraceTelem(MAX_DEPTH_REACHED_MESSAGE).send()
158158

159-
InfectionMonkey.run_ransomware()
159+
if self._keep_running and WormConfiguration.alive:
160+
InfectionMonkey.run_ransomware()
160161

161162
# if host was exploited, before continue to closing the tunnel ensure the exploited
162163
# host had its chance to

0 commit comments

Comments
 (0)