When applications need to communicate with custom system services, some choose to simply talk via TCP or UDP sockets within the same computer.
Instead, prefer using the Unix sockets via the AF_UNIX protocol. Unix sockets
come in packet and stream variants that work just like the network counterparts,
but they live on the filesystem. Who is allowed to connect to the socket can be
controlled with standard filesystem permissions.
Unix sockets can also pass file descriptors. A privileged service can open a restricted file on behalf of a client and pass the descriptor over, giving the client access.
sigma star gmbh
Eduard-Bodem-Gasse 6, 1st floor
6020 Innsbruck | Austria