sockserv.py Python Socket library
Download
by FTP:
ftp.tummy.com:/pub/tummy/sockserv/
Introduction
sockserv is a
Python module for easily creating command/response socket
servers (for example, SMTP, POP, NNTP, etc...). It also includes code for
connecting to such servers and interacting with them. It has been used
internally to create a header-rewriting SMTP proxy server, POP3, and
regular SMTP server (each in under 100 lines of code), and a light-weight
phone database server in 51 lines.
The server runs as a single process, multiplexing access to the different
clients. Therefore, it's best suited to tasks which don't block for long
periods of time.
This code has been in internal use for over a year before it's public
release. It's reasonably stable and has been in operation as an NNTP proxy
in which it ran for nearly 6 months without restarting.
Requirements
Python: a current version (1.5.1+) to work. You can get source (and
binaries for selected systems) from www.python.org.
Advantages
- A *VERY* high-level interface to Unix sockets (the Python library
socket module is a very thin wrapper on top of the Unix socket API).
- Reduces time required to code socket applications.
Getting Started
sockserv includes full inline documentation. See the source for
examples and documentation on it's use.
Copyright
sockserv (source, documentation and all related matter) is
copyright © 1998, 1999 Sean Reifschneider, tummy.com, ltd. The
source is available under the Tummy Public License Version 1.0 (the
"License"); you may not use sockserv except in compliance with the
License. You may obtain a copy of the License at this
link