Question: Write a procedure that performs simple encryption by rotating each plaintext byte a varying number of positions to the left based on the key value.

Write a procedure that performs simple encryption by rotating each plaintext byte a varying number of positions to the left based on the key value.

The integer in each position indicates the magnitude of the rotation: key BYTE 1, 7, 2, 3, 5, 4, 6

Your procedure should loop through a plaintext message and align the key to the first 7 bytes of the message. Rotate each plaintext byte by the amount indicated by its matching key array value. Then, align the key to the next 7 bytes of the message and repeat the process. Write a program that tests your encryption procedure by calling it twice, with different data sets. Print the original and encrypted plaintext.

This is in assembly language.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!