Re: [CGA-EXT] SEND checksum issue in current RFC 3791 - update needed

Sheng Jiang <shengjiang@huawei.com> Thu, 17 September 2009 07:44 UTC

Return-Path: <shengjiang@huawei.com>
X-Original-To: cga-ext@core3.amsl.com
Delivered-To: cga-ext@core3.amsl.com
Received: from localhost (localhost [127.0.0.1]) by core3.amsl.com (Postfix) with ESMTP id 566C73A679F for <cga-ext@core3.amsl.com>; Thu, 17 Sep 2009 00:44:35 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.033
X-Spam-Level:
X-Spam-Status: No, score=-1.033 tagged_above=-999 required=5 tests=[AWL=1.566, BAYES_00=-2.599]
Received: from mail.ietf.org ([64.170.98.32]) by localhost (core3.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id VM82E4fU75y3 for <cga-ext@core3.amsl.com>; Thu, 17 Sep 2009 00:44:33 -0700 (PDT)
Received: from szxga03-in.huawei.com (szxga03-in.huawei.com [119.145.14.66]) by core3.amsl.com (Postfix) with ESMTP id 3457F3A6784 for <cga-ext@ietf.org>; Thu, 17 Sep 2009 00:44:33 -0700 (PDT)
Received: from huawei.com (szxga03-in [172.24.2.9]) by szxga03-in.huawei.com (iPlanet Messaging Server 5.2 HotFix 2.14 (built Aug 8 2006)) with ESMTP id <0KQ30021NUQI8J@szxga03-in.huawei.com> for cga-ext@ietf.org; Thu, 17 Sep 2009 15:42:18 +0800 (CST)
Received: from huawei.com ([172.24.1.24]) by szxga03-in.huawei.com (iPlanet Messaging Server 5.2 HotFix 2.14 (built Aug 8 2006)) with ESMTP id <0KQ300NWOUQC1S@szxga03-in.huawei.com> for cga-ext@ietf.org; Thu, 17 Sep 2009 15:42:12 +0800 (CST)
Received: from j66104a ([10.111.12.58]) by szxml04-in.huawei.com (iPlanet Messaging Server 5.2 HotFix 2.14 (built Aug 8 2006)) with ESMTPA id <0KQ300ASAUQC6L@szxml04-in.huawei.com> for cga-ext@ietf.org; Thu, 17 Sep 2009 15:42:12 +0800 (CST)
Date: Thu, 17 Sep 2009 15:42:12 +0800
From: Sheng Jiang <shengjiang@huawei.com>
In-reply-to: <87iqficdo9.fsf@small.ssi.corp>
To: 'Arnaud Ebalard' <arno@natisbad.org>
Message-id: <002501ca376a$5eb39950$3a0c6f0a@china.huawei.com>
MIME-version: 1.0
X-MIMEOLE: Produced By Microsoft MimeOLE V6.00.2900.3350
X-Mailer: Microsoft Office Outlook 11
Content-type: text/plain; charset="us-ascii"
Content-transfer-encoding: 7bit
Thread-index: Aco3Ybay4/dOfQHuTVaHo+mnY1CuowAA87rw
Cc: 'wdwang' <wdwang@bupt.edu.cn>, cga-ext@ietf.org
Subject: Re: [CGA-EXT] SEND checksum issue in current RFC 3791 - update needed
X-BeenThere: cga-ext@ietf.org
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: CGA and SeND Extensions <cga-ext.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/listinfo/cga-ext>, <mailto:cga-ext-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/cga-ext>
List-Post: <mailto:cga-ext@ietf.org>
List-Help: <mailto:cga-ext-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/cga-ext>, <mailto:cga-ext-request@ietf.org?subject=subscribe>
X-List-Received-Date: Thu, 17 Sep 2009 07:44:35 -0000

Hi, Arnaud,

Yes, it is an issue must be clearly clarified in the specification.
Actually, there are two possibility here (which makes more important that
specification should be clearly follow only one of them):

A, if we would like to follow the drscription in Section 5.2.1 RFC 3791, the
input of RSA signature should be a checksum calculated without RSA signature
and it will be recalculated after signature attached. On the receiver side,
ICMP checksum should be validated, then signature validate, then maybe
checksum validate again.

B, more efficiently, on the sender side, as you said, the input of RSA
signature should be a checksum with all 0, and after signature attached, the
checksim is computed over the whole packet. However, this makes the
signature over checksum totally meaningless. Alternatively, we may take
checksum bits out from the RSA signature input.

Additionally, there are intercommunication issues if a sender use A
implementation and a receiver uses B implementation.

Sum up, an update over the current definition RFC 3791 is needed on this
issue.

Cheers,

Sheng

> -----Original Message-----
> From: Arnaud Ebalard [mailto:arno@natisbad.org] 
> Sent: Thursday, September 17, 2009 2:02 PM
> To: Sheng Jiang
> Cc: cga-ext@ietf.org; 'wdwang'
> Subject: Re: [CGA-EXT] SEND checksum issue in current RFC 
> 3791 - update needed
> 
> Hi,
> 
> Sheng Jiang <shengjiang@huawei.com> writes:
> 
> > During our implementation of SEND & CGA, we discovered an 
> issue in the 
> > current RFC 3791, described as the following. An update is 
> needed to 
> > solve this issue.
> >
> > Checksum issue in the current SEND definition RFC 3791.
> >
> > In Section 5.2, RFC3791, digital signature is defined to sign data 
> > include checksum fieds from ICMP header (bullet item 4), 
> which should 
> > already be calculated during the construction of message (the first 
> > step in Section 5.2.1). After RSA signature is attached, 
> the original 
> > checksum value is no longer valid. It should be 
> recalsulated. However, 
> > this was not clearly defined in RFC 3791. More importantly, the 
> > correspondent validation rule must be defined on the 
> receiver side too.
> 
> I already reported that same issue some time ago and the good 
> way to understand the spec is to compute the signature over 
> the packet with the checksum field to 0. Then, the checksum 
> is computed over the whole packet. But I agree that the spec 
> is unclear on that.
> 
> See my post and Eric's reply here:
> 
>   http://www.ietf.org/mail-archive/web/cga-ext/current/msg00098.html
> 
> Cheers,
> 
> a+