This is SRPSocket version 1.1

SRPSocket is a Python module that creates an _authenticated_ socket.  The
socket is authenticated using the SRP (Secure Remote Password) protocol.
SRP is safe to use over the network.  It resists offline dictionary attacks,
man-in-the-middle attacks, allows both client and host authentication (to
prevent host spoofing), creates a secure, shared session key as a side
effect, and has several other nice properties.

Note that the term 'password' may safely and usefully be replaced with the
term 'passphrase', as the latter are usually more secure (i.e.  have more
bits of entropy) and easier to remember.

The home page for SRP is http://srp.stanford.edu/.

This version uses SHA hashes.  If your version of Python does not have SHA
hashes, consider upgrading to the latest version of Python, or simply
replace all references to "sha" with "md5".

SRP uses arithmetic in a prime field.  The distribution comes with one
preselected safe prime that is about 120 bits long.  Feel free to use
others, but keep in mind that the client and the server must agree on the
set of primes used.

To begin, create the passwd database with "python SRP.py" (see client.py).
In this version, the passwd file is just in the local directory of the
server, and no mode setting is done.  The passwd file should not be world
readable, since that allows offline dictionary attacks.  Note again that
even if it is readable (like the standard /etc/passwd), use of long pass
phrases instead of passwords can help tremendously.

Finally, remember that many breaches of security involve buggy servers, such
as those susceptible to buffer overflow exploits that totally bypass any
passphrase, secure or not.  But SRP will at least stop you from sending
passwords over the net in the clear!

Dr. Tom
tomh@po.crl.go.jp
