即使 Windows 在缓存(ARP 表)中有条目,也会发送 ARP 请求

发布于 2024-11-04 15:55:17 字数 322 浏览 8 评论 0原文

我们有一款运行 Windows XP Embedded SP1 的产品。我们在 ARP 表中为假 IP 配置假(不存在)MAC 地址。当发生通信时,Windows 将数据包发送到假 MAC 和 fakeIP,然后我们在驱动程序中将其更改为真实的 MAC 和 fakeIP。 这就是软件的设计方式。

问题是,有时 Windows 会开始发送针对假 IP 的 ARP 请求,即使它在 ARP 表中有一个条目。我不知道为什么会发生这种情况,并且为了盲目地尝试重现该问题,我编写了一个脚本来删除 ARP 条目,然后在几秒钟后再次添加它。经过一番尝试,我发现问题发生了。

关于我应该检查/更改什么的任何想法?

We have a product that runs Windows XP Embedded SP1. We configure a fake (does not exist) MAC address for a fake IP in the ARP table. When there is a communication happening, Windows sends packets to the fake MAC and fakeIP and later we change it to real ones in a driver.
This is how the software is designed.

The problem is that sometimes Windows starts sending ARP requests for the fake IP even though it has an entry for it in the ARP table. I had no clue why this was happening and, in blind attempt to reproduce the issue, I wrote a script to delete ARP entry then add it again after some seconds. After some attempts, I saw the problem happening.

Any ideas about what should I check/change?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

小瓶盖 2024-11-11 15:55:18

您可以在 arp 缓存中有条目和没有条目的两种情况下检查以太网帧 MAC 地址吗?
另外,检查您的代码,我想您会在代码中找到一些对假IP地址的引用(您可能忘记更改)
有许多应用程序层协议需要在通信之前使用 ARP,所以我认为您可能在代码中使用这些协议之一,并且指示代码与假 IP 地址进行通信,这就是为什么当您调用该协议使用 arp 来查找假 IP 的 MAC 地址。
如果这能回答您的问题,请告诉我。

Can you Check the Ethernet Frame MAC Addresses in both cases, in the case where there is an entry and when there is no entry in the arp cache.
Additionally, Check your code, I think you will find some reference to the FAKE IP address inside your code (that you might have forgot to change)
There are many application layer protocols that require the use of ARP prior to their commmunication, So I think maybe you're using one of these protocols in your code and you instruct the code to communicate with the fake IP address, that's why when you invoke this protocol it uses arp to find the mac address of the fake IP.
Let me know if this answers your question.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文