I have several processes running on a system that interact with each other by TCP (eg. with the asynchronous messaging protocol by twisted).
process1 <=====> broker <=====> process2
There is one server instance (broker) running on a linux host, that listens to a TCP socket localhost:port. There are also some other processes, running on the same host, which query the broker instance by using the socket via TCP (given by twisted). The broker has access to a hardware security module (HSM).
I'm currently thinking about the security aspects of this design. Would it be possible for an eavesdropper, who has direct physical access to the host, to listen to the TCP traffic between the clients and the broker on this host? Since sometimes sensitive data is being transferred, I want to secure the communication between the processes and broker on the host.
How can this be done? There is always the problem of storing a private secret. For the broker its no problem because it has access to HSM, but for the client-processes which interact with the broker. Its hard to hide a secret for an attacker which has physical access to the host. How can authentication/encryption between processes and broker be realised?
Hope you understand my problem and can help me!
EDIT: SSL/TLS wouldn't be a good approach, since it comes with high overhead and there also exists the problem of secure storage for private secret.