New ESC15 vulnerability discovered in Active Directory Certificate Services - easy-to-implement countermeasures

The purposes for which a digital certificate may be used are controlled via the "Key Usage" and "Extended Key Usage" certificate extensions. The "Extended Key Usage" certificate extension contains the extended key usages for which the certificate may be used.

However, certificates issued by a Microsoft certification authority contain another certificate extension called "Application Policies", which also contains a list very similar to the Extended Key Usages extension.

Justin Bollinger from TrustedSec has found out that with offline certificate requests against schema version 1 certificate templates it is possible (similar to the Security Identifier extension ) to include arbitrary Application Policies in the certificate request, which are transferred unchanged to the issued certificate and can then be used to attack the Active Directory forest. The attack was named ESC15.

Continue reading "New ESC15 vulnerability discovered in Active Directory Certificate Services - easy-to-implement countermeasures"

Logons via the Network Policy Server (NPS) fail with reason "Authentication failed due to a user credentials mismatch. Either the user name provided does not map to an existing user account or the password was incorrect."

Assume the following scenario:

  • A certificate-based logon is performed with user or computer accounts to log them on to a wireless (IEEE 802.11 or Wireless LAN) or wired network (IEEE 802.3), or to a remote access connection (e.g. DirectAccess, Routing and Remote Access (RAS), Always on VPN ).
  • As a server for authentication, authorization and accounting (AAA), the company uses the Network Policy Server (NPS) from Microsoft.
  • Logging on to the network is no longer possible.
  • The Network Policy Server logs the following event when a logon attempt is made:
Network Policy Server denied access to a user. [...] Authentication failed due to a user credentials mismatch. Either the user name provided does not map to an existing user account or the password was incorrect.
Der Netzwerkrichtlinienserver hat einem Benutzer den Zugriff verweigert. [...] Authentifizierungsfehler aufgrund der Nichtübereinstimmung von Benutzeranmeldeinformationen. Der angegebene Benutzername ist keinem vorhandenen Benutzerkonto zugeordnet, oder das Kennwort war falsch.

Continue reading "Logons via the Network Policy Server (NPS) fail with reason "Authentication failed due to a user credentials mismatch. Either the user name provided does not map to an existing user account or the password was incorrect.""

Details of the event with ID 39 of the source Microsoft-Windows-Kerberos-Key-Distribution-Center

Event Source:Microsoft-Windows-Kerberos-Key-Distribution-Center
Event ID:39 (0x80000027)
Event log:System
Event type:Warning or error
Event text (English):The Key Distribution Center (KDC) encountered a user certificate that was valid but could not be mapped to a user in a secure way (such as via explicit mapping, key trust mapping, or a SID). Such certificates should either be replaced or mapped directly to the user via explicit mapping. See https://go.microsoft.com/fwlink/?linkid=2189925 to learn more. User: %1 Certificate Subject: %2 Certificate Issuer: %3 Certificate Serial Number: %4 Certificate Thumbprint: %5
Event text (German):Der Schlüsselverteilungscenter (KDC) hat ein gültiges Benutzerzertifikat gefunden, das jedoch keinem Benutzer auf sichere Weise zugeordnet werden konnte (z. B. über eine explizite Zuordnung, eine Schlüsselvertrauenszuordnung oder eine SID). Solche Zertifikate sollten entweder ersetzt oder dem Benutzer über eine explizite Zuordnung direkt zugeordnet werden. Weitere Informationen finden Sie unter https://go.microsoft.com/fwlink/?linkid=2189925 . Benutzer: %1 Zertifikatantragsteller: %2 Zertifikataussteller: %3 Zertifikatseriennummer: %4 Zertifikatfingerabdruck: %5

Continue reading "Details of the event with ID 39 of the source Microsoft-Windows-Kerberos-Key-Distribution-Center"

A policy module to tame them all: Introducing the TameMyCerts Policy Module for Microsoft Active Directory Certificate Services

As the operator of a certification authority, you are (among other things) responsible for the identification of the enrollees and the confirmation of the requested identities . The fact that this task is carried out conscientiously and without error is the central pillar of the trust placed in the certification authority. Well-known companies have already failed at this task , even had to file for insolvency as a result of misissuances and/or were severely punished by the big players in the market.

In many cases, we as (Microsoft) PKI operators in companies (regardless of the associated quality) are able to delegate our task of uniquely identifying an enrollee to the Active Directory. In many cases, however, we unfortunately also have to instruct our certification authority(ies) to simply issue everything that is requested.

Continue reading "A policy module to tame them all: Introducing the TameMyCerts Policy Module for Microsoft Active Directory Certificate Services"

Changes to Certificate Issuance and Certificate-Based Logon to Active Directory with the May 10, 2022 Patch for Windows Server (KB5014754)

With the May 10, 2022 patch, Microsoft is attempting to close a vulnerability in Active Directory that affects certificate-based logon (commonly known as PKINIT or also smart card logon ).

The update changes both the behavior of the certification authority as well as the behavior of Active Directory when processing certificate-based logons.

Continue reading "Changes to Certificate Issuance and Certificate-Based Logon to Active Directory with the May 10, 2022 Patch for Windows Server (KB5014754)"

About the "Build this from Active Directory information" option for certificate templates

When configuring a certificate template, one must decide on the intended certificate content, i.e., among other things, which identities are confirmed by the certificates and how they are mapped.

In the "Subject Name" tab of the certificate template configuration dialog, you can configure how the identity confirmed by the certificate is mapped.

Continue reading "About the "Build this from Active Directory information" option for certificate templates"

Details of the event with ID 4889 of the source Microsoft-Windows-Security-Auditing

Event Source:Microsoft-Windows-Security-Auditing
Event ID:4889 (0x1319)
Event log:Security
Event type:Information
Event text (English):Certificate Services set the status of a certificate request to pending. Request ID: %1 Requester: %2 Attributes: %3 Disposition: %4 SKI: %5 Subject: %6
Event text (German):Die Zertifikatdienste haben den Status einer Zertifikatanforderung als "anstehend" festgelegt. Anforderungs-ID: %1 Antragsteller: %2 Attribute: %3 Disposition: %4 SKI: %5 Betreff: %6

Continue reading "Details of the event with ID 4889 of the source Microsoft-Windows-Security-Auditing"

Details of the event with ID 4888 of the source Microsoft-Windows-Security-Auditing

Event Source:Microsoft-Windows-Security-Auditing
Event ID:4888 (0x1318)
Event log:Security
Event type:Information
Event text (English):Certificate Services denied a certificate request. Request ID: %1 Requester: %2 Attributes: %3 Disposition: %4 SKI: %5 Subject: %6
Event text (German):Die Zertifikatdienste haben eine Zertifikatanforderung abgelehnt. Anforderungs-ID: %1 Antragsteller: %2 Attribute: %3 Disposition: %4 SKI: %5 Betreff: %6

Continue reading "Details of the event with ID 4888 of the source Microsoft-Windows-Security-Auditing"

Details of the event with ID 4887 of the source Microsoft-Windows-Security-Auditing

Event Source:Microsoft-Windows-Security-Auditing
Event ID:4887 (0x1317)
Event log:Security
Event type:Information
Event text (English):Certificate Services approved a certificate request and issued a certificate. Request ID: %1 Requester: %2 Attributes: %3 Disposition: %4 SKI: %5 Subject: %6
Event text (German):Die Zertifikatdienste haben eine Zertifikatanforderung genehmigt und ein Zertifikat ausgestellt. Anforderungs-ID: %1 Antragsteller: %2 Attribute: %3 Disposition: %4 SKI: %5 Betreff: %6

Continue reading "Details of the event with ID 4887 of the source Microsoft-Windows-Security-Auditing"