Microsoft changed the key concept for LAPS.
New Policies, LAPS for Windows, LAPS in Azure AD etc.
Check out the following Link:
https://learn.microsoft.com/en-us/windows-server/identity/laps/laps-concepts
Microsoft changed the key concept for LAPS.
New Policies, LAPS for Windows, LAPS in Azure AD etc.
Check out the following Link:
https://learn.microsoft.com/en-us/windows-server/identity/laps/laps-concepts
Most time there should be warning events in the System event log, with a source called Time-Service.
To verify network connection and ntp settings you can use w32tm.
show source server:
w32tm /query /source
verify network connectivity to an NTP server:
w32tm /stripchart /computer:ntp01.mydomain.zz
show configuration:
w32tm /query /configuration
(NT5DS using domain hierarchy)
force client to use domain hierarchy:
w32tm /config /syncfromflags:domhier /update
Find attached a script to get all systems that using zerologon (event 5829) described in CVE-2020-1472. I want to upload this script to my technet gallery, but MS changed it all so I cant acces it...
More infos about this topic and how to handle the update process:
You can change the event to find other objects like trusts etc.
# --------------------------------------------------------------------------------------------------------
# Author: Tim Buntrock
# Script: Get_ZeroLogons5829.ps1
# Description: Get all machinesamaccountnames that appear in Event 5829, to find systems using zerologon!
# --------------------------------------------------------------------------------------------------------
# Prepare Variables
Param (
[parameter(Mandatory=$false,Position=0)][String]$DCName = "localhost",
[parameter(Mandatory=$false,Position=1)][Int]$Minutes = 15)
# Create an Array to hold the values
$InsecureNetLogons = @()
# Grab the appropriate events
$Events = Get-WinEvent -ComputerName $DCName -FilterHashtable @{Logname='System';Id=5829; StartTime=(get-date).AddMinutes("-$Minutes")}
# Loop through each event
ForEach ($Event in $Events) {
$eventXML = [xml]$Event.ToXml()
$Client = ($eventXML.event.EventData.Data[0]) #get Machinesamaccountname
# Add Them To a Row in our Array
$Row = "" | select Client
$Row.Client =$Client
# Add the row to our Array
$InsecureNetLogons += $Row
}
# Dump it all out to a CSV and open gridview
Write-Host $InsecureNetLogons.Count "records found ... saving unique entries to .\InsecureNetLogons.csv for DC" $ComputerName -ForegroundColor DarkYellow
$InsecureNetLogons | Sort-Object -Unique -Property Client| Export-CSV -NoTypeInformation .\InsecureNetLogons.csv
$InsecureNetLogons | Sort-Object -Unique -Property Client| Out-GridView
Activate debug logging using nltest and set log
size using registry
Type the
following command, and then press Enter to enable logging:
Nltest
/DBFlag:2080FFFF
Setting the
maximum log file size for Netlogon logs using Registry
The
MaximumLogFileSize registry entry can be used to specify the maximum size. You must
create this entry, because it doesn´t exist.
Path:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Netlogon\Parameters
Value Name:
MaximumLogFileSize
Value Type:
REG_DWORD
Value Data:
<max log file size in bytes>
1073741824 Bytes
is 1 GB
This registry setting specify the disk space for the Netlogon.log and Netlogon.bak file. For example, a setting of 1 GB can require 2 GB of disk space.
Using Policy to enable logging and configuring
log size
You can use
the following Computer policy to configure the log file size in bytes and debug
level:
Computer
Configuration\Administrative Templates\System\Net Logon\Specify maximum log file
size
1073741824 (
Computer
Configuration\Administrative Templates\System\Net Logon\Specify log file debug
output level
545325055 (
Bind
operations are used to authenticate clients to the Domain Controller, to
establish an authorization identity that will be used for subsequent operations
processed on that connection, and to specify the LDAP protocol version that the
client will use.
This LDAP
authentication process supports three types:
With a LDAP
Simple Bind, the credentials of a user, that are used to bind the LDAP client
to the Domain Controller are unencrypted.
SASL is the
term for a framework of mechanisms that allow for secured authentication to
take place over an unencrypted or encrypted communications channel. In this
case Kerberos V5 is used for authentication. Most Microsoft Consoles using SASL
to authenticate.
Active
Directory also supports this authentication approach during LDAP binds and is
intended for compatibility with legacy systems and will result in NTLM being
used as underlying authentication protocol.
So let´s clarify what´s LDAPS about...
It's a mechanism
that uses TLS to secure communication between LDAP clients and Domain Controllers
to avoid insecure simple bind or securing auth for clients that are not supporting SASL.
The
following scenarios are possible:
LDAPS
over port 636 (DC) or port 3269 (GC) where the connection is immediately
secured by the certificate. SSL/TLS is negotiated before any LDAP traffic happens.
LDAP
using StartTLS over port 389 (DC) or 3268 (GC) where the StartTLS operation
is used to establish secure communications. It requires the LDAP client to
support StartTLS operation.