联系方式

  • QQ:99515681
  • 邮箱:99515681@qq.com
  • 工作时间:8:00-21:00
  • 微信:codinghelp

您当前位置:首页 >> Python编程Python编程

日期:2020-12-16 11:33

Implementation of

Simple ARP Program

DATA COMMUNICATION ASSIGNMENT #2

The Pusrpose of Assignment #2

? Learning how to use the Ethernet directly from the applicati

on layer. ? understanding the Ethernet Frame, the EUI-48 MAC address, and ethernet type. ? exercise the socket API of the L2 layer for the Linux operating system.

ARP (Address Resolution Protocol)

? When an IP module wants to send an IP packet via DLL SAP,

it needs the destination MAC Address of the next hop node

of the IP packet. ? The IP module get the destination address by the ARP mod

ule. ? The ARP module maintains an ARP cache. ? From this cache, IP layer can get destination MAC Address of next hop toward de

stination IP of the IP packet. ? When the cache lookup missed, the ARP module performs the Address Resolutio

n Procedure.

Assignment #2

? 1. Implementation of Simple ARP Program

? 1. install two VM, VM1 and VM2. ? 2. An application on the VM1 send an ARP request. ? 3. An application on the VM2 receives the request and sends a ARP reply. ? 4. The application on the VM1 sends a data packet to the application the VM2. ? 2. Application must use the PF_PACKET socket for all comm

unication

? You may define any unused ETHER TYPE for the assignment applications

? In example codes, we used 0xFFFE for ARP request and reply and 0xFFFD for the data packet

? You may use two sockets but one socket with ETH_P_ALL is enough to exchange

all packets used at the assignment application.

Communication Flow (First sending)

It’

s me. My MAC Address is ~~~ 4

5 Hello! (Send intended message)

Communication Flow (Second sending)

Execute your sender program Receive ARP and normal data from VM1

Demo (On Wireshark, VM1)

NO.1 => ARP Request

NO.2 => ARP Reply

NO.3 => Send 1

st Normal Message

NO.4 => reply from VM2

NO.5 => Send 2

nd Normal Message

NO.6 => reply from VM2

Demo (On Wireshark, ARP Reply)

VM2

s MAC Address

Submission List

? 1. Report (Accept pdf and MS word only.)

? Explain how you designed two applications (sender (VM1), receiver (VM2)). ? Explain your application codes, including the skeleton codes. ? 2. Your application codes

? After compress above things, submit one compressed file. ? Important Notice

? Not completed/executable codes are acceptable, but heavily penalized. ? Late submission is accepted for one week only but penalized.


版权所有:编程辅导网 2021 All Rights Reserved 联系方式:QQ:99515681 微信:codinghelp 电子信箱:99515681@qq.com
免责声明:本站部分内容从网络整理而来,只供参考!如有版权问题可联系本站删除。 站长地图

python代写
微信客服:codinghelp