Is there an equivalent to WSAAccept in Linux?
During the day my job requires me to develop using Microsoft's tools, but during my personal time I develop on Linux. Anyways, I was trying to find an socket function with equivalent functionality to "WSAAccept" on Linux. For those of you not familiar with WSAAccept, it is essentially the same accept() function that we all know and love with the addition of a conditional acceptance function (passed as a parameter). This allows one to inspect the remote address information of a waiting socket and do some calculations to determine whether you actually want to complete the 3-way handshake (note: this address may be spoofed so you don't want to rely on it completely). This is in contrast with accept() which always completes the 3-way handshake (provided the incoming request wasn't spoofed/network issues) and after returning you then have access to the address information for the remote socket.