Minitalk: Inter-Process Communication With Just Signals
July 8, 2022
École 42
Related Posts
Hi! Minitalk asks for a client and a server that exchange messages using nothing but two UNIX signals: SIGUSR1 and SIGUSR2. That is literally one bit of information per signal — so you end up streaming every character of the message bit by bit.
The client takes the server’s PID and a string, then sends each byte as eight signals (one per bit). The server reconstructs the bits into characters with a signal handler and prints the message. For the bonus, the server acknowledges every byte back to the client, turning a fire-and-forget protocol into a reliable one.
It is a tiny project, but it rewires how you think about processes: even with the most primitive channel imaginable, you can build a working protocol with framing, acknowledgement and error handling. My implementation is in the 42Cursus repository.
