locked
WinAPI. Where are pipes storage in windows? RRS feed

  • Question

  • Good evening. i am learning how to work with threads and process in WinAPI. During this, i faced with interesting question. When i created named channel i used pipes. I used #define BASE_PATH_PIPE "\\\\.\\pipe\\PipeName". So can you please answer me. In wich folder pipes storaging in my computer. I used search on my hard disk and did not find it. Where i can find this storage with pipes. Thank you
    Friday, May 22, 2020 8:59 AM

All replies

  • Named pipes will not appear in the file system that can be displayed by Explorer or console commands like "dir".

    However, you can obtain a listing of open named pipes using Microsoft's Sysinternals Pipelst utility.

    In the description of the utility note that it says, "...its possible to obtain a directory listing of the named pipes defined on a system. This fact is not documented, nor is it possible to do this using the Win32 API. "

    Friday, May 22, 2020 10:26 PM
  • Thank you!
    Saturday, May 23, 2020 10:04 AM
  • You can list the Pipes with NtQueryDirectoryFile and FileDirectoryInformation

    on "\\.\Pipe\

    (tested on Windows 10)



    • Edited by Castorix31 Saturday, May 23, 2020 11:47 AM
    Saturday, May 23, 2020 11:46 AM
  • Just to clarify for the benefit of the OP --

    NtQueryDirectoryFile is the function that Sysinternal's pipelist utility uses.

    However, it is not a Windows API function.  Rather, it is part of a lower level set of functions referred to as the native API.  Windows API functions call into the native API.

    For a brief discussion, see https://docs.microsoft.com/en-us/windows-hardware/drivers/kernel/using-nt-and-zw-versions-of-the-native-system-services-routines

    Saturday, May 23, 2020 12:00 PM