This class provides implementation of triple DES algorithm which uses MD5 hash of password as a key (it uses 16-byte key so it is triple DES with 2 keys)
More...
This class provides implementation of triple DES algorithm which uses MD5 hash of password as a key (it uses 16-byte key so it is triple DES with 2 keys)
Definition at line 10 of file tripledes.py.
◆ __init__()
def caellion.pycommons.encryption.tripledes.TripleDESECBMD5Key.__init__ |
( |
|
self, |
|
|
|
password |
|
) |
| |
Sets up the class for use.
- Parameters
-
password | password to use for key generation |
Definition at line 20 of file tripledes.py.
◆ decrypt()
def caellion.pycommons.encryption.tripledes.TripleDESECBMD5Key.decrypt |
( |
|
self, |
|
|
|
cipher |
|
) |
| |
Decodes and decrypts Base64-encoded 3DES-encrypted data.
- Parameters
-
cipher | base64-encoded encrypted data to decrypt |
- Returns
- decrypted string
Definition at line 45 of file tripledes.py.
◆ encrypt()
def caellion.pycommons.encryption.tripledes.TripleDESECBMD5Key.encrypt |
( |
|
self, |
|
|
|
data |
|
) |
| |
Encrypts data with 3DES ECB algorithm.
- Parameters
-
- Returns
- base64-encoded 3DES encrypted string
Definition at line 34 of file tripledes.py.
◆ DES3
caellion.pycommons.encryption.tripledes.TripleDESECBMD5Key.DES3 = None |
|
static |
◆ encryptionKey [1/2]
string caellion.pycommons.encryption.tripledes.TripleDESECBMD5Key.encryptionKey = "" |
|
static |
◆ encryptionKey [2/2]
caellion.pycommons.encryption.tripledes.TripleDESECBMD5Key.encryptionKey |
◆ padmode
caellion.pycommons.encryption.tripledes.TripleDESECBMD5Key.padmode = pyDes.PAD_PKCS5 |
|
static |
◆ password [1/2]
string caellion.pycommons.encryption.tripledes.TripleDESECBMD5Key.password = "" |
|
static |
◆ password [2/2]
caellion.pycommons.encryption.tripledes.TripleDESECBMD5Key.password |
The documentation for this class was generated from the following file: