CIS 427/IMSE 453: Homework 4 (HW4)

CIS 427/IMSE 453: Homework 4 (HW4)
Instructions
• No teamwork is allowed for all homework assignment.
• Turnitin option has been enabled on Canvas to compare your submission with other submissions
from this semester and past semesters and Internet database.
• Your solution should be written in a “.docx”, “.doc”, or “.pdf” format and submitted to the
assignment folder HW4 on Canvas.
• A subset of questions will be graded.
Questions
1. In CRC, we consider a 5-bit generator, G = 10011, and suppose that D has the value 1010101111.
What is the value of R? If the the 2nd bit (from left) of the received message is flipped, how can the
receiver detect such error?
2. Consider the slotted ALOHA for 4 users with transmission probability p. What is the efficiency?
What is the optimal value of p?
3. Consider multiple access protocols in link layer.
(a) Explain how random access MAC protocols could outperform channel partitioning MAC protocols.
(b) Explain how CSMA protocol could outperform ALOHA protocol.
4. Let’s consider the operation of a learning switch in the context of the multi-switch example on the
slides, where Hosts A, B, . . . , I are connected with four hierarchical switches Si, i = 1, 2, 3, 4. The
switch table is initially empty. Suppose that
(1) A sends a frame to H,
(2) H replies with a frame to A,
(3) D sends a frame to H,
(4) H replies with a frame to D.
For each of these events, identify the interface(s) through which the transmitted frame will be forwarded
at S3 (using the switching table to filter the transmitted frame). Show the state of the switch
table at S3 after each of these events (ignore the TTL field).
1
5. Explain what technology is used in CSMA/CD to specify when each host starts transferring a frame,
and what technology is used in CSMA/CD to specify when each host stops transferring a frame.
Explain how these two technologies reduce collisions, respectively.
6. Recall that with the CSMA/CD protocol, the exponential backoff is adopted. Explain in details how
it can reduce collision. Consider the following scenario: the adapter waits K · 512-bit times after a
collision, where K is drawn randomly. For K = 26, how long does the adapter wait until returning
to Step 2 for a 1 Gbps Ethernet?
7. What are the wireless link characteristics?
8. What are the requirement of the code used by each sender in CDMA? How many concurrent senders
can CDMA support for a code-length 16? Show how with CDMA the receiver recovers the original
message from each sender.
9. Explain why collision detection cannot be used in wireless environment. Instead we use CSMA/CA
in such environment. Unlike CSMA/CD, CSMA/CA applies random backoff before each new frame
sending and acknowledgement for each received frame. What are the main reasons behind this design?
10. What is the hidden terminal problem in the above wireless setting? How could RTS/CTS partially
solve this problem?
11. Message Authentication Code (MAC) can be used for verify the message integrity. Describe how
Message Authentication Code (MAC) works. However, MAC cannot be used for end-point authentication
due to the playback attach. Describe in detail such attack and how to defend against such
attack.
12. In Slide 21 in “6.2 security.pptx”, Alice uses symmetric key cyptography, public key cryptography, a
hash function, and a digital signature to send a secure email to Bob, which provides secrecy, sender
authentication, and message integrity. Diagram the corresponding decryption that Bob must perform
on the received encrypted email from Alice.
13. Consider the following pseudo-WEP protocol. The key is 4 bits and the IV is 2 bits. The IV is
appended to the end of the key when generating the keystream. Suppose that the shared secret key
is 1011. The keystreams for the four possible inputs are as follows:
1011 00: 1100101101010101001011010100100…
1011 01: 0110011011001010110100100101101…
1011 10: 1010111010111100010100101001111…
1011 11: 1111101010001000101010100010111…
Suppose all messages are 8-bits long and the ICV ( integrity check), and is calculated by XOR-ing
the first 4 bits of data with the last 4 bits of data. Suppose the pseudo-WEP packet consists of three
fields: first the IV field, then the message field, and last the ICV field, with last two fields encrypted.
(1) We want to send the message m = 11111001 using the above pseudo-WEP protocol with IV
= 01. What will be the values of the ICV before encryption, the encrypted message, and the
encrypted ICV?
(2) Briefly explain how confidentiality and message integrity are achieved in this pseudo-WEP protocol.
(3) What is the weakness of WEP? Explain why.
2

Order from us and get better grades. We are the service you have been looking for.