Re: SRv6 Network Programming: ENH = 59

Mark Smith <markzzzsmith@gmail.com> Wed, 08 May 2019 15:48 UTC

Return-Path: <markzzzsmith@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 482E812024C for <ipv6@ietfa.amsl.com>; Wed, 8 May 2019 08:48:52 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.498
X-Spam-Level:
X-Spam-Status: No, score=-1.498 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, FREEMAIL_FROM=0.001, FROM_LOCAL_NOVOWEL=0.5, HK_RANDOM_ENVFROM=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 (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 54r4YqRiL6c6 for <ipv6@ietfa.amsl.com>; Wed, 8 May 2019 08:48:49 -0700 (PDT)
Received: from mail-ot1-x334.google.com (mail-ot1-x334.google.com [IPv6:2607:f8b0:4864:20::334]) (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 BC3E0120165 for <ipv6@ietf.org>; Wed, 8 May 2019 08:48:49 -0700 (PDT)
Received: by mail-ot1-x334.google.com with SMTP id i8so9026000oth.10 for <ipv6@ietf.org>; Wed, 08 May 2019 08:48:49 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=e+la0ZNOxL0I9sja+oZoPfgMP//KTecxwCJywHcROys=; b=TrdbGJKx5zcuC+wBnWtLOhMo9ld80Y7FZawIyJVFvLzpHCPYkv2qRzS1R5/fqejgt+ H+howoeqaAYvGcl/93BCyhe01VglZoO/nawrkVqqJwsI7ulz34yHejEZpJryQ26iMSXq GEZpaH5Eqtj+ZKcalV0HKD7XgXnBSPA1he0g9MAkmdW/o3VOwGz4406pByGus5WJA5ox VlUaXhAAMDhZsIJ5BHwG5Upy+0Lr6PcBQq47TGeJhZLmY30no41Nt3Td5Hv35Z2tWefU BzLp9wdHQQjy5fGmxHsFZvbKOYYmft4uCWRMHug4m9qQNLK0fODDDQiRhGIjL7Q6HsZv cdew==
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=e+la0ZNOxL0I9sja+oZoPfgMP//KTecxwCJywHcROys=; b=acahaMHRMjDVIk1stlx0FLMiolLE7UVetx59xQJbGw5BN3h6JDFIu4znzVlRGVVXaV Pme67c4tdKKJV+jMV8Pjqtr3GyYECHHxBD2dw5QZQb/iEJD46eKeTgYBdbkyAm9rgbFF /yI5CMDxXv4zOFVP8tKFElbERaZtwbXoSDj5QW3tg3pzoYCqCf8yxDfp8Y/UWvg7HoTs kLK+qPtBkzXycM5JijToNOCnRz1ldvxMkkMEQ+7ovqT2uMi9TDqG9hJfr8v1sCQM1OL+ mm23JI7CRKLDGBJweljUi3jg6IuML+iCDAmdTVww5Zqpo2F1CQzIXHL2OjKWy/Rqdcev jXvw==
X-Gm-Message-State: APjAAAWY7NvWxDzhBlqab8tRzZN6xrSLzhBEQl/rTKpBntxA/p+b8BIE cCHwiGcbBP9aVFU6yX2XlZ+dhWpRmoKAV363DzE=
X-Google-Smtp-Source: APXvYqyIZ0PZjetc034va/0W6PaDT3/A+cdgJ2nabm6sG4XbMjnEx1dO77x3nboOJJ2O6UHJPlFS3TSdHDeL51mLCDE=
X-Received: by 2002:a9d:6407:: with SMTP id h7mr607153otl.35.1557330528534; Wed, 08 May 2019 08:48:48 -0700 (PDT)
MIME-Version: 1.0
References: <BYAPR05MB4245988C3A47C3665BD91172AE300@BYAPR05MB4245.namprd05.prod.outlook.com> <AA81898A-9E6C-4AD5-9629-4BA283378A79@cisco.com> <BYAPR05MB4245AEA785C959D29E4ECE61AE310@BYAPR05MB4245.namprd05.prod.outlook.com> <58529f07-acfc-3678-5381-4ae271143a45@gmail.com> <94EF12FB-0598-4E76-9A60-0CF67096DD04@employees.org> <CALx6S360dJD4_YcqMMy9k8NOLNdy1UZPAzBNOw1WpAz6iYfWag@mail.gmail.com>
In-Reply-To: <CALx6S360dJD4_YcqMMy9k8NOLNdy1UZPAzBNOw1WpAz6iYfWag@mail.gmail.com>
From: Mark Smith <markzzzsmith@gmail.com>
Date: Thu, 09 May 2019 01:48:21 +1000
Message-ID: <CAO42Z2wBL=h=MKLshKUJa4m6aqTSGn4XQgKao06wKvvreKpB8w@mail.gmail.com>
Subject: Re: SRv6 Network Programming: ENH = 59
To: Tom Herbert <tom@herbertland.com>
Cc: Ole Troan <otroan@employees.org>, 6man WG <ipv6@ietf.org>
Content-Type: text/plain; charset="UTF-8"
Archived-At: <https://mailarchive.ietf.org/arch/msg/ipv6/PWARcTcO5uJQmAToEVdCNWy7mWo>
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: Wed, 08 May 2019 15:48:59 -0000

On Thu, 9 May 2019 at 00:57, Tom Herbert <tom@herbertland.com> wrote:
>
> On Wed, May 8, 2019 at 3:37 AM Ole Troan <otroan@employees.org> wrote:
> >
> > >> I am not sure that your use of this field is in accordance with Section 4.7 of RFC 8200.
> > >
> > > The language is quite subtle, in fact, so I'm not sure either. However, the doubt can easily be resolved by using protocol number 22, which appears to be intended exactly for this purpose.
> >
> > I spent some time yesterday digging into history and intent.
> > As far as I could find from the ipng mailing list, the idea was suggested in November 1994. The use case was to be able to signal end to end with extension headers, so the No next header value was a way of signalling termination of the chain.
> > There was a lot of support for using the value 0, but there was an argument made that comparing a the next header field against the constant 0 was faster than comparing it to another constant (really?). So that number went to HBH.
> >
> > The allocation was done by IANA in February 95 and the 4.7 text was included in the first draft published March 17:
> > https://tools.ietf.org/html/draft-ietf-ipngwg-ipv6-spec-01
> >
> > There is no discussion on the mailing list that I can find about additional data after the last header.
> > I vaguley recall having a discussion at some IETF about this, but I can't recall the conclusion.
> > Given the text on "must forward", I think it was intended as an extension mechanism / scratch space.
> >
> Ole,
>
> This situation sounds very similar to the "surplus space" in UDP where
> the IP length and UDP length differ such that there are bytes in the
> IP packet following the UDP headers. While RFC768 implicitly defined
> the surplus space, no use or requirements about what it contains were
> ever specified. Now there is an attempt to define these bytes in UDP
> (draft-ietf-tsvwg-udp-options).
>
> I believe a reasonable interpretation of "No next header" is that the
> trailing bytes contain something not describable by a standard
> protocol number, but the bytes should be allowed to contain data of
> interest to the receiver. So the bytes need to be interpreted by other
> means. This is in fact how we are using protocol number 59 in GUE when
> the GUE payload is a fragment or has been transformed, e.g. by
> encryption. The payload cannot simply be parsed as an IP protocol.
> Information in the GUE header indicates how the payload is
> interpreted, and we use No-next-header to ensure that intermediate
> devices don't try to parse the payload.
>
> So I think the use of No-next-header in segment routing would be
> consistent with this interpretation, however, in this case the data
> being carried in the payload is describable by an existing protocol
> number, namely ETHERIP (protocol 97), so using No-next-header seems
> like unnecessary complexity.
>

Here's what RFC8200 says:

"The value 59 in the Next Header field of an IPv6 header or any
   extension header indicates that there is nothing following that
   header."

The etymology of "nothing" is "no thing", so there is to be no thing
following the No Next Header EH.

It also says,

"If the Payload Length field of the IPv6 header indicates the
   presence of octets past the end of a header whose Next Header field
   contains 59, those octets must be ignored and passed on unchanged if
   the packet is forwarded."

Processing values in those bytes is obviously not ignoring them.

"passed on unchanged if the packet is forwarded." is really a
redundant statement, as IPv6 forwarding isn't looking at any EH other
than Hop-by-Hop. Passing on unchanged is implicit in IPv6 forwarding
being intentionally oblivious to packet payloads.

This second statement seems to really be text on how to treat an error
in the Payload Length field value when it points past the end of the
packet. There could be invalid bytes there because of Ethernet padding
of frames up to 64 octets.

Regards,
Mark.


> Tom
>
>
> > Cheers,
> > Ole
> > --------------------------------------------------------------------
> > 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
> --------------------------------------------------------------------