fix(sessions): restrict the worker named pipe to the gateway's account (#187)
ci / nightly-windev (push) Has been skipped
ci / windows-x86 (push) Successful in 1m23s
ci / java (push) Successful in 2m20s
ci / portable (push) Failing after 4m46s

On Windows each worker pipe is created via NamedPipeServerStreamAcl with a
protected DACL granting FullControl only to the gateway process user (the
worker is launched under the same account) and denying NETWORK logons. On
non-Windows hosts (test matrix) the pipe uses PipeOptions.CurrentUserOnly.
Tests assert the factory ACL and the ACL read back from the created pipe
(Windows), and that a same-user client still connects.
This commit is contained in:
Joseph Doherty
2026-11-06 15:45:50 -05:00
parent 9354d69bf9
commit 34a7453ac3
4 changed files with 200 additions and 3 deletions
+4 -1
View File
@@ -742,7 +742,10 @@ Transport security here applies only to the public gRPC channel. The
gateway↔worker link is a per-session **named pipe**
(`mxgw-{gatewayPid}-{sessionUid}`), not a network socket. It is not
TLS-encrypted and does not need to be: it never leaves the local Windows host and
is secured by the OS pipe ACL. See [Worker Frame Protocol](./WorkerFrameProtocol.md).
is secured by the OS pipe ACL: on Windows the gateway creates each pipe with a
protected DACL that grants only its own account (the account the worker is
launched as) and denies network logons; on the non-Windows test matrix it uses
`PipeOptions.CurrentUserOnly`. See `WorkerPipeSecurity` and [Worker Frame Protocol](./WorkerFrameProtocol.md).
## Related Documentation