Re: [RTG-DIR] RtgDir review: draft-ietf-rtgwg-policy-model-16

Yingzhen Qu <yingzhen.qu@futurewei.com> Tue, 07 July 2020 18:45 UTC

Return-Path: <yingzhen.qu@futurewei.com>
X-Original-To: rtgwg@ietfa.amsl.com
Delivered-To: rtgwg@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 879AD3A0912; Tue, 7 Jul 2020 11:45:29 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.089
X-Spam-Level:
X-Spam-Status: No, score=-2.089 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, HTML_MESSAGE=0.001, RCVD_IN_MSPIKE_H2=-0.001, T_SPF_PERMERROR=0.01, URIBL_BLOCKED=0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (1024-bit key) header.d=futurewei.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 QnPDJsV1Oj8h; Tue, 7 Jul 2020 11:45:27 -0700 (PDT)
Received: from NAM04-SN1-obe.outbound.protection.outlook.com (mail-eopbgr700110.outbound.protection.outlook.com [40.107.70.110]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 96AC53A090B; Tue, 7 Jul 2020 11:45:27 -0700 (PDT)
ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=DD06jqEX1OxhGtpKLUjGId/AVCVAlaxGBwZ+voTqzjkIDOJ72gNcvJWTMsvfQz64GgZhGhv7orHzO4qEnu2RUz9cP8lBT4M8tGY1jJO+PhTMS4HsRM5Syt3PQNapQeFNoPBDzPYhXT7eD2gGPdQlHSVDftXppIP7/uZqdUniIRK5y54kK1BlSHzK8JEIOuAnkw9JRKuoNEj8q05XOFMai/frtJ8cuZ+HWBb1DR+D414ypm787C2svQRBe2GyeiVKJBN2g6STOkIfzHhdg8wSu/NBuAPQa84Zkg/3DV7xQYeFPJyBZox1MVocNJDAek6+EyYKU5aiENoVOQx+j61Opg==
ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=BT6B+q25j+U3V8xcwJv4X/98rfEXZf98GhlD+gj8Ips=; b=Oa+dP4rV2Z8QutxVCS0rPvA86lvi9FmNALX3e2g7JvRp+1bZftYIgNohlanxEJZs3dju5M0+CQv5aHDtZii9B5RkLfmv2b7bS+wP94/NFKSXj89dAzr1Bmgy0T+xkbBlpJkcdw2m1xDlmQPWjb5hPshF/l9ps+qAdPf9RGes4LsK70qbfHOaAIU68X2HcfZeiKjNszqjbCRfJu8IBZd2Q7Z9tMoIHqll1BmL4VLRjnfZkoUKac2PDVuTQmtUQms2hrt7OPwRC1huGZC1muX2n/mEaW+cA+bJq9fu2Tr0HxzjtD0jPJCaJIR6IGW+OIOavfv3hh/aujW26JcoZXApHw==
ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=futurewei.com; dmarc=pass action=none header.from=futurewei.com; dkim=pass header.d=futurewei.com; arc=none
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=Futurewei.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=BT6B+q25j+U3V8xcwJv4X/98rfEXZf98GhlD+gj8Ips=; b=uRR0DzftQS4p7EzGccvoyz4gcLb/tX7waLdxK/9tG/xpnhXdGIU6ngvcrhneyNuMruwLAzQB2zneUqVdvIU6otkQF8lRFgU1Mqx/E3z2Dz0b2Vgi+O9DHEt63mXJpCi/KK0UlGH6NtFi0oFEyEtMIBJZRcKe4isNvmmH2LvdW5s=
Received: from BY5PR13MB3048.namprd13.prod.outlook.com (2603:10b6:a03:188::21) by BY5PR13MB3731.namprd13.prod.outlook.com (2603:10b6:a03:219::9) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3174.8; Tue, 7 Jul 2020 18:45:26 +0000
Received: from BY5PR13MB3048.namprd13.prod.outlook.com ([fe80::28f0:8a33:3418:b39b]) by BY5PR13MB3048.namprd13.prod.outlook.com ([fe80::28f0:8a33:3418:b39b%4]) with mapi id 15.20.3174.020; Tue, 7 Jul 2020 18:45:26 +0000
From: Yingzhen Qu <yingzhen.qu@futurewei.com>
To: John Scudder <jgs@juniper.net>, "John G. Scudder" <jgs@bgp.nu>
CC: "Acee Lindem (acee)" <acee=40cisco.com@dmarc.ietf.org>, "rtg-ads@ietf.org" <rtg-ads@ietf.org>, "rtg-dir@ietf.org" <rtg-dir@ietf.org>, "draft-ietf-rtgwg-policy-model.all@ietf.org" <draft-ietf-rtgwg-policy-model.all@ietf.org>, RTGWG <rtgwg@ietf.org>
Subject: Re: [RTG-DIR] RtgDir review: draft-ietf-rtgwg-policy-model-16
Thread-Topic: [RTG-DIR] RtgDir review: draft-ietf-rtgwg-policy-model-16
Thread-Index: AQHWU+A6nTbEfqVBRUGyDP1DTaqhSaj7HgOAgAERb4D//8jjgIAASEWAgAAIpYD//7c1gA==
Date: Tue, 07 Jul 2020 18:45:26 +0000
Message-ID: <B1218178-1663-4892-912C-C8196EE4C45D@futurewei.com>
References: <D0B93C7C-BA13-42B5-B6CF-FCCC4BCAD880@bgp.nu> <D69DC25E-3D50-4F66-AF73-EB9316A990A0@juniper.net>
In-Reply-To: <D69DC25E-3D50-4F66-AF73-EB9316A990A0@juniper.net>
Accept-Language: en-US
Content-Language: en-US
X-MS-Has-Attach:
X-MS-TNEF-Correlator:
user-agent: Microsoft-MacOutlook/10.1e.0.191013
authentication-results: juniper.net; dkim=none (message not signed) header.d=none;juniper.net; dmarc=none action=none header.from=futurewei.com;
x-originating-ip: [2601:646:9500:c900:110f:4b81:a371:3bac]
x-ms-publictraffictype: Email
x-ms-office365-filtering-correlation-id: c237da39-3834-4c55-67a8-08d822a5e9f9
x-ms-traffictypediagnostic: BY5PR13MB3731:
x-microsoft-antispam-prvs: <BY5PR13MB37319585BC75AFF5A9EF65D9E1660@BY5PR13MB3731.namprd13.prod.outlook.com>
x-ms-oob-tlc-oobclassifiers: OLM:9508;
x-ms-exchange-senderadcheck: 1
x-microsoft-antispam: BCL:0;
x-microsoft-antispam-message-info: e5BBmAlvj67hrv952xcJilBxNBAoPE5G9TeZsraKfd++qsqbwU9h6I7NLqEVog45XDEmBKqL9Jp8AzbvRKqBeyCoD24hqsjmJ+9xl48mEFfVsb2F+slfNOtbQqxmJfVekzmHKEW02uY0odtojQfx6kuuJ71zy52O2vwyFVuFIzGg9M8FRAtuOesPpfzDMi13AA7D5LTH+lxmzIDN8Eu3bV1aoyPY+NYNeyIIQ/O3J2Ku7lJFMnmMHIXdQX6ozkA0IR0OMPRplbtN/cO8+ifbSKQIysf/SdlNVKx1IP/rzCa3lQw8jHCWuMA3jDyc4NYW7135pc3tMT+rw+IaqGtc7Q==
x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:BY5PR13MB3048.namprd13.prod.outlook.com; PTR:; CAT:NONE; SFTY:; SFS:(4636009)(346002)(136003)(376002)(366004)(39830400003)(396003)(54906003)(2906002)(5660300002)(66946007)(64756008)(66446008)(66556008)(76116006)(478600001)(44832011)(186003)(36756003)(66476007)(6486002)(6506007)(53546011)(71200400001)(2616005)(6512007)(33656002)(110136005)(316002)(86362001)(4326008)(8676002)(83380400001)(8936002); DIR:OUT; SFP:1102;
x-ms-exchange-antispam-messagedata: TpaZrAmFFhY9TBRrgeCWg7Fx0myeS87aC1RKIoP04+YrqRN+KU/6AFMd0rd5oyInukfAlr4S+6vPANZIIvPlnXLAdfT/6jYwiK7lbW5XM9NHy97kZPS4l/ulOmTnaq8IM76hQeXox8DGCx08R56/ZFNYBs4bOncOPnpc5DyXqGMLB9exjk8R3nsbDmjQ1s+Cd4aiAb5rhIazG7Ee7lEKW4YOA9CZZutk9gISczq3+d8TZqnoaW8jFCYJ7T1VEDxqzdLuSuTrGfifuXvYFd/CsQQ4oJ/dqGHAzWgtJik87NMxkiTIIJAkdbiYBf4jfrcKn6HvGC6FPFL3VEhgHPWVhnWaFFLH/L84+lya60sEvullqViWCub1dfzfIqAdymeEmPmcnUqGZP6jKAGHSztLgTiuyEq76zHNDufVAdfZhrOyc8cSvaXgDKIFUG5tbtUVOpX4FtSA9y57Mxsb06a7RqwgWDGOtKXPvHLU8lR1J1widTf8FEuyK8T4BIeAzdJ3q6YO1Ze5oqbkuLhfh/EHgfTwdIpasxBCGO7+ZEBRFCUIb3eSzBv2wIAiS+j/+WRu
x-ms-exchange-transport-forked: True
Content-Type: multipart/alternative; boundary="_000_B121817816634892912CC8196EE4C45Dfutureweicom_"
MIME-Version: 1.0
X-OriginatorOrg: Futurewei.com
X-MS-Exchange-CrossTenant-AuthAs: Internal
X-MS-Exchange-CrossTenant-AuthSource: BY5PR13MB3048.namprd13.prod.outlook.com
X-MS-Exchange-CrossTenant-Network-Message-Id: c237da39-3834-4c55-67a8-08d822a5e9f9
X-MS-Exchange-CrossTenant-originalarrivaltime: 07 Jul 2020 18:45:26.1061 (UTC)
X-MS-Exchange-CrossTenant-fromentityheader: Hosted
X-MS-Exchange-CrossTenant-id: 0fee8ff2-a3b2-4018-9c75-3a1d5591fedc
X-MS-Exchange-CrossTenant-mailboxtype: HOSTED
X-MS-Exchange-CrossTenant-userprincipalname: +WckQYACRBkiAidoNeYh0T+qXikthNCd4/yJZx6DpNcicBAwOw8PABNYTVJ+YKNJk/1oVH9vj6s2igBtOkOxew==
X-MS-Exchange-Transport-CrossTenantHeadersStamped: BY5PR13MB3731
Archived-At: <https://mailarchive.ietf.org/arch/msg/rtgwg/dBuhaQSgWqPcTA9cOtwN1B8RWl4>
X-BeenThere: rtgwg@ietf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: Routing Area Working Group <rtgwg.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/rtgwg>, <mailto:rtgwg-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/rtgwg/>
List-Post: <mailto:rtgwg@ietf.org>
List-Help: <mailto:rtgwg-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/rtgwg>, <mailto:rtgwg-request@ietf.org?subject=subscribe>
X-List-Received-Date: Tue, 07 Jul 2020 18:45:30 -0000

Hi all,

Thank you all for the discussions and comments.

If we’re to do error-checking in the YANG module, here’re the two issues:

Ip-prefix is a union of “ipv4-prefix” and “ipv6-prefix”. The mask-length-upper is 32 for IPv4 and 128 for IPv6, so we either have to separate ipv4 and ipv6 in order to add a constraint or it will be up to the server to reject the config.

“ipv4-prefix” and “ipv6-prefix” are defined as a string, so the mask-length is part of the string. I don’t know an easy way to add a constraint if mask-length-lower needs to be verified against mask-length.

Any comments and suggestions are welcome.

Thanks,
Yingzhen

From: John Scudder <jgs@juniper.net>
Date: Tuesday, July 7, 2020 at 9:06 AM
To: "John G. Scudder" <jgs@bgp.nu>
Cc: "Acee Lindem (acee)" <acee=40cisco.com@dmarc.ietf.org>, Yingzhen Qu <yingzhen.qu@futurewei.com>, "rtg-ads@ietf.org" <rtg-ads@ietf.org>, "rtg-dir@ietf.org" <rtg-dir@ietf.org>, "draft-ietf-rtgwg-policy-model.all@ietf.org" <draft-ietf-rtgwg-policy-model.all@ietf.org>, RTGWG <rtgwg@ietf.org>
Subject: Re: [RTG-DIR] RtgDir review: draft-ietf-rtgwg-policy-model-16

On Jul 7, 2020, at 11:35 AM, John G. Scudder <jgs@bgp.nu> wrote:

Hi Acee,


On Jul 7, 2020, at 11:16 AM, Acee Lindem (acee) <acee=40cisco.com@dmarc.ietf.org> wrote:
Yes. I’d say we should just use the ip-prefix type from RFC 6021. This type has the right semantics.
However, I’m wondering how we do the mask-length-lower checking with the union. I imagine it should be possible.

How would you test the constraint on mask-length-upper if you use ip-prefix?

Duh, that’s what you said, s/upper/lower/. I don’t see a way to do it, but if you can work it out I agree it otherwise seems like the right approach.

—John