feat(m365): add entra_pim_only_management security check#10848
feat(m365): add entra_pim_only_management security check#10848HugoPBrito wants to merge 1 commit intomasterfrom
Conversation
Add new security check entra_pim_only_management for m365 provider. Includes check implementation, metadata, and unit tests.
Compliance Mapping ReviewThis PR adds new checks. Please verify that they have been mapped to the relevant compliance framework requirements. New checks already mapped in this PR
Use the |
|
✅ Conflict Markers Resolved All conflict markers have been successfully resolved in this pull request. |
06a9a99 to
e30bfe0
Compare
|
✅ All necessary |
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #10848 +/- ##
==========================================
- Coverage 93.51% 88.01% -5.51%
==========================================
Files 228 132 -96
Lines 32266 5582 -26684
==========================================
- Hits 30174 4913 -25261
+ Misses 2092 669 -1423
Flags with carried forward coverage won't be shown. Click here to find out more.
🚀 New features to boost your workflow:
|
🔒 Container Security ScanImage: 📊 Vulnerability Summary
4 package(s) affected
|
Context
Role assignments made outside of Privileged Identity Management (PIM) bypass critical governance controls—removing audit trails, approval workflows, and time-bound access restrictions. This can indicate an active attack or privilege escalation attempt, as adversaries or malicious insiders can silently grant themselves persistent administrative access without detection, impacting confidentiality, integrity, and availability across the tenant.
Description
This check examines PIM alerts in Microsoft Entra ID looking for the
RolesAssignedOutsidePimAlertalert type. If the alert is active and has affected items, the check reports a FAIL with the count of role assignments made outside PIM. When no such alert is active, the check passes, confirming all privileged role assignments are governed through PIM. Remediation involves reviewing the alert in the Entra admin center, removing direct role assignments, and re-creating them as PIM-eligible assignments.Steps to review
prowler/providers/m365/services/entra/entra_pim_only_management/prowler/compliance/m365/to ensure the check is correctly mapped to relevant requirementspoetry run pytest tests/providers/m365/services/entra/entra_pim_only_management/ -vChecklist
Community Checklist
SDK/CLI
License
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.