Skip to content
SOC Analyst Role
  • Loading index…

↑↓ navigate · ↵ open · Esc close

en

Security · Object access

5145 · A network share object was checked to see whether client can be granted desired access

Logged on the share-hosting machine each time a client's access to a specific file, folder or named pipe within a share is checked. It is extremely noisy but shows exactly what was touched, such as a service binary written to ADMIN$ or the svcctl pipe opened over IPC$, which is how PsExec-style remote service creation looks on the wire.

low prioritySecurity logObject accessMITRE T1021.002

Where it is logged

Security log on the target server or endpoint hosting the share. Requires Audit Detailed File Share (Object Access) for Success and/or Failure. Because of volume, many organizations enable it only on DCs, file servers with sensitive data, or as part of a targeted hunt.

Key fields to read

FieldWhat it tells you
ShareNameShare involved, e.g. \\*\IPC$ or \\*\ADMIN$.
RelativeTargetNameFile or pipe within the share, e.g. svcctl, PSEXESVC.exe, Finance\payroll.xlsx.
AccessMaskRequested rights; 0x2 (WriteData) or 0x12019f indicate write access, 0x1/0x120089 read.
AccessListHuman-readable rights requested, e.g. %%4417 WriteData.
IpAddressSource IP of the client.
SubjectUserNameAccount performing the access.
KeywordsAudit Success vs Audit Failure; failures show denied attempts, e.g. during share enumeration.

Sample event

5145 — synthetic example
Log Name: Security
EventID: 5145
TimeCreated: 2026-11-20T23:11:47.315Z
Computer: NW-FIN-WS07.northwind.local
Keywords: Audit Success
SubjectUserName: adm.jkim
SubjectDomainName: NORTHWIND
SubjectLogonId: 0x5F0B11A
IpAddress: 10.20.30.57
ShareName: \\*\IPC$
ShareLocalPath: 
RelativeTargetName: svcctl
AccessMask: 0x3
AccessList: %%4416 %%4417

How to triage it

  1. 1Identify the share and RelativeTargetName: is it a named pipe (svcctl, atsvc, samr, lsarpc) or a file?
  2. 2For ADMIN$/C$, check for write access (AccessMask with WriteData) to .exe, .dll, .bat or .ps1 files.
  3. 3Correlate svcctl access with 7045/4697 on the same host seconds later (remote service creation) and atsvc with 4698 (remote scheduled task).
  4. 4Validate the source IP and account: management servers are expected; user workstations are not.
  5. 5Scope: check the same source and account across other hosts for the same pattern.

Benign vs suspicious

Usually benign

  • Endpoint management, backup and monitoring tools using IPC$ pipes and admin shares.
  • Users opening documents on file shares (huge volume on file servers).
  • Domain logon processing reading SYSVOL/NETLOGON on DCs.

Red flags

  • An executable written to ADMIN$ followed by \PIPE\svcctl access over IPC$ from the same source: PsExec-style remote service creation.
  • Access to atsvc (remote scheduled task) or winreg from a workstation.
  • Mass read access to many files on a file server by one account in minutes (data staging or exfiltration).
  • Many access failures across shares from one source (share enumeration).

Hunt for it: Splunk & KQL

Splunk SPL
index=wineventlog EventCode=5145
  ((ShareName="\\*\IPC$" RelativeTargetName IN ("svcctl", "atsvc")) OR
   (ShareName="\\*\ADMIN$" (RelativeTargetName="*.exe" OR RelativeTargetName="*.dll" OR RelativeTargetName="*.bat")))
| stats values(ShareName) AS shares values(RelativeTargetName) AS targets min(_time) AS first max(_time) AS last BY host, IpAddress, SubjectUserName
| convert ctime(first) ctime(last)
Sentinel KQL
// Sentinel SecurityEvent: remote service creation pattern (ADMIN$ binary write + svcctl pipe)
SecurityEvent
| where TimeGenerated > ago(1d)
| where EventID == 5145
| where (ShareName endswith @"\IPC$" and RelativeTargetName in~ ("svcctl", "atsvc"))
    or (ShareName endswith @"\ADMIN$" and RelativeTargetName matches regex @"(?i)\.(exe|dll|bat|ps1)$")
| summarize Targets = make_set(RelativeTargetName), Shares = make_set(ShareName) by Computer, IpAddress, SubjectUserName, bin(TimeGenerated, 5m)
| where array_length(Shares) >= 2

Field names depend on your add-on and table. More translations in the Splunk vs KQL cheat sheet.

Interview question

“How does PsExec-style lateral movement appear in Windows logs on the target?”

✓ Strong answer sketch

On the target I would expect a 4624 type 3 network logon, then 5140 connections to ADMIN$ and IPC$. With detailed file share auditing, 5145 shows the service binary (for example PSEXESVC.exe or a random name) written to ADMIN$ and the svcctl named pipe opened over IPC$, which is how the Service Control Manager is driven remotely. Seconds later the System log records 7045 for the new service (and 4697 if Security System Extension auditing is on), and the payload runs as a child of services.exe. Matching the same source IP and logon ID across those events turns individually noisy logs into a clear lateral movement story.

More SOC interview questions

Frequently asked questions

Why is Event 5145 so noisy?

It is logged for every access check on files, folders and pipes within a share, not once per session like 5140. On busy file servers that can mean millions of events per day.

What is the svcctl named pipe?

svcctl is the RPC endpoint of the Service Control Manager. Remote access to it over IPC$ is how tools create and start services on another machine.

Which audit policy enables 5145?

Audit Detailed File Share under Object Access in Advanced Audit Policy, on the machine hosting the share.