gpo-security-review
Skill0 starsChanged 14 days agoMITView on GitHub
Review Group Policy for security baseline compliance, dangerous settings, GPP passwords, excessive edit rights and malicious GPO changes; detect GPO-based malware deployment via event 5136. Use when auditing GPOs, comparing to Microsoft/CIS baselines, or investigating ransomware deployed through Group Policy.
In this repository273 other files it gives its agents.
- ad-attack-path-analysisSkill
- adcs-security-reviewSkill
- ad-privileged-access-reviewSkill
- dcsync-detectionSkill
- kerberos-attack-detectionSkill
- agent-tool-permission-reviewSkill
- ai-incident-responseSkill
- llm-gateway-controlsSkill
- llm-security-evaluationSkill
- mcp-server-security-reviewSkill
- model-artifact-securitySkill
- prompt-injection-reviewSkill
- rag-security-reviewSkill
- api-abuse-detectionSkill
- api-authorization-testingSkill
- api-inventorySkill
- api-schema-securitySkill
- dast-baselineSkill
- sast-triageSkill
- sca-dependency-riskSkill
- secure-code-reviewSkill
- security-requirementsSkill
- threat-modelingSkill
- asset-criticality-tieringSkill
- asset-inventory-reconciliationSkill
- external-attack-surface-reviewSkill
- shadow-it-discoverySkill
- aws-credential-compromiseSkill
- aws-iam-reviewSkill
- aws-org-guardrailsSkill
- cloudtrail-investigationSkill
- guardduty-triageSkill
- s3-exposure-reviewSkill
- azure-activity-investigationSkill
- azure-rbac-reviewSkill
- conditional-access-reviewSkill
- entra-audit-investigationSkill
- entra-signin-investigationSkill
- backup-assuranceSkill
- critical-service-mappingSkill
- ransomware-recoverySkill
- recovery-exerciseSkill
- cloud-exposure-reviewSkill
- cloud-incident-responseSkill
- cloud-logging-baselineSkill
- cloud-posture-assessmentSkill
- audit-evidence-packageSkill
- continuous-control-monitoringSkill
- control-mappingSkill
- control-testing-samplingSkill
- container-incidentSkill
- dockerfile-hardeningSkill
- image-scanningSkill
- runtime-detection-falcoSkill
- db-audit-loggingSkill
- db-exfiltration-investigationSkill
- db-hardeningSkill
- db-privilege-reviewSkill
- data-classificationSkill
- data-discoverySkill
- The first 60 shown.
The file
Files
GPO Security Review
Collection
Get-GPO -All | Select-Object DisplayName, Id, ModificationTime, GpoStatus
Get-GPOReport -All -ReportType Xml -Path C:\review\gpos.xml
# Who can edit each GPO
Get-GPO -All | ForEach-Object { $g=$_; Get-GPPermission -Guid $g.Id -All |
Where-Object { $_.Permission -in 'GpoEdit','GpoEditDeleteModifySecurity' } |
Select-Object @{n='GPO';e={$g.DisplayName}}, Trustee, Permission }
# GPP cpassword remnants (MS14-025)
Select-String -Path "\\$env:USERDNSDOMAIN\SYSVOL\*\Policies\*\*.xml" -Pattern 'cpassword' -ListCompare with Microsoft Security Compliance Toolkit baselines using Policy Analyzer.
What to flag
- Non-Tier-0 principals with edit rights on GPOs linked to DCs/Tier 0 OUs (or at domain root).
- GPP XML containing
cpassword(decryptable, key is public). - Startup/logon scripts or Scheduled Task (GPP) items pointing to writable shares.
- Settings weakening security: WDigest enabled, LM hash storage, NTLMv1 allowed (
LmCompatibilityLevel< 5), SMB signing not required on DCs, LDAP signing/channel binding not enforced, Defender disabled/exclusions, Restricted Groups adding broad groups to local Administrators. - Audit policy GPO missing or weaker than recommended (
windows-event-log-analysis). - Orphaned/unlinked GPOs and SYSVOL folders without GPO objects.
Detecting malicious GPO changes
5136 (directory object modified) on groupPolicyContainer objects, especially gPCMachineExtensionNames / versionNumber changes; 5137 new GPO; 5141 deleted. File changes in SYSVOL\...\Machine\Preferences\ScheduledTasks\ScheduledTasks.xml or Scripts\ (file integrity monitoring on SYSVOL).
SecurityEvent
| where EventID == 5136 and ObjectClass == "groupPolicyContainer"
| project TimeGenerated, SubjectUserName, ObjectDN, AttributeLDAPDisplayName, AttributeValueOutput
GPO | Linked to | Finding | Setting/ACL | Risk | Recommended change | Owner
Related skills
ad-privileged-access-review, ransomware-response, endpoint-hardening
References
- Microsoft Security Compliance Toolkit: https://learn.microsoft.com/en-us/windows/security/operating-system-security/device-management/windows-security-configuration-framework/security-compliance-toolkit-10
- MS14-025 (GPP passwords): https://learn.microsoft.com/en-us/security-updates/securitybulletins/2014/ms14-025
- CIS Benchmarks: https://www.cisecurity.org/cis-benchmarks
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

