Skip to main content
COSMICBYTEZLABS
NewsSecurityHOWTOsToolsTraining
StudyProjectsNewsletterHire MeAbout
Subscribe

Press Enter to search or Esc to close

News
Security
HOWTOs
Tools
Training
Study
Projects
Newsletter
Hire Me
About
RSS Feed
Reading List
Subscribe

Stay in the Loop

Get the latest security alerts, tutorials, and tech insights delivered to your inbox.

Subscribe NowFree forever. No spam.
COSMICBYTEZLABS

Your trusted source for IT intelligence, cybersecurity insights, and hands-on technical guides.

2493+ Articles
160+ Guides

CONTENT

  • Latest News
  • Security Alerts
  • HOWTOs
  • Checklists
  • Projects
  • Exam Prep

RESOURCES

  • Search
  • Browse Tags
  • Newsletter Archive
  • Reading List
  • RSS Feed

COMPANY

  • About Us
  • Contact
  • Privacy Policy
  • Terms of Service

© 2026 CosmicBytez Labs. All rights reserved.

System Status: Operational
  1. Home
  2. News
  3. Named Pipes Under Attack: Securing Windows Interprocess Communication
Named Pipes Under Attack: Securing Windows Interprocess Communication
NEWS

Named Pipes Under Attack: Securing Windows Interprocess Communication

Weak access controls on Windows named pipes let untrusted processes reach privileged services. Here's how endpoint verification and strict ACLs help.

Dylan H.

News Desk

August 22, 2026
4 min read

Overview

Windows named pipes are one of the oldest and most widely used interprocess communication (IPC) mechanisms in the Windows ecosystem. Security researchers and ThreatLocker have spotlighted how weak access controls on named pipes can expose privileged system services to untrusted or compromised processes — making them a reliable primitive for local privilege escalation and lateral movement within a network.

What Are Named Pipes?

Named pipes provide a communication channel between processes on the same machine or across a network. Unlike anonymous pipes, they have a filesystem-like name (e.g., \\.\pipe\MyService) and can be accessed by any process with sufficient permissions. They are used extensively by Windows services, security tools, backup agents, and enterprise software.

The problem: many applications create named pipes with overly permissive access control lists (ACLs), granting write or full-control access to Everyone, Authenticated Users, or NETWORK SERVICE — far broader than necessary.

The Attack Surface

When a privileged service (e.g., running as SYSTEM) listens on a named pipe with loose ACLs, an unprivileged attacker who can write to that pipe gains:

  • Command injection — if the service processes pipe data as executable commands or shell strings, arbitrary code runs under the privileged context
  • Token impersonation — a classic Windows privilege escalation technique where the server-side process impersonates the client's security token. If the server is SYSTEM and the client causes an impersonation, the result is a SYSTEM-level token for the attacker
  • Information disclosure — sensitive configuration, credentials, or operational data flowing through the pipe is exposed

Real-world examples include well-known escalation paths through print spooler pipes, backup agent pipes, and EDR service pipes — many CVEs over the years trace back to exactly this pattern.

How Attackers Exploit Named Pipes

A typical attack flow:

  1. Enumerate writable named pipes on the system using tools like Sysinternals' Process Monitor, PipeList, or purpose-built offensive tooling
  2. Identify a pipe backed by a privileged service process
  3. Send crafted data to trigger command execution, path injection, or impersonation
  4. Escalate from a low-privileged user or a compromised service account to SYSTEM

Attackers operating post-exploitation (e.g., via a Cobalt Strike or Havoc C2 beacon) frequently target named pipes as a reliable, detection-resistant escalation technique.

Defensive Controls

ThreatLocker's guidance outlines four key controls for hardening named-pipe IPC:

1. Strict ACLs

Apply the principle of least privilege to pipe security descriptors. Only grant access to the specific accounts or security groups that legitimately need to communicate over the pipe. Avoid Everyone or Authenticated Users where a more specific SID will work.

# Example: set a restrictive DACL on a pipe during service startup
$pipeSecurity = New-Object System.IO.Pipes.PipeSecurity
$accessRule = New-Object System.IO.Pipes.PipeAccessRule(
    "DOMAIN\ServiceAccount",
    [System.IO.Pipes.PipeAccessRights]::ReadWrite,
    [System.Security.AccessControl.AccessControlType]::Allow
)
$pipeSecurity.AddAccessRule($accessRule)

2. Endpoint Verification

Before processing any message from a pipe client, the server should verify the client's identity. Use GetNamedPipeClientProcessId / GetNamedPipeClientSessionId to identify the connecting process and validate it against an allowlist before acting on its data.

3. Command Authorization

Implement allowlist-based command authorization on the server side — reject any command or request that does not match a known-good pattern. Never pass raw pipe data to shell interpreters, cmd.exe, or CreateProcess without validation and escaping.

4. Narrowly Scoped Service Privileges

Run services that expose named pipes under dedicated low-privilege service accounts (Virtual Accounts or Managed Service Accounts) rather than LocalSystem. If a pipe-connected service is compromised or abused, the blast radius is limited to what that service account can access.

Detection

Monitor for:

  • Named pipe enumeration activity — bursts of NtCreateFile or CreateFile calls against \\.\pipe\* paths from unusual processes
  • Impersonation tokens created in the context of high-privilege services
  • Unusual processes connecting to known privileged service pipes (e.g., a user-mode application talking to \\.\pipe\ntsvcs or similar)

Windows Security Event ID 4656 (A handle to an object was requested) and 4663 (An attempt was made to access an object) can surface pipe access if object auditing is enabled. Sysmon Event ID 17 (Pipe Created) and 18 (Pipe Connected) provide richer telemetry.

Key Takeaways

RiskMitigation
Overly permissive pipe ACLsApply least-privilege DACLs at pipe creation
Unauthenticated clientsVerify client process identity before processing
Raw data executionValidate and allowlist all commands from pipe
High-privilege service contextUse dedicated low-privilege service accounts

Named pipes are not going away — they are deeply embedded in the Windows architecture. The goal is not to avoid them but to use them securely. Reviewing your privileged services' pipe ACLs is a low-effort, high-value hardening exercise that can close off an entire class of local privilege escalation paths.

Source

  • BleepingComputer: Named Pipes Under Attack — Securing Windows Interprocess Communication
#Windows#IPC Security#Privilege Escalation#Endpoint Security#Hardening

Related Articles

Microsoft Patches LegacyHive Windows Zero-Day That Grants Admin Privileges

CVE-2026-62832 in Windows User Profile Service lets local users hijack registry hives and escalate to admin. Patch now via August Patch Tuesday.

5 min read

New Windows LegacyHive Zero-Day Gives Hackers Admin Privileges

A security researcher has released a public Windows zero-day exploit called LegacyHive that allows local privilege escalation to SYSTEM on fully...

5 min read

Researcher Drops New Windows Zero-Day PoC Hours After Microsoft Patch Tuesday

Security researcher Chaotic Eclipse released LegacyHive, a proof-of-concept exploit for a Windows User Profile Service privilege escalation vulnerability,...

6 min read
Back to all News