RFC 777 (ICMP) - April 1981 Obsoleted by: 792 (ICMP) Updates: RFC 760 (IP) RFC 792 (S, ICMP) - September 1981 Updated by: 4884 (PS, Extended ICMP to Support Multi-Part Messages), 950 (S, Internet Standard Subnetting Procedure) Updates: RFCs 777 (ICMP), 760 (IP) 777 0 1 2 3 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | Type | Code | unused | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | Gateway Internet Address | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | Internet Header + 64 bits of Original Data Datagram | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 792 0 1 2 3 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | Type | Code | Checksum | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | Gateway Internet Address | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | Internet Header + 64 bits of Original Data Datagram | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ RFC 1122 Tutto molto bello, pratico e funzionante. Tranne che per gli IBM AS/400. Malgrado la RFC sia categorica (“A host receiving a Redirect message MUST update its routing information accordingly.”), lo stack TCP/IP degli AS/400 non obbedisce ai messaggi ICMP Redirect e gli ignora bellamente. Nel caso in oggetto quindi, oltre alla rotta statica sul default gateway, che fa funzionare gli host “obbedienti” senza doverli neppure toccare, è necessario inserire una entry direttamente nella tabella di routing dell”AS, altrimenti i pacchetti di ritorno agli host della sede remota non giungerebbero a destinazione. Updated by: 1349, 4379 Network Working Group Internet Engineering Task Force Request for Comments: 1122 R. Braden, Editor October 1989 Requirements for Internet Hosts -- Communication Layers 3.2.2.2 Redirect: RFC-792 A host SHOULD NOT send an ICMP Redirect message; Redirects are to be sent only by gateways. A host receiving a Redirect message MUST update its routing information accordingly. Every host MUST be prepared to accept both Host and Network Redirects and to process them as described in Section 3.3.1.2 below. A Redirect message SHOULD be silently discarded if the new gateway address it specifies is not on the same connected (sub-) net through which the Redirect arrived [INTRO:2, Appendix A], or if the source of the Redirect is not the current first-hop gateway for the specified destination (see Section 3.3.1). static void icmp_redirect() net/ipv4/icmp.c http://www.laurentconstantin.com/en/netw/netwag/