des-PurePy 1.0.6__tar.gz → 1.0.7__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {des_purepy-1.0.6 → des_purepy-1.0.7}/PKG-INFO +7 -15
- {des_purepy-1.0.6 → des_purepy-1.0.7}/README.md +32 -40
- {des_purepy-1.0.6 → des_purepy-1.0.7}/pyproject.toml +1 -1
- {des_purepy-1.0.6 → des_purepy-1.0.7}/.github/workflows/python-app.yml +0 -0
- {des_purepy-1.0.6 → des_purepy-1.0.7}/.gitignore +0 -0
- {des_purepy-1.0.6 → des_purepy-1.0.7}/LICENSE +0 -0
- {des_purepy-1.0.6 → des_purepy-1.0.7}/driver.py +0 -0
- {des_purepy-1.0.6 → des_purepy-1.0.7}/src/des_PurePy/__init__.py +0 -0
- {des_purepy-1.0.6 → des_purepy-1.0.7}/src/des_PurePy/constants.py +0 -0
- {des_purepy-1.0.6 → des_purepy-1.0.7}/src/des_PurePy/des.py +0 -0
- {des_purepy-1.0.6 → des_purepy-1.0.7}/tests/functionality_test.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: des_PurePy
|
|
3
|
-
Version: 1.0.
|
|
3
|
+
Version: 1.0.7
|
|
4
4
|
Summary: A pure python implementation of DES
|
|
5
5
|
Project-URL: Homepage, https://github.com/Perez-Herrera-Luna/DES-Python
|
|
6
6
|
Author-email: Luna Perez-Herrera <lunaperezherrer@gmail.com>
|
|
@@ -28,26 +28,18 @@ Install using your Python package manager of choice:
|
|
|
28
28
|
pip install des_Py
|
|
29
29
|
```
|
|
30
30
|
|
|
31
|
-
```
|
|
32
|
-
Plaintext: 0x0123456789abcdef
|
|
33
|
-
Key: 0x133457799bbcdff1
|
|
34
|
-
Ciphertext: 0x85e813540f0ab405
|
|
35
|
-
Decrypted text: 0x0123456789abcdef
|
|
36
|
-
```
|
|
37
|
-
|
|
38
31
|
## Usage
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
Define a `DES` object while passing in your key. Key should be a hex string representing an 8 byte hexadecimal number.
|
|
32
|
+
### Encrypting Hex Strings
|
|
33
|
+
Define a `DES` object while passing in your key. The key can be a hex string or a bytes object.
|
|
42
34
|
```python
|
|
43
35
|
import des_Py
|
|
44
36
|
des = des_Py.DES("0x133457799bbcdff1")
|
|
45
37
|
```
|
|
46
|
-
You can encrypt by calling `encrypt()` and passing in a hex string
|
|
38
|
+
You can encrypt by calling `encrypt()` and passing in a hex string or bytes object.
|
|
47
39
|
```python
|
|
48
|
-
des.encrypt("0x0123456789abcdef") # -> "
|
|
40
|
+
des.encrypt("0x0123456789abcdef") # -> "0x85e813540f0ab405fdf2e174492922f8"
|
|
49
41
|
```
|
|
50
|
-
You can simarly decrypt by calling `decrypt()` and passing in a hex string
|
|
42
|
+
You can simarly decrypt by calling `decrypt()` and passing in a hex string or bytes object.
|
|
51
43
|
```python
|
|
52
|
-
des.decrypt("
|
|
44
|
+
des.decrypt("0x85e813540f0ab405fdf2e174492922f8") # -> "0x0123456789abcdef"
|
|
53
45
|
```
|
|
@@ -1,40 +1,32 @@
|
|
|
1
|
-
# DES-Python
|
|
2
|
-
|
|
3
|
-

|
|
4
|
-
[](https://github.com/Perez-Herrera-Luna/DES-Python/blob/main/LICENSE)
|
|
5
|
-
[](https://github.com/Perez-Herrera-Luna/DES-Python/actions/workflows/python-app.yml)
|
|
6
|
-
|
|
7
|
-
Data Encryption Standard (DES) implemented in pure Python
|
|
8
|
-
|
|
9
|
-

|
|
10
|
-
|
|
11
|
-
## Installation
|
|
12
|
-
|
|
13
|
-
Install using your Python package manager of choice:
|
|
14
|
-
```bash
|
|
15
|
-
pip install des_Py
|
|
16
|
-
```
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
des
|
|
32
|
-
```
|
|
33
|
-
You can encrypt by calling `encrypt()` and passing in a hex string representing an 8 byte hexadecimal number
|
|
34
|
-
```python
|
|
35
|
-
des.encrypt("0x0123456789abcdef") # -> "0x85e813540f0ab405"
|
|
36
|
-
```
|
|
37
|
-
You can simarly decrypt by calling `decrypt()` and passing in a hex string to decrypt
|
|
38
|
-
```python
|
|
39
|
-
des.decrypt("0x85e813540f0ab405") # -> "0x0123456789abcdef"
|
|
40
|
-
```
|
|
1
|
+
# DES-Python
|
|
2
|
+
|
|
3
|
+

|
|
4
|
+
[](https://github.com/Perez-Herrera-Luna/DES-Python/blob/main/LICENSE)
|
|
5
|
+
[](https://github.com/Perez-Herrera-Luna/DES-Python/actions/workflows/python-app.yml)
|
|
6
|
+
|
|
7
|
+
Data Encryption Standard (DES) implemented in pure Python
|
|
8
|
+
|
|
9
|
+

|
|
10
|
+
|
|
11
|
+
## Installation
|
|
12
|
+
|
|
13
|
+
Install using your Python package manager of choice:
|
|
14
|
+
```bash
|
|
15
|
+
pip install des_Py
|
|
16
|
+
```
|
|
17
|
+
|
|
18
|
+
## Usage
|
|
19
|
+
### Encrypting Hex Strings
|
|
20
|
+
Define a `DES` object while passing in your key. The key can be a hex string or a bytes object.
|
|
21
|
+
```python
|
|
22
|
+
import des_Py
|
|
23
|
+
des = des_Py.DES("0x133457799bbcdff1")
|
|
24
|
+
```
|
|
25
|
+
You can encrypt by calling `encrypt()` and passing in a hex string or bytes object.
|
|
26
|
+
```python
|
|
27
|
+
des.encrypt("0x0123456789abcdef") # -> "0x85e813540f0ab405fdf2e174492922f8"
|
|
28
|
+
```
|
|
29
|
+
You can simarly decrypt by calling `decrypt()` and passing in a hex string or bytes object.
|
|
30
|
+
```python
|
|
31
|
+
des.decrypt("0x85e813540f0ab405fdf2e174492922f8") # -> "0x0123456789abcdef"
|
|
32
|
+
```
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|