The technology that allows communication to flow from device to device over the Internet is quite complex, with multiple layers that work together to ensure reliability and scalability. Fortunately, the .NET Framework makes networking programming fairly easy, by encapsulating DNS lookup in a Dns class and providing a .NET implementation of Windows sockets through the TcpListener, TcpClient, and UdpClient. Armed with these techniques, you're ready to create the file-sharing application in Chapter 9. First, though, you need to consider a new method of peer-to-peer discovery: using a web service.