Question: This Python homework simulates a simplified cache - based side - channel attack to illustrate the vulnerability. In this case, you will try to break
This Python homework simulates a simplified cachebased sidechannel attack to illustrate the vulnerability. In this case, you will try to break a bit encryption mechanism running on the target VM
Objectives:
Simulate a scenario where a VM attacker tries to guess bits of a target VM secret key using variations in cache access times.
The program will take arguments:
A csv file that will contain the delay to be added to the different encryption bits. The file will have the following format:
Encryption Bit,Delay
where the first column will represent the specific bit, and the second column the delay in seconds to be added. The time will simulate a "cache delay" when using that specific key bit.
A time delay that will represent the "cache latency" of an unknown key.
Your program will only use bit keys. That means that a key will need to have a value between and I a key of is passed, it means bit is enabled for that key and the time delay for that bit must be added. If a key of is passed, it means bit is enabled so a time delay of must be added.
Expected output
Using the bit delay file your program will perform a probePhase where you will pass known keys to an encryptionstr key method. This encryption method will add proper delays depending on the bits used on the key. The key can only be bits long. During this probe phase your program will store relevant information on the different keys passed and the "cache latency" that is incurred after using these keys.
Using these cache profile your program will output the set of keys that are in the seconds ballpark of the cache latency passed as input.
This is a sample program run:
python sidechannel.py
Expected Output:
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
