1

Is there a way to send out a packet such that its path is predetermined? Basically, I want to attach an "IP map" of how I want it to travel. If so, what are the steps?

Thanks!

  • That actually defeats the purpose of IP, which is to automatically route around damage. IP was an experiment funded by the DoD to maintain communications in the event of war, where the traditional circuit-switched infrastructure is susceptible to being damaged and not working. – Ron Maupin May 8 '19 at 19:38
6

What you are describing is IP Source Route. However, any network with even a hint of security will have source-route disabled. But if you want to try it anyway, keep in mind there's a limit to the size of an IP header, and thus, a limit to the number of hops you can specify.

| improve this answer | |
  • Worth mentioning that IP source routing is on by default in IOS. Readers should disable it on their Cisco boxes if they have not already done so – Mike Pennington Apr 28 '14 at 21:52
  • I went to the wikipedia article on IP source routing and read that there's strict source & record routing (SSRR) and loose source & record route (LSRR) and that LSRR is the one that's blocked on many routers. So am I correct in thinking that SSRR will likely still work? – lynvie Apr 29 '14 at 3:41
  • 1
    The wiki article is sparse and incorrect. no ip source-route turns off all ip header source routing on Cisco gear. (and everybody else clones that behavior) The accept_source_route flag in linux also affects both strict and loose source-route options. – Ricky Apr 29 '14 at 4:06
  • So it sounds like it's not really possible. The closest thing is just a passive traceroute approach. Too bad! Thanks for the info. – lynvie Apr 29 '14 at 21:11
2

You can use ping with the -j (loose source) or -k (strict source) option to send such a packet. Just keep in mind that this feature is normally disabled on routers for security reasons.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.