Skip to content

Instantly share code, notes, and snippets.

View richardhicks's full-sized avatar

Richard M. Hicks richardhicks

View GitHub Profile
@richardhicks
richardhicks / Configure-Nat64.ps1
Last active May 14, 2025 19:13
Configure NAT64 on Windows Server
# This Gist contains PowerShell commands to enable NAT64 on a Windows server.
# Reference: https://learn.microsoft.com/en-us/powershell/module/networktransition/new-netnattransitionconfiguration
# Define variables
$AcceptInterface = 'LAN' # The interface name or alias that will accept NAT64 traffic
$SendInterface = 'DMZ' # The interface name or alias that will send NAT64 traffic
$Nat64Prefix = '64:ff9b::/96' # The NAT64 prefix
$Ipv4Address = '172.16.1.216' # The IPv4 address of the NAT64 server
# Configure NAT64
@richardhicks
richardhicks / Configure-Dns64.ps1
Created May 14, 2025 19:12
Configure DNS64 on Windows Server
# This Gist contains PowerShell commands to enable DNS64 on a Windows server.
# Reference: https://learn.microsoft.com/en-us/powershell/module/networktransition/set-netdnstransitionconfiguration
# Define variables
$AcceptInterface = 'LAN' # The interface name or alias that will accept DNS64 traffic
$SendInterface = 'LAN' # The interface name or alias that will send DNS64 traffic
$Nat64Prefix = '64:ff9b::/96' # The NAT64 prefix
# Configure DNS64
Set-NetDnsTransitionConfiguration -State Enabled -AcceptInterface $AcceptInterface -SendInterface $SendInterface -PrefixMapping "$Nat64Prefix,0.0.0.0/0" -PassThru
@richardhicks
richardhicks / Optimize-DomainControllerTlsCipherSuites.ps1
Last active March 22, 2024 18:53
Disable Insecure TLS Cipher Suites for LDAPS on Domain Controllers
# This Gist is a PowerShell script to set the SSL Cipher Suite Order Group Policy Object (GPO) for Windows Server 2016 and 2019/2022.
# Reference: https://www.dsinternals.com/en/active-directory-domain-controller-tls-ldaps/
# Security optmized cipher suite list for Windows Server 2019/2022
$Ciphers2022 = 'TLS_AES_256_GCM_SHA384,TLS_AES_128_GCM_SHA256,TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384,TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256,TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384,TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256'
# Security optmized cipher suite list for Windows Server 2016
$Ciphers2016 = 'TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384,TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256,TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384,TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256'
$GpoName = 'Domain Controller Security Baseline'