Skip to content
Saafir HaleSecurity & InfrastructureAtlanta, GA
← Security & Infrastructure

Microsoft 365 BEC Exposure Audit.

Read-only PowerShell audit of a Microsoft 365 tenant for the weaknesses business email compromise depends on, with an HTML report.

Public
About

A PowerShell module that audits a Microsoft 365 / Entra ID tenant for the conditions behind business email compromise. Fifteen checks cover MFA registration and phishing-resistant MFA for admins, legacy authentication, security defaults versus Conditional Access coverage, sign-in and user risk policies, external mailbox forwarding, inbox rules that forward, delete or hide mail, the outbound spam policy's auto-forwarding setting, audit logging, third-party apps holding mail or privilege-escalation permissions, user consent settings, standing Global Administrators, privileged roles held outside PIM, stale guests, and emergency access accounts.

Collection is read-only by construction: four read-only Microsoft Graph scopes, GET requests only, and Exchange Online Get-* cmdlets only, each enforced by a test. Every finding carries a severity, the evidence that triggered it, remediation steps and a link to the Microsoft documentation for the fix, and the output is a console summary, a self-contained HTML report and JSON.

The analysis is separated from collection. A live collector and a fixture collector both produce the same tenant snapshot, so every check runs offline against recorded JSON, and a live collection can be saved and replayed. Three synthetic tenants (one failing every check, one passing every check, one on security defaults without premium licences) back a 149-test Pester suite, and the code is clean under PSScriptAnalyzer at every severity.

Built with
PowerShellMicrosoft GraphExchange Online PowerShellMicrosoft Entra IDConditional AccessPesterPSScriptAnalyzer
Links
NextPassword Strength & Breach Checker →