Python SHA-based encryption function, new version

Paul Rubin phr-n2002a at nightsong.com
Mon May 6 06:10:44 EDT 2002


Paul Rubin <phr-n2002a at nightsong.com> writes:
> The current version (revision 1.13) is still considered an eval/test
> version and still has a date check.  

Doh.  I botched this upload and a few people retrieved the file before
I fixed it.  If you're one of them, please try again.  I'm sorry about
the false starts.  At least the revision that was up there (1.13)
failed immediately on loading rather than giving insecure results
silently.

Revision 1.15 is now up and has the correct fix.  It also portably
incorporates the process ID into the nonce, on systems that support
os.getpid; Unix and Windows are among these.  Thanks to Alex Martelli
for this suggestion.  There are probably still bizarre conditions
under which you can re-use a nonce even on those systems, but you'll
have to work pretty hard at it now.

The URL again is <http://www.nightsong.com/phr/crypto/p2.py>.



More information about the Python-list mailing list