Re: Transfer socket connection between programs



JamesHoward wrote:
Does anyone know any method to have one program, acting as a server
transfer a socket connection to another program? I looked into
transferring the connection via xml rpc to no avail. It seems to be a
problem of getting access to a programs private memory space and
giving another program access to that space.
If you are using UNIX, you can create a pipe in the filesystem, and connect I/O on both ends. Of course this is not the same, because - for example - you cannot use setsockopt. But it works with already existing processes very well, and usually you can setup socket options in your server.

Under windows, I have no clue. It may be possible to use pipes under Windows but I don't know how. You can also use other nasty techniques, like loading a DLL into your "another program", then make a code hook into your server. Brrrrrrr. :-) (Unstable, not portable even between Windows versions...)

Regards,

Laszlo


.



Relevant Pages

  • Re: ASP.NET ServiceName?
    ... John Timney ... socket connection to the listener, it will be about as instant as it can ... Because I wanna show some windows forms on the server side for the ...
    (microsoft.public.dotnet.framework.aspnet)
  • Named pipes
    ... the name of the pipe ... - server on Windows XP, client on Windows Server 2003, using ... - server and multiple clients on the same machine using ...
    (microsoft.public.win32.programmer.kernel)
  • Re: Named pipes

    (microsoft.public.win32.programmer.kernel)
  • Re: TCP receive too many small packets
    ... I have a client / server application that communicates with each other ... thru a socket connection. ... Is something wrong with sending small TCP packets? ...
    (microsoft.public.win32.programmer.networks)
  • Re: Problem with XML-RPC, possibly with SOAP too
    ... >> communication protocol amoing client apps and server. ... >> The third problem was since a new connection is needed on each call, ... >> second), no more socket connection can be made, and communication just ...
    (comp.lang.java.programmer)