diff --git a/app/Config/config.default.php b/app/Config/config.default.php index a31e947f8..65c50e99a 100644 --- a/app/Config/config.default.php +++ b/app/Config/config.default.php @@ -16,6 +16,10 @@ $config = array( 'footermidright' => '', 'org' => 'ORGNAME', 'showorg' => true, + 'threatlevel_in_email_subject' => true, + 'email_subject_TLP_string' => 'TLP Amber', + 'email_subject_tag' => 'tlp', + 'email_subject_include_tag_name' => true, 'background_jobs' => true, 'cached_attachments' => true, 'email' => 'email@address.com', diff --git a/app/Model/Event.php b/app/Model/Event.php index 0c61c057b..eb484f4da 100644 --- a/app/Model/Event.php +++ b/app/Model/Event.php @@ -1617,7 +1617,11 @@ class Event extends AppModel { break; } } - $subject = "[" . Configure::read('MISP.org') . " MISP] Event " . $id . " - " . $subject . $event[0]['ThreatLevel']['name'] . " - ".$subjMarkingString; + $threatLevel = $event[0]['ThreatLevel']['name'] . " - "; + if(Configure::read('MISP.threatlevel_in_email_subject') === false) { + $threatLevel = ''; + } + $subject = "[" . Configure::read('MISP.org') . " MISP] Event " . $id . " - " . $subject . $threatLevel . $subjMarkingString; // Initialise the Job class if we have a background process ID // This will keep updating the process's progress bar diff --git a/app/Model/Server.php b/app/Model/Server.php index 1c8d9f725..d1c4fdfd4 100644 --- a/app/Model/Server.php +++ b/app/Model/Server.php @@ -265,6 +265,14 @@ class Server extends AppModel { 'test' => 'testBool', 'type' => 'boolean', ), + 'threatlevel_in_email_subject' => array( + 'level' => 2, + 'description' => 'Put the event threat level in the notification E-mail subject.', + 'value' => true, + 'errorMessage' => '', + 'test' => 'testBool', + 'type' => 'boolean', + ), 'email_subject_TLP_string' => array( 'level' => 2, 'description' => 'This is the TLP string for e-mails when email_subject_tag is not found.', diff --git a/app/files/taxonomies b/app/files/taxonomies index 1d957da22..40d96b6f2 160000 --- a/app/files/taxonomies +++ b/app/files/taxonomies @@ -1 +1 @@ -Subproject commit 1d957da2245203f9fa9f4d01b71d6f62c11b4442 +Subproject commit 40d96b6f2d19afc74eeb0ee3b10bd6a0b76da5fe