Skip to main content
Version: 2.1.1-preview

DPDP.Sec.08.19 - Ensure Safe Attachments ATP policy is active to block zero-day malicious payloads

Overview

2.1.4 (L2) Ensure Safe Attachments policy is enabled

The Safe Attachments policy helps protect users from malware in email attachments by scanning attachments for viruses, malware, and other malicious content. When an email attachment is received by a user, Safe Attachments will scan the attachment in a secure environment and provide a verdict on whether the attachment is safe or not.

Rationale

Enabling Safe Attachments policy helps protect against malware threats in email attachments by analyzing suspicious attachments in a secure, cloud-based environment before they are delivered to the user's inbox. This provides an additional layer of security and can prevent new or unseen types of malware from infiltrating the organization's network.

Impact

Delivery of email with attachments may be delayed while scanning is occurring

Remediation action:

To enable the Safe Attachments policy:

  1. Navigate to Microsoft 365 Defender.
  2. Click to expand E-mail & Collaboration select Policies & rules.
  3. On the Policies & rules page select Threat policies.
  4. Under Policies select Safe Attachments.
  5. Click + Create.
  6. Create a Policy Name and Description, and then click Next.
  7. Select all valid domains and click Next.
  8. Select Block.
  9. Quarantine policy is AdminOnlyAccessPolicy.
  10. Leave Enable redirect unchecked.
  11. Click Next and finally Submit.
PowerShell
  1. Connect to Exchange Online using Connect-ExchangeOnline.
  2. To change an existing policy modify the example below and run the following PowerShell command:
Set-SafeAttachmentPolicy -Identity 'Example policy' -Action 'Block' -QuarantineTag 'AdminOnlyAccessPolicy' -Enable $true
  1. Or, edit and run the below example to create a new safe attachments policy.
New-SafeAttachmentPolicy -Name "CIS 2.1.4" -Enable $true -Action 'Block' -QuarantineTag 'AdminOnlyAccessPolicy'

New-SafeAttachmentRule -Name "CIS 2.1.4 Rule" -SafeAttachmentPolicy "CIS 2.1.4" -RecipientDomainIs 'exampledomain[.]com'

Note: Policy targets such as users and domains should include domains, or groups that provide coverage for a majority of users in the organization. Different inclusion and exclusion use cases are not covered in the benchmark.

Test Metadata

FieldValue
Test IDDPDP.Sec.08.19
SeverityUnknown
SuiteDPDP Act 2023
CategoryGeneral
PowerShell testTest-MtCisSafeAttachment
TagsDPDP, DPDP.Sec.08, DPDP.Sec.08.19, DPDP2023

Source

  • Pester test: tests/dpdp/Test-MtDpdp-MailAndThreatProtection.Tests.ps1
  • PowerShell source: powershell/public/cis/Test-MtCisSafeAttachment.ps1