Re: [VRRP] RFC5798 - clarification on checksum calculation

Tomoyuki Sahara <sahara@surt.net> Sun, 01 April 2012 23:48 UTC

Return-Path: <tomosann@gmail.com>
X-Original-To: vrrp@ietfa.amsl.com
Delivered-To: vrrp@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id ECBE421F8778 for <vrrp@ietfa.amsl.com>; Sun, 1 Apr 2012 16:48:02 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.977
X-Spam-Level:
X-Spam-Status: No, score=-2.977 tagged_above=-999 required=5 tests=[BAYES_00=-2.599, FM_FORGED_GMAIL=0.622, RCVD_IN_DNSWL_LOW=-1]
Received: from mail.ietf.org ([12.22.58.30]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id Yd456q0kpeCa for <vrrp@ietfa.amsl.com>; Sun, 1 Apr 2012 16:48:02 -0700 (PDT)
Received: from mail-bk0-f44.google.com (mail-bk0-f44.google.com [209.85.214.44]) by ietfa.amsl.com (Postfix) with ESMTP id 37B8221F8777 for <vrrp@ietf.org>; Sun, 1 Apr 2012 16:48:02 -0700 (PDT)
Received: by bkuw5 with SMTP id w5so1922832bku.31 for <vrrp@ietf.org>; Sun, 01 Apr 2012 16:48:01 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type :content-transfer-encoding; bh=pj/kfZ+/0Bd3Z20qtSmB/ghrg+sQ2dvEv7k8nWlt8VE=; b=vMEXO3+W+UFeVejJC5b9qFZMSh/f+wDk0h8Jwx0Fv1NaK/jVMFctS2z4mmHnBjOV5C TgQfwT5l1X6Zj5cB2rYaBJEGAOJPwpnWMOELlu7pRe83ym85U0AgyJ19dbe1zXiiODgU 9hqMLo5jwZnse7CCD8D569x/q8Dxx6sbsyTHlBGDSf/q/5OgiSq0HQ5pO+K0OEggYtfV ca4SAzeBWmPU/UBQv/ia//KqRcBnbiIeSVwi4XUghTF8v9XwG2T2/uAiesK8xothfaVY xZVMoOfM3qIPO/S9MmPJOl+ua+J9PTW8M2GyOWpC3P/iLZz/JHgK2LVFzrVs8q2UlNxa y/oA==
MIME-Version: 1.0
Received: by 10.204.150.73 with SMTP id x9mr2547002bkv.7.1333324081261; Sun, 01 Apr 2012 16:48:01 -0700 (PDT)
Sender: tomosann@gmail.com
Received: by 10.204.153.194 with HTTP; Sun, 1 Apr 2012 16:48:01 -0700 (PDT)
In-Reply-To: <CAJgsEzVnofJ+Fm_eHgpHcZu8+Xuj2ZwEYT_Dy9wbovcVQzfWiA@mail.gmail.com>
References: <CAJgsEzVnofJ+Fm_eHgpHcZu8+Xuj2ZwEYT_Dy9wbovcVQzfWiA@mail.gmail.com>
Date: Mon, 2 Apr 2012 08:48:01 +0900
X-Google-Sender-Auth: IWcK3p2UN2oBMtrpyXmCtMaxSes
Message-ID: <CAH=tA5vaTU9X8t=JiZgxHKjq0-pCuw_vLmSHqjxzazWmrbFR9w@mail.gmail.com>
From: Tomoyuki Sahara <sahara@surt.net>
To: Hermin Anggawijaya <hermin.anggawijaya@gmail.com>
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
Cc: vrrp@ietf.org
Subject: Re: [VRRP] RFC5798 - clarification on checksum calculation
X-BeenThere: vrrp@ietf.org
X-Mailman-Version: 2.1.12
Precedence: list
List-Id: Virtual Router Redundancy Protocol <vrrp.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/vrrp>, <mailto:vrrp-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/vrrp>
List-Post: <mailto:vrrp@ietf.org>
List-Help: <mailto:vrrp-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/vrrp>, <mailto:vrrp-request@ietf.org?subject=subscribe>
X-List-Received-Date: Sun, 01 Apr 2012 23:48:03 -0000

Hi,

On Thu, Mar 29, 2012 at 4:29 PM, Hermin Anggawijaya
<hermin.anggawijaya@gmail.com>; wrote:
> Would someone be able to help clarifying RFC5798 Sec. 5.2.8 on
> checksum for me please...
>
> It says that
>
>  "The checksum is the 16-bit one's complement of the one's complement
>   sum of the entire VRRP message starting with the version field and a
>   "pseudo-header" as defined in Section 8.1 of [RFC2460].  The next
>   header field in the "pseudo-header" should be set to 112 (decimal)
>   for VRRP.  For computing the checksum, the checksum field is set to
>   zero.  See RFC1071 for more detail [RFC1071]."
>
> My interpretation of the above clause is, for IPv4 VRRP the checksum would be
> defined as:
>
> "The checksum is the 16-bit one's complement of the one's complement
>  sum of the entire VRRP message starting with the version field"
>
> as per RFC 3768, instead of involving "pseudo header" (as defined in
> Section 8.1 of [RFC2460]).

My understanding is only reference text ("as defined in Section 8.1 of
[RFC2460]") is irrelevant for IPv4.  Our implementation calculates checksum
including pseudo header as for TCP/UDP/DCCP.

> If my interpretation is correct, would it be useful to change the text to
> reflect specific checksum detail for IPv4 ?

My interpretation is different from yours but clarification should be
very useful.
It's vital for interoperable implementations of VRRPv3/IPv4.


Thanks,
Tomoyuki