Skip to content
Tech Atlas, home
Search
Esc
  • All roadmapsBrowse every learning path
  • ExploreFind a technology area
  • ProjectsGuided projects and builds
  • My AtlasYour learning dashboard
Lesson 2 of 6 · Lab · 30 min · revision 2

Hardening a Lab Domain Through Group Policy

Apply a recognised hardening baseline to a lab domain through scoped Group Policy Objects with real registry paths and values, deploy Windows LAPS for member machines and DSRM accounts, and then verify it with a Python baseline checker you run here over shipped exports for a domain controller and a workstation: it skips rules outside each host's role, flags the weak lab, passes the hardened one, and catches a tampered value. Learn tiered administration, PAWs and Microsoft security baselines.

Contentsand lesson path

What you will learn

  • Harden a lab domain and its Windows hosts through Group Policy against a recognised baseline: tiered administration, unique local administrator passwords with Windows LAPS, credential protections, restricted RDP, LDAP signing, and removal of legacy protocols such as SMBv1, NTLMv1 and LLMNR.

01. Goal and setup

You will harden a lab domain against a recognised baseline and then prove it. The proof is a Python baseline checker that reads an export of a host's effective settings and reports, rule by rule, whether the host meets the baseline. Not every rule fits every machine: LDAP signing is a domain controller (DC) setting, and Microsoft advises against enabling Credential Guard on DCs. So each rule has a scope, each export records the host's role, and the checker prints SKIP for an out-of-scope rule instead of hiding it.

You run the checker on a DC (DC01) and a workstation (WS01): on weak before exports, on hardened after exports, and on a DC export with one value tampered. This is configuration auditing: do not trust that a GPO applied, collect the effective value and check it.

The Group Policy and Windows LAPS steps change a real domain, so they are not reproducible on this lesson's sandbox and their output is labelled Illustrative, in the format Microsoft Learn shows. Run them only in your own isolated lab built from evaluation images, never on a production or shared domain.

You need Python 3.10 or later (standard library only) and a folder gpo-lab holding the six files printed below. The exports use the reserved domain example.invalid.

gpo-lab/ layout
gpo-lab/
  baseline_rules.py   # the baseline: scope, source, check and reason per rule
  check_baseline.py   # reads exports, prints PASS/FAIL/SKIP, sets the exit code
  before-dc01.json    # DC01 (domain controller) before hardening
  before-ws01.json    # WS01 (workstation) before hardening
  after-dc01.json     # DC01 after hardening
  after-ws01.json     # WS01 after hardening
  tampered-dc01.json  # created in step 5: DC01 with one value changed back

02. Step 1: The baseline as code, with scopes

baseline_rules.py lists each control with its scope (all hosts, domain controllers only, or member machines only), the registry value or query it maps to, a check, and a one-line reason. Every path and value comes from the Microsoft pages in the references. Two details are easy to get wrong. NetBIOS over TCP/IP is set per network adapter, under one Tcpip_{GUID} subkey each, so the export holds a list. Windows LAPS reads Group Policy from HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\LAPS, not from SOFTWARE\Policies; the Intune (CSP) root is HKLM\SOFTWARE\Microsoft\Policies\LAPS.

Python · gpo-lab/baseline_rules.py
"""The hardening baseline: expected effective settings, scope and reason per rule.

Each rule has an id, a human name, a scope (which hosts it applies to), the
registry value or query it maps to, a check over the exported value, and a
one-line reason. Paths and values come from Microsoft Learn (lesson references).
"""
ALL, DC, MEMBER = "all hosts", "domain controllers only", "member machines only"

HKLM = "HKLM\\"
SVC = HKLM + "SYSTEM\\CurrentControlSet\\Services\\"
LANSRV = SVC + "LanmanServer\\Parameters"
LANWS = SVC + "LanmanWorkstation\\Parameters"
NTDS = SVC + "NTDS\\Parameters"
NBT = SVC + "NetBT\\Parameters\\Interfaces\\Tcpip_*"  # one subkey per adapter
LSA = HKLM + "SYSTEM\\CurrentControlSet\\Control\\Lsa"
POL = HKLM + "SOFTWARE\\Policies\\Microsoft\\"
DNSC = POL + "Windows NT\\DNSClient"
TS = POL + "Windows NT\\Terminal Services"
# Windows LAPS reads its Group Policy settings from this root (the CSP root
# is HKLM\SOFTWARE\Microsoft\Policies\LAPS; legacy LAPS used AdmPwd).
LAPS = HKLM + "SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Policies\\LAPS"
BROAD = ("Everyone", "Authenticated Users", "Domain Users", "Domain Computers")


def is_in(*allowed):
    return lambda v: v in allowed


def at_least(n):
    return lambda v: isinstance(v, int) and v >= n


def every(x):
    # the value is a list with one entry per network adapter
    return lambda v: isinstance(v, list) and len(v) > 0 and all(i == x for i in v)


def contains(x):
    return lambda v: isinstance(v, list) and x in v


def excludes(*bad):
    # the value is a list of principals granted a right; none may be a broad group
    return lambda v: isinstance(v, list) and not (set(v) & set(bad))


RULES = [
    ("smb1_server", "SMBv1 server disabled", ALL,
     "Get-SmbServerConfiguration EnableSMB1Protocol; GPO item " + LANSRV + "!SMB1=0",
     is_in(False), "SMBv1 is obsolete and has serious known vulnerabilities."),
    ("smb_sign_server", "SMB signing required (server)", ALL,
     LANSRV + "!RequireSecuritySignature", is_in(1),
     "Required signing makes the server reject unsigned, relayable sessions."),
    ("smb_sign_client", "SMB signing required (client)", ALL,
     LANWS + "!RequireSecuritySignature", is_in(1),
     "The client side must also require signing on outbound connections."),
    ("ldap_server_signing", "LDAP server signing required", DC,
     NTDS + "!LDAPServerIntegrity", is_in(2),
     "2 = Require signing (1 = None); the DC rejects unsigned SASL binds."),
    ("ldap_channel_binding", "LDAP channel binding always", DC,
     NTDS + "!LdapEnforceChannelBinding", is_in(2),
     "2 = Always (1 = When supported); ties an LDAPS bind to its TLS channel."),
    ("lm_compat", "LAN Manager auth level 5 (NTLMv2 only)", ALL,
     LSA + "!LmCompatibilityLevel", is_in(5),
     "5 sends NTLMv2 only and refuses LM and NTLM (v1) responses."),
    ("llmnr_off", "LLMNR turned off", ALL,
     DNSC + "!EnableMulticast", is_in(0),
     "0 turns off multicast name resolution, a spoofing entry point."),
    ("nbtns_off", "NetBIOS over TCP/IP off on every adapter", ALL,
     NBT + "!NetbiosOptions", every(2),
     "2 disables NetBT, which also removes NBT-NS broadcast lookups."),
    ("cred_guard", "Credential Guard running", MEMBER,
     "Win32_DeviceGuard SecurityServicesRunning (1 = Credential Guard)",
     contains(1), "Isolates NTLM hashes and Kerberos TGTs; not advised on DCs."),
    ("lsa_ppl", "LSA protection (RunAsPPL) on", ALL,
     LSA + "!RunAsPPL", is_in(1, 2),
     "1 or 2 runs LSASS as a protected process, blocking memory reads."),
    ("rdp_nla", "RDP Network Level Authentication required", ALL,
     TS + "!UserAuthentication", is_in(1),
     "NLA authenticates the user before a remote session is created."),
    ("rdp_logon_right", "RDP logon right limited to admin groups", ALL,
     "User right SeRemoteInteractiveLogonRight", excludes(*BROAD),
     "Only named admin or jump groups should be able to RDP in."),
    ("laps_backup", "Windows LAPS backs up the password", ALL,
     LAPS + "!BackupDirectory", is_in(1, 2),
     "1 = Entra ID, 2 = AD; 0 (the default) means LAPS manages nothing."),
    ("laps_length", "Windows LAPS password length 14 or more", ALL,
     LAPS + "!PasswordLength", at_least(14),
     "Set it explicitly; a long random password resists offline cracking."),
    ("laps_dsrm", "Windows LAPS backs up the DSRM password", DC,
     LAPS + "!ADBackupDSRMPassword", is_in(1),
     "DCs have no local admin; LAPS manages the DSRM account (AD only)."),
]

The checker takes the role from domain_role, the DomainRole property of Win32_ComputerSystem: 1 and 3 are member machines, 4 and 5 are DCs. An applicable value that is missing counts as a failure. Any failure gives a non-zero exit code, so a pipeline can gate on it.

Python · gpo-lab/check_baseline.py
"""Check one or more settings exports against the hardening baseline.

Usage: python3 check_baseline.py <export.json> [<export.json> ...]
Exit code 0 only if every applicable rule passes on every host; 1 if any rule
fails or an applicable value is missing; 2 for bad usage or an unknown role.
Rules outside a host's scope are printed as SKIP, so you can see they were
not forgotten.
"""
import json
import sys

from baseline_rules import ALL, DC, MEMBER, RULES

# Win32_ComputerSystem.DomainRole: 1 member workstation, 3 member server,
# 4 backup DC, 5 primary DC (0 and 2 are standalone, outside this baseline).
ROLES = {1: MEMBER, 3: MEMBER, 4: DC, 5: DC}
LABEL = {MEMBER: "member machine", DC: "domain controller"}


def check_host(path):
    with open(path) as f:
        export = json.load(f)
    host = export.get("host", "?")
    role = ROLES.get(export.get("domain_role"))
    if role is None:
        print(f"{host}: unknown domain_role {export.get('domain_role')!r}")
        return None
    settings = export.get("settings", {})
    print(f"{host} ({LABEL[role]}, domain_role {export['domain_role']})")
    passed = failed = skipped = 0
    for rid, name, scope, source, check, reason in RULES:
        if scope not in (ALL, role):
            print(f"  SKIP {name} ({scope})")
            skipped += 1
        elif rid not in settings:
            print(f"  FAIL {name}: value not collected")
            failed += 1
        elif check(settings[rid]):
            print(f"  PASS {name}")
            passed += 1
        else:
            print(f"  FAIL {name}: got {settings[rid]!r}")
            failed += 1
    print(f"  result: {passed} passed, {failed} failed, {skipped} skipped")
    return failed


def main(paths):
    total = 0
    for path in paths:
        failed = check_host(path)
        if failed is None:
            return 2
        total += failed
    print(f"hosts checked: {len(paths)}, failures: {total}")
    return 1 if total else 0


if __name__ == "__main__":
    if len(sys.argv) < 2:
        print("usage: python3 check_baseline.py <export.json> [...]")
        sys.exit(2)
    sys.exit(main(sys.argv[1:]))

03. Step 2: Measure the weak lab on a DC and a workstation

Each export holds the host name, its domain_role and a settings map of rule id to the effective value an auditor collected (registry, Get-SmbServerConfiguration, Win32_DeviceGuard, resultant set of policy). null means not set. The before exports have several settings weakened on purpose. Save both and run the checker.

JSON · gpo-lab/before-dc01.json
{
  "host": "DC01.example.invalid",
  "domain_role": 5,
  "collected": "2026-11-16 before hardening",
  "settings": {
    "smb1_server": false,
    "smb_sign_server": 1,
    "smb_sign_client": 0,
    "ldap_server_signing": 1,
    "ldap_channel_binding": 0,
    "lm_compat": 3,
    "llmnr_off": 1,
    "nbtns_off": [0],
    "lsa_ppl": 0,
    "rdp_nla": 0,
    "rdp_logon_right": ["Administrators"],
    "laps_backup": 0,
    "laps_length": null,
    "laps_dsrm": 0
  }
}
JSON · gpo-lab/before-ws01.json
{
  "host": "WS01.example.invalid",
  "domain_role": 1,
  "collected": "2026-11-16 before hardening",
  "settings": {
    "smb1_server": false,
    "smb_sign_server": 0,
    "smb_sign_client": 0,
    "lm_compat": 3,
    "llmnr_off": 1,
    "nbtns_off": [0, 0],
    "cred_guard": [0],
    "lsa_ppl": 0,
    "rdp_nla": 0,
    "rdp_logon_right": ["Administrators", "Domain Users"],
    "laps_backup": 0,
    "laps_length": null
  }
}
Terminal
cd gpo-lab
python3 check_baseline.py before-dc01.json before-ws01.json
echo "exit code: $?"
Expected output
DC01.example.invalid (domain controller, domain_role 5)
  PASS SMBv1 server disabled
  PASS SMB signing required (server)
  FAIL SMB signing required (client): got 0
  FAIL LDAP server signing required: got 1
  FAIL LDAP channel binding always: got 0
  FAIL LAN Manager auth level 5 (NTLMv2 only): got 3
  FAIL LLMNR turned off: got 1
  FAIL NetBIOS over TCP/IP off on every adapter: got [0]
  SKIP Credential Guard running (member machines only)
  FAIL LSA protection (RunAsPPL) on: got 0
  FAIL RDP Network Level Authentication required: got 0
  PASS RDP logon right limited to admin groups
  FAIL Windows LAPS backs up the password: got 0
  FAIL Windows LAPS password length 14 or more: got None
  FAIL Windows LAPS backs up the DSRM password: got 0
  result: 3 passed, 11 failed, 1 skipped
WS01.example.invalid (member machine, domain_role 1)
  PASS SMBv1 server disabled
  FAIL SMB signing required (server): got 0
  FAIL SMB signing required (client): got 0
  SKIP LDAP server signing required (domain controllers only)
  SKIP LDAP channel binding always (domain controllers only)
  FAIL LAN Manager auth level 5 (NTLMv2 only): got 3
  FAIL LLMNR turned off: got 1
  FAIL NetBIOS over TCP/IP off on every adapter: got [0, 0]
  FAIL Credential Guard running: got [0]
  FAIL LSA protection (RunAsPPL) on: got 0
  FAIL RDP Network Level Authentication required: got 0
  FAIL RDP logon right limited to admin groups: got ['Administrators', 'Domain Users']
  FAIL Windows LAPS backs up the password: got 0
  FAIL Windows LAPS password length 14 or more: got None
  SKIP Windows LAPS backs up the DSRM password (domain controllers only)
  result: 1 passed, 11 failed, 3 skipped
hosts checked: 2, failures: 22
exit code: 1

DC01 checks fourteen rules and skips Credential Guard; WS01 checks twelve and skips the two LDAP rules and the DSRM rule, which only mean something on a DC. The LDAP failures are real DC findings: the DC accepts unsigned binds and does not tie LDAPS binds to their TLS channel, so a relayed authentication can reach the directory. DC01 passes server SMB signing because the Default Domain Controllers Policy requires it. Both hosts leave LLMNR and NetBIOS on, so an attacker on the subnet can answer name lookups and collect NTLMv2 responses. Windows 11 24H2 Pro, Enterprise and Education already require SMB signing in both directions by default, one more reason to measure instead of assuming. The exit code is 1.

04. Step 3: Harden with scoped GPOs and LAPS

A Group Policy Object (GPO) is a named bundle of settings that applies to the machines below the domain or organisational unit (OU) it is linked to. Mirror the checker's scopes with three GPOs: one at the domain root for all hosts, one on the Domain Controllers OU, and one on the Lab OU that holds the member machines. The commands below use the GroupPolicy module on your lab DC; they are not run here. Create the all-hosts GPO and set server SMB signing: Set-GPRegistryValue writes a registry-based setting into the GPO.

PowerShell · on your lab DC
$all = 'Lab Baseline - All Hosts'
New-GPO -Name $all -Comment 'SMB, NTLM, LLMNR, RDP, LSA, LAPS'

$lanSrv = 'HKLM\System\CurrentControlSet\Services\LanManServer\Parameters'
$smb = @{ Name = $all; Key = $lanSrv; ValueName = 'RequireSecuritySignature' }
Set-GPRegistryValue @smb -Type DWord -Value 1
Illustrative output (format of the New-GPO example on Microsoft Learn; IDs and dates differ)
DisplayName      : Lab Baseline - All Hosts
DomainName       : example.invalid
Owner            : EXAMPLE\Domain Admins
Id               : b8c1f2c2-fbd3-4a1f-94e1-3e156a65a29a
GpoStatus        : AllSettingsEnabled
Description      : SMB, NTLM, LLMNR, RDP, LSA, LAPS
CreationTime     : 11/16/2026 9:12:03 AM
ModificationTime : 11/16/2026 9:12:03 AM

Set the other all-hosts values the same way, with the paths in baseline_rules.py: RequireSecuritySignature = 1 under ...\LanmanWorkstation\Parameters, LmCompatibilityLevel = 5 and RunAsPPL = 1 under ...\Control\Lsa, EnableMulticast = 0 under ...\DNSClient, and UserAuthentication = 1 under ...\Terminal Services. Values outside SOFTWARE\Policies show as Extra Registry Settings and stay on a machine after the GPO is removed; the Security Options node of the GPO editor sets the same SMB, NTLM and LDAP values.

SMBv1 is not installed by default on Windows 11 or Windows Server 2019 and later; where it is, run Disable-WindowsOptionalFeature -Online -FeatureName SMB1Protocol. Set NetbiosOptions = 2 through DHCP or a startup script. Credential Guard needs virtualization-based security (VBS); on Windows 11 22H2 or later and Windows Server 2025, qualifying domain-joined machines that are not DCs turn both on by default, so check msinfo32 on the host. The scoped settings go into the other two GPOs.

PowerShell · on your lab DC
$dc = 'Lab Baseline - Domain Controllers'
New-GPO -Name $dc -Comment 'LDAP signing and channel binding, DSRM backup'
$ntds = 'HKLM\System\CurrentControlSet\Services\NTDS\Parameters'
$ldap = @{ Name = $dc; Key = $ntds; Type = 'DWord'; Value = 2 }
Set-GPRegistryValue @ldap -ValueName 'LDAPServerIntegrity'        # Require signing
Set-GPRegistryValue @ldap -ValueName 'LdapEnforceChannelBinding'  # Always

$mem = 'Lab Baseline - Members'
New-GPO -Name $mem -Comment 'Credential Guard: member machines only'
# Edit $mem: Computer Configuration > Policies > Administrative Templates >
# System > Device Guard > Turn On Virtualization Based Security = Enabled,
# Credential Guard Configuration = Enabled with UEFI lock

Link each GPO where its scope lives. A backtick at the end of a line continues it in PowerShell.

PowerShell · on your lab DC
New-GPLink -Name 'Lab Baseline - All Hosts' -Target 'DC=example,DC=invalid'
New-GPLink -Name 'Lab Baseline - Domain Controllers' `
  -Target 'OU=Domain Controllers,DC=example,DC=invalid'
New-GPLink -Name 'Lab Baseline - Members' -Target 'OU=Lab,DC=example,DC=invalid'
Illustrative output for the second link (format from Microsoft Learn; Order 2 because the Default Domain Controllers Policy is link 1)
GpoId       : 3f0c2a5e-8d41-4b7a-9e2c-6a1d5b0f7c93
DisplayName : Lab Baseline - Domain Controllers
Enabled     : True
Enforced    : False
Target      : OU=Domain Controllers,DC=example,DC=invalid
Order       : 2

Deploy Windows LAPS (Local Administrator Password Solution) so every member machine has a unique, rotated local administrator password stored in AD. Then one stolen local admin hash no longer unlocks every machine. DCs have no local accounts, so there LAPS manages the Directory Services Restore Mode (DSRM) password, which needs AD backup and password encryption (domain functional level 2016 or later). Extend the schema once per forest, let the Lab OU machines update their own passwords, then set the policy in two GPOs.

PowerShell · on your lab DC
Update-LapsADSchema
Set-LapsADComputerSelfPermission -Identity Lab
# 'Lab Baseline - All Hosts', Computer Configuration > Policies >
# Administrative Templates > System > LAPS:
#   Configure password backup directory = Active Directory (BackupDirectory 2)
#   Password Settings = complexity 4, length 16 (PasswordLength 16)
# 'Lab Baseline - Domain Controllers', same folder:
#   Enable password backup for DSRM accounts (ADBackupDSRMPassword 1)
Illustrative output of Set-LapsADComputerSelfPermission (format from Microsoft Learn)
Name DistinguishedName
---- -----------------
Lab  OU=Lab,DC=example,DC=invalid

05. Step 4: Verify the hardened hosts (negative test)

After policy refreshes, collect both exports again. A check must stay quiet on the state it should accept, so these hardened exports are the negative test: zero failures, with out-of-scope rules still shown as SKIP.

JSON · gpo-lab/after-dc01.json
{
  "host": "DC01.example.invalid",
  "domain_role": 5,
  "collected": "2026-11-16 after hardening",
  "settings": {
    "smb1_server": false,
    "smb_sign_server": 1,
    "smb_sign_client": 1,
    "ldap_server_signing": 2,
    "ldap_channel_binding": 2,
    "lm_compat": 5,
    "llmnr_off": 0,
    "nbtns_off": [2],
    "lsa_ppl": 1,
    "rdp_nla": 1,
    "rdp_logon_right": ["Administrators"],
    "laps_backup": 2,
    "laps_length": 16,
    "laps_dsrm": 1
  }
}
JSON · gpo-lab/after-ws01.json
{
  "host": "WS01.example.invalid",
  "domain_role": 1,
  "collected": "2026-11-16 after hardening",
  "settings": {
    "smb1_server": false,
    "smb_sign_server": 1,
    "smb_sign_client": 1,
    "lm_compat": 5,
    "llmnr_off": 0,
    "nbtns_off": [2, 2],
    "cred_guard": [1],
    "lsa_ppl": 1,
    "rdp_nla": 1,
    "rdp_logon_right": ["Administrators", "Tier2-Workstation-Admins"],
    "laps_backup": 2,
    "laps_length": 16
  }
}
Terminal
python3 check_baseline.py after-dc01.json after-ws01.json
echo "exit code: $?"
Expected output
DC01.example.invalid (domain controller, domain_role 5)
  PASS SMBv1 server disabled
  PASS SMB signing required (server)
  PASS SMB signing required (client)
  PASS LDAP server signing required
  PASS LDAP channel binding always
  PASS LAN Manager auth level 5 (NTLMv2 only)
  PASS LLMNR turned off
  PASS NetBIOS over TCP/IP off on every adapter
  SKIP Credential Guard running (member machines only)
  PASS LSA protection (RunAsPPL) on
  PASS RDP Network Level Authentication required
  PASS RDP logon right limited to admin groups
  PASS Windows LAPS backs up the password
  PASS Windows LAPS password length 14 or more
  PASS Windows LAPS backs up the DSRM password
  result: 14 passed, 0 failed, 1 skipped
WS01.example.invalid (member machine, domain_role 1)
  PASS SMBv1 server disabled
  PASS SMB signing required (server)
  PASS SMB signing required (client)
  SKIP LDAP server signing required (domain controllers only)
  SKIP LDAP channel binding always (domain controllers only)
  PASS LAN Manager auth level 5 (NTLMv2 only)
  PASS LLMNR turned off
  PASS NetBIOS over TCP/IP off on every adapter
  PASS Credential Guard running
  PASS LSA protection (RunAsPPL) on
  PASS RDP Network Level Authentication required
  PASS RDP logon right limited to admin groups
  PASS Windows LAPS backs up the password
  PASS Windows LAPS password length 14 or more
  SKIP Windows LAPS backs up the DSRM password (domain controllers only)
  result: 12 passed, 0 failed, 3 skipped
hosts checked: 2, failures: 0
exit code: 0

Every applicable rule passes and the exit code is 0. WS01 grants the RDP logon right to Administrators and a named Tier2-Workstation-Admins group, not Domain Users; DC01 keeps it to Administrators, as Microsoft recommends for DCs.

06. Step 5: Catch a tampered value on the DC

Settings drift. An administrator sets LDAP server signing back to None so that an old application can keep making unsigned binds. The command below writes that change into tampered-dc01.json and checks it.

Terminal
python3 - <<'PY'
import json
with open("after-dc01.json") as f:
    export = json.load(f)
export["collected"] = "2026-11-16 re-check after a change"
export["settings"]["ldap_server_signing"] = 1  # set back to None
with open("tampered-dc01.json", "w") as f:
    json.dump(export, f, indent=2)
PY
python3 check_baseline.py tampered-dc01.json
echo "exit code: $?"
Expected output
DC01.example.invalid (domain controller, domain_role 5)
  PASS SMBv1 server disabled
  PASS SMB signing required (server)
  PASS SMB signing required (client)
  FAIL LDAP server signing required: got 1
  PASS LDAP channel binding always
  PASS LAN Manager auth level 5 (NTLMv2 only)
  PASS LLMNR turned off
  PASS NetBIOS over TCP/IP off on every adapter
  SKIP Credential Guard running (member machines only)
  PASS LSA protection (RunAsPPL) on
  PASS RDP Network Level Authentication required
  PASS RDP logon right limited to admin groups
  PASS Windows LAPS backs up the password
  PASS Windows LAPS password length 14 or more
  PASS Windows LAPS backs up the DSRM password
  result: 13 passed, 1 failed, 1 skipped
hosts checked: 1, failures: 1
exit code: 1

Thirteen rules pass, the changed one fails, Credential Guard is still skipped, and the exit code is 1. On a real DC, event 2887 counts unsigned binds and event 2889 (with LDAP interface logging raised) names each client, so you can fix clients before requiring signing.

07. Tiered administration, PAWs and security baselines

Registry values are half of hardening; the other half is who may sign in where. Tiered administration (Microsoft's Enterprise access model) splits identities and machines into layers by how much damage they can do. Tier 0, which the model expands into the control plane, is anything that controls identity: DCs, the AD database and the Entra Connect server. A Tier 0 credential is only typed on a Tier 0 machine. When a Domain Admin signs in to an ordinary workstation, their credential material stays in its memory, so whoever compromises that workstation inherits Tier 0. That is why the exports keep the RDP logon right to small named groups.

A privileged access workstation (PAW) is a locked-down machine used only for administration, with no email or general web browsing. Tiering and PAWs are designed controls, not registry keys, but they decide whether the keys above protect you.

Microsoft publishes security baselines in the Security Compliance Toolkit: GPO backups with recommended values, plus Policy Analyzer and LGPO to compare a host against them. Tailor one, then verify it with a checker like this.

08. Check your understanding

Practice check · 3 questions

Reading the checker

Three questions about the scoped baseline checker and the GPOs you applied.

Q1. You link the hardening GPOs, but `check_baseline.py after-ws01.json` still reports one FAIL and exits 1. What is the most useful conclusion?
Q2. A colleague wants to move the Credential Guard setting into the GPO linked at the domain root, so that every machine gets it. What is the problem with that plan?
Q3. An auditor's WS01 export (`domain_role` 1) is missing `lm_compat` but contains `"ldap_server_signing": 1`. What does the checker print for those two rules?
Practice only: not graded, not saved, not evidence.

09. Troubleshooting

10. Apply it

For the skill project, grow this into a usable audit:

  • Write a PowerShell script that reads each value in baseline_rules.py plus DomainRole on your lab DC and workstation and writes the JSON. Fix any FAIL through the right GPO.
  • Add a member-server export (domain_role 3) and one rule of your own with its scope, source and reason.
  • Open a Microsoft security baseline in Policy Analyzer and reconcile three of its values with your rules.

11. Review prompt

Without looking back, explain: why a linked GPO is not proof; how the checker uses domain_role; why LDAP rules are skipped on a workstation and Credential Guard on a DC; why the hardened exports are a negative test; two relay-related settings and what each blocks; what Windows LAPS manages on a member and on a DC; and where a Tier 0 credential may be typed.

References

Your progress

Reading state

Sign in to save that you finished reading this lesson.

Sign in to mark reading complete

Prove this skill

8 questions · about 6 minutes · scored automatically. Marking a lesson as read never demonstrates a skill.
Take the skill check