本文共 1652 字,大约阅读时间需要 5 分钟。
a) F
b) T c) T d) FIf Trudy does not bother to change the sequence number, R2 will detect the duplicate when checking the sequence number in the
ESP header. If Trudy increments the sequence number, the packet will fail the integrity check at R2.a) Since IV = 11, the key stream is 111110100000 ……….
Given,
m = 10100000Hence,
ICV = 1010 XOR 0000 = 1010The
three fields will be:IV: 11
Encrypted
message: 10100000 XOR 11111010 = 01011010Encrypted
ICV: 1010 XOR 0000 = 1010b) The receiver extracts the IV (11) and generates the
key stream 111110100000 ……….XORs
the encrypted message with the key stream to recover the original message:01011010
XOR 11111010 = 10100000XORs
the encrypted ICV with the keystream to recover the original ICV:1010
XOR 0000 = 1010The receiver
then XORs the first 4 bits of recovered message with its last 4 bits:1010
XOR 0000 = 1010 (which equals the recovered ICV)c) Since the ICV is calculated as the XOR of first 4
bits of message with last 4 bits of message, either the 1st bit or the 5th bit of the message has to be flipped for the received packet to pass the ICV check.d) For part (a), the encrypted message was 01011010
Flipping
the 1st bit gives, 11011010Trudy
XORs this message with the keystream:11011010
XOR 11111010 = 00100000If
Trudy flipped the first bit of the encrypted ICV, the ICV value received by the receiver is 0010The receiver XORs this value with the keystream to get the ICV:
0010 XOR 0000 = 0010
The receiver now calculates the ICV from the recovered message:
0010 XOR 0000 = 0010 (which equals the recovered ICV and so the received packet
passes the ICV check)转载地址:http://ckwai.baihongyu.com/