Question: Write a Python code to do the following: * Generate a random 2 5 6 - bit AES key and a 1 2 8 -
Write a Python code to do the following:
Generate a random bit AES key and a bit random IV
Based on the above key & IV
Use AES to encrypt and decrypt a message Cyber Security is fun
Use AES to encrypt a given file eg "test.txt and output "test.txtenc".
Use AES again to decrypt the "test.txtenc" to get your file back "test.dec.txt
Check that "test.dec.txt is identical to "test.txt
Test the above on different files.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
