Microsoft Purview
Premium.
What Emberseal does: before a message or request is stored, it sends the text and each file to Microsoft Graph processContent as the sending user, after checking which activities that user's policies cover (protectionScopes/compute). If a policy answers Block, the send is refused; Warn lets the sender continue with a reason; Audit only records it in Purview.
0. Licensing (check first)
Purview only evaluates content from third-party apps for users licensed for it. You need both:
- A DLP-capable license on each person who sends through Emberseal: Microsoft 365 E5 / A5 / G5, or an E5 Compliance, E5 Information Protection & Governance or Purview Suite add-on (on E3 or similar). Business Premium and plain E3 aren't on that list.
- Purview pay-as-you-go billing linked to an Azure subscription (Microsoft Purview portal → Settings → Billing).
Pay-as-you-go doesn't replace the user license. Without both, Microsoft answers InsufficientServicePlans and Emberseal can't get a verdict. License changes can take a few hours to reach Purview. Microsoft's licensing for Entra-registered apps is still changing, so confirm with your Microsoft licensing contact before buying.
1. Register an app in Microsoft Entra ID
- Open the Microsoft Entra admin center → Identity → Applications → App registrations → New registration.
- Name it (e.g.
Emberseal DLP), choose Accounts in this organizational directory only, and leave the redirect URI blank (Emberseal signs in as the app, not a user). You can reuse Emberseal's existing SSO registration instead, but a separate one keeps permissions apart. - Copy the Application (client) ID and Directory (tenant) ID into Settings → Data loss prevention → Microsoft Purview.
2. Create a client secret
Certificates & secrets → Client secrets → New client secret. Paste the Value (not the Secret ID) into Client secret in Settings → Data loss prevention and save. Note the expiry: Emberseal stops getting verdicts when it lapses (and blocks sends if If DLP can't be reached is set to block).
3. Grant Microsoft Graph application permissions
API permissions → Add a permission → Microsoft Graph → Application permissions, add:
| Permission | Why |
|---|---|
Content.Process.All | Evaluate message text and files against DLP policies |
ProtectionScopes.Compute.All | Find which activities each user's policies cover |
User.Read.All | Find the sender's Entra ID from their email address |
Then Grant admin consent for (needs a Global Administrator or Privileged Role Administrator).
4. Create the DLP policy in Purview (PowerShell)
The Purview portal can't target Entra-registered apps yet, so the policy is created with Security & Compliance PowerShell. Run this as a Compliance Administrator:
Install-Module ExchangeOnlineManagement -Scope CurrentUser # once
Connect-IPPSSession
$appId = "<client ID from step 1>"
$appName = "Emberseal"
$locations = "[{`"Workload`":`"Applications`",`"Location`":`"$appId`",`"LocationDisplayName`":`"$appName`",`"LocationSource`":`"Entra`",`"LocationType`":`"Individual`",`"Inclusions`":[{`"Type`":`"Tenant`",`"Identity`":`"All`"}]}]"
New-DlpCompliancePolicy -Name "$appName DLP" -Mode Enable -Locations $locations -EnforcementPlanes @("Application")
Then add one or more rules. This example blocks credit card numbers in message text and files; swap in the sensitive information types (or -ContentContainsSensitiveInformation with labels) your policies use:
New-DlpComplianceRule -Name "$appName - block card numbers" -Policy "$appName DLP" `
-ContentContainsSensitiveInformation @{Name = "Credit Card Number"} `
-RestrictAccess @(@{setting="UploadText";value="Block"}, @{setting="UploadFile";value="Block"}) `
-GenerateAlert $true
valuecan be Block, Warn (sender may continue with a reason) or Audit (recorded in Purview only).UploadTextcovers the subject and message text;UploadFilecovers attachments.- Policies can take up to an hour to reach Emberseal. It re-reads each user's scopes hourly and as soon as Purview says they changed.
5. Turn it on and test
- Tick Microsoft Purview, save, then Test Purview with a user's email. A good result shows their Entra ID and the activities their policies evaluate (
uploadText,uploadFile). - "No Purview DLP policy targets this app for this user yet" means the app works but step 4 hasn't reached them.
- Send yourself a test message containing
4111 1111 1111 1111. It should be blocked, and the match appears in Purview → Activity explorer under the app name Emberseal.
Troubleshooting
- AADSTS7000215 / invalid client secret: paste the secret's Value, not its ID.
- 403 Authorization_RequestDenied: a permission in step 3 is missing or admin consent wasn't granted.
- 403 InsufficientServicePlans: the app's permissions are fine; the user being checked isn't licensed (see step 0). Test with a user who has one of the licenses above. Pay-as-you-go alone doesn't clear it.
- Finding a user fails: the sender's Emberseal email must match their UPN or primary email in Entra ID. The local bootstrap admin has no Entra account, so its sends can't be evaluated by Purview.
- Emberseal reaches
login.microsoftonline.comandgraph.microsoft.comover HTTPS (443); allow them through any egress proxy or firewall on the Emberseal server's network.

