File tree 1 file changed +7
-9
lines changed
1 file changed +7
-9
lines changed Original file line number Diff line number Diff line change 1
1
import base64
2
- from Crypto .Cipher import AES
2
+ from Crypto .Cipher import AES
3
3
from Crypto .Util .Padding import pad , unpad
4
4
5
5
6
-
7
- '''
8
- AES (Advanced Encryption Standard) is a symmetric encryption algorithm used
9
- for secure data encryption. AES-128 uses a 128-bit key to encrypt and decrypt
10
- data blocks of 128 bits. This implementation uses Cipher Block Chaining (CBC) mode
6
+ """
7
+ AES (Advanced Encryption Standard) is a symmetric encryption algorithm used
8
+ for secure data encryption. AES-128 uses a 128-bit key to encrypt and decrypt
9
+ data blocks of 128 bits. This implementation uses Cipher Block Chaining (CBC) mode
11
10
with PKCS7 padding for encrypting messages.
12
11
13
- For more details, visit:
12
+ For more details, visit:
14
13
https://en.wikipedia.org/wiki/Advanced_Encryption_Standard
15
- '''
16
-
14
+ """
17
15
18
16
19
17
def aes_encrypt (plaintext : str , key : str ) -> str :
You can’t perform that action at this time.
0 commit comments