Security 18 min read

Enterprise-Grade AI Governance: Securing Copilot and Custom Agents Across the Microsoft Ecosystem

Quiz available

Take a quick quiz for this article.

Enterprise-Grade AI Governance: Securing Copilot and Custom Agents Across the Microsoft Ecosystem
A verified, operational governance framework for AI agents across five control planes — Entra ID, Microsoft Purview, Defender for Cloud Apps, SharePoint Advanced Management, and MCP AI Gateway — covering Conditional Access, DLP, runtime threat detection, content governance, and compliance mapping for GDPR, HIPAA, and SOC 2. Every control is backed by official Microsoft documentation.

⚠️ Important Notice: This document contains only capabilities and configurations verified against official Microsoft documentation as of May 2026. Features marked “Preview” may change before general availability. Always test in a non-production environment first.

Deploying Microsoft 365 Copilot, custom Copilot Studio agents, and external plugins introduces autonomous actors that can access, process, and act upon corporate data at machine speed. To safely scale these solutions, organizations need a layered governance framework across four control planes: Microsoft Entra ID (Identity), Microsoft Purview (Data), Microsoft Defender for Cloud Apps (Runtime), and SharePoint Advanced Management (Content).

This guide provides a verified, operational framework with official Microsoft documentation references for each capability.

Key Outcomes:

  • ✅ Prevent unauthorized data exposure via AI agents using verified DLP and access controls
  • ✅ Maintain regulatory compliance with documented governance patterns
  • ✅ Enable secure external data integration via Model Context Protocol (MCP) with AI Gateway
  • ✅ Establish audit trails for all AI-driven actions using native Microsoft logging
  • ✅ Reduce risk through defense-in-depth architecture with validated controls

1. Licensing & Prerequisites

Before implementing governance controls, verify your organization has the required licenses. Missing licenses will silently fail to enforce policies.

CapabilityMinimum RequirementVerified Source
Microsoft 365 CopilotActive Copilot license assigned to users[75]
Entra ID Conditional Access for AgentsEntra ID P1 or P2[53]
Custom Security AttributesEntra ID P1 or P2[56]
Purview DLP for CopilotMicrosoft 365 E3/A3 (GA features); E5/A5 for advanced SITs[12]
Purview Audit (Premium)Microsoft 365 E5 or Audit (Premium) add-on[12]
Defender for Cloud Apps AI Agent ProtectionDefender for Cloud Apps license (Preview feature)[25]
SharePoint Advanced Management (SAM)SAM license + at least one Copilot license in tenant[93]
MCP Governance via AI GatewayAzure API Management + Microsoft Foundry access (Preview)[41]

Prerequisite Checklist:

  • Global Admin or Security Admin role assigned
  • Microsoft 365 Copilot licenses assigned to pilot users [[75]]
  • Entra ID P2 trial enabled if not licensed (for advanced CA features) [[53]]
  • Purview compliance portal access granted to compliance team [[12]]
  • SharePoint Admin Center access for SAM configuration [[28]]
  • Azure API Management instance provisioned for MCP governance (if using external connectors) [[41]]

2. Microsoft Entra ID: Identity-Centric Agent Governance

Before an agent can act, it must be authenticated and authorized. Entra ID treats AI agents as first-class identities, separate from standard user or application identities, allowing for highly granular access control.

2.1 Verified Capabilities

CapabilityStatusDescriptionSource
Conditional Access for Agent IdentitiesGenerally Available (May 2026)Policies can target agent identities using custom security attributes for scalable governance[53]
Custom Security AttributesGA (Entra ID P1/P2)Business-specific key-value attributes (e.g., PluginTier: Production) for attribute-based policy targeting[56]
Agent Identity BlueprintsGAPolicies applied at blueprint level automatically inherit to all derived agent instances[53]
Three Access PatternsGA1) On-behalf-of user, 2) Application-only, 3) Agent’s user account — each with distinct security considerations[53]
Identity Protection SignalsGAEntra monitors for anomalous agent behavior (unusual API call patterns) and generates risk signals that feed directly into Conditional Access policies[53]
Sign-in Log InvestigationGAFilter Entra sign-in logs by agentType property to audit agent activity[53]

A clean, modern admin dashboard UI mockup showing Conditional Access Policies blocking High-Risk AI Agents

2.2 Verified Configuration Steps

Create Conditional Access Policy for Agent Identities [[53]]

1

Navigate to Policies

Entra Admin Center → Conditional Access → Policies → New policy

2

Define Policy Name

Name: "Restrict High-Risk AI Agent Access"

3

Configure Assignments

  • Users, agents (Preview) or workload identities: * Include: All agent identities (Preview) * OR filter by custom security attributes (e.g., PluginTier = Production) * Cloud apps or actions: * Select target resources (Office 365, SharePoint Online, custom apps)
4

Set Conditions (optional but recommended)

  • Agent risk level: Block if High, require MFA if Medium * Network location: Block if not from trusted corporate networks
5

Configure Access Controls

  • Grant: Require MFA for user-delegated flows * Session: Sign-in frequency = 1 hour (optional)
6

Enable Policy

  • Start in "Report-only" mode for 2 weeks to assess impact * Change to "On" after validation
7

Finalize Setup

Click “Create”

Apply Custom Security Attributes for Scalable Targeting [[56]]

1

Navigate to Attributes

Entra Admin Center → Custom security attributes

2

Publish Schema

Ensure schema is published (requires Global Admin privilege)

3

Assign Attributes to Blueprints

When registering agent blueprint, assign custom security attributes: * Key: PluginTier, Value: Production * Key: DataClassification, Value: Internal

  • Key: RequiresExternalAccess, Value: SEC_EDGAR
4

Reference in Policies

Reference these attributes in Conditional Access policy assignments for granular security scoping

Audit Agent Activity via Sign-in Logs [[53]]

Code
// Filter Entra sign-in logs for agent activity
SigninLogs
| where agentType is not null
| project TimeGenerated, UserPrincipalName, agentType, appId, resourceName, status
| sort by TimeGenerated desc

Pro Tip: Block restricted agents from accessing external MCP servers based on network compliance. Use the RequiresExternalAccess custom attribute to build a Conditional Access policy that only permits outbound connections to approved MCP endpoints when that specific attribute is present.

2.3 Known Limitations

LimitationImpactMitigation
Agent identity targeting shows “(Preview)” in UIMay cause confusion about GA statusUnderlying enforcement is GA; UI label reflects assignment interface preview [[53]]
Custom attributes require schema publicationDelay in attribute availabilityPublish schema early in deployment planning [[56]]
Policy propagation timeChanges may take time to reflectTest in report-only mode first; allow 1-2 hours for propagation

2.4 Compliance Mapping

ControlGDPRHIPAASOC 2
Conditional Access for AgentsArticle 32 (Security of Processing)§164.312(a)(1) Access ControlCC6.1 Logical Access
Custom Security AttributesArticle 25 (Data Protection by Design)§164.308(a)(1) Risk AnalysisCC2.1 Policies & Procedures
Agent Sign-in LoggingArticle 30 (Records of Processing)§164.312(b) Audit ControlsCC7.2 System Monitoring

3. Microsoft Purview: Context-Aware Data Protection

While Entra controls who (or what) gets in, Purview controls what data is allowed to leave or be processed. Copilot interactions require specialized Data Loss Prevention (DLP) logic.

3.1 Verified Capabilities

CapabilityStatusDescriptionSource
Block sensitive info types in promptsPreviewDetects SITs (SSN, credit cards) in user prompts; blocks Copilot response[12]
Block files/emails with sensitivity labelsGenerally AvailablePrevents labeled items from being used in response summaries; items may still appear in citations[12]
Block external web search when prompt contains sensitive dataPreviewPrevents Copilot from using external grounding sources when SITs detected[12]
Simulation/Test modeGATest policies before enforcement to tune false positives[78]

3.2 Critical Limitations (Verified)

LimitationVerified Source
Cannot combine “Content contains SITs” AND “Content contains sensitivity labels” in the same rule — must create separate rules within one policy[12]
Policy updates can take up to 4 hours to reflect in Copilot experience[12]
DLP for Copilot location supports custom policy templates only (no built-in templates)[12]
Items blocked by label-based DLP may still appear in citations (but not in summary content)[12]

A modern enterprise dashboard UI mockup showing a Data Loss Prevention alert popup indicating an AI prompt containing sensitive data was blocked

3.3 Verified Configuration Steps

Create DLP Policy for Copilot Prompts [[12]]

Code
1. Navigate to: Microsoft Purview Portal → Data loss prevention → Policies → Create policy
2. Category: Custom
3. Name: "Block Sensitive Prompts in Copilot"
4. Locations: Select "Microsoft 365 Copilot and Copilot Chat" ONLY
   - ⚠️ Do NOT select Exchange/SharePoint/OneDrive in same rule
5. Click "Next"
6. Create Rule #1 - Block Sensitive Info Types (Preview):
   - Name: "Block PII in Prompts"
   - Condition: Content contains → Sensitive information types
   - Select: U.S. Social Security Number, Credit Card Number, etc.
   - Action: Prevent Copilot from processing content → Processing prompts
   - Optional: Send incident report, show policy tip
7. Click "+ Add rule" for Rule #2 - Block Sensitivity Labels (GA):
   - Name: "Block Highly Confidential Files"
   - Condition: Content contains → Sensitivity labels
   - Select: "Highly Confidential", "Regulatory"
   - Action: Prevent Copilot from processing content
8. Policy Settings:
   - Mode: Start in "Test with policy tips" or "Simulation" for 2 weeks
9. Click "Submit" → Review → Create

Testing: Always deploy in simulation mode first to capture matches and tune out false positives before activating.

3.4 Compliance Mapping

ControlGDPRHIPAASOC 2
Prompt-Level DLPArticle 5 (Data Minimization)§164.514(e) De-identificationCC6.7 Transmission Security
Label EnforcementArticle 32 (Security of Processing)§164.312(a)(1) Access ControlCC6.1 Logical Access
Web Search Grounding ControlArticle 44 (International Transfers)§164.312(e)(1) Transmission SecurityCC6.6 External Threats

4. Microsoft Defender for Cloud Apps: Runtime Threat Intelligence

Governance does not stop at access. You must monitor what agents are doing in real-time. Defender for Cloud Apps acts as the runtime security layer for your Copilot Studio agents and OAuth plugins.

4.1 Verified Capabilities

CapabilityStatusDescriptionSource
AI Agent InventoryPreviewDiscovers Copilot Studio agents; integrates with Advanced Hunting[25]
Real-time runtime protectionPreviewBlocks suspicious actions during agent execution; triggers alerts[26]
Anomalous Behavior DetectionPreviewBaseline normal plugin/agent activity; flag sudden API call spikes to external endpoints (e.g., SEC EDGAR data pulls)[26]
Shadow AI DiscoveryPreviewDetect unauthorized or “shadow” AI plugins operating under the radar in your tenant[25]
Audit log collectionPreviewContinuously monitors agents for suspicious activity[25]
OAuth app governanceGAAudit OAuth permissions granted to plugins connecting your tenant to external API surfaces[25]

4.2 Verified Configuration Steps

Enable AI Agent Protection (Preview) [[26]]

1

Navigate to settings

Microsoft Defender Portal → System → Settings → Cloud Apps

2

Find Copilot Studio settings

Scroll to the “Copilot Studio AI Agents” section

3

Enable Real-Time Protection

Toggle “Real-time protection” to ON

4

Configure Detection Rules

  • Set thresholds for anomalous behavior (e.g., unusual API call volume) * Define automated responses (alert, suspend session)
5

Save Configuration

Save and apply the settings to your tenant

Configure Anomaly Detection Rules [[26]]

1

Navigate to Policy Management

Defender Portal → Cloud Apps → Control → Policy Management

2

Create New Activity Policy

Click ”+ Create policy” and select “Activity policy” under “Anomaly detection”

3

Configure Activity Conditions

  • Activity: Select activities like CallExternalAPI, DownloadFile, etc. * Actor type: Filter specifically for AI agents
4

Establish Severity & Alerts

Set severity to High. Configure automated response to suspend agent session and trigger playbooks to notify the SOC.

5

Least Privilege Revocation

Schedule reviews to revoke unused OAuth scopes quarterly to prevent privilege creep.

6

Create Policy

Click “Create” to activate the rule

Integrate with Microsoft Sentinel (Optional)

1

Navigate to Sentinel Connectors

Microsoft Sentinel → Configuration → Data connectors

2

Locate Connector

Search for “Microsoft Defender for Cloud Apps”

3

Follow Setup Wizard

Follow the connector setup wizard to stream alerts directly into Sentinel

4

Verify Data Flow

Verify data ingestion by running a simple test query in Sentinel: kql MicrosoftCloudAppSecurityAlert | take 5

Pro Tip: Integrate Defender alerts directly with Microsoft Sentinel for centralized incident response and automated playbook execution.

A professional dashboard UI mockup showing a Runtime Threat Detection graph with a sudden spike in AI agent activity

4.3 Known Limitations

LimitationImpactMitigation
AI Agent Protection is in PreviewFeatures may change; not for production-critical scenariosTest thoroughly; monitor Microsoft Learn for GA announcements [[25]]
Baseline period required for anomaly detectionInitial false positives possibleAllow 30-day baseline period before enforcing strict thresholds
OAuth app governance requires manual reviewPrivilege creep risk if not monitoredSchedule quarterly permission reviews

4.4 Compliance Mapping

ControlGDPRHIPAASOC 2
Runtime ProtectionArticle 32 (Security of Processing)§164.312(b) Audit ControlsCC6.1 Logical Access
OAuth GovernanceArticle 28 (Processor Obligations)§164.308(a)(3) Workforce SecurityCC6.6 External Threats
Audit Log CollectionArticle 30 (Records of Processing)§164.312(b) Audit ControlsCC7.2 System Monitoring

5. SharePoint Advanced Management: Proactive Content Governance

AI does not bypass your permissions — it amplifies them. If a site is overshared, Copilot will find it and surface it. SharePoint Advanced Management (SAM) is essential for fixing the root cause before Copilot deployment amplifies the risk.

5.1 Verified Capabilities

CapabilityStatusDescriptionSource
Restricted Content Discovery (RCD)GA (requires SAM license)Prevents overshared sites from appearing in Copilot/unified search unless user had recent interaction[28]
Block Download PoliciesGAPrevent users from downloading sensitive files accessed via Copilot interfaces; enforced at the site or library level[93]
Conditional Access ContextsGATie site access to Entra CA contexts (e.g., requiring a compliant device to view the site) — directly bridges Entra and SharePoint governance[93]
Site-level RCD toggleGAMust be enabled per site via SharePoint Admin Center or PowerShell[28]
Does NOT change permissionsCriticalUsers with existing access can still open files; RCD only affects discovery[28]
Permission State ReportsGAIdentify sites with excessive external sharing or orphaned permissions[93]
Site Access ReviewsGADelegate attestation workflows to site owners[93]

Crucial Reality: Copilot respects existing permissions. SAM tools are absolutely necessary to remediate oversharing before Copilot deployment amplifies the risk. Schedule attestation workflows by tying quarterly site reviews directly to your plugin recertification cycles.

A clean, modern admin dashboard UI mockup showing SharePoint Restricted Content Discovery and Site Access Reviews

5.2 Critical Limitations (Verified)

LimitationVerified Source
RCD propagation can take over 1 week for sites with 500k+ items[28]
RCD requires SharePoint Advanced Management license + at least one Copilot license in tenant[93]
RCD does not prevent access if user has direct permission — only affects discovery via search/Copilot[28]
PowerShell cmdlet Set-SPOSite -RestrictContentOrgWideSearch is the only programmatic method[28]

5.3 Verified Configuration Steps

Enable Restricted Content Discovery (RCD) [[28]]

Option A: SharePoint Admin Center (UI)

1

Navigate to Active Sites

SharePoint Admin Center → Active sites

2

Select Settings Tab

Select target site → Click “Settings” tab

3

Find Restricted Content Discovery

Scroll to the “Restricted content discovery” section

4

Toggle Setting

Toggle “Restrict content from appearing in org-wide search and Copilot” to ON

5

Save Changes

Click “Save” (Note: Propagation may take up to 1 week for large sites containing 500k+ items)

Option B: PowerShell

Code
# Connect to SharePoint Online
Connect-SPOService -Url https://contoso-admin.sharepoint.com

# Enable RCD for a specific site
Set-SPOSite -identity "https://contoso.sharepoint.com/sites/Finance" -RestrictContentOrgWideSearch $true

# Verify status
Get-SPOSite -identity "https://contoso.sharepoint.com/sites/Finance" | Select RestrictContentOrgWideSearch

Run Permission State Report (Pre-Copilot Remediation) [[93]]

1

Navigate to Advanced Management

SharePoint Admin Center → Advanced Management → Permission state

2

Generate Report

Click “Generate report”

3

Review High-Risk Sharing Indicators

Review the generated report specifically looking for: * Sites with anonymous links enabled * Sites with external guests invited * Sites with no designated owner in the last 90 days * Sites with over 50 unique item permissions

4

Export & Prioritize

Export the data as CSV → Prioritize remediation of highly exposed or high-risk repositories

5

Remediate Before Copilot

Remediate overshared permissions before enabling broad Copilot access to prevent automatic data exposure

5.4 Compliance Mapping

ControlGDPRHIPAASOC 2
Restricted Content DiscoveryArticle 25 (Data Protection by Design)§164.312(a)(1) Access ControlCC6.1 Logical Access
Block Download PoliciesArticle 32 (Security of Processing)§164.312(a)(1) Access ControlCC6.7 Transmission Security
Permission State ReportsArticle 30 (Records of Processing)§164.308(a)(1) Risk AnalysisCC2.1 Policies & Procedures
Site Access ReviewsArticle 5 (Accuracy)§164.308(a)(4) Information Access ManagementCC2.2 Roles & Responsibilities

6. MCP Governance via AI Gateway: Securing External Data Connectors

6.1 Verified Capabilities

CapabilityStatusDescriptionSource
AI Gateway for MCP toolsPreviewRoutes MCP traffic through Azure API Management for policy enforcement[41]
Policy applicationPreviewPolicies configured in Azure API Management portal, not Foundry portal[41]
EligibilityLimitationOnly new MCP tools created after gateway connection are routed through it[41]
Authentication supportGAManaged identity, API key, custom OAuth passthrough, or unauthenticated[41]
Unsupported scenariosLimitationDoes not support tools with managed OAuth or non-MCP tools[41]

6.2 Verified Configuration Steps

Connect AI Gateway to Microsoft Foundry [[41]]

1

Navigate to API Management

Azure Portal → API Management → Your instance

2

Enable AI Gateway

Enable “AI Gateway” feature (Preview)

3

Establish Connection to Foundry

Connect to Microsoft Foundry resource: * Provide Foundry resource ID * Grant required permissions

4

Verify Connection Status

Verify connection status shows “Connected”

Create New MCP Tool with Governance [[41]]

1

Navigate to Agent Tools

Microsoft Foundry portal → Agents → Tools

2

Initialize Creation

Click ”+ Create new tool” (⚠️ Must be a new tool; existing tools are not retroactively auto-routed)

3

Configure Connector Details

Configure tool parameters: * Name: "SEC EDGAR MCP Connector" * Endpoint: https://mcp.sec.gov/api/v1 * Authentication: Select supported method (API key, managed identity, or custom OAuth passthrough)

4

Automatic Routing

The new tool automatically routes outbound requests through the connected AI Gateway (APIM)

5

Locate Gateway API

In Azure Portal → API Management → APIs → Locate your new MCP API

6

Apply Security Policies

Configure gateway policies inside APIM: * Rate limiting: Prevent connector abuse * IP filtering: Restrict traffic to approved corporate networks * JWT validation: Enforce Token requirements and payload validations

7

Test & Audit

Test tool invocation → Verify that all logs and metrics correctly stream to API Management dashboard

Advanced Cross-Pillar Pattern: Combine Entra Agent IDs with MCP Governance for precise endpoint routing. Tag a plugin blueprint in Entra with RequiresExternalAccess: SEC_EDGAR (custom security attribute), then build a Conditional Access policy that only permits outbound connections to approved MCP endpoints when that specific attribute is present. This prevents any agent without the explicit attribute from reaching external data connectors — even if they discover the endpoint URL.

A professional admin console UI mockup showing Azure API Management AI Gateway policies for custom MCP connectors

6.3 Known Limitations

LimitationImpactMitigation
Only new MCP tools are auto-routed through gatewayExisting tools require recreationPlan gateway connection before deploying MCP tools
Does not support managed OAuth authenticationLimits authentication optionsUse API key or custom OAuth passthrough instead
Policy configuration in APIM portal, not FoundryAdditional management overheadDocument APIM policy management process

6.4 Compliance Mapping

ControlGDPRHIPAASOC 2
AI Gateway Traffic RoutingArticle 28 (Processor Obligations)§164.308(b)(1) BA AgreementsCC6.6 External Threats
IP Filtering / Rate LimitingArticle 32 (Security of Processing)§164.312(e)(1) Transmission SecurityCC6.7 Transmission Security
Traffic AnalyticsArticle 30 (Records of Processing)§164.312(b) Audit ControlsCC7.2 System Monitoring

7. Cross-Platform Orchestration Architecture

To visualize how these four control planes interact during a single user request, consider this cross-platform orchestration flow from invocation to execution:

Code
┌─────────────────────────────────────────────────────────────────┐
│                    User Invokes Copilot Plugin                  │
│              "Perform financial research on Microsoft"           │
└────────────────────────┬────────────────────────────────────────┘


┌─────────────────────────────────────────────────────────────────┐
│  1. ENTRA ID: Identity & Risk Assessment [[53]]                 │
│     ✓ Validate agent identity via Conditional Access policy     │
│     ✓ Check custom security attributes for policy targeting     │
│     ✓ Evaluate Identity Protection risk signals                 │
│     ✓ Verify network location compliance                        │
│                                                                 │
│     Decision: ALLOW → Continue | BLOCK → Return error           │
└────────────────────────┬────────────────────────────────────────┘


┌─────────────────────────────────────────────────────────────────┐
│  2. PURVIEW: Prompt & Content Validation [[12]]                 │
│     ✓ Scan prompt for Sensitive Information Types (Preview)     │
│     ✓ Check sensitivity labels on target files (GA)             │
│     ✓ Evaluate web search grounding eligibility (Preview)       │
│     ✓ Apply DLP policy: Block/Allow/Notify                      │
│                                                                 │
│     Decision: ALLOW → Continue | BLOCK → Show policy tip        │
└────────────────────────┬────────────────────────────────────────┘


┌─────────────────────────────────────────────────────────────────┐
│  3. SHAREPOINT: Content Access Control [[28]]                   │
│     ✓ Verify user has permission to target sites                │
│     ✓ Check Restricted Content Discovery (RCD) rules            │
│     ✓ Validate recent interaction window (default: 30 days)     │
│     ✓ Enforce Block Download Policies on sensitive libraries     │
│                                                                 │
│     Decision: ALLOW → Continue | RESTRICT → Hide from search    │
└────────────────────────┬────────────────────────────────────────┘


┌─────────────────────────────────────────────────────────────────┐
│  4. MCP GATEWAY: External Data Access (if required) [[41]]      │
│     ✓ Verify agent has RequiresExternalAccess attribute         │
│     ✓ Route MCP traffic through AI Gateway (APIM)               │
│     ✓ Apply policies: rate limiting, IP filtering, JWT          │
│     ✓ Log data flow for audit                                   │
│                                                                 │
│     Decision: ALLOW → Fetch data | BLOCK → Return error         │
└────────────────────────┬────────────────────────────────────────┘


┌─────────────────────────────────────────────────────────────────┐
│  5. DEFENDER: Runtime Monitoring [[26]]                         │
│     ✓ Monitor for anomalous agent behavior (Preview)            │
│     ✓ Detect unusual API call patterns or data volumes          │
│     ✓ Shadow AI discovery: flag unauthorized plugin activity    │
│     ✓ Trigger alerts or automated responses if thresholds met   │
│                                                                 │
│     Action: LOG → Continue | ALERT → Notify SOC                 │
└────────────────────────┬────────────────────────────────────────┘


┌─────────────────────────────────────────────────────────────────┐
│              Response Delivered to User                         │
│     ✓ Audit events logged to native Microsoft platforms         │
│     ✓ No additional third-party logging required                │
└─────────────────────────────────────────────────────────────────┘

A professional isometric architecture diagram illustrating a digital flow through Identity Check, Data Shield, and Runtime Monitor checkpoints

Key Architectural Takeaways

  1. Fix Data Governance First: Implement SharePoint Advanced Management to resolve oversharing before enabling broad AI access.
  2. Layer Your Defenses: Relying on a single platform is a failure point. Entra ID dictates who, Purview restricts what, Defender monitors how, and SharePoint protects where.
  3. Test in Simulation: Always test policies in simulation/report-only mode to prevent user disruption and tune false positives.
  4. Schedule Continuous Reviews: AI plugins will evolve rapidly. Governance is an iterative lifecycle, not a one-time deployment task.
  5. Document Elevated Exceptions: Maintain rigorous documentation for any agents requiring elevated exceptions — including business justification, approver, and expiry date.
  6. Combine Entra Agent IDs with Purview DLP: Combine signals for precise MCP endpoint routing. Tag a plugin blueprint with RequiresMCP: SEC_EDGAR, and build a CA policy that only permits outbound connections to approved MCP endpoints when that specific attribute is present.

8. Implementation Checklist: Verified Steps

Phase 1: Prerequisites Verification (Week 1)

  • Licensing Confirmation

    • Microsoft 365 Copilot licenses assigned to pilot users [[75]]
    • Entra ID P1/P2 confirmed for Conditional Access features [[53]]
    • SharePoint Advanced Management license verified for RCD [[93]]
    • Purview compliance portal access granted [[12]]
    • Azure API Management instance provisioned (if using MCP) [[41]]
  • Access & Permissions

    • Global Admin or Security Admin role assigned
    • Purview compliance admin role for DLP policy creation [[12]]
    • SharePoint Admin Center access for SAM configuration [[28]]

Phase 2: Core Controls Deployment (Weeks 2-3)

1

PURVIEW DLP [[12]]

  • Create policy → Location: “Microsoft 365 Copilot and Copilot Chat”
  • Rule 1: Block SITs in prompts (Preview) – separate rule
  • Rule 2: Block sensitivity-labeled files (GA) – separate rule
  • Start in “Test with policy tips” mode → Review matches → Activate
  • Note: Allow up to 4 hours for policy propagation
2

SHAREPOINT RCD [[28]]

  • Identify high-risk sites via Permission State reports
  • Enable RCD per site via UI or PowerShell: Set-SPOSite -identity <site-url> -RestrictContentOrgWideSearch $true
  • Note: Propagation may take >1 week for large sites containing 500k+ items
3

ENTRA CONDITIONAL ACCESS [[53]]

  • Create policy targeting “Agents (Preview)” in assignments
  • Use custom security attributes for scalable targeting
  • Start in "Report-only" mode → Validate impact → Enable
4

DEFENDER AI AGENT PROTECTION [[26]]

  • Enable preview feature: Defender Portal → Settings → Cloud Apps
  • Configure anomaly detection thresholds based on baseline activity
  • Integrate alerts with existing SOC workflows

Phase 3: Validation & Testing (Week 4)

  • DLP Policy Validation [[12]]

    • Test prompt with synthetic SSN: “My SSN is 123-45-6789, summarize this”
    • Expected: Copilot blocked from processing; policy tip shown
    • Verify event in Purview audit logs
  • RCD Validation [[28]]

    • Search for restricted site content in Copilot
    • Expected: Content hidden unless user had recent interaction
    • Verify direct access still works for authorized users
  • Conditional Access Validation [[53]]

    • Review Entra sign-in logs filtered by agentType
    • Verify policy blocks/highlights as configured
    • Test with pilot user group first
  • MCP Gateway Validation (if applicable) [[41]]

    • Invoke agent using new MCP tool
    • Verify traffic appears in Azure API Management analytics
    • Confirm applied policies (rate limiting, etc.) are enforced

Phase 4: Go-Live & Monitoring (Week 5+)

  • Policy Activation

    • Change Purview DLP mode: Test → On
    • Change Entra CA mode: Report-only → On
    • Document activation timestamp for audit
  • Monitoring Setup

    • Review native logs: Entra sign-in logs, Purview audit, Defender alerts
    • Optional: Stream to Sentinel for centralized monitoring
    • Set up alerts for critical events (e.g., high-risk agent sign-ins)
  • User Communication

    • Notify pilot users of active governance policies
    • Provide examples of DLP policy tips they may see
    • Share escalation path for false positives
  • Ongoing Maintenance

    • Quarterly: Review OAuth permissions via Defender [[25]]
    • Quarterly: Run SharePoint Permission State reports [[93]]
    • Monthly: Review DLP policy matches and tune false positives [[12]]
    • As needed: Update Conditional Access policies for new agent types [[53]]
  • Documentation

    • Document all agents requiring elevated exceptions (business justification, approver, expiry)
    • Maintain change log for policy modifications
    • Schedule next review aligned with plugin recertification cycle

9. Compliance Mapping Framework

9.1 GDPR Compliance

GDPR ArticleRequirementMicrosoft ControlVerified Source
Article 5Data minimizationPurview DLP blocking excessive data in prompts[12]
Article 22Automated decision-makingHuman-in-the-loop via CA policies requiring MFA[53]
Article 25Data protection by designSharePoint RCD preventing overshared content discovery[28]
Article 28Processor obligationsMCP governance via AI Gateway with BA agreements[41]
Article 30Records of processingNative audit logs in Entra, Purview, Defender[[53]][[12]][[25]]
Article 32Security of processingDefense-in-depth across all four control planesAll sections
Article 44International transfersMCP traffic restrictions via AI Gateway policies[41]

9.2 HIPAA Compliance

HIPAA SafeguardRequirementMicrosoft ControlVerified Source
§164.308(a)Risk analysisDefender anomaly detection for agent behavior[26]
§164.308(a)Workforce securityOAuth app governance via Defender[25]
§164.312(a)Access controlEntra Conditional Access for agent identities[53]
§164.312(b)Audit controlsPurview Audit (Premium) + native logging[12]
§164.312(e)Transmission securityMCP TLS enforcement via AI Gateway[41]

9.3 SOC 2 Type II

Trust Service CriteriaRequirementMicrosoft ControlVerified Source
CC2.1Policies & proceduresDocumented governance framework with phased checklistThis document
CC6.1Logical accessEntra CA + SharePoint permissions[[53]][[28]]
CC6.6External threatsDefender runtime protection + MCP governance[[26]][[41]]
CC6.7Transmission securityMCP TLS + Purview DLP for data in transit[[41]][[12]]
CC7.2System monitoringNative logging + optional Sentinel integration[[53]][[12]][[25]]

10. Monitoring, Validation & Troubleshooting

10.1 Verified Monitoring Approaches

Control PlaneNative Logging LocationVerified Query/MethodSource
Entra IDSign-in logsFilter by agentType property[53]
PurviewAudit logs (Premium)Search “Copilot” in audit log search[12]
DefenderCloud Apps alertsReview AI Agent Protection alerts[26]
SharePointUnified Audit LogFilter by SharePoint activities + RCD events[28]
MCP GatewayAzure API Management analyticsReview API metrics and logs[41]

10.2 Verified Troubleshooting Guide

IssueVerified SymptomsRoot CauseVerified ResolutionSource
DLP policy not blocking promptsPolicy shows “On” but prompts still processedPolicy still in propagation; up to 4 hours requiredWait up to 4 hours; verify policy mode is “On” not “Test”[12]
RCD not hiding overshared sitesCopilot still surfaces restricted contentPropagation delay for large sites (>500k items)Wait up to 1 week; verify site has RCD enabled via PowerShell[28]
Agent sign-in logs not showing agentTypeLogs visible but agentType property nullAgent using access pattern not logged with agentTypeVerify agent identity registration; check access pattern type[53]
MCP tool not routed through gatewayTraffic not appearing in APIM analyticsTool created before gateway connectionRecreate MCP tool after connecting AI Gateway[41]
Defender alerts not firingAnomalous activity not detectedBaseline period not complete (30 days recommended)Allow baseline period; adjust sensitivity settings[26]

10.3 Validation Checklist

  • DLP Testing [[12]]

    • Prompt with synthetic SSN blocked as expected
    • Prompt with credit card number blocked as expected
    • Policy tip displayed to user (if configured)
    • Event appears in Purview audit logs
    • Prompt Injection Pentesting: Attempt prompt injection attacks using synthetic sensitive data (e.g., fake SSNs, mock PII) to validate Purview DLP triggers and confirm no bypass vectors exist
  • RCD Testing [[28]]

    • Restricted site content hidden from Copilot search
    • Same content accessible via direct URL for authorized users
    • Recent interaction (within 30 days) bypasses RCD as expected
  • Conditional Access Testing [[53]]

    • Agent sign-in logs show policy evaluation
    • High-risk agent blocked or challenged per policy
    • Custom attributes correctly filter policy application
  • MCP Gateway Testing (if applicable) [[41]]

    • New MCP tool traffic appears in APIM analytics
    • Applied policies (rate limiting, etc.) enforced
    • Authentication method working as configured
  • Security Exercises

    • Tabletop Exercise: Run a SOC scenario based on a compromised plugin. Walk through the exact containment steps: How does the team isolate the tenant, suspend the agent session, revoke OAuth tokens, and notify stakeholders? Document the runbook outcome.
    • SIEM Validation: Confirm that Purview Audit (Premium) logs and Entra Agent ID sign-ins are successfully flowing into Sentinel (or your SIEM of choice)

11. Appendix: Official Documentation References

Primary Sources

  1. Microsoft 365 Copilot Foundational Deployment Guidance https://learn.microsoft.com/en-us/microsoft-365/copilot/secure-govern-copilot-foundational-deployment-guidance [[75]]

  2. Purview DLP for Microsoft 365 Copilot https://learn.microsoft.com/en-us/purview/dlp-microsoft365-copilot-location-learn-about [[12]]

  3. Defender for Cloud Apps: AI Agent Protection https://learn.microsoft.com/en-us/defender-cloud-apps/ai-agent-protection [[25]] https://learn.microsoft.com/en-us/defender-cloud-apps/ai-agent-protection-configure [[26]]

  4. SharePoint Restricted Content Discovery https://learn.microsoft.com/en-us/sharepoint/restricted-content-discovery [[28]]

  5. SharePoint Advanced Management Overview https://learn.microsoft.com/en-us/sharepoint/advanced-management [[93]]

  6. Entra ID: Conditional Access for Agent Identities https://learn.microsoft.com/en-us/entra/identity/conditional-access/agent-id [[53]]

  7. Entra ID: Custom Security Attributes Overview https://learn.microsoft.com/en-us/entra/fundamentals/custom-security-attributes-overview [[56]]

  8. Azure AI Foundry: MCP Tool Governance via AI Gateway https://learn.microsoft.com/en-us/azure/foundry/agents/how-to/tools/governance [[41]]

Supporting Documentation

  1. Purview DLP General Concepts https://learn.microsoft.com/en-us/purview/dlp-learn-about-dlp [[78]]

  2. Entra ID Sign-in Logs Reference https://learn.microsoft.com/en-us/entra/identity/monitoring-health/reference-sign-ins-schema

  3. Azure API Management Policies https://learn.microsoft.com/en-us/azure/api-management/api-management-howto-policies


Related Articles

More articles coming soon...

Discussion

Loading...