How do you communicate with a remote Server, who will always send his answer packages to your requests, to the IP/Port Tuple the requests come from ?
In TCP you will always need two sockets. One for the local Server and one for the local Client. As it is not possible to bind them to exactly the same port, let's say i bind the Server socket to port X and the Client socket to port Y. Now sending a request with the help of my local Client to the remote server, would cause that the remote Server respectively now the remote Client sends his answer to port Y, but my local Server is listening on Port X.
Neither i can use a single socket for sending and receiving, like in UDP, nor i can bind twice the same port.
recv()
– plover