Re: [Rtg-yang-coord] comment concerning draft-shaikh-rtgwg-policy-model-00
Anees Shaikh <aashaikh@google.com> Thu, 28 May 2015 07:27 UTC
Return-Path: <aashaikh@google.com>
X-Original-To: rtg-yang-coord@ietfa.amsl.com
Delivered-To: rtg-yang-coord@ietfa.amsl.com
Received: from localhost (ietfa.amsl.com [127.0.0.1])
by ietfa.amsl.com (Postfix) with ESMTP id BAF551A6F0E
for <rtg-yang-coord@ietfa.amsl.com>; Thu, 28 May 2015 00:27:35 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -0.788
X-Spam-Level:
X-Spam-Status: No, score=-0.788 tagged_above=-999 required=5
tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1,
DKIM_VALID_AU=-0.1, FM_FORGED_GMAIL=0.622, HTML_MESSAGE=0.001,
J_CHICKENPOX_26=0.6, SPF_PASS=-0.001, T_RP_MATCHES_RCVD=-0.01]
autolearn=no
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 d1QFZDcdRuvd for <rtg-yang-coord@ietfa.amsl.com>;
Thu, 28 May 2015 00:27:32 -0700 (PDT)
Received: from mail-ob0-x231.google.com (mail-ob0-x231.google.com
[IPv6:2607:f8b0:4003:c01::231])
(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 5AF021A3B9C
for <Rtg-yang-coord@ietf.org>; Thu, 28 May 2015 00:27:32 -0700 (PDT)
Received: by obbea2 with SMTP id ea2so26225505obb.3
for <Rtg-yang-coord@ietf.org>; Thu, 28 May 2015 00:27:30 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113;
h=mime-version:in-reply-to:references:date:message-id:subject:from:to
:cc:content-type;
bh=93pv8Uskh/25zfFKY6BztYlx4qzj+EPLc+g7LaqJYLc=;
b=hOqlXkEFD6PzptGoTGhhzsP1YOFhPT/wwRJuGqSCFOMo+GBM9N+pG/4hAtGaFmRjf6
EL3Fczf3T+rbZLqqsyumkGKDcR4tuhJMYdqvhWptpJxr9lfmNlnv5z0zC88Dh+0ZNolY
OoqHkwU/HrFPHYinIYQDjfwcg37BwbE28k0feApjHOKUrXVilFPAHjUkudL3+AaHJGc+
WL+UTUyeUAZBSNMWuPTjJBURafL8kGK0LTt/LNyKoZiHCEB6p1YK8+ZlsYFt16fmH+9h
G9Iy7OL5NscZSnAW51mYrtOxxksmayM65eGqrVzegE8QxEOkBxgnTzkNHfU16Zq+2SDj
BSgQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
d=1e100.net; s=20130820;
h=x-gm-message-state:mime-version:in-reply-to:references:date
:message-id:subject:from:to:cc:content-type;
bh=93pv8Uskh/25zfFKY6BztYlx4qzj+EPLc+g7LaqJYLc=;
b=OgW4O+JVoHKq5Y3ZE3MYvexd+gXElj7PsWsvZPTb8HyE9XTGJN1L99JPNmRrsX81Pt
6o+hHPufbBVmhTzZCRhNONWbYMwdhYMX7OBaB8FU5Hcr/pr5OqlM+A1yHQ+zFtCvdRgK
bV+xMSfJm/Hqu9WOUktvyi8AE6vefm7hk+/1FOJV5rDh/RBTuqOq++bw7P0Rv6CbYOya
9OUQ+dbnQ22HSaxEA9QGXGrItVc6TOFNVPZq4G6KkxX3f5JQtbI/P3xUQc5cD0wIJEgZ
Vj7JQbw8r9prKLvYCfOeZHUGTY8h58wUu2Ml1TLf3S0hxs2jJpLSCDofTYc4vk5ZM6hJ
MlJg==
X-Gm-Message-State: ALoCoQlvXXqXRK8+fXCyERglMpkB1iP6/qLsSSpM0cuxAMN1lhTn1WNRCPvsMfctvyWPnGXf7VdB
MIME-Version: 1.0
X-Received: by 10.60.245.104 with SMTP id xn8mr1218192oec.51.1432798050674;
Thu, 28 May 2015 00:27:30 -0700 (PDT)
Received: by 10.182.144.228 with HTTP; Thu, 28 May 2015 00:27:30 -0700 (PDT)
In-Reply-To: <376DFA77-D190-4957-B842-DDB6ACAF3E1B@ericsson.com>
References: <20150527122452.GC41087@elstar.local>
<CAJK7ZqKHEYpD3nb8J5hjbex=NVhAAtURHWw5jGKxdrRWZe+sCw@mail.gmail.com>
<D18B6A36.1F437%acee@cisco.com>
<15B43214-AE84-49C0-A83B-9E4DB6184CC6@cisco.com>
<CAJK7Zq+9bFvuW79Cv5eg9E+189PW8zZ0aSHFCvPWSy-Pf=ksDQ@mail.gmail.com>
<376DFA77-D190-4957-B842-DDB6ACAF3E1B@ericsson.com>
Date: Thu, 28 May 2015 00:27:30 -0700
Message-ID: <CAJK7ZqLMqAHOxYZBxun1KU2vZ2MAsd6eZn_rtCqueb5fE2syhQ@mail.gmail.com>
From: Anees Shaikh <aashaikh@google.com>
To: Jeff Tantsura <jeff.tantsura@ericsson.com>
Content-Type: multipart/alternative; boundary=001a11347536d8a00105171f4a4e
Archived-At: <http://mailarchive.ietf.org/arch/msg/rtg-yang-coord/74K6aZIWjWURO6tLV9tift96swc>
Cc: "rtg-yang-coord@ietf.org" <Rtg-yang-coord@ietf.org>,
Juergen Schoenwaelder <j.schoenwaelder@jacobs-university.de>,
"Acee Lindem \(acee\)" <acee@cisco.com>
Subject: Re: [Rtg-yang-coord] comment concerning
draft-shaikh-rtgwg-policy-model-00
X-BeenThere: rtg-yang-coord@ietf.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: "\"List to discuss coordination between the Routing related YANG
models\"" <rtg-yang-coord.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/rtg-yang-coord>,
<mailto:rtg-yang-coord-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/rtg-yang-coord/>
List-Post: <mailto:rtg-yang-coord@ietf.org>
List-Help: <mailto:rtg-yang-coord-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/rtg-yang-coord>,
<mailto:rtg-yang-coord-request@ietf.org?subject=subscribe>
X-List-Received-Date: Thu, 28 May 2015 07:27:35 -0000
hi Jeff, agree -- we'll try to get this fix into the next published version of the models -- which should hopefully be available very soon (said with fingers crossed). thanks. -- Anees On Wed, May 27, 2015 at 11:50 PM, Jeff Tantsura <jeff.tantsura@ericsson.com> wrote: > Hi Anees, > > Using ip:prefix type would for sure benefit from better validation > enforcement. > Saying "for now" - do you expect it to be changed later? > > Thanks! > > Regards, > Jeff > > On May 27, 2015, at 10:53 PM, "Anees Shaikh" <aashaikh@google.com> wrote: > > hi Acee, thanks for the comments -- we debated these same questions :-) > > > This approach was based on the wish to avoid operators having to worry > about specifying an ipv4 prefix list separately from an ipv6 -- no major > implementation has this separation today (though it could be considered). > > If using inet:ip-prefix type instead of inet:ip-address + masklength > buys us some range checking in the pattern , maybe that's another reason to > switch to using that union type instead. We will discuss making that > update. > > You're right that with a string we don't do checking on the > masklength-range field. As I mentioned earlier in the thread, this was to > accommodate a simple way to express an exact prefix (several > implementations do something similar). > > Among OpenConfig operators, after some debate, we generally try to > balance the amount of validation in the model itself, with maintaining > flexibility and simplicity. In other words, we don't believe the model > needs to prevent every conceivable error -- the implementation also has to > participate by rejecting invalid / unsupported configuration. That said, > where it's easy to add validation, we have tried to include it, though > ranges, defaults, min/max values, etc. get harder when trying to build > something vendor-neutral. > > Same applies to your correct comment that the current construct > theoretically allows one to mix address types in the prefix list. > Interestingly, some implementations allow you to create such a list, but > fail later when you try to use it in a policy. We've chosen for now to > allow it (again for simplicity), but explicitly say in the description that > most implementations will reject a prefix-list with mixed address types. > > thanks. > -- Anees > > > > On Wed, May 27, 2015 at 9:57 AM, Acee Lindem (acee) <acee@cisco.com> > wrote: > >> >> On May 27, 2015, at 12:47 PM, Acee Lindem (acee) <acee@cisco.com> wrote: >> >> Hi Anees, >> I had noted problems with the prefix-lists in the draft as well but >> hadn’t got around to raising them. One thing about the masklength and >> masklength-range is that there is no validation in the model snippet below. >> In other words, there is nothing to express that the masklength must >> between 0..32 for IPv4 addresses and 0..128 for IPv6 addresses (this is >> enforced by the ip-prefix type from RFC 6991). Similarly, as a string there >> in no inherent validation of the masklength-range (e.g., both values must >> be >= masklength, second value must be >= first-value, and both values must >> be >= AF specific limit). >> >> >> Of course I meant "<= AF specific limit”. >> >> Thanks, >> Acee >> >> >> Also, there is nothing to prevent one from mixing IPv4 and IPv6 >> prefixes in the same length which is definitely not allowed for the >> prefix-lists we all know and love. >> Thanks, >> Acee >> >> From: Anees Shaikh <aashaikh@google.com> >> Date: Wednesday, May 27, 2015 at 12:09 PM >> To: Juergen Schoenwaelder <j.schoenwaelder@jacobs-university.de>de>, >> Routing YANG <rtg-yang-coord@ietf.org> >> Subject: Re: [Rtg-yang-coord] comment concerning >> draft-shaikh-rtgwg-policy-model-00 >> >> Juergen, you're right that prefix-lists in the model turned out to be >> a bit problematic as currently defined. We've updated the model in the >> most recent revision after going through some translations of our configs >> to the OpenConfig model and running into some issues. The updated version >> looks more like the following: >> >> list prefix { >> key "address masklength masklength-range"; >> >> leaf address { >> type inet:ip-address; >> } >> >> leaf masklength { >> type uint8; >> } >> >> leaf masklength-range { >> type string { >> pattern '^([0-9]+\.\.[0-9]+)|exact$'; >> } >> } >> } >> >> The model used address and a separate masklength so that range checking >> could be performed on the mask. We've since removed the range-checking in >> favor of simplifying to keep a single prefix list for both address types, >> ipv4 and ipv6. >> >> The original model had the problem you mention, which is that all keys >> must be mandatory, including masklength-range, which meant there was no >> simple way to express an exact prefix other than, e.g., 21..21 which we >> didn't think was desirable. Changing the masklength-range to a string >> allows a more flexible pattern (including an 'exact' setting). The >> masklength-range is included in the keys to make the list have unique >> members. >> >> I think we could also consider your suggestion to use a inet:ip-prefix >> instead of address since we're not doing range-checking on the masklength >> in the current approach -- will discuss with the co-authors. >> >> Agree with your suggestion to make the XML examples more conformant >> (they should certainly validate), though we've only been using ad-hoc >> namespaces for models that are not IETF WG models so far. My understanding >> is that this is the recommended practice. >> >> thanks. >> -- Anees >> >> >> On Wed, May 27, 2015 at 5:24 AM, Juergen Schoenwaelder < >> j.schoenwaelder@jacobs-university.de> wrote: >> >>> Hi, >>> >>> I have read the document and I have a small comment. >>> >>> - You define a list 'prefix' in the list 'prefix-set' which is keyed >>> by three leafs. As a result, all three leafs are mandatory. Your XML >>> instance snipped in section 10 does not validate because it is >>> missing mandatory key elements. I wonder (a) why did you not use >>> inet:ip-prefix instead of the pair inet:ip-address and a unit8 >>> masklength. And given the desire to represent a prefix range, would >>> a special syntax not make sense, e.g. an extension of ip-prefix, >>> lets call it ip-prefix-range, that allows to express a range of >>> prefixes: >>> >>> 10.3.192.0/21-24 -> 10.3.192.0/21 >>> 10.3.192.0/22 >>> 10.3.192.0/23 >>> 10.3.192.0/24 >>> >>> If the '-24' part is made optional, your prefix list will be >>> collapsed to a simple >>> >>> list prefix { >>> key prefix-range; >>> >>> leaf prefix-range { >>> type ip-prefix-range; >>> } >>> } >>> >>> Such an ip-prefix-range type may even be a useful addition to >>> ietf-inet-types. >>> >>> - The XML snippets are nice but it would be cool if they were using >>> proper namespaces and validate against the data model. Perhaps >>> something to consider for -01. The pyang tutorial provides examples >>> how to validate XML snippets against YANG definitions. >>> >>> /js >>> >>> -- >>> Juergen Schoenwaelder Jacobs University Bremen gGmbH >>> Phone: +49 421 200 3587 Campus Ring 1 | 28759 Bremen | Germany >>> Fax: +49 421 200 3103 <http://www.jacobs-university.de/> >>> >>> _______________________________________________ >>> Rtg-yang-coord mailing list >>> Rtg-yang-coord@ietf.org >>> https://www.ietf.org/mailman/listinfo/rtg-yang-coord >>> >> >> _______________________________________________ >> Rtg-yang-coord mailing list >> Rtg-yang-coord@ietf.org >> https://www.ietf.org/mailman/listinfo/rtg-yang-coord >> >> >> > _______________________________________________ > Rtg-yang-coord mailing list > Rtg-yang-coord@ietf.org > https://www.ietf.org/mailman/listinfo/rtg-yang-coord > >
- [Rtg-yang-coord] comment concerning draft-shaikh-… Juergen Schoenwaelder
- Re: [Rtg-yang-coord] comment concerning draft-sha… Anees Shaikh
- Re: [Rtg-yang-coord] comment concerning draft-sha… Acee Lindem (acee)
- Re: [Rtg-yang-coord] comment concerning draft-sha… Acee Lindem (acee)
- Re: [Rtg-yang-coord] comment concerning draft-sha… Anees Shaikh
- Re: [Rtg-yang-coord] comment concerning draft-sha… Jeff Tantsura
- Re: [Rtg-yang-coord] comment concerning draft-sha… Anees Shaikh
- Re: [Rtg-yang-coord] comment concerning draft-sha… Acee Lindem (acee)
- Re: [Rtg-yang-coord] comment concerning draft-sha… Mahesh Jethanandani
- Re: [Rtg-yang-coord] comment concerning draft-sha… Anees Shaikh