Re: Extension Header processing rules

Bob Hinden <bob.hinden@gmail.com> Tue, 10 November 2020 19:50 UTC

Return-Path: <bob.hinden@gmail.com>
X-Original-To: ipv6@ietfa.amsl.com
Delivered-To: ipv6@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id EC1DE3A0EAD for <ipv6@ietfa.amsl.com>; Tue, 10 Nov 2020 11:50:50 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.098
X-Spam-Level:
X-Spam-Status: No, score=-2.098 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com
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 d64eiJsso00P for <ipv6@ietfa.amsl.com>; Tue, 10 Nov 2020 11:50:49 -0800 (PST)
Received: from mail-wm1-x32a.google.com (mail-wm1-x32a.google.com [IPv6:2a00:1450:4864:20::32a]) (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 DD1753A0EA8 for <ipv6@ietf.org>; Tue, 10 Nov 2020 11:50:48 -0800 (PST)
Received: by mail-wm1-x32a.google.com with SMTP id w24so4386878wmi.0 for <ipv6@ietf.org>; Tue, 10 Nov 2020 11:50:48 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:message-id:mime-version:subject:date:in-reply-to:cc:to :references; bh=8RctFldJGny7R4LXVopqlovDq0nWpTnrT6vC3TdrUjk=; b=YbOQ6ogVkt1YNfzshJBygySFjVW9RmCKYZZQu3Vfd0lgXCqASVtVtw1RmriSn1vWlF /LiE3XW3sx3mbJctEoVZx4qtBy9XeGr0SwVBk6gKnitIxmnPfYrz0FYMrfN6yaC9ffJ1 IC7XmTMCIDaVpIjll88amHZOtgEzuvpHXkA2HRAblTLgJd/rKdACYGrAJlE4KnCCejgk FY1Qh+fNrO251qqXDBC4TEza7j5GT4n8YTeT8BWyEU1F41OQq+nxPdTB80dxXgsZFhyB PZ0b5GViWPTvBr7/Ugtwhfpjhn4BD8ZDtmbLtE8RLQQOfG135iRqBe3wqXEiuPqKCHfn Auhw==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:message-id:mime-version:subject:date :in-reply-to:cc:to:references; bh=8RctFldJGny7R4LXVopqlovDq0nWpTnrT6vC3TdrUjk=; b=dQCRvG+DJX/49xcNKfOioiMhUARCOO+bOWM3xRsrLSY4gIiJQAvmCX8fvthX04DDYg /echiAcKmy7sknW25G2T4zpOVvzlV6J2/6b8KFj8qaNz+1cbfX6UVvgn+Q7KFW/yk9n4 hA3/ikthfzT8Ezh2sVuraHxKTUL0bo+GEHHZs6ozsxr9xwf5WmD4zZn3lbP9sbGucRdV uG9xYRmDnENx0Sar46YyA5iVUCoc8aZDHowVDvbBoSvo0bJPjFdrPTOIl5C3EpOq3exv JtBDiMdQoCD7Hw7ZmDHbG8822rB2g2Mmf3VI4mFnGCy6zDbImUFIU3Y0VpTZ7Rvk+uYB 0LyQ==
X-Gm-Message-State: AOAM533EcPZpCEz9GxpLDoWD38BNLkTDE7cIXD3voM+suf/5FHeC5wKg SvFF2MmrnqPG5NmZzdPuUt0=
X-Google-Smtp-Source: ABdhPJxAQSi5vrbncnDGFNicfQD5saIyzmx7nofmh0uKAiWEe+cN/BzLf5bkumgGh2Xo7mC/belI9Q==
X-Received: by 2002:a1c:1b43:: with SMTP id b64mr810675wmb.64.1605037847268; Tue, 10 Nov 2020 11:50:47 -0800 (PST)
Received: from [10.0.0.199] (c-24-5-53-184.hsd1.ca.comcast.net. [24.5.53.184]) by smtp.gmail.com with ESMTPSA id u81sm4330278wmb.27.2020.11.10.11.50.44 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Tue, 10 Nov 2020 11:50:45 -0800 (PST)
From: Bob Hinden <bob.hinden@gmail.com>
Message-Id: <3E0C3544-EF7F-44BF-BF10-97DB5F79639E@gmail.com>
Content-Type: multipart/signed; boundary="Apple-Mail=_32941458-EA49-4277-8B9F-BF1094D7BCD6"; protocol="application/pgp-signature"; micalg="pgp-sha512"
Mime-Version: 1.0 (Mac OS X Mail 12.4 \(3445.104.17\))
Subject: Re: Extension Header processing rules
Date: Tue, 10 Nov 2020 11:50:40 -0800
In-Reply-To: <202011101501583763174@zte.com.cn>
Cc: Bob Hinden <bob.hinden@gmail.com>, tom@herbertland.com, IPv6 List <ipv6@ietf.org>
To: peng.shaofu@zte.com.cn
References: <9EEAC2D8-375A-43C6-BC51-3C3242C80287@gmail.com, 202011091732387131414@zte.com.cn, CALx6S36dF2GQ=nL9DPsdJeeRt4K2KaQRjdQogf_EL=xc_0ws3w@mail.gmail.com> <202011101501583763174@zte.com.cn>
X-Mailer: Apple Mail (2.3445.104.17)
Archived-At: <https://mailarchive.ietf.org/arch/msg/ipv6/Ax403zB-1Y88ruLUkDa_43nA8dI>
X-BeenThere: ipv6@ietf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: "IPv6 Maintenance Working Group \(6man\)" <ipv6.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/ipv6>, <mailto:ipv6-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/ipv6/>
List-Post: <mailto:ipv6@ietf.org>
List-Help: <mailto:ipv6-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/ipv6>, <mailto:ipv6-request@ietf.org?subject=subscribe>
X-List-Received-Date: Tue, 10 Nov 2020 19:50:51 -0000

Peng,

> On Nov 9, 2020, at 11:01 PM, peng.shaofu@zte.com.cn wrote:
> 
> 
> 
> Hi Tom, and Bob,
> 
> 
> 
> Thank you for sharing your opinion. I totally agree with that.
> 
> So, in general, we should discuss all kinds of Extension Header under the IPv6 specification, not simply equate them with IPv4 options. I think there are differences in semantics.
> 
> Now I am faced with the implementation of DOH related functions, and try to get a clear processing rule for DOH. According to your opinon the design of DOH has its specific purpose to provide optional information to end nodes. Therefore, when the packet arrives at the end node and all the options in the DOH are processed strictly in the order, the processing rule I'm trying to get is: the next header should be parsed. I think this processing rule is also Bob's answer to me.
> 
> However, I'm worried that the problem will go beyond design principles. If, I mean if, in DOH it also implements the function similar to RH, in this case when the source route entries in the related option have not been traversed, obviously the next header should not be parsed. This (i.e, whether to parse next header is decided by an option) brings confusion and complexity to the DOH's processing rules, because DOH can contain multiple options and the decisions for each option may be inconsistent. I don't think we should encourage DOH to do this under the IPv6 specification.

If I understand your question, the answer to your question is in the excerpt I sent earlier:

>    At the destination node, normal demultiplexing on the Next Header
>    field of the IPv6 header invokes the module to process the first
>    extension header, or the upper-layer header if no extension header is
>    present.  The contents and semantics of each extension header
>    determine whether or not to proceed to the next header.  Therefore,
>    extension headers must be processed strictly in the order they appear
>    in the packet; a receiver must not, for example, scan through a
>    packet looking for a particular kind of extension header and process
>    that header prior to processing all preceding ones.

Specifically:

   The contents and semantics of each extension header
   determine whether or not to proceed to the next header.

Bob


> 
> What do you think ?
> 
> 
> 
> Regards,
> 
> PSF
> 
> 
> 
> 
> >
> >
> > Hi Bob,
> >
> >
> > Excuse me, I have other doubts.
> >
> > I don't know what principles IPv6 followed when designing IPv6 Extension Heads, maybe these principles determine the application scenarios of each Extension Head.
> >
> Right having different type extension of extensions facilitates
> different use cases and efficient implementation. For instance,
> there's separate Hop-by-Hop Options and Destination Options because
> the former needs to be processed by all nodes in the path, and the
> latter is just processed by the destination so an intermediate node
> doesn't have to burn cycles processing options that are only of
> consequence at the end nodes.
> 
> > For example, why not use DOH to realize the function of RH, just like the loose source and record route (LSRR) option defined in RFC791 ?
> >
> Conceivably that could be done, but having a separate extension header
> devoted to just one purpose leads to more efficient implementation in
> high speed devices (serially parsing a potentially long list of
> options to find a routing header might be prohibitive in
> implementation). Another thing to point out is that IPv4 options,
> including LSRR, weren't exactly a success; the extension header model
> of IPv6 attempts to correct some of the deficiencies in IPv4 options.
> 
> Tom
> 
> >
> >
> > Regards,
> >
> > PSF
> >
> >
> >
> > > On Nov 4, 2020, at 11:44 PM, peng.shaofu@zte.com.cn wrote:
> > >
> > >
> > >
> > > Hi 6man experts,
> > >
> > > RFC8200 mention that extension headers must be processed strictly in the order they appear in the packet, but there are
> >
> > It doesn’t mention, it specifies.
> >
> > > not explicit description for that when an EH is finished processing it must continue to process the next EH. Is this an obvious behavior so that no necessary to describe explicitly, or a local behavior that can be controlled?
> >
> > It is an obvious behavior.   That is why the field is called the “Next Header”.  I think the relavant text from Section 4 is:
> >
> >    At the destination node, normal demultiplexing on the Next Header
> >    field of the IPv6 header invokes the module to process the first
> >    extension header, or the upper-layer header if no extension header is
> >    present.  The contents and semantics of each extension header
> >    determine whether or not to proceed to the next header.  Therefore,
> >    extension headers must be processed strictly in the order they appear
> >    in the packet; a receiver must not, for example, scan through a
> >    packet looking for a particular kind of extension header and process
> >    that header prior to processing all preceding ones.
> >
> > Note the last sentence where is says a receiver must not scan through a packet….
> >
> > Bob
> >
> >
> >
> > >
> > > For example, for the follow packet,
> > >
> > >    IPv6 Header + DOH + Upper-layer
> > >
> > >
> > >
> > > At the destination node, normal demultiplexing on the Next Header field of the IPv6 header invokes the module to process the DOH. When DOH is finished processing, should the upper-layer be processed ? or not be processed by local policy ? What is the standard behavior ?
> > >
> > >
> > >
> > > In addition to DOH, same question is for HBH.
> > >
> > >
> > >
> > > Regards,
> > >
> > > PSF
> > >
> > > --------------------------------------------------------------------
> > > IETF IPv6 working group mailing list
> > > ipv6@ietf.org
> > > Administrative Requests: https://www.ietf.org/mailman/listinfo/ipv6
> > > --------------------------------------------------------------------
> >
> >
> > --------------------------------------------------------------------
> > IETF IPv6 working group mailing list
> > ipv6@ietf.org
> > Administrative Requests: https://www.ietf.org/mailman/listinfo/ipv6
> > --------------------------------------------------------------------
> 
>