[Freeciv-Dev] Re: Extended connect dialog (PR#977)
[Top] [All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
<URL: http://rt.freeciv.org/Ticket/Display.html?id=977 >
The method of local authorization is quite a hack.
The server needs to make sure it is the correct client connecting that
it's going to give HACK authorization to. So the server sends (over the
network) the name of a local file. The client creates this file and
puts some auth info into it. The client then sends this auth info to
the server, which it verifies against the data in the file.
The question is: is there a better way?
On posix systems, the answer is clearly yes. The client should call
socketpair() to generate a pair of sockets before the fork; client and
server each get one of the sockets. It then takes just a few lines for
the server to use this socket as the client's automatic connection.
It's fast, secure, and elegant. The only drawback is that win32 has no
socketpair() function. Is there a way to do this on windows? (I surely
hope so, since I need to do this for another project.) Any win32
developers know how it might be done? Win32 has various methods of
creating pipes, but we need to create a two-way socket that can be
accessed via the normal file descriptor functions (read, write).
jason
- [Freeciv-Dev] Re: Extended connect dialog (PR#977), Mike Kaufman, 2004/03/14
- [Freeciv-Dev] Re: Extended connect dialog (PR#977), Jason Short, 2004/03/16
- [Freeciv-Dev] Re: Extended connect dialog (PR#977),
Jason Short <=
- [Freeciv-Dev] Re: Extended connect dialog (PR#977), Daniel L Speyer, 2004/03/16
- [Freeciv-Dev] Re: Extended connect dialog (PR#977), Jason Short, 2004/03/17
- [Freeciv-Dev] Re: Extended connect dialog (PR#977), Jason Short, 2004/03/17
- [Freeciv-Dev] Re: Extended connect dialog (PR#977), Daniel L Speyer, 2004/03/23
|
|