After hours of searching on the internet, I still wasn't able to find an answer for my problem.
My task is to create a server that accepts sockets from a variable number of interfaces (given in a config file as eth0, eth1, etc.
).
What is the easiest way to do this?
Is there any way to bind one socket to multiple interfaces? I haven't found a way to do that yet.
Or, do I have to use INADDR_ANY
and somehow find out the interface which the packet was sent from?
Is there another way to handle this problem?