Trees | Index | Help |
---|
Package yawPyCrypto ::
Module _CipherBase ::
Class EncryptBase |
|
object
--+
|
EncryptBase
EncryptCipher
,
ZipEncryptCipher
,
KeyEncryptCipher
,
ZipKeyEncryptCipher
Method Summary | |
---|---|
Initialize the encryption cipher. | |
a new object with type S, a subtype of T |
|
Feed data to the encryption. | |
Finish the encryption stream. | |
Write out the encryption end packet. | |
Overridable function which writes an additional encryption header. | |
Write out the random first block of data. | |
Overridable function which writes an additional encryption signature. |
Class Variable Summary | |
---|---|
bool |
_showpassword
|
Method Details |
---|
__init__(self,
password=None,
cipher_algo=3,
cipher_mode=0,
IV=None,
hash_algo=5)
Initialize the encryption cipher. The arguments this class takes are
passed to the encryption start functions of the cipher stream which is
associated with this class when creating the actual instance.
|
__new__(S, ...)
|
feed(self, data)Feed data to the encryption. The parameter must be a string. Output isn't producted necessarily, unless data is long enough to fill the internal buffering of the encryption buffer and (possibly) the zlib buffer. |
finish(self)Finish the encryption stream. This writes out the last packet of data and an encryption end signature. After this function has been called, all further calls to feed are disallowed, and will fail, invalidating the stream. No more data will be written to the output after this function has been called. |
_encryptionEnd(self)Write out the encryption end packet. The encryption end packet contains a hash digest of the original data which has been written, and the length of the actual data, without fillers added to pad it up to a multiple of block_size. |
_encryptionHeader(self)Overridable function which writes an additional encryption header. This is used in the KeyCipher* classes. The default implementation does nothing. |
_encryptionRandom(self)Write out the random first block of data. The default implementation writes block_size bytes of data on block cipher algorithms, and 128 bytes of random data on stream cipher algorithms. The latter works around a problem with the RC5 key scheduling algorithm. |
_encryptionSignature(self)Overridable function which writes an additional encryption signature. This is used in the KeyCipher* classes. The default implementation does nothing. |
Class Variable Details |
---|
_showpassword
|
Trees | Index | Help |
---|
Generated by Epydoc 1.1 on Sun Aug 17 03:32:34 2003 | http://epydoc.sf.net |