In modern enterprise identity architectures, an internal Public Key Infrastructure (PKI) is no longer just for issuing web server SSL certificates. With Microsoft enforcing phishing-resistant authentication, Certificate-Based Authentication (CBA) in Microsoft Entra ID, smart cards, and certificate-driven automation in Exchange Online, Active Directory Certificate Services (AD CS) serves as the bedrock of zero-trust security.
Deploying an Enterprise Certificate Authority on modern Windows Server (2025 or 2022) requires adhering to modern cryptographic standards: discarding obsolete SHA-1 hashing, implementing modern Key Storage Providers (KSP) rather than legacy CryptoAPI CSPs, and configuring robust CRL Distribution Points (CDP) and AIA paths.
In this updated runbook, we walk through the step-by-step deployment of an Enterprise Certificate Authority using automated PowerShell cmdlets and secure best practices.
Enterprise PKI Architecture: The Modern Two-Tier Model
In a production enterprise deployment, never install an Enterprise Root CA directly on a domain controller or expose a Root CA online. The industry standard is a Two-Tier PKI Hierarchy:
- Tier 1: Standalone Offline Root CA: A non-domain-joined, air-gapped machine kept offline. It signs the subordinate CA certificate and publishes a long-lived Certificate Revocation List (CRL).
- Tier 2: Enterprise Issuing Subordinate CA: A domain-joined server integrated with Active Directory. It issues client authentication certificates, smart card logon certificates, and Entra ID CBA certificates based on AD CS Certificate Templates.
(For lab and staging environments, an Enterprise Root CA can be deployed directly to demonstrate end-to-end enrollment workflows).
Phase 1: Installing the AD CS Server Roles via PowerShell
On Windows Server 2025 or 2022, avoid tedious Server Manager wizards. Open an elevated PowerShell prompt and install the AD CS role, Certification Authority management tools, and Web Enrollment:
# Install Active Directory Certificate Services and Management Tools
Install-WindowsFeature `
-Name "AD-Certificate", "ADCS-Cert-Authority", "ADCS-Web-Enrollment", "RSAT-ADCS-Mgmt" `
-IncludeManagementTools
# Verify installed features
Get-WindowsFeature | Where-Object { $_.Name -like "*ADCS*" -and $_.Installed }
Phase 2: Configuring the Enterprise Root / Issuing CA
Once binaries are installed, execute the post-installation configuration using Install-AdcsCertificationAuthority.
Enterprise Root CA Deployment (Lab / Standalone Model)
# Parameters for modern cryptographic configuration
$CaConfig = @{
CAType = "EnterpriseRootCA"
CryptoProviderName = "RSA#Microsoft Software Key Storage Provider" # Modern KSP
HashAlgorithmName = "SHA256" # Zero SHA-1
KeyLength = 4096 # 4096-bit RSA
CACommonName = "LAB365-Root-CA"
ValidityPeriod = "Years"
ValidityPeriodUnits= 10
DatabaseLocations = "C:\Windows\System32\CertLog"
LogLocations = "C:\Windows\System32\CertLog"
OverwriteExistingKey = $false
}
Install-AdcsCertificationAuthority @CaConfig -Verbose
Subordinate CA Deployment (Production Two-Tier Model)
For an Enterprise Subordinate CA, generate a Certificate Signing Request (CSR) to be signed by your offline Root CA:
# Subordinate CA configuration
$SubCaConfig = @{
CAType = "EnterpriseSubordinateCA"
CryptoProviderName = "RSA#Microsoft Software Key Storage Provider"
HashAlgorithmName = "SHA256"
KeyLength = 4096
CACommonName = "LAB365-Issuing-CA01"
OutputFileName = "C:\Certs\LAB365-Issuing-CA01.req"
}
Install-AdcsCertificationAuthority @SubCaConfig -Verbose
Phase 3: Post-Installation Hardening & URL Path Configuration
A Certificate Authority cannot function properly without accessible AIA (Authority Information Access) and CDP (CRL Distribution Point) endpoints. If clients cannot verify certificate revocation via HTTP, certificate validation fails across Entra ID, VPNs, and Exchange Online.
1. Configure CDP (CRL Distribution Point)
Configure clean HTTP distribution points rather than legacy LDAP paths:# Define Web CRL Distribution Point
$CrlHttpUrl = "http://pki.lab365.in/pki/<CaName><CRLNameSuffix><DeltaCRLAllowed>.crl"
certutil -setreg CA\CRLPublicationURLs "1:C:\Windows\system32\CertSrv\CertEnroll\%3%8%9.crl\n65:$CrlHttpUrl"
2. Configure AIA (Authority Information Access)
Publish the CA's public certificate (.crt) for chain-building:
# Define Web AIA URL
$AiaHttpUrl = "http://pki.lab365.in/pki/<CaName><CertificateName>.crt"
certutil -setreg CA\CACertPublicationURLs "1:C:\Windows\system32\CertSrv\CertEnroll\%1_%3%4.crt\n2:$AiaHttpUrl"
3. Adjust CRL Overlap and Publication Intervals
# Set Base CRL publication to 7 days with a 24-hour overlap
certutil -setreg CA\CRLPeriodUnits 7
certutil -setreg CA\CRLPeriod "Days"
certutil -setreg CA\CRLDeltaPeriodUnits 1
certutil -setreg CA\CRLDeltaPeriod "Days"
certutil -setreg CA\CRLOverlapUnits 24
certutil -setreg CA\CRLOverlapPeriod "Hours"
# Restart the CertSvc service to commit changes
Restart-Service CertSvc
# Force immediate CRL publication
certutil -CRL
Phase 4: Deploying Certificates for Entra ID & Exchange Online
Once your CA is operational, you can leverage it across Microsoft 365 services:
- Microsoft Entra ID Certificate-Based Authentication (CBA):
Export the Root CA public certificate (certutil -ca.cert RootCA.cer) and upload it to the Microsoft Entra admin center under Protection > Authentication methods > Certificate-based authentication. Review our guide on Migrating Exchange ActiveSync Direct CBA to Entra ID CBA.
- Exchange Online Application Authentication:
Issue a client authentication certificate to authenticate daemon scripts via Microsoft Graph without passwords. Review our runbook on Connecting to Exchange Online using Certificate Authentication.
Summary Checklist
| Component | Modern Standard | Legacy Pitfall |
|---|---|---|
| Hash Algorithm | SHA-256 or SHA-384 | SHA-1 (Cryptographically broken) |
| Provider | Microsoft Software Key Storage Provider (KSP) | CryptoAPI CSP |
| Root Key Length | 4096-bit RSA | 1024-bit or 2048-bit |
| Revocation Paths | High-availability HTTP Web URLs | Internal LDAP-only paths (Unreachable outside domain) |
| Architecture | 2-Tier (Offline Root + Online Issuing) | Single-Tier Root on Domain Controller |