Windows Hardening via Intune
Contents
Disclaimer
This is a living document of my own hardening notes for Windows 10/11 endpoints managed through Microsoft Intune. The controls documented here are what I actually use and have tested. They are not vendor-endorsed, not compliance-certified, and not guaranteed to work in your org without adaptation. Read everything before you push anything.
My blog is my garden.
WARNING: No AI was used in the making of this blog post. Not one token. Just the docs, the policies, and a long afternoon.
Nobody hands you a clean Windows hardening guide when your org moves from traditional Active Directory to Azure AD (EntraID). What you get instead is a migration deck from Microsoft Professional Services, a Conditional Access walkthrough, and a vague promise that "Intune handles the rest." The rest turns out to be several hundred registry keys, CSP policies, and Settings Catalog entries that collectively determine whether your endpoints are a hardened fleet or a credential farm waiting to be harvested.
I've been maintaining this baseline for two years across a few different organizations. The controls came from a mix of CIS Benchmarks, DISA STIGs, hard lessons from incident response, and watching threat actors document their own tradecraft in public research. I recommend this baseline to friends who ask what they should push on day one of an Intune rollout. I've run on it myself. Normal work survives: Teams, Google Workspace, Slack, Zoom, any SaaS you can name. More on that at the end.
What this is not: a compliance checkbox exercise. If your goal is to pass an ISO 27001 audit by pushing 30 settings and calling it "hardened," stop here. This post will make your auditor happy as a side effect, not as the goal.
Understanding the Control Surface
When you're on traditional AD, your security configuration lives in Group Policy Objects. GPOs are deployed through SYSVOL, processed at startup and logon, and managed from a DC you physically control. The attack surface that comes with that DC (Kerberoasting, DCSync, SYSVOL scripts, lateral movement through SMB admin shares) is enormous and usually underappreciated.
Intune replaces GPO with two overlapping mechanisms. The first is MDM CSP policies: these map to OMA-URI endpoints that the Windows MDM client processes locally. The second is the Settings Catalog, which is Microsoft's unified policy interface that wraps both CSPs and legacy ADMX-backed Group Policy settings. You push these policies from the Intune portal; the device checks in on its own schedule and applies them without any DC in the path. No SYSVOL. No net logon share. The attack surface for the management plane shrinks significantly.
The trade-off is that you're now writing your entire security posture deliberately, from scratch, instead of inheriting it from AD Group Policy. That's a gift if you know what you're doing. It's a disaster if you don't.
Stopping Credential Theft
Let me start here because this is where most enterprise compromises begin. The standard playbook for an attacker who lands on a Windows endpoint goes: establish foothold, dump credentials from LSASS, use those credentials to move laterally, reach a Domain Controller or high-value target, done. WannaCry and NotPetya used variants of this. Every major ransomware group documented on Malpedia has a credential theft step somewhere in their intrusion chain. The specific tool changes. Mimikatz, ProcDump, custom LSASS reading code. But the target is always the same: lsass.exe, the Windows process that holds every authenticated credential on that machine.
The first line of defense is LSA Protected Process with a UEFI lock. The registry key is HKLM\SYSTEM\CurrentControlSet\Control\Lsa\RunAsPPL, value 2. Setting it to 2 instead of 1 writes the protection into UEFI, meaning even an attacker with admin privileges on the running OS cannot simply clear the flag and reboot cleanly. The protection survives. Userland tools that try to open LSASS for reading (PROCESS_VM_READ) get an access denied. The MITRE ATT&CK technique this directly disrupts is T1003.001 (LSASS Memory). It does not make the attack impossible. A kernel-mode driver can bypass it, and there are documented techniques using vulnerable signed drivers (BYOVD). But it eliminates the entire class of userland LSASS dumping tools and makes the attack loud, slow, and detectable.
Above LSA PPL in the stack sits Windows Defender Credential Guard with its own UEFI lock. Credential Guard uses Virtualization-Based Security to move derived credentials (NTLM hashes and Kerberos TGTs) out of the regular kernel and into an isolated VBS hypervisor-protected region called the Secure World. Mimikatz sekurlsa::logonpasswords against a machine with Credential Guard enabled returns empty hashes. Benjamin Delpy (the author of Mimikatz) documented this directly in the tool's own changelog. The key policy is CredentialGuard with UEFI Lock enabled. This blocks Pass-the-Hash (T1550.002) and Pass-the-Ticket (T1550.003) for credentials that Credential Guard manages: network logon hashes and Kerberos tickets.
The underlying machinery for all of this is Virtualization-Based Security itself. VBS creates a second, isolated execution environment within the hypervisor, separate from the main OS. Device Guard, Credential Guard, and Windows Defender Application Guard all depend on it. In the Intune Device Guard settings, you want VBS enabled with Secure Boot and DMA Protection, locked at UEFI level. The DMA protection matters specifically because it prevents an attacker with physical access and a Thunderbolt port from reading memory directly through a DMA device, bypassing all software controls.
This stack (VBS + Secure Boot + DMA Protection + Credential Guard + LSA PPL) is the most important thing in this entire baseline. If you only push five settings, push these. The rest of the hardening matters, but these five are the difference between a credential dump that takes thirty seconds and an attack chain that has nowhere to go.
Killing NTLM Downgrade and Relay Attacks
NTLM is Windows' legacy authentication protocol and it is, at this point, 30 years of accumulated regret. The modern attack surface around NTLM is well understood: responder-style tools intercept broadcast authentication requests (from LLMNR and NetBIOS Name Service) and relay them to targets the attacker chooses, or capture NTLMv1/v2 hashes for offline cracking.
The controls here work together. LLMNR (Link-Local Multicast Name Resolution) is disabled in the baseline: it's the Turn off Multicast Name Resolution setting under Administrative Templates. NetBIOS Node Type gets set to P-node, eliminating broadcast name resolution. These two settings together cut off the most common feeding vector for tools like Responder that work by posing as LLMNR responders on the local network.
Then in Local Security Policy (pushed via Intune Security Baseline), the LAN Manager authentication level gets set to NTLMv2 only, refuse LM and NTLM. No LM hash storage. Minimum session security for both NTLM and NTLMv2 is set to require 128-bit encryption. This closes the downgrade path where an attacker can coax a machine into using weaker authentication. LM and NTLMv1 hashes are trivially cracked offline; NTLMv2 with 128-bit session security is not breakable in any realistic timeframe without the original password.
SMB signing is required on both client and server. This is the control that prevents NTLM relay attacks from working against SMB targets. When SMB signing is enforced, a relay attacker in the middle cannot inject or replay the captured authentication against a third server. The signature covers the session, so a relayed session is rejected. The EternalBlue exploit (CVE-2017-0144, the vulnerability WannaCry weaponized) required SMBv1. SMBv1 is disabled. There is no legitimate reason for SMBv1 to be enabled in 2026. If you have something in your environment that still requires SMBv1, that thing needs to be replaced.
Hardened UNC paths for \\*\NETLOGON and \\*\SYSVOL require mutual authentication and integrity, which blocks an adversary from intercepting Group Policy or logon scripts even if they manage to spoof a DC. In an EntraID-only environment this matters less, but if you're in a hybrid state during migration, it matters a lot.
PowerShell is an Attack Surface. Treat it as one.
PowerShell is the most commonly abused tool in Windows intrusion chains. This is not an opinion, it's a consistent finding in public threat intel going back to at least 2015. The MITRE ATT&CK technique T1059.001 has documented usage by more threat groups than any other sub-technique in the execution category. The reason is obvious: PowerShell is a fully capable scripting runtime, signed by Microsoft, present on every Windows machine, and historically logged nowhere.
The baseline addresses this with two settings. First: Execution Policy is set to AllSigned. Scripts cannot run unless they carry a valid digital signature from a trusted publisher. The commodity PowerShell dropper that grabs a second-stage payload from a remote URL and runs it in memory will fail at this gate, because nobody who wrote it signed their code. Second: Script Block Logging is enabled. Every script block that PowerShell evaluates gets written to the Windows event log under Microsoft-Windows-PowerShell/Operational, event ID 4104. Even if an attacker runs code directly in memory (bypassing execution policy through reflection or through the PowerShell API), the logging captures what was executed. You can search event 4104 logs for DownloadString, IEX, FromBase64String, Invoke-Expression (the fingerprints of most commodity PS-based post-exploitation) and get a clear picture of what ran.
There is a real question of whether signed-scripts-only execution policy helps sophisticated attackers (the answer is no, not much, since they can bypass it or use living-off-the-land alternatives). But it cuts off the bottom 80% of the attacker population: commodity malware, script-kiddie tools, off-the-shelf offensive frameworks with lazy defaults. For a corporate endpoint in a SaaS-primary environment, 80% coverage at this layer is worth the inconvenience of requiring signed scripts for administrative automation.
WinRM and Remote Access
WinRM (Windows Remote Management) is PowerShell Remoting's transport and the mechanism that most remote management tools use to execute commands on Windows endpoints. Left in its default state, WinRM accepts basic authentication and can transmit credentials in cleartext. This baseline disables Basic authentication on both the client and server (AllowBasicAuthentication = 0), disables unencrypted traffic (AllowUnencryptedTraffic = 0), disables Digest authentication, and disables credential delegation through WinRM entirely.
RDP (Remote Desktop Protocol) gets NLA (Network Level Authentication) enforced, SSL required, and credential delegation blocked via CredSSP. Clipboard and drive redirection are both disabled. RDP sessions idle for 30 minutes disconnect automatically; sessions terminate after an hour. Encryption level is High. On an Intune-managed EntraID device, RDP usage should be the exception and not the norm. When it does happen, these settings ensure the session doesn't become a credential theft vector.
Device-Level Integrity
Secure Boot is enforced. Full disk encryption via BitLocker is required. These are baseline expectations and they matter for the obvious reason: a machine without disk encryption is a machine where an attacker with physical access can extract all data by booting from a USB drive. A machine without Secure Boot is a machine where a bootkit can survive a full OS reinstall. Neither of these should be acceptable for any endpoint handling real data.
The less obvious one is System Guard / Secure Launch. This is the Windows 10/11 implementation of Dynamic Root of Trust for Measurement (DRTM). It uses the CPU's hardware virtualization extensions to establish a chain of trust from the firmware up before the OS boots. The point is that the attestation of "this machine booted clean" is hardware-rooted, not just OS-rooted. An attacker who compromises the bootloader still cannot falsify the System Guard measurement. When combined with Intune's device compliance checks, this lets you make access decisions based on hardware-attested boot state rather than just trust-the-agent self-reporting.
Windows Defender Configuration
The Defender settings in this baseline are not the defaults. Not the "turn on Defender" checkbox most orgs stop at. Cloud-delivered protection is enabled, and the cloud block level is set to High. Block at First Sight is on. Advanced cloud scanning (extended timeout of 50 seconds) is enabled. MAPS membership is set to Advanced, meaning samples are submitted to Microsoft's telemetry automatically. Real-time behavior monitoring is on. File hash computation is enabled, which allows Defender to compute hashes for processes and submit them for threat intelligence correlation.
Network Protection is enabled in block mode. This is the Defender feature that inspects connections at the kernel level and blocks outbound traffic to known-malicious domains and IPs, using the same telemetry that SmartScreen uses for URLs. The distinction between audit and block mode matters: audit mode logs and alerts, block mode actually stops the connection. An endpoint with Network Protection in audit mode and a C2 beacon running is an endpoint that generates logs. An endpoint with Network Protection in block mode is an endpoint where the C2 beacon fails to reach home.
PUA (Potentially Unwanted Application) protection is enabled in block mode. This catches greyware, adware bundlers, and coin miners without needing a fully malicious classification.
SmartScreen is enforced for both Microsoft Edge and for downloaded files (SmartScreen and PreventSmartScreenPromptOverride both set). The important part is PreventSmartScreenPromptOverride. Without it, users can click through the SmartScreen warning and run flagged binaries anyway. With it, they cannot.
Audit Policy: Detection-First Posture
This section gets skipped most often. Hardening without logging is security theater. You've made the attacker's job harder, but you've given yourself no visibility into whether they succeeded anyway.
The audit policy in this baseline is configured at Success+Failure for every category that matters:
Credential Validation, Kerberos Authentication, Kerberos Service Ticket Operations. Process Creation and Process Termination. Token Right Adjusted Events. Logon, Logoff, Account Lockout. Sensitive Privilege Use. DPAPI Activity (underappreciated: DPAPI is the Windows Data Protection API, used to protect stored credentials. DPAPI audit events fire when credentials are decrypted, and they're a reliable signal for credential theft tools that target browser-stored passwords and Windows Credential Manager). Security System Extension. Security State Change. System Integrity.
Specifically: Audit Process Creation success logging with command line in event data is enabled. This means every process that starts on the machine writes an event 4688 to the Security log, including the full command line. Combine that with Script Block Logging for PowerShell and you have a ground-truth audit trail of execution across the endpoint that no userland attacker can trivially erase, because Security log access requires admin privileges the audit policy itself restricts.
Event log sizes are set accordingly. The Security log gets 2GB (2,097,152 KB in the registry). System and Application each get 64MB. These numbers exist because the default Security log size (20MB) rolls over fast on an active machine and destroys forensic history. 2GB of Security log history buys you days or weeks of retention depending on activity, long enough for an incident response team to reconstruct an intrusion after the fact.
A weekly scheduled reboot at 3 AM is configured via Intune. This is not a hardening control in the traditional sense, but it matters for persistence: most in-memory only malware and fileless implants rely on maintaining execution across reboot without writing to disk. A weekly forced reboot at 3 AM costs the attacker a persistence mechanism they have to re-establish, creates a detection window when the C2 beacon drops and then re-connects from a new process, and ensures Defender and LSA protection updates take effect without waiting for a user to manually reboot.
Browser Hardening
Both Microsoft Edge and Google Chrome are locked via enterprise policy pushed through Intune.
For Edge: SmartScreen is enforced. The prompt overrides for SmartScreen are disabled. Password manager is disabled (the baseline forces credential storage to go through a corporate password manager rather than the browser's local store). Extensions are restricted. Safe browsing is on. Basic Auth is blocked for HTTP. Legacy Browser Support mode is off.
For Chrome (CIS Benchmark Level 2): Developer tools are disabled in normal browser mode. Incognito mode is disabled. SafeSearch is enforced for all search queries. Safe Browsing is set to Enhanced. URL predictions that send keystrokes to Google's servers are disabled. Browser history deletion by the user is disabled. Third-party cookies are blocked. Chrome's built-in password manager is disabled, for the same reason as Edge's.
The developer tools restriction is the one that gets pushback. The argument for keeping it is sound: browser dev tools are how a lot of browser-based exfiltration and credential injection attacks are staged interactively. A threat actor who's landed a session as a user and opened a browser is partially limited if they can't pop the JavaScript console and run arbitrary code against the DOM. It doesn't stop a determined attacker with execution on the host already, but it closes an interactive attack surface that's real for browser-based phishing scenarios and insider threat. If developers in your org need dev tools, that's what a developer device profile is for.
Storage and Device Controls
Removable storage write access is denied. Removable disk execution is denied. CD/DVD write and execute are denied. AutoPlay is disabled on all drive types. AutoRun is disabled.
AutoRun deserves a specific note because it's old enough that people assume it's been fixed and forgotten. It hasn't. The technique of using autorun.inf on a USB drive to launch an executable automatically when the drive is inserted was responsible for widespread malware distribution (Conficker used it heavily). Modern variants like BadUSB abuse the HID (Human Interface Device) enumeration to appear as a keyboard rather than a storage device, which bypass storage controls entirely, but the classic autorun vector is still live against unpatched or misconfigured Windows machines. This baseline closes the classic vector. BadUSB requires separate controls (USB device type restrictions) which are worth layering on top if your threat model includes physical access attacks.
The Kill Switches
WSL is completely disabled. All of it: WSL1, WSL2, virtual machine-based WSL, custom kernel configuration, custom distribution installation. The relevant Intune policies are under the Windows Subsystem for Linux section in the Settings Catalog. Every AllowWSL variant is set to 0.
This will upset developers. The rationale is straightforward: WSL creates a Linux execution environment inside Windows that operates largely outside Windows security controls. Defender does not natively scan WSL filesystem paths by default. The WSL instance can make network connections, write to the Windows filesystem, and execute ELF binaries that Windows security tooling may not inspect. From an attacker's perspective, landing on a machine with WSL enabled and then dropping Linux tooling into the WSL instance is a known technique for defense evasion (T1202 adjacent). Disabling WSL eliminates that entire class of evasion. If you need WSL, you need a developer device profile with appropriate compensating controls.
Sudo for Windows is disabled. Microsoft shipped a Windows Sudo implementation that allows running elevated commands from a non-elevated context, similar to Unix sudo. The baseline disables it because the same facility that makes elevated operations convenient for administrators makes privilege escalation more convenient for attackers who have compromised a user account with sudo configured.
Network Misc
IP source routing is disabled on both IPv4 and IPv6. Source routing is a feature that lets a sender specify the path a packet takes through the network. It's essentially dead in normal networking and its only real use in 2026 is in crafted packets designed to probe or confuse packet inspection. Disabling it costs nothing.
ICMP redirects are disabled. An ICMP redirect message tells a host to update its routing table and send future traffic to a different next-hop. The legitimate use is for routers to optimize routing. The attack use is for a host on the local network to redirect a target's traffic through an attacker-controlled machine. Same calculus as source routing: zero operational value, non-trivial attack surface.
Cortana is disabled. The Windows cloud search indexer is disabled (no sending of search queries to Microsoft's cloud). Windows consumer features (suggested apps, third-party tiles, auto-installing sponsored content from the Microsoft Store during OOBE and beyond) are blocked. These are privacy controls as much as security controls, but they also reduce the external connectivity footprint of the endpoint.
Font providers from the internet are blocked. Windows has a feature that downloads fonts from a remote provider when a document requests a font not installed locally. This is a download-and-execute-code vector, just with fonts as the payload wrapper. Remote font providers are off.
What's NOT Locked
This part matters as much as everything above. A baseline that locks everything is not a real baseline; it's a DoS attack on your users. The controls above are targeted at the actual attack surface. Several things are deliberately left permissive:
OneDrive file sync is enabled. The policy value is literally "Sync Enabled." Organizations running on Microsoft 365 need OneDrive for file storage and collaboration. Blocking it would break the fundamental SaaS workflow. What the baseline does instead is push OneDrive's own compliance settings (Known Folder Move, sensitivity labeling, etc.) separately.
Location services are allowed. Teams needs location for meeting rooms. Zoom needs it. Various SaaS tools request it. The privacy cost is real, but for a corporate device the operational cost of blocking location entirely is higher.
Microsoft Account connections are allowed. In a pure EntraID environment you'd think you could block personal Microsoft accounts entirely, but some Microsoft 365 services and authentication flows touch personal account paths. This is a pragmatic call. The organizational account controls (Conditional Access, MDM enrollment requirements) do more for security here than blocking the Microsoft account connection path.
Edge and Chrome extensions are restricted, not eliminated. A curated allowlist is better than a full block, and both browsers have enterprise extension allowlist mechanisms. Blanket extension blocking breaks productivity for users who depend on enterprise-approved extensions for password managers, VPN clients, and accessibility tools.
The point is: this baseline is aggressive on the controls that matter for actual attacks. It is not maximum lockdown everywhere.
Does Normal Work Actually Survive This?
Yes. I've tested it and I run on it.
Microsoft Teams, Google Workspace, Slack, Zoom, Notion, Linear, GitHub, Figma. All the major SaaS tools work fine. Browsers work. OneDrive works. Outlook works. Email, calendar, video calls, collaborative documents. None of it breaks under this baseline.
What changes: you cannot run unsigned PowerShell scripts. You cannot plug in a USB drive and write to it. You cannot install random executables without an admin escalation. You cannot use Chrome's dev tools in normal mode. You cannot use WSL. You cannot spin up a local shell and do whatever you want.
If your workflow is a browser and Microsoft 365, this baseline is invisible to you. If your workflow involves running local automation scripts, you need to get those scripts signed or work with IT on a device profile that accommodates developer needs. That's the right answer: appropriate profiles for appropriate roles, not loosening the baseline for everyone.
This is the baseline I recommend to anyone migrating from AD to EntraID and asking what to push first. It's also what I recommend to friends setting up a new Intune tenant from scratch. The work survives it. The commodity attacker does not.
The AD to EntraID Migration Angle
One thing that surprises people when they move off AD is that the attack surface actually shrinks, if the migration is done properly.
On a traditional AD domain, you have domain controllers that are essentially the crown jewels of the entire forest. Kerberoasting (T1558.003) targets service account credentials encrypted with the service account's NTLM hash, which any domain user can request without any special privileges. DCSync (T1003.006) allows any account with the right privileges to simulate a domain controller and pull all credentials from AD. Privilege escalation to get those permissions is not that hard if you have a foothold and patience. The SYSVOL share historically contained Group Policy scripts and preferences with hardcoded credentials, a problem so common that Microsoft published a fix (MS14-025) and it still shows up in assessments fifteen years later.
EntraID eliminates all of that. There is no DC to pivot to. There is no SYSVOL share. Kerberoasting against EntraID-only service accounts is not the same attack as against AD service accounts. The ticket issuance mechanism is different and the offline crack path is much narrower. Cloud-side privilege escalation uses different paths (Azure RBAC, PIM, conditional access bypass) that require different techniques and are logged at the Azure audit layer, which you can ship to a SIEM.
The trade-off is that EntraID introduces its own attack surface: OAuth token theft (T1528), illicit application consent grants (T1550.001 adjacent), and enumeration through the Microsoft Graph API. Those are real threats and they need cloud-side controls (Conditional Access, App Consent policies, PIM for privileged roles) that are outside the scope of Intune endpoint hardening. But the endpoint controls in this baseline combine with those cloud controls to give you a defensible posture that was much harder to achieve in a pure on-prem AD environment.
The migration itself is also an opportunity. Moving to EntraID forces you to enumerate every AD-joined device and decide explicitly whether to hybrid join it or wipe-and-re-enroll it. A wipe-and-re-enroll brings a device under Intune MDM enrollment from day one with your baseline applied. Hybrid join is a shortcut that preserves old configuration debt. The former is better from a security posture perspective, though the operational cost is real.
References and Further Reading
If you want to go deeper on the formal frameworks behind these controls:
- CIS Benchmarks for Windows: the Level 2 benchmark covers most of what's in this baseline and includes the rationale for each control. Read the rationale section before you push anything.
- DISA STIGs: the DoD's hardening guides are stricter than CIS in some areas and have good coverage of Windows 10/11.
- MITRE ATT&CK: every technique referenced in this post has an ATT&CK entry. The "Mitigations" section of each technique page maps back to configuration controls.
- Malpedia Library: Fraunhofer FKIE's malware research library. When I want to understand what a specific ransomware group's credential theft phase looks like, this is the first stop.
Final Word
Most Windows hardening guides are either a 200-page PDF nobody reads past page 3, or a blog post listing five settings that sounds like it was written to close a ticket. This is neither. These are the controls I've actually deployed, in real organizations, tested against real users doing real work.
The hardening is not perfect. No hardening is. BYOVD driver attacks can bypass LSA PPL. A sophisticated attacker with persistent access will work around signed-scripts-only execution policy eventually. The point is not to make compromise impossible. The point is to make it expensive, slow, loud, and detectable. Eliminate the entire class of commodity attacks that are responsible for 80% of real-world enterprise incidents.
For the friends asking about the AD to EntraID migration: do it. The move to Intune-managed EntraID endpoints, with a baseline like this pushed on day one, puts you in a materially better security position than most AD-managed environments I've seen. The credentials don't live in an LSASS you can dump with a free tool. The lateral movement paths you're used to seeing don't exist. The audit trail is better by default.
Build the baseline. Push it. Then go read your logs.
Jai Hind.
#Windows Hardening #Windows Security #Intune #AzureAD #EntraID #cyber security #hacking #research #detection-engineering
๐ Verify authenticity
PGP key xer0x-public.asc · id e8270d03
sha256(post) 79a56dd3bed60563f8516f47629d744bdd1296fd4429615a198db90b24daa98e
Confirm this post is byte-for-byte authentic โ paste into any macOS or Linux terminal:
curl -fsSL https://xer0x.in/blog/windows-intune-hardening/content.txt | openssl dgst -sha256 | grep -qi 79a56dd3bed60563f8516f47629d744bdd1296fd4429615a198db90b24daa98e && echo "signature ok" || echo "TAMPERED"