fix: Prevent named-pipe squatting in Windows example app via FILE_FLAG_FIRST_PIPE_INSTANCE#905
fix: Prevent named-pipe squatting in Windows example app via FILE_FLAG_FIRST_PIPE_INSTANCE#905NandanPrabhu wants to merge 1 commit into
Conversation
closing a window where an attacker (running as the same user) could pre-create the pipe before the app starts and have later client connections round-robin onto their instance instead of ours. This is additional defense-in-depth on top of the SID-restricted ACL and callback-prefix validation already in main (PR #833).
|
Important Review skippedReview was skipped due to path filters ⛔ Files ignored due to path filters (1)
CodeRabbit blocks several paths by default. You can override this behavior by explicitly including those paths in the path filters. For example, including ⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: ASSERTIVE Plan: Pro Plus Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Summary
CreateNamedPipeWin the Windows example app's redirect-forwarding pipe server now passesFILE_FLAG_FIRST_PIPE_INSTANCE, so pipe creation fails if a pipe with the same name already exists.main.Test plan
CreateNamedPipeWfailure (e.g. simulated pre-existing pipe) is handled gracefully — pipe server thread exits rather than crashing