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

Event ID 4741: A computer account was created

Written by a domain controller each time a computer account is created, by an administrator, a deployment account or a user joining a machine through the machine account quota. Shows who created it, its initial flags and its SPNs.

Log source
Windows Security log
Detection value
High
Volume
Low
Last updated
Audit subcategory
Audit Computer Account Management (Account Management, Success)
Logged on
Domain controllers only
Event versions
0
Detects
4 attacks (4 rules · 3 detection logic)
MITRE ATT&CK
2 techniques in 2 tactics
Threat groups
10 groups that MITRE ATT&CK records using these techniques
Fields the rules read
SubjectUserNameUserAccountControl

When it is written

A domain controller writes 4741 each time a computer object is created in the domain: an administrator creating the account in advance, a user or a service joining a computer to the domain, or any program that creates the object over LDAP or the SAM remote protocol. Microsoft says only domain controllers write it. Subject is the account that created the computer object; New Computer Account is the new account. No SACL is needed.

The event lists the account's initial attributes. Microsoft notes that for a computer joined to the domain in the usual way Password Last Set holds the creation time and Service Principal Names holds HOST and RestrictedKrbHost names, while an account created by hand in Active Directory Users and Computers shows <never> and a dash. When a user joins a computer with the Add workstations to domain right, the number of computers it can create is limited by ms-DS-MachineAccountQuota, 10 by default. Microsoft lists Authenticated Users as the default holder of that right on domain controllers, so unless it was changed any authenticated user can create computer accounts up to the quota.

The two ways of creating an account mark the object differently, and the event shows neither mark. Microsoft says an account created through the Add workstations to domain right is owned by Domain Admins, while one created through the Create Computer objects permission on the container is owned by its creator, and it points to the ms-DS-CreatorSID attribute of machine accounts for counting the accounts a user created under the quota. Read both from the object.

A creation the domain controller refuses writes no 4741: the subcategory has no failure events. Since the November 9, 2021 updates (KB5008102), a domain controller blocks a non-administrator from creating a computer account whose name lacks the trailing $, or whose object class and account type flags do not match, and logs event 16991 or 16990 of Directory-Services-SAM in the System log.

How to turn it on

Advanced audit policy subcategory Audit Computer Account Management, Success. 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 > Account Management > Audit Computer Account Management
Microsoft's recommendation per computer role
ComputerAuditNote
Domain controllersSuccessMicrosoft recommends Success auditing in both its general and stronger baselines and monitoring changes to critical computer objects such as domain controllers, administrative workstations and critical servers, especially their deletion. The subcategory has no failure events.
Member serversNot loggedMicrosoft says the subcategory generates events only on domain controllers.
WorkstationsNot loggedMicrosoft says the subcategory generates events only on domain controllers.
Check the current setting
auditpol /get /subcategory:"Computer Account Management"
Based on vendor documentation.
Turn it on (local policy; a domain GPO overrides it)
auditpol /set /subcategory:"Computer Account Management" /success:enable
Based on vendor documentation.
The same on a Windows in another display language
auditpol /get /subcategory:"{0CCE9236-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

No SACL is needed: Audit Computer Account Management (Success) on every domain controller is enough. Microsoft's Advanced Audit Policy Configuration page lists Success as the default for this subcategory on server editions, but a Group Policy can change it, so check the setting with auditpol on each domain controller.

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
Security IDSubjectUserSidSubjectSID of the account that created the computer object.v0
Account NameSubjectUserNameSubjectRead by 2 rulesName of the account that created the computer object. A name ending with $ is a computer account; the two creation rules split on this.v0
Account DomainSubjectDomainNameSubjectDomain of the creating account, usually as a NetBIOS name.v0
Logon IDSubjectLogonIdSubjectLogon ID of the creating session, in hexadecimal. Matches the 4624 of that session on this domain controller, which gives the client address.v0
Security IDTargetSidNew Computer AccountSID of the new account. Event Viewer resolves it to a name.v0
Account NameTargetUserNameNew Computer AccountName of the new computer account, its sAMAccountName ending with $.v0
Account DomainTargetDomainNameNew Computer AccountDomain of the new account, usually as a NetBIOS name.v0
SAM Account NameSamAccountNameAttributesPre-Windows 2000 logon name (sAMAccountName) of the new account, with the trailing $.v0
Display NameDisplayNameAttributesdisplayName of the new account. Optional for computers and usually a dash.v0
User Principal NameUserPrincipalNameAttributesuserPrincipalName of the new account. Usually not set on computers; a value deserves a look.v0
Home DirectoryHomeDirectoryAttributeshomeDirectory. Usually a dash for computers.v0
Home DriveHomePathAttributesHome Drive (homeDrive), shown as Home Drive in Event Viewer. Usually a dash for computers.v0
Script PathScriptPathAttributesscriptPath, a logon script. Usually a dash for computers.v0
Profile PathProfilePathAttributesprofilePath. Usually a dash for computers.v0
User WorkstationsUserWorkstationsAttributesuserWorkstations, the computers the account may log on from. Usually a dash for computers.v0
Password Last SetPasswordLastSetAttributespwdLastSet as a date and time; the creation time after a normal domain join, (%%1794) for an account created by hand.v0
Account ExpiresAccountExpiresAttributesaccountExpires; normally (%%1794). Microsoft says another value is an anomaly worth monitoring.v0
Primary Group IDPrimaryGroupIdAttributesRID of the primary group, normally 515 (Domain Computers), 516 (Domain Controllers) or 521 (Read-only Domain Controllers).v0
AllowedToDelegateToAttributesmsDS-AllowedToDelegateTo, the services this account may delegate to (constrained delegation). Normally a dash on a new account.v0
Old UAC ValueOldUacValueAttributesAlways 0x0 for a new account (Microsoft).v0
New UAC ValueNewUacValueAttributesAccount flags of the new account in hexadecimal, in the SAM encoding, which Microsoft says differs from the userAccountControl attribute; for example 0x80 for a workstation trust account.v0
User Account ControlUserAccountControlAttributesRead by 2 rulesThe flags of the new account, one %% code per flag, for example %%2087 ('Workstation Trust Account' - Enabled). In the Windows message file codes from %%2080 mean a flag was set and codes from %%2048 to %%2079 that it was cleared.v0
User ParametersUserParametersAttributesuserParameters (dial-in settings). Usually a dash.v0
SID HistorySidHistoryAttributessIDHistory. Always a dash unless the account was migrated from another domain (Microsoft).v0
Logon HoursLogonHoursAttributeslogonHours. (%%1793) for new computer accounts (Microsoft).v0
DNS Host NameDnsHostNameAttributesdNSHostName, the computer's DNS name. Set by a normal join, a dash for an account created by hand.v0
Service Principal NamesServicePrincipalNamesAttributesservicePrincipalName values, separated by spaces in the XML. After a normal join HOST and RestrictedKrbHost names for the short and DNS names; a dash for an account created by hand.v0
PrivilegeListPrivileges used for the operation, or a dash when none was captured.v0

Values to know

User Account Control UserAccountControl

ValueMeaningSignal
%%2087'Workstation Trust Account' - EnabledAn ordinary member computer, as in Microsoft's sample.Expected
%%2088'Server Trust Account' - EnabledMarks a domain controller account. Microsoft says it should be enabled only for domain controllers; the server trust rule reads it.Attack signal
%%2093'Trusted For Delegation' - EnabledUnconstrained delegation. Microsoft says it should not be enabled for new member servers and workstations; it is enabled by default for new domain controllers.Attack signal
%%2082'Password Not Required' - EnabledMicrosoft notes that manually created computer objects may not require a password; it should not stay set.Worth knowing

Account Name SubjectUserName

ValueMeaningSignal
Ends with $Created by a computer accountOne of the two creation rules. Expected from failover cluster name objects; otherwise unusual.Worth knowing
Any user accountCreated by a user, with the machine account quota or a delegated permissionThe other creation rule. Usually help desk or deployment accounts; compare with your list of accounts allowed to join computers.Worth knowing

Primary Group ID PrimaryGroupId

ValueMeaningSignal
515Domain ComputersMember servers and workstations.Expected
516Domain ControllersA new domain controller. Monitor it (Microsoft).Worth knowing
521Read-only Domain ControllersA new read-only domain controller. Monitor it (Microsoft).Worth knowing
Any other valueAn unusual primary groupMicrosoft says any value other than 515, 516 or 521 is not typical and should be monitored. A privileged group (512, 518, 519) is the concern.Worth knowing

Password Last Set PasswordLastSet

ValueMeaningSignal
%%1794<never>Typical of an account created by hand rather than by a domain join (Microsoft).Worth knowing
A date and timePassword set at creationThe usual value after a domain join.Expected

Volume and noise

Microsoft rates Audit Computer Account Management low on domain controllers, and 4741 is rare compared with logon events. Domain joins, reimaging, virtual desktop pools and server builds are the ordinary sources. Failover clusters also create computer objects: the cluster name object creates the accounts of the clustered roles, so some creations by computer accounts are expected.

Keeping it manageable

  • Keep every 4741: the volume is low, and the two creation rules, the server trust and delegation rules and several hypotheses read it.
  • Exclude known provisioning accounts (deployment services, join service accounts, cluster name objects) from the creation rules by SID rather than by name.
  • Set ms-DS-MachineAccountQuota to 0 and give the Create Computer objects permission on the right OUs to the accounts that join computers, as Microsoft recommends against relying on the quota; every creation by another user account then stands out.
  • Look at the flags a creation sets: %%2088 (server trust) or %%2093 (trusted for delegation) on a new account outside a domain controller promotion is what the server trust and delegation rules look for.

Sample event

Version 0, 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>4741</EventID>
    <Version>0</Version>
    <Level>0</Level>
    <Task>13825</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>DC01.corp.example.com</Computer>
    <Security />
  </System>
  <EventData>
    <Data Name="TargetUserName">WS0142$</Data>
    <Data Name="TargetDomainName">CORP</Data>
    <Data Name="TargetSid">S-1-5-21-1004336348-1177238915-682003330-2241</Data>
    <Data Name="SubjectUserSid">S-1-5-21-1004336348-1177238915-682003330-1105</Data>
    <Data Name="SubjectUserName">alice</Data>
    <Data Name="SubjectDomainName">CORP</Data>
    <Data Name="SubjectLogonId">0x4b2d19</Data>
    <Data Name="PrivilegeList">-</Data>
    <Data Name="SamAccountName">WS0142$</Data>
    <Data Name="DisplayName">-</Data>
    <Data Name="UserPrincipalName">-</Data>
    <Data Name="HomeDirectory">-</Data>
    <Data Name="HomePath">-</Data>
    <Data Name="ScriptPath">-</Data>
    <Data Name="ProfilePath">-</Data>
    <Data Name="UserWorkstations">-</Data>
    <Data Name="PasswordLastSet">11/18/2026 9:30:12 AM</Data>
    <Data Name="AccountExpires">%%1794</Data>
    <Data Name="PrimaryGroupId">515</Data>
    <Data Name="AllowedToDelegateTo">-</Data>
    <Data Name="OldUacValue">0x0</Data>
    <Data Name="NewUacValue">0x80</Data>
    <Data Name="UserAccountControl">%%2087</Data>
    <Data Name="UserParameters">-</Data>
    <Data Name="SidHistory">-</Data>
    <Data Name="LogonHours">%%1793</Data>
    <Data Name="DnsHostName">WS0142.corp.example.com</Data>
    <Data Name="ServicePrincipalNames">HOST/WS0142.corp.example.com RestrictedKrbHost/WS0142.corp.example.com HOST/WS0142 RestrictedKrbHost/WS0142</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

Who can create computer accounts, and how does 4741 show it?

A user with the Add workstations to domain right can create up to ms-DS-MachineAccountQuota computer accounts (10 by default); accounts with the Create Computer objects permission on an OU, and administrators, are not limited. Microsoft lists Authenticated Users as the default holder of the right on domain controllers. Subject Account Name shows who created the account; the creation rules split it into computer accounts and user accounts. Afterwards the owner of the object tells the two paths apart, because Microsoft says an account created through the user right is owned by Domain Admins and one created through the container permission by its creator.

Why was a computer account created by another computer account?

The common legitimate case is a failover cluster, whose cluster name object creates the computer accounts of its clustered roles. Outside such cases a computer account creating others is unusual and is what one of the creation rules looks for.

How can I tell an account created by hand from one created by a domain join?

Microsoft notes that an account created in Active Directory Users and Computers shows Password Last Set as <never> and no DNS host name or SPNs, while a domain join sets the password time and registers HOST and RestrictedKrbHost names.

Is 4741 logged on member servers?

No. Microsoft says the event is generated only on domain controllers.

References