Re: [6tisch] SeqNum definition in RFC8480 (6P)

Xavi Vilajosana Guillen <xvilajosana@uoc.edu> Tue, 23 April 2019 03:34 UTC

Return-Path: <xvilajosana@uoc.edu>
X-Original-To: 6tisch@ietfa.amsl.com
Delivered-To: 6tisch@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 2E255120155 for <6tisch@ietfa.amsl.com>; Mon, 22 Apr 2019 20:34:53 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -0.95
X-Spam-Level:
X-Spam-Status: No, score=-0.95 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DATE_IN_PAST_12_24=1.049, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=no autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (1024-bit key) header.d=uoc.edu
Received: from mail.ietf.org ([4.31.198.44]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id plK-l6Xh2yvb for <6tisch@ietfa.amsl.com>; Mon, 22 Apr 2019 20:34:49 -0700 (PDT)
Received: from mail-lj1-x22e.google.com (mail-lj1-x22e.google.com [IPv6:2a00:1450:4864:20::22e]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id D9652120136 for <6tisch@ietf.org>; Mon, 22 Apr 2019 20:34:48 -0700 (PDT)
Received: by mail-lj1-x22e.google.com with SMTP id l23so1522820lja.3 for <6tisch@ietf.org>; Mon, 22 Apr 2019 20:34:48 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=uoc.edu; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=B9t/TntHXrok6yrPRVhii5XjbSFYiVd/uEhD+Gy8i18=; b=MRWJt5Xjn9cJtjtZMJWscplW2Y43rTJO5qYKMo+NIMLnsFlAuZvsquEV/Ee+0kNa6e pX3qwUnbjoRMlE+n6iClPZbuVjvYTH9n35/0ZMdGSWqhYCPsGMVZVAi063/34/2Otuou +WNbY7SMhbdhAmew4Ocm4XfJWpJMqNTaLY3b0=
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=B9t/TntHXrok6yrPRVhii5XjbSFYiVd/uEhD+Gy8i18=; b=d8q+DglCZX9TDfCsC2i+cyLFzAR53MYLynZRB/ztT98SR0su4+EtU3D9RhK7MElYLG EQM7IHV53oXUYaNs6OWRYGIZoHTok4ymNrWhLmnPdqe7MEngF+n+I/8IbiyPPILrv7+Y f4IGn0wvemInzuQ1jI93BGew/6byAdl0U2g0NUbZBAVxCP6DY8qd+GNAYEClEkRQLFyA M13jAMbuIdokYYQ+viAn2KOdykyfMrL1dUM1RsnvV18oXyj1IkEA8/N5wZckdRznMfAo sZ7uP4l5hvjlM4RmzavtQjBU2NzihVjS6JjnRuFhDpAmz+lkKs+4fzSkoF+C8c7RGCXF RRmQ==
X-Gm-Message-State: APjAAAW0pFgiMurW56iwueTNGZvu9QRJsopH6RfA1wLyXYvDnIk5aqa3 mbGnEfXD1hL7plstjWpmim7NlnJ9cELJyJmN+jh4yQ==
X-Google-Smtp-Source: APXvYqzXLOh+kUb8ikMRVAz6sBYIwbLMpVSqWTR+25EOrxH/Js3bvxIq1g51jTs5PYbwKMGjWY4WToXy3nTKQtCl2I4=
X-Received: by 2002:a2e:a301:: with SMTP id l1mr13159803lje.61.1555990486797; Mon, 22 Apr 2019 20:34:46 -0700 (PDT)
MIME-Version: 1.0
References: <03CD9F4A-D6CD-44D2-AFF4-9F005ED409E8@inria.fr>
In-Reply-To: <03CD9F4A-D6CD-44D2-AFF4-9F005ED409E8@inria.fr>
From: Xavi Vilajosana Guillen <xvilajosana@uoc.edu>
Date: Mon, 22 Apr 2019 17:34:35 +0200
Message-ID: <CAC9+vPgBUVjOiECs5ZL6c6PNkZ12X81=YThCs872VCbtJVb=uQ@mail.gmail.com>
To: Yasuyuki Tanaka <yasuyuki.tanaka@inria.fr>
Cc: tisch <6tisch@ietf.org>
Content-Type: multipart/alternative; boundary="0000000000003d71eb05872a4437"
Archived-At: <https://mailarchive.ietf.org/arch/msg/6tisch/V-9_YBLjrWofW2d1wXwpjQHqN2Q>
Subject: Re: [6tisch] SeqNum definition in RFC8480 (6P)
X-BeenThere: 6tisch@ietf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: "Discuss link layer model for Deterministic IPv6 over the TSCH mode of IEEE 802.15.4e, and impacts on RPL and 6LoWPAN such as resource allocation" <6tisch.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/6tisch>, <mailto:6tisch-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/6tisch/>
List-Post: <mailto:6tisch@ietf.org>
List-Help: <mailto:6tisch-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/6tisch>, <mailto:6tisch-request@ietf.org?subject=subscribe>
X-List-Received-Date: Tue, 23 Apr 2019 03:34:53 -0000

Hi Yatch,

thanks for your observation. I think that the behaviour is correct as
described in the text. When node B power cycles loses the last seen seqNum.
Its stored value is then 0 and hence when it receives the request responds
with the error and with the stored last seen seqnum (0).

does it make sense?
regards
Xavi

Missatge de Yasuyuki Tanaka <yasuyuki.tanaka@inria.fr> del dia dv., 19
d’abr. 2019 a les 18:05:

> Hi,
>
> I came across a question in RFC8480 (6P), which looks like an error to
> me... Can anybody help? This is about the SeqNum field of the 6P header.
>
> Section 3.2.2 defines SeqNum like this:
>
> [https://tools.ietf.org/html/rfc8480#section-3.2.2]
> >   SeqNum:  The sequence number associated with the 6P Transaction.
> >         Used to match the 6P Request, 6P Response, and 6P Confirmation
> >         of the same 6P Transaction.
>
> So, basically, a response and a confirmation have the same SeqNum
> value as the corresponding request. This is very normal.
>
> However, Section 3.4.6.2 says, if a node detect schedule inconsistency
> with a received request, the node does a different thing. A response
> in this case has a different SeqNum value from the corresponding
> request. This is strange...
>
> [https://tools.ietf.org/html/rfc8480#section-3.4.6.2]
> >   If the inconsistency is detected during a 6P Transaction (Figure 31),
> >   the node that has detected it MUST send back a 6P Response or 6P
> >   Confirmation with an error code of RC_ERR_SEQNUM.  In this 6P
> >   Response or 6P Confirmation, the SeqNum field MUST be set to the
> >   value of the sender of the message (0 in the example in Figure 31).
>
> In Figure 31, Node A receives 6P Response (SeqNum=0, RC_ERR_SEQNUM) in
> the last part of the message sequence. But, according to the
> definition by Section 3.2.2, Node A doesn't consider the response to
> be part of the transaction initiated by 6P Request (SeqNum=88),
>
> [https://tools.ietf.org/html/rfc8480#section-3.4.6.2]
> >           +----------+                           +----------+
> >           |  Node A  |                           |  Node B  |
> >           +----+-----+                           +-----+----+
> >      SeqNum=87 |                                       | SeqNum=87
> >                |                                       |
> >                | 6P Request  (SeqNum=87)               |
> >                |-------------------------------------->|
> >                |                                L2 ACK |
> >                |<- - - - - - - - - - - - - - - - - - - |
> >                |                                       |
> >                | 6P Response  (SeqNum=87)              |
> >                |<--------------------------------------|
> >                | L2 ACK                                |
> >                | - - - - - - - - - - - - - - - - - - ->|
> >                |                                     ==== power-cycle
> >                |                                       |
> >      SeqNum=88 |                                       | SeqNum=0
> >                |                                       |
> >                | 6P Request (SeqNum=88)                |
> >                |-------------------------------------->| Inconsistency
> >                |                                L2 ACK | detected
> >                |<- - - - - - - - - - - - - - - - - - - |
> >                |                                       |
> >                | 6P Response (SeqNum=0, RC_ERR_SEQNUM) |
> >                |<--------------------------------------|
> >                | L2 ACK                                |
> >                | - - - - - - - - - - - - - - - - - - ->|
> >
> >         Figure 31: Example of Inconsistency Because Node B Resets
> >                           (Detected by Node B)
>
> If this is an error, I'm going to file an errata entry. Otherwise, I'd
> like to know why Node B in Figure 31 MUST set 0 to SeqNum for the 6P
> Response having RC_ERR_SEQNUM. Node A becomes aware of schedule
> inconsistency anyway, seeing RC_ERR_SEQNUM in the response.
>
> By the way, the 5th paragraph in Section 3.4.6 supports Section
> 3.2.2. The response in an example of the paragraph has the same SeqNum
> value as the response, which is 0. This is the same case as explained
> with Figure 32.
>
> [https://tools.ietf.org/html/rfc8480#section-3.4.6]
> >   When node B receives a 6P Request from node A with SeqNum equal to 0,
> >   it checks the stored SeqNum for A.  If A is a new neighbor, the
> >   stored SeqNum in B will be 0.  The transaction can continue.  If the
> >   stored SeqNum for A in B is different than 0, a potential
> >   inconsistency is detected.  In this case, B MUST return RC_ERR_SEQNUM
> >   with SeqNum=0.  The SF of node A MAY decide what to do next, as
> >   described in Section 3.4.6.2.
>
> Or, am I just confused...?
>
> Best,
> Yatch
>
> _______________________________________________
> 6tisch mailing list
> 6tisch@ietf.org
> https://www.ietf.org/mailman/listinfo/6tisch
>


-- 
Dr. Xavier Vilajosana
Wireless Networks Lab

*Internet Interdisciplinary Institute (IN3)Professor*
(+34) 646 633 681
xvilajosana@uoc.edu <usuari@uoc.edu>
http://xvilajosana.org
http://wine.rdi.uoc.edu
Parc Mediterrani de la Tecnologia
Av Carl Friedrich Gauss 5, B3 Building
08860 Castelldefels (Barcelona). Catalonia. Spain
[image: Universitat Oberta de Catalunya]
­