1. Resources
  2. Detection sources
  3. Event ID 4887

Event ID 4887: Certificate Services approved a certificate request and issued a certificate

Written by an AD CS certification authority each time it issues a certificate. Gives the requester, the request attributes and the certificate's subject: the record of every credential the CA hands out.

Log source
Windows Security log
Detection value
High
Volume
Medium
Last updated
Audit subcategory
Audit Certification Services (Object Access, Success and Failure)
Logged on
Certification authority servers only
Event versions
0, 1
Detects
4 attacks (1 rule · 4 detection logic)
MITRE ATT&CK
2 techniques in 3 tactics
Threat groups
7 groups that MITRE ATT&CK records using these techniques
Fields the rules read
Attributes

When it is written

A certification authority (CA) running Active Directory Certificate Services writes 4887 to its own Security log when it issues a certificate. On an enterprise CA most requests are issued at once, so 4887 follows the request event 4886 directly; on a stand-alone CA, Microsoft notes, a request stays pending until a CA administrator approves it. A request held as pending (4889) is issued later by a certificate manager, and 4887 then comes when that decision is made, possibly after changes to the request (4873, 4874). All of these events share the Request ID.

The CA writes it only when the Audit Certification Services subcategory is enabled on the CA server and the "Issue and manage certificate requests" category is selected in the CA's own audit filter. A domain controller logs it only if it also holds the CA role: collect the Security log of every CA server.

The event comes from the CA service, so it covers what the service issues. Microsoft's PKI monitoring guide lists use of the CA private key outside certsrv.exe as a separate activity to watch: a certificate signed that way does not pass through the service, so do not expect a 4887 for it.

How to turn it on

Advanced audit policy subcategory Audit Certification Services, Success and Failure. Set it in a Group Policy object linked to the computers that write the event:

Computer Configuration > Policies > Windows Settings > Security Settings > Advanced Audit Policy Configuration > Audit Policies > Object Access > Audit Certification Services
Microsoft's recommendation per computer role
ComputerAuditNote
Domain controllersSuccess if needed and Failure if neededMicrosoft marks every column "IF" (the same in its general and stronger baselines). Enable the subcategory when the server has the Active Directory Certificate Services role installed and you need to monitor AD CS events.
Member serversSuccess if needed and Failure if neededMicrosoft marks every column "IF" (the same in its general and stronger baselines). Enable the subcategory when the server has the Active Directory Certificate Services role installed and you need to monitor AD CS events.
WorkstationsNot loggedMicrosoft says the AD CS role cannot be installed on a client operating system.
Check the current setting
auditpol /get /subcategory:"Certification Services"
Based on vendor documentation.
Turn it on (local policy; a domain GPO overrides it)
auditpol /set /subcategory:"Certification Services" /success:enable /failure:enable
Based on vendor documentation.
The same on a Windows in another display language
auditpol /get /subcategory:"{0CCE9221-69AE-11D9-BED3-505054503030}"
Based on vendor documentation.

Run the commands in an elevated prompt on a computer that writes the event. Subcategory settings take effect only when the security option Audit: Force audit policy subcategory settings (Windows Vista or later) to override audit policy category settings is enabled (the default), and a Group Policy object that sets advanced audit policy replaces local changes at its next refresh. Microsoft's advanced audit policy reference

Two settings must both be on, on every CA server:

  1. The Audit Certification Services subcategory, Success and Failure (Microsoft's PKI monitoring guide asks for both).
  2. The Issue and manage certificate requests category in the CA's own audit filter: the Auditing tab of the CA's properties in the Certification Authority console, or bit value 4 of the CA's AuditFilter registry value (all seven categories together are 127). Microsoft's procedure restarts Certificate Services after the filter is changed. To read the current value on the CA: certutil -getreg CA\AuditFilter.

Microsoft notes that the audit filter alone does not make Windows write the event, and the subcategory alone does not either.

Fields

In Event Viewer order. The field names are those of the event XML, from the event template that ships with Windows.

FieldWhat it holdsSince
Request IDRequestIdCertificate Services approved a certificate request and issued a certificate.ID of the request in the CA database, a decimal number (shown as Request ID). The same ID appears in 4886 (request received), 4889 (pending), 4873 and 4874 (pending request changed).v0
RequesterCertificate Services approved a certificate request and issued a certificate.Account that submitted the request, as DOMAIN\name. Computer accounts end with $. The template has no field for the certificate manager who approves a pending request.v0
AttributesCertificate Services approved a certificate request and issued a certificate.Read by 1 ruleRequest attributes, as name:value pairs separated by new lines, for example CertificateTemplate:WebServer or san:dns=www.corp.example.com. Can be empty. The CA ignores case, spaces and hyphens in attribute names.v0
DispositionCertificate Services approved a certificate request and issued a certificate.Disposition of the request, the CA's decision code. Every 4887 is an issuance. Microsoft does not document the values the event writes; the 3 in the sample is the value its enrollment protocol (MS-WCCE) returns for an issued certificate, so check it on a record of your own.v0
SKISubjectKeyIdentifierCertificate Services approved a certificate request and issued a certificate.Subject key identifier of the issued certificate (shown as SKI), in hexadecimal. Microsoft describes it as typically a SHA-1 hash of the public key, so it identifies the certificate's key across systems.v0
Certificate SubjectSubjectCertificate Services approved a certificate request and issued a certificate.Subject name of the issued certificate (shown as Certificate Subject), as a distinguished name. Can be empty, for example when the template puts the identity only in the SAN.v0
Certificate SANSubjectAlternativeNameCertificate Services approved a certificate request and issued a certificate.Subject alternative name of the issued certificate (shown as Certificate SAN). Version 1; Microsoft does not document the field or its format.v1
Certificate TemplateCertificateTemplateCertificate Services approved a certificate request and issued a certificate.Template the certificate was issued from (shown as Certificate Template). Version 1; Microsoft does not document the field.v1
Serial NumberSerialNumberCertificate Services approved a certificate request and issued a certificate.Serial number of the issued certificate, in hexadecimal (shown as Serial Number). Version 1; Microsoft does not document the field.v1
Authentication ServiceAuthenticationServiceCertificate Services approved a certificate request and issued a certificate.Authentication service of the requester's connection to the CA (shown as Authentication Service). Version 1; Microsoft does not document the field or its values.v1
Authentication LevelAuthenticationLevelCertificate Services approved a certificate request and issued a certificate.Authentication level of the requester's connection to the CA (shown as Authentication Level). Version 1; Microsoft does not document the field or its values.v1
DCOMorRPCCertificate Services approved a certificate request and issued a certificate.Whether the request reached the CA over DCOM or over RPC. Windows enrollment clients use DCOM by default and can be told to use RPC instead. Version 1; Microsoft does not document the field or its values.v1

Event versions

The Windows event template has two versions. Version 0 has the six fields Microsoft documents: Request ID, Requester, Attributes, Disposition, SKI (subject key identifier) and Subject. Version 1 adds the certificate's subject alternative name, its template and serial number, and the authentication service, authentication level and transport (DCOM or RPC) of the connection. Microsoft's documentation does not describe version 1 or say which Windows release writes it. Our rule reads only Attributes, which both versions carry.

  • Version 0: 6 fields
  • Version 1: 12 fields, adds SubjectAlternativeName, CertificateTemplate, SerialNumber, AuthenticationService, AuthenticationLevel, DCOMorRPC

Values to know

Attributes

ValueMeaningSignal
san:A subject alternative name passed as a request attribute, for example san:upn=... or san:dns=...The value the rule looks for in Attributes. The CA used it for the certificate only if EDITF_ATTRIBUTESUBJECTALTNAME2 is enabled, in which case any requester can name another account (ESC6 in Microsoft's Defender for Identity assessments).Attack signal
CertificateTemplate:The template the request namedExpected
Any other nameAnother request attributeWorth knowing

Certificate SAN SubjectAlternativeName

ValueMeaningSignal
The requester's own namesA SAN that belongs to the requesting user or computerExpected
A UPN or DNS name of another accountA certificate that can identify someone other than the requesterVersion 1 only, and not read by our rule. Covers names supplied as an attribute and names supplied inside the request on templates that let the enrollee supply them.Attack signal

Certificate Template CertificateTemplate

ValueMeaningSignal
Enrollment agent, key recovery agent or code signing templatesCertificates with privileged usesMicrosoft advises watching their issuance. An enrollment agent certificate can request certificates on behalf of other users. Version 1 only.Attack signal
User, computer, domain controller and web server templatesOrdinary issuanceExpected

Requester

ValueMeaningSignal
Ends with $A computer account, usually autoenrollmentExpected
An account that does not match the certificate's subject or SANA certificate for another identityLook for a certificate logon (4768 with a certificate) by the named account soon after.Attack signal

Volume and noise

One event per issued certificate, so its volume follows the CA's issuance: autoenrollment and renewal of user and computer certificates (computer requesters end with $), domain controller and web server certificates. Microsoft notes that the "Issue and manage certificate requests" category can produce a large number of events on a CA that issues many certificates, and still recommends it for the audit trail. It rates 4887 medium and advises watching the issuance of certificates with privileged uses, such as enrollment agent or code signing, and certificates issued to high-value users.

Keeping it manageable

  • Keep every event: the SAN rule reads Attributes of every issuance, and several detection hypotheses follow an issued certificate to its use on a domain controller.
  • Alert on content, not volume: a san: attribute, a requester that does not match the certificate's subject or SAN, or a sensitive template (enrollment agent, key recovery agent, code signing, any template whose certificates authenticate) issued to an unusual requester.
  • Keep the SerialNumber (version 1) or look it up by RequestId in the CA database: revocation, and the certificate logon on a domain controller (4768), refer to the certificate, not to the request.
  • Record the accounts that legitimately add DNS names through a san: attribute, and review upn= entries separately from dns= entries.

Sample event

Version 1, with made-up values.

<Event xmlns="http://schemas.microsoft.com/win/2004/08/events/event">
  <System>
    <Provider Name="Microsoft-Windows-Security-Auditing" Guid="{54849625-5478-4994-a5ba-3e3b0328c30d}" />
    <EventID>4887</EventID>
    <Version>1</Version>
    <Level>0</Level>
    <Task>0</Task>
    <Opcode>0</Opcode>
    <Keywords>0x8020000000000000</Keywords>
    <TimeCreated SystemTime="2026-11-18T09:30:12.4567890Z" />
    <EventRecordID>1048576</EventRecordID>
    <Correlation />
    <Execution ProcessID="712" ThreadID="2408" />
    <Channel>Security</Channel>
    <Computer>CA01.corp.example.com</Computer>
    <Security />
  </System>
  <EventData>
    <Data Name="RequestId">4135</Data>
    <Data Name="Requester">CORP\alice</Data>
    <Data Name="Attributes">CertificateTemplate:User</Data>
    <Data Name="Disposition">3</Data>
    <Data Name="SubjectKeyIdentifier">4f 8b 2c 91 d0 37 6a e5 13 c8 72 9e 05 bb 41 6d 2a f0 c3 18</Data>
    <Data Name="Subject">CN=alice, OU=Staff, DC=corp, DC=example, DC=com</Data>
    <Data Name="SubjectAlternativeName">Other Name:Principal Name=alice@corp.example.com</Data>
    <Data Name="CertificateTemplate">User</Data>
    <Data Name="SerialNumber">5a00001027c4e1b9f2d6a8f9c300000000102f</Data>
    <Data Name="AuthenticationService">Kerberos</Data>
    <Data Name="AuthenticationLevel">Packet Privacy</Data>
    <Data Name="DCOMorRPC">DCOM</Data>
  </EventData>
</Event>

Attacks this event reveals

Detection rules that read this event:

Detection logic (hypotheses that join this event with others) for:

Frequently asked questions

Which 4887 events should I review?

Issuances whose request attributes contain a SAN attribute, certificates whose subject or SAN names an account other than the requester, and certificates from templates with privileged uses such as enrollment agent or code signing, which Microsoft's PKI guide singles out together with certificates for high-value users.

Can I see the certificate's subject alternative name in 4887?

Only on CAs that write version 1 of the event, which adds the certificate's SAN, template and serial number; Microsoft does not document these fields. Version 0 gives the subject and the request attributes. The certificate itself is in the CA database under the Request ID.

How do I connect an issued certificate to a logon?

A domain controller writes 4768 for a ticket requested with a certificate, with the certificate's issuer, serial number and thumbprint. Match the serial number of the certificate (from version 1 of 4887 or from the CA database), after bringing both values to the same format, and compare the account of the logon with the requester.

References