Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Write Assembly code ( only assembly code and no procedure call ) that performs decryption ( recovers the original string ) of an encrypted string.
Write Assembly code only assembly code and no procedure call that performs decryption recovers the original string of an encrypted string. The encryption is performed by rotating each plaintext byte a varying number of positions in different directions. For example, in the following array that represents the encryption key, a negative value indicates a rotation to the left and a positive value indicates a rotation to the right for rotation you are only allowed to use ROR instruction The integer in each position indicates the magnitude of the rotation: key BYTE
Encryption algorithm rotates each plaintext byte by the amount indicated by its matching key array value. Then, align the key to the next bytes of the message and repeat the process.
Please remember that ROR eax, is the same as ROL. eax,
Here is a sample input:
data
Encryptkey BYTE
encrypted BYTE Hv$Pq&JzXuT@w
size $encrypted
decrypted BYTE DUP sizePlease only in MASM
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started