Sweet, thanks! On Sat, Mar 16, 2013 at 8:16 PM, Daniel Borkmann <[email protected]> wrote: > On 03/12/2013 10:22 PM, Jon Schipp wrote: >> >> Earlier, I was looking for an ICMP checksum definition but noticed >> that it isn't in there. >> https://github.com/borkmann/netsniff-ng/blob/master/configs/stddef.h > > > Done. > > >> I imagine that this is because it's not a static value and there's not >> a possible way of doing it >> unless the default Linux and Windows payload values are used in >> stddef.h. I was trying to think >> of a way so I could add it but couldn't come up with anything. I may >> just try and add the OS defaults for >> an ICMP Echo request. I believe they use the same string each time. if >> there isn't a better way? Thoughts? >> >> Anyways, using csumip() works because the calculation is the same, you >> just have to make >> the ending offset included the ICMP header and data too. >> >> e.g. /* ICMP Checksum (Same as IP, end includes ICMP bytes) */ >> csumip(14, 48), > > > I've added this by today into the code. csumicmp aliases now to csumip > in the lexer script. > > >> ^Offset 14 (begin IP header) + 20 (end IP header) + 14 ICMP bytes >> (including ICMP header) = 48 data bytes for checksum calculation > > > -- > You received this message because you are subscribed to the Google Groups > "netsniff-ng" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > For more options, visit https://groups.google.com/groups/opt_out. > >
-- You received this message because you are subscribed to the Google Groups "netsniff-ng" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/groups/opt_out.
