There are code recipes of Python Network Programming Cookbook