views:

496

answers:

2

I want to know is there any python 3.0 supported library for encryption. To encrypt files of 128 bits of data??

+3  A: 

I suggest my open-source project slowaes, http://code.google.com/p/slowaes/ -- should be trivial to adapt if it doesn't work out of the box, as it's pure-Python (and for 128 bits of data, the "slow" part shouldn't matter).

Alex Martelli
A: 

To properly encrypt data, you need more than just an encryption algorithm. It's probably best you find a complete library with documentation showing how to do things properly, if you absolutely must do it yourself.

Encryption alone is not sufficient. How are you generating keys? What mode of operation are you using? Are you using a MAC on the data?

Straight AES in ECB mode leaks information. Without a MAC, even though the data is encrypted, an attacker can still tamper with your data.

mattjf