From 306be14e80991a9e37cf4532e1388af063b435c8 Mon Sep 17 00:00:00 2001 From: Richard Moore Date: Wed, 7 May 2014 03:23:01 -0400 Subject: [PATCH] Some clean up (more to come). --- pyscrypt/file.py | 21 ++------------------- 1 file changed, 2 insertions(+), 19 deletions(-) diff --git a/pyscrypt/file.py b/pyscrypt/file.py index 5a22349..45ccc22 100644 --- a/pyscrypt/file.py +++ b/pyscrypt/file.py @@ -60,23 +60,6 @@ BLOCK_SIZE = 16 -# We use the crypto library to test until we finish the pure-python aes-256 CTR library -if False: - from Crypto.Cipher import AES - from Crypto.Util import Counter - - class aes(object): - def __init__(self, key): - counter = Counter.new(128, initial_value = 0) - self._aes = AES.new(key, AES.MODE_CTR, counter = counter) - - def encrypt(self, plaintext): - return self._aes.encrypt(plaintext) - - def decrypt(self, ciphertext): - return self._aes.decrypt(ciphertext) - - class InvalidScryptFileFormat(Exception): pass class ScryptFile(object): @@ -150,8 +133,8 @@ def _load_get_attr(self, name): #newlines = property(lambda s: s._fp.newlines) # This requires more work to make work # @TODO; test with print - def _set_softspace(self, value): - self._fp.softspace = value + #def _set_softspace(self, value): + # self._fp.softspace = value #softspace = property(lambda s: s._fp.softspace, _set_softspace) def fileno(self):