Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

I need help writing a program for the following problem ( Python Programming) .Please provide the original work ( do not post ans from other

I need help writing a program for the following problem ( Python Programming) .Please provide the original work ( do not post ans from other sources)

Implement a Message Authentication Code program in Python.

See the following steps.

1. Accept a message as keyboard input to your program.

2. Accept a secret key for the sender/recipientas keyboard input to your program.

3. Your hash function H() is simply the checksum. To compute the checksum, you add all the characters of the string in ASCII codes. For example, the checksum of a string "TAMUC" would be 84 + 65 + 77 + 85 + 67 = 378.

Concatenate the secret key of the sender/recipient (from step 2) and the message (from step 1) and compute the checksum of the concatenated string. For ASCII codes, refer to the following website:

http://www.asciitable.com

4. Accept a secret key for the attacker as keyboard input to your program.

5. The attacker modifies the message from step 1. The original message can be modified any way you want.

6. Concatenate the secret key of the attacker (from step 4) and the modified message (from step 5) and compute the checksum of the concatenated string.

7. Concatenate the secret key of thesender/recipient (from step 2) and the modified message (from step 5) and compute the checksum of the concatenated string.

8. Compare the checksum from step 7 and the checksum from step 6. See if they match or not.

9. Compare the checksum from step 3 and the checksum from step 6. See if they match or not.

NOTE: your program should have separate functions for the checksum and the message modification by the attacker

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Students also viewed these Programming questions