Understanding Sockets in Networking: A Comprehensive Case Study