Auditing - Ensure Mailbox Auditing For All Users Is Enabled

 








Summary

Enabling mailbox auditing will help the Microsoft 365 back office teams in tracking logons to a mailbox as well as the actions taken while the user is logged on. When the mailbox audit logging is turned on for a mailbox, it will allow to search the audit log for mailbox activity, along with the additional actions performed by administrators, delegates, and owners logged by default.

Reason

By default, Microsoft has turned on mailbox audit logging since January, 2019, for all organizations, which means that certain actions performed by mailbox owners, delegates, and admins are automatically logged, and the corresponding mailbox audit records will be available for search in the mailbox audit log. Also after turning on this setting, the AuditEnabled property for affected mailboxes won't be changed from False to True; i.e., it ignores the AuditEnabled property on mailboxes. However, only certain mailbox types support default auditing On
  • User Mailboxes
  • Shared Mailboxes
  • Microsoft 365 Group Mailboxes

However, the remaining mailbox types require auditing be turned on at the mailbox level-
  • Resource Mailboxes
  • Public Folder Mailboxes
  • DiscoverySearch Mailboxes                                                                                                             
Whether it is for regulatory compliance or for tracking unauthorized configuration changes in Microsoft 365, enabling mailbox auditing allows for Microsoft 365 back office teams to run security operations, forensics or general investigations on mailbox activities.

Note- Without advanced auditing (E5 function) the logs are limited to 90 days.                                                                                                                                                       

 How to?

To enable mailbox auditing for all users, use the Exchange Online PowerShell Module:
  1. Run Microsoft Exchange Online PowerShell Module.
  2. Connect using Connect-ExchangeOnline.
  3. Run the following PowerShell commands-
$AuditAdmin = @ ("Copy", "Create", "FolderBind", "HardDelete", "MessageBind", "Move", "MoveToDeletedItems", "SendAs", "SendOnBehalf", "SoftDelete", "Update", "UpdateCalendarDelegation", "UpdateFolderPermissions", "UpdateInboxRules")

$AuditDelegate =
@ ("Create", "FolderBind", "HardDelete", "Move", "MoveToDeletedItems", "SendAs", "SendOnBehalf", "SoftDelete", "Update", " UpdateFolderPermissions", "UpdateInboxRules")

$AdminOwner =
@ ("Create", "HardDelete", "MailBoxLogin", "Move", "MoveToDeletedItems", "SoftDelete", "Update", "UpdateCalendarDelegation", "UpdateFolderPermissions", "UpdateInboxRules")

Get-Mailbox -ResultSize Unlimited | Set-Mailbox -AuditEnabled $true - AuditLogAgeLimit 180 -AuditAdmin $AuditAdmin -AuditDelegate $AuditDelegate -AuditOwner $AuditOwner

Monitor:

To verify mailbox auditing is enabled by default, use the Exchange Online PowerShell Module:
  1. Run Microsoft Exchange Online PowerShell Module.
  2. Connect using Connect-ExchangeOnline.
  3. Run the following PowerShell commands-

Get-OrganizationConfig | Format-List AuditDisabled

      4. Verify AuditDisabled is set to False.

To verify mailbox auditing is enabled for all mailboxes that do not support default auditing, use the Exchange Online PowerShell Module:
  1. Run Microsoft Exchange Online PowerShell Module.
  2. Connect using Connect-ExchangeOnline.
  3. Run the following PowerShell commands-

    Get-Mailbox -ResultSize Unlimited | Where-Object {$_.AuditEnabled -ne $true - and ($_.RecipientTypeDetails -ne "Usermailbox" -or $_.RecipientTypeDetails -ne "SharedMailbox")}
Alternatively, you can also run this command-

  Get-Mailbox | Where AuditEnabled -Match 'False' | select UserPrincipalName, auditenabled

      3. Verify AuditEnabled  is set to True for all mailboxes that are not a user, shared, or group mailbox.


































Comments

Popular posts from this blog

Deployment (Part 3)

Project Resourcing (Part 2)

Design Planning (Part 3)