From 179ed52089f6de511fd752086f9185479e46f390 Mon Sep 17 00:00:00 2001 From: Mike Salvatore Date: Tue, 12 Sep 2023 14:03:04 -0400 Subject: [PATCH] Common: Allow '.' characters in Event tags The MITRE ATT&CK framework identifies subtechniques by using a '.' to separate the technique ID from the subtechnique ID. For example, the technique "Defacement" has the ID T1491, whereas the subtechnique "Internal Defacement" has the ID T1491.001. Allowing '.' characters in tags allows us to specify MITRE ATT&CK subtechniques without performing any translation. PR #3676 --- CHANGELOG.md | 2 +- monkey/common/agent_events/abstract_agent_event.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 4e39e38d58b..da90fdbdc1d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -23,7 +23,7 @@ Changelog](https://keepachangelog.com/en/1.0.0/). ### Changed - Plugin source is now gzipped. #3392 -- Allowed characters in Agent event tags. #3399 +- Allowed characters in Agent event tags. #3399, #3676 - Hard-coded Log4Shell exploiter to a plugin. #3388 - Hard-coded SSH exploiter to a plugin. #3170 - Identities and secrets can be associated when configuring credentials in the diff --git a/monkey/common/agent_events/abstract_agent_event.py b/monkey/common/agent_events/abstract_agent_event.py index 99b2deff5ec..1ee2c7deeec 100644 --- a/monkey/common/agent_events/abstract_agent_event.py +++ b/monkey/common/agent_events/abstract_agent_event.py @@ -8,7 +8,7 @@ from common.base_models import InfectionMonkeyBaseModel, InfectionMonkeyModelConfig from common.types import AgentID, MachineID -EVENT_TAG_REGEX = r"^[a-zA-Z0-9_-]+$" +EVENT_TAG_REGEX = r"^[a-zA-Z0-9._-]+$" class AgentEventTag(ConstrainedStr):