arp协议、mac和ip
对 ARP 感兴趣并想检查一下。
ARP协议是用来查找MAC和IP地址的,是吗?
与此有何不同:
IPHostEntry iphostentry = Dns.GetHostByName(strHostName);
interested in ARP and wanted to check.
ARP protocol is used found MAC and IP addresses, yes?
How is it different from this:
IPHostEntry iphostentry = Dns.GetHostByName(strHostName);
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
Dns.GetHostByName()
使用 DNS - 从 DNS 域 (www.google.com) 获取 IP 地址 (1.2.3.4)。ARP 用于从 IP (1.2.3.4) 获取 MAC 地址 (11:22:33:44:55:66)。
假设您在浏览器中输入 www.google.com:
ARP 向局域网发送一个问题 - 谁有 1.2.3.4?拥有它的人都会回答 - 这样发送者就知道他需要将数据包发送到的 1.2.3.4 的 MAC 地址是什么。
请参阅 http://en.wikipedia.org/wiki/Address_Resolution_Protocol
和 http://en.wikipedia.org/wiki/Domain_Name_System
Dns.GetHostByName()
uses DNS - to get IP address (1.2.3.4) from a DNS domain (www.google.com).ARP is used to get a MAC address (11:22:33:44:55:66) from IP (1.2.3.4).
Let's say you write www.google.com in your browser:
ARP sends a question to the LAN - who has 1.2.3.4? And whoever has it answers - so the sender knows what's the MAC address of 1.2.3.4 that he needs to send the packets to.
See http://en.wikipedia.org/wiki/Address_Resolution_Protocol
And http://en.wikipedia.org/wiki/Domain_Name_System