Hi Yukiyo Akisada,
Thank you for your answer.
> Inverse of checksum should be applied only to UDP packet.
> Your log is the checksum of ICMPv6, right?
Right, it is an ICMPv6 packet.
> ICMPv6's checksum isn't optional.
> So it doesn't need to inverse checksum.
>
> The purpose of inverse is to distinguish the checksum was calculated or not by the sender.
I'm not sure I've correctly understoud your explainations. His is a
summary of my situation : my nut generates an ICMPv6 packet that
contains a 0xFFFF checksum, which is correct according to the RFC below.
TAHI tells the test is FAIL because it processes the checksum field by
itself to 0x0000, which seems incorrect according to the RFC below.
>> o Unlike IPv4, when UDP packets are originated by an IPv6 node,
>> the UDP checksum is not optional. That is, whenever
>> originating a UDP packet, an IPv6 node must compute a UDP
>> checksum over the packet and the pseudo-header, and, if that
>> computation yields a result of zero, it must be changed to hex
>> FFFF for placement in the UDP header. IPv6 receivers must
>> discard UDP packets containing a zero checksum, and should log
>> the error.
With the patch, I can't see the problem anymore. But what I'm not sure
in my patch is : is it the good way to do it ?
In my opinion, the variable 'optionable' is true when the checksum can
be an option. So, I replaced the test :
"if checksum is 0 and can be an option => set it to 0xFFFF"
by :
"if checksum is 0 and _cannot_ be an option => set it to 0xFFFF"
Thanks,
Olivier