Agent: Update propagation tags for log4shell

This commit is contained in:
Kekoa Kaaikala 2022-10-05 12:48:16 +00:00 committed by Ilija Lazoroski
parent ac69064dec
commit 48e6e95271
1 changed files with 3 additions and 2 deletions

View File

@ -4,7 +4,7 @@ from pathlib import PurePath
from common import OperatingSystem from common import OperatingSystem
from common.common_consts.timeouts import LONG_REQUEST_TIMEOUT, MEDIUM_REQUEST_TIMEOUT from common.common_consts.timeouts import LONG_REQUEST_TIMEOUT, MEDIUM_REQUEST_TIMEOUT
from common.tags import T1203_ATTACK_TECHNIQUE_TAG from common.tags import T1105_ATTACK_TECHNIQUE_TAG, T1203_ATTACK_TECHNIQUE_TAG
from common.utils import Timer from common.utils import Timer
from infection_monkey.exploit.log4shell_utils import ( from infection_monkey.exploit.log4shell_utils import (
LINUX_EXPLOIT_TEMPLATE_PATH, LINUX_EXPLOIT_TEMPLATE_PATH,
@ -28,6 +28,7 @@ from infection_monkey.utils.threading import interruptible_iter
logger = logging.getLogger(__name__) logger = logging.getLogger(__name__)
LOG4SHELL_EXPLOITER_TAG = "log4shell-exploiter" LOG4SHELL_EXPLOITER_TAG = "log4shell-exploiter"
PROPAGATION_TAGS = (LOG4SHELL_EXPLOITER_TAG, T1203_ATTACK_TECHNIQUE_TAG, T1105_ATTACK_TECHNIQUE_TAG)
class Log4ShellExploiter(WebRCE): class Log4ShellExploiter(WebRCE):
@ -218,7 +219,7 @@ class Log4ShellExploiter(WebRCE):
self._publish_propagation_event( self._publish_propagation_event(
target=self.host.ip_addr, target=self.host.ip_addr,
propagation_success=True, propagation_success=True,
tags=(LOG4SHELL_EXPLOITER_TAG, T1203_ATTACK_TECHNIQUE_TAG), tags=PROPAGATION_TAGS,
) )
self.exploit_result.propagation_success = True self.exploit_result.propagation_success = True
break break