路由追踪理论

发布于 2024-08-27 01:58:17 字数 188 浏览 4 评论 0原文

我正在玩跟踪路由,每次收到超时消息时,我的应用程序都会发送一个 ttl 为 0 的 ICMP 回显请求,我将 ttl 加一并重新发送包,但发生的情况是我的网络上有 2 个路由器可以通过这些路由器跟踪路由,但无论我跟踪路由到哪里,第三跳总是最终成为每次相同 IP 的开放 DNS 服务器之一。 AFAIK这是正确的traceroute实现,谁能告诉我我做错了什么?

I am toying with trace route, my application send a ICMP echo request with a ttl of 0 every time i receive a time exceeded message i increment the ttl by one and resent the package, but what happens is I have 2 routers on my network i can trace the route through these router but third hop always ends up being one of the open dns servers same ip every time no matter where i traceroute to. AFAIK this is the correct traceroute implementation, can anyone tell me what i am doing wrong?

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

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

发布评论

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

评论(3

亢潮 2024-09-03 01:58:17

两个路由器有可能连接到同一个对等点,并且您会得到所描述的行为。

如果没有更多信息,实际上不可能回答您的问题。

It's possible that both routers connect to the same peer, and you'd get the described behaviour.

Without more info, it's not really possible to answer your question.

奢欲 2024-09-03 01:58:17

虽然在没有任何附加信息的情况下很难说,但最好的选择是安装一些数据包嗅探器 - 可能是wireshark / www.wireshark.org - 并比较 icmp 数据包 - 线路上发生了什么与你的跟踪路由,以及系统做了什么/usr/bin/traceroute(或 \windows\system32\tracert)发送。

While it's hard to say without any additional information, the best bet would be to install some packet sniffer — probably wireshark / www.wireshark.org — and compare the icmp packets — what goes on the wire with your traceroute, and what does the system /usr/bin/traceroute (or \windows\system32\tracert) send.

迷离° 2024-09-03 01:58:17

如果路径上有 NAT 路由器,它可能会破坏您精心调整的 TTL

If you have a NAT router on the path it can screw up your nicely adjusted TTL's

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