To create a bidirectional unix IPC:
- Server creates a sockets and
bind
s it to an address (typically a file). Do NOT useconnect
as allsend
/recv
operation will be done usingconnect
's address! - Client creates a socket and
bind
s it to its own address. However the socketconnect
s to the address of server. - Server uses
recv_from
to get data from socket along side with the address of the client that sent the data. This way it can use the address to send a response back to client.