Example #1
0
def test_encrypt_decrypt():
    raw_data = [
        123,
        '£¿éά',
        {
            (2, 3, 5): datetime.datetime.now()
        }
    ]
    key = 'strong password'
    assert raw_data == decrypt(encrypt(raw_data, key), key)
Example #2
0
def loads(bytes_object, key, *,  fix_imports=True, encoding='ASCII', errors='strict'):
    return _utils.decrypt(bytes_object, key, fix_imports, encoding, errors)