Safeguard the Windows host operating system¶
The security of the Windows host directly impacts the safety of the containers that run on it. Hardening the operating system is the first step to securing MCR.
Advanced Group Policy Configurations¶
Group Policy is a critical tool for enforcing security configurations across the host environment. Advanced settings for securing Windows are offered below:
Account policies
Set password policies to enforce complexity, expiration, and minimum length:
From the Search bar, run
gpedit.msc
.Navigate to Computer Configuration > Windows Settings > Security Settings > Account Policies > Password Policy.
Set Minimum password length to 14 characters and enable Password must meet complexity requirements..
Configure Account lockout threshold to 5 failed attempts.
Logon restrictions
Limit local and remote logon rights to specific administrative accounts:
Navigate to Computer Configuration > Windows Settings > Security Settings > Local Policies > User Rights Assignment.
Assign Deny log on locally to unauthorized groups, and restrict Allow log on through Remote Desktop Services.
Restrict Access to System Tools
Block access to registry editing tools and command-line interpreters for non-administrative users using Software Restriction Policies or AppLocker:
Navigate to guilabel:Computer Configuration > Windows Settings > Security Settings > Application Control Policies > AppLocker > Executable Rules > Create new rule.
Input the following as a rule:
- Deny - Select users or groups - Select "Path" - Paths for registry editing tools: - %windir%\regedit.exe - %windir%\system32\regedt32.exe Paths for command-line interpreters: - %windir%\system32\cmd.exe - %windir%\system32\windowspowershell\v1.0\powershell.exe
Adjust Local Security Policy¶
The Local Security Policy tool provides granular controls over system security. Mirantis recommends that you disable NTLM authentication and secure anonymous access
Disable NTLM Authentication
To enforce the use of Kerberos for authentication to reduce susceptibility to pass-the-hash attacks:
Navigate to Local Policies > Security Options > Network security: Restrict NTLM: NTLM Authentication in this domain > Deny All > Apply.
Secure Anonymous Access
Navigate to Local Policies > Security Options and enable:
Harden File System and Registry Permissions¶
To prevent unauthorized tampering, restrict access to all critical system directories, for example C:WindowsSystem32:
Open File Explorer and navigate to C:Windows.
Right-click on the
System32
folder and select Properties.Go to the Security tab and click on Advanced >Tab Auditing > Flag “Replace all child object auditing entries with inheritable auditing entries from this object.
Click on Disable inheritance.
Use Access Control Lists (ACLs)) to secure sensitive registry keys:
icacls "HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Services\docker" /deny "Users:(F)"
Use the Registry Editor, as it is forbidden to use icacls by way of the CLI.
Network Security Enhancements¶
Host-Based Firewall Rules
Configure Windows Defender Firewall to block all inbound traffic by default and to only allow explicitly defined traffic into container endpoints:
New-NetFirewallRule -DisplayName "Deny All Inbound" -Direction Inbound -Action Block
IPsec Policies
Implement IPsec rules to secure network traffic:
Access the Windows Advanced Firewall MMC snap-in to configure IPsec for container-to-host communications.
Open firewall settings by way of CLI
wf.msc
.Go to Connection Security Rules > New Rule..(Depending on the application and its traffic).
For DNS Security, deploy DNSSEC to authenticate DNS responses and mitigate DNS spoofing. DNS server must be installed.
DNS Security
Deploy DNSSEC to authenticate DNS responses and to mitigate DNS spoofing.
Secure Boot and Credential Guard¶
Enable Secure Boot, which ensures that only signed OS components load during startup, by running msinfo32.exe.
Check Secure Boot State under System Summary.
Enable Credential Guard, to isolate secrets using virtualization-based security, by way of Group Policy. #. Navigate to :guilabel:Computer Configuration > Administrative Templates > System > Device Guard. #. Click on Turn on Virtualization Based Security. #. Click on Enabled. #. Click Apply.