On Fri, Feb 22, 2013 at 5:40 PM, <Valdis.Kletnieks@xxxxxx> wrote:
In that case, you *really* want to go look at how TCP and SCTP and otherprotocols handle ICMP integration. You want an API that integrates your ICMP
handling with the rest of the protocol stack, because otherwise you'll
end up with an unmaintainable mess. Also, it will be about 436 times easier
to extend your protocol to work correctly over IPv6. :)
I am gonna definetly suggest that to the team and see what their reply is; thanks for a nice suggestions :)
Go look at net/ipv4/udp.c, functions __udp4_lib_err() and __udp_lib_rcv(),
particularly the latter's use of icmp_send(). You'll want to extend icmp_send()
to handle your additional control information.
Using icmp_send as it is wouldn't be as useful because my aim is to use ICMP(or actually any type of traffic, I wouldn't mind anything as long as it does the job and makes sense from an implementation prespective), to use ICMP, to send the information data I am exchanging to let my protocol work and that data might be 200 bytes long sometimes.
Regards,
Adel
Adel
_______________________________________________ Kernelnewbies mailing list Kernelnewbies@xxxxxxxxxxxxxxxxx http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies