Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Windows Named Pipe Support in Linux [closed]

I'm looking at a project which will require inter-process communication between a legacy Windows application using named pipes, and a new service running on a Linux server. The windows application cannot be changed. Does anyone know if there is a Linux library available that supports Windows named pipes? Or even better, can anyone recommend a library they have used for this purpose?

like image 379
MichaelB76 Avatar asked Dec 05 '22 01:12

MichaelB76


1 Answers

Windows and Linux named pipes are different animals. If an interop solution exists you are going to be one of a very small population of users.

You might be better off writing a proxy on the Windows side to map between Named Pipe and socket, and connecting this to a socket on the Linux end. This provides you a useful networked interface on the Linux side going forward, and removes what might be a world of Named Pipes interop hurt from the picture.

If I was doing this I would try to produce a simple passthrough proxy in C# (managed code) as a proof of concept. Can always convert to native code (Win32/C++) if throughput does not measure up. There is some sample C# code here that might be a useful reference.

Here is background on the nuances of Windows vs Linux named pipes.

like image 82
Steve Townsend Avatar answered Dec 09 '22 15:12

Steve Townsend