This is a complete hands-on practical introduction to transmission control protocol/Internet protocol (TCP/IP) programming with Python. In less than 500 pages, the reader advances from basic user datagram protocol (UDP)/TCP programming to complex multi-threaded simple object access protocol (SOAP)/Web server development.
The book is well written, and the author does an excellent job of keeping the reader focused on the essentials. Most of the concepts are detailed with fully functional code examples, and most of the examples are complex enough to make their points, without failing into the extreme of being oversized and hard to follow; I appreciated the appropriate code size.
The book is structured into six logical parts. The first part starts with the basics: low-level socket programming in Python, as well as an introduction to the PyDNS library. This section might raise the interest of even an advanced reader familiar with socket programming in C. I liked the chapter covering the domain name system (DNS): the samples on reverse and forward lookups are very valuable.
Part 2 of the book covers Extensible Markup Language (XML) and hypertext transfer protocol (HTTP) client programming. Programming with the XML and uniform resource locator (URL) library (urlib) in Python is described in detail, and becomes trivial after reading this section.
The third part addresses programming topics related to email, covering the programming support for simple mail transfer protocol (SMTP), point-of-presence (POP), and Internet message access protocol (IMAP). The examples for these protocols will give you the necessary knowledge to program an advanced email client, just by assembling them. The next part covers the Python support for file transfer protocol (FTP), databases, and secure sockets layer (SSL); a chapter is dedicated to each topic.
The last two parts are about server side programming (SSP). The fourth part addresses the programming of simple (single-threaded) servers: HTTP, XML/remote procedure call (RPC) (Web services), common gateway interface (CGI), and Apache specific extensions. It was amazing to realize how simple the programming of Web services can be with Python, and the author’s clear and precise writing style is particularly refreshing.
The last part of the book is my favorite, covering the design and implementation of multitasking servers. The three possible ways to implement these servers are presented, with one chapter each for forking, multi-threading, and asynchronous communication.
The book covers an important topic, and can be read by advanced Python programmers, as well as simple beginners. The code is very easy to follow, and can be read by beginners without requiring additional references.
To conclude: this is a very well-written book, providing a comprehensive introduction to network programming in Python. It is easy to follow, and very pleasant to read; I highly recommend it to Python programmers.