intermediate

RPC & COM foundations

Procedure-style communication between components, locally or across the network.

Official Microsoft docs

Closest official references related to this topic on Microsoft Learn.

Why it matters

A large portion of Windows management, service coordination, and distributed features depend on RPC-style contracts.

Mental model

RPC lets a client pretend it is calling a function, while under the hood the call is marshaled, transported, checked, and executed elsewhere.

How it works

  1. 1Interfaces are defined and exposed by a server component.
  2. 2Client stubs and server stubs marshal parameters into a transport-safe format.
  3. 3The RPC runtime chooses a protocol sequence such as ncalrpc, named pipes, or TCP depending on the scenario.

Key terms

Stub
Generated code that marshals and unmarshals parameters for RPC.
Protocol sequence
The RPC transport selection, such as ncalrpc or ncacn_np.

A management tool talking to a service

The user sees a button click, but the real work may be an RPC call into a service that owns the privileged operation.

Common misconception

RPC is not automatically 'remote only'. A lot of Windows RPC traffic is local and never leaves the machine.

You should read next

Ranked from your current topic, related links, branch depth, and any active guided path.

Related topics