LoFP LoFP / email forwarding may be configured for legitimate purposes, filter as needed.

Techniques

Sample rules

O365 Mailbox Email Forwarding Enabled

Description

This detection is designed to identify instances where email forwarding has been enabled on mailboxes within an Office 365 environment. By monitoring for the specific operation Set-Mailbox within the o365_management_activity logs, this analytic hones in on changes made to mailbox configurations that initiate the forwarding of emails. It specifically looks for the activation of ForwardingAddress or ForwardingSmtpAddress parameters, indicating that emails are being automatically sent to another email address from the user’s mailbox.

Detection logic

`o365_management_activity` Operation=Set-Mailbox  
| eval match1=mvfind('Parameters{}.Name', "ForwardingAddress") 
| eval match2=mvfind('Parameters{}.Name', "ForwardingSmtpAddress") 
| where match1>= 0 OR match2>= 0 
| eval ForwardTo=coalesce(ForwardingAddress, ForwardingSmtpAddress) 
| search ForwardTo!=""  
| rename user_id as user 
| stats count earliest(_time) as firstTime latest(_time) as lastTime values(ForwardTo) as ForwardTo by user ObjectId 
|`security_content_ctime(firstTime)`  
|`security_content_ctime(lastTime)` 
| `o365_mailbox_email_forwarding_enabled_filter`