pySecret

you@debian:~$ hg clone http://bitbucket.org/cedricbonhomme/pysecret
you@debian:~$ ipython
In [1]: from pysecret import permutation
In [2]: permutation.encrypt("Python est un très bon language!", [2,4,0,1,3])
Out[2]: 'toPyhetn snt u \xa8 r\xc3snlbo gaanu!XgeX'
In [3]: print permutation.decrypt(permutation.encrypt("Python est un très bon language!", [2,4,0,1,3]), [2,4,0,1,3])
Python est un très bon language!XX
In [4]: from pysecret import rsa
In [5]: rsa_cipher = rsa.RSA()
In [6]: rsa_cipher.decrypt_text("eJwNjrsRw1AMw3pPksonUqQ+O3gJ9ymyf5VXEzjw8/3hehgloJwwmO0eAxFFbW8oc7MrpyowuWLk\nmZVuzn
AstTCUcppNL1yaQcoQNx1NxbSPq8YUaCzqEO6UVMsk4mSb54lI1kmsn+u9/9cOIaE=")
Out[6]: 'Il reste encore beaucoup de travail!'
In [7]: exit()
Do you really want to exit ([y]/n)? y
you@debian:~$ ls -l pysecret/
total 140
-rwx------ 1 you you  1356 2010-09-26 18:23 afine.py
-rwx------ 1 you you   883 2010-09-26 18:24 autokeycipher.py
-rwx------ 1 you you   774 2010-09-26 18:06 cesar.py
-rwx------ 1 you you 35146 2010-04-29 22:32 COPYING
-rwx------ 1 you you  1921 2010-09-26 18:19 elgamal.py
-rwx------ 1 you you  1299 2010-09-26 18:21 hill.py
-rwx------ 1 you you     2 2010-09-26 18:14 __init__.py
-rwx------ 1 you you  1629 2010-09-26 18:26 permutation.py
-rwx------ 1 you you  1704 2010-09-26 18:26 rabin.py
-rwx------ 1 you you  6402 2010-09-26 18:07 rsa_gui.py
-rwx------ 1 you you  3824 2010-09-26 18:26 rsa.py
-rwx------ 1 you you   908 2010-09-26 18:28 substitution.py
-rwx------ 1 you you 10420 2010-09-26 18:28 utils.py
-rwx------ 1 you you  2234 2009-02-26 22:06 vigenere.py