Re: [netmod] 6991bis - Any plans to add more URI Syntax components?

Mahesh Jethanandani <mjethanandani@gmail.com> Tue, 01 October 2019 22:21 UTC

Return-Path: <mjethanandani@gmail.com>
X-Original-To: netmod@ietfa.amsl.com
Delivered-To: netmod@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id ABD1212084B for <netmod@ietfa.amsl.com>; Tue, 1 Oct 2019 15:21:07 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.999
X-Spam-Level:
X-Spam-Status: No, score=-1.999 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, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-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 jboG_dcdKH5n for <netmod@ietfa.amsl.com>; Tue, 1 Oct 2019 15:21:02 -0700 (PDT)
Received: from mail-pl1-x62e.google.com (mail-pl1-x62e.google.com [IPv6:2607:f8b0:4864:20::62e]) (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 3F37C120219 for <netmod@ietf.org>; Tue, 1 Oct 2019 15:21:02 -0700 (PDT)
Received: by mail-pl1-x62e.google.com with SMTP id u20so6237885plq.4 for <netmod@ietf.org>; Tue, 01 Oct 2019 15:21:02 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:subject:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to; bh=NBFeivmAs31SHxXg1PlUgCyPHVLjqySL75ezbGhrgNk=; b=CqcTCeM8GzkRtsryKCmin6YqMvuJGd3WLJ08P1OJ7lEXwqoIJauRKV3NJHx2QLCr2C y9YyklfB40VJvtd5UxnP4XvdynkeTta32rw1X45y5xJaq/5BVRYZzsxjOEbMjPQk8l2u Y+0tDDsSbpXJiNZDAAwV/0MWn8yOgrQH3l/Gb0rd9B8PtrCDfbw4vXZovR5C93065IMq 4LiIaKGL9hNHbKAZE0f1Bp7sNGyACNBduwZcBgPxRTQPvr2Bg2u8Xx3v3JhBqOXWtBJQ zL+dg7mnz6obzGLzx4NhMyX3GRbzEVX1kqQarmWur3BR0BF/NuDgJorQFOc556Kv6tbY 4QlA==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:subject:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to; bh=NBFeivmAs31SHxXg1PlUgCyPHVLjqySL75ezbGhrgNk=; b=ITwvFgCs925L0KyBoXkiBFUJCuFnJXxYW/Db0+81ZGI8tlNGHehY85dkZpRZ10cwQl OR0j127PkOrUANzSrEwO7iIrYUDDt+ToqJ4J3FOrCMGmonyfglObZABiHO6c7VDTI5M4 a8+AUkY/31mfWkPv6rjeJYkZ0jvI18hqI3+sHHC1enQ32QZlA4H2KEZPZRI1LeT0P8pQ icH0c8hM4BaZjdtXzNXKf+2mnOIZ6H+zyNFLZH7Dzx+jIlCC73YU7+wIOs4k5jmRB1wn BCHeXQ2P7FZFwuUsb19fufFuMEKIelNj1WL01M7GbnMHoSyDwExNoXLm3N/ij4scKbWC SoGQ==
X-Gm-Message-State: APjAAAXXCmhfL7O4zvh9n8ib39e6gtg8LSUq/2sp5CPE4cjvDZU24k2/ kCzvqLhXikh83x7rwOrlbNo=
X-Google-Smtp-Source: APXvYqxLT2V3XL0oWfEPKfvasW62m/CaWGYKJnFdyr+xJfzHl8qKiiDqz2aLy1h6fQ8xN9I+StBIHw==
X-Received: by 2002:a17:902:a586:: with SMTP id az6mr137903plb.12.1569968461597; Tue, 01 Oct 2019 15:21:01 -0700 (PDT)
Received: from [10.33.123.155] ([66.170.99.2]) by smtp.gmail.com with ESMTPSA id q13sm20821885pfn.150.2019.10.01.15.20.59 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 01 Oct 2019 15:21:00 -0700 (PDT)
Content-Type: text/plain; charset=utf-8
Mime-Version: 1.0 (Mac OS X Mail 11.5 \(3445.9.1\))
From: Mahesh Jethanandani <mjethanandani@gmail.com>
In-Reply-To: <20191001085414.5ranv7psycaccdqo@anna.jacobs.jacobs-university.de>
Date: Tue, 1 Oct 2019 15:20:59 -0700
Cc: netmod <netmod@ietf.org>
Content-Transfer-Encoding: quoted-printable
Message-Id: <A03CAD44-D3A1-4386-95EA-363A6D98BA5D@gmail.com>
References: <8F6D6E58-CCB2-4404-AFB1-876EBE5721E7@gmail.com> <20190928085715.oo457rppqxcmd2qx@anna.jacobs.jacobs-university.de> <3090E658-652B-43CA-A777-180EA4875200@gmail.com> <20191001085414.5ranv7psycaccdqo@anna.jacobs.jacobs-university.de>
To: Juergen Schoenwaelder <J.Schoenwaelder@jacobs-university.de>
X-Mailer: Apple Mail (2.3445.9.1)
Archived-At: <https://mailarchive.ietf.org/arch/msg/netmod/l4AiGqB9zPO45qnxigKT_sMERMY>
Subject: Re: [netmod] 6991bis - Any plans to add more URI Syntax components?
X-BeenThere: netmod@ietf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: NETMOD WG list <netmod.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/netmod>, <mailto:netmod-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/netmod/>
List-Post: <mailto:netmod@ietf.org>
List-Help: <mailto:netmod-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/netmod>, <mailto:netmod-request@ietf.org?subject=subscribe>
X-List-Received-Date: Tue, 01 Oct 2019 22:21:14 -0000

Hi Juergen

Ok. I had most of the definitions as strings with no pattern restrictions. On your prompting, I started to put them together. Note, I do not have a definition for ‘path’ as yet. I will work on it next. For the remaining, here is what I came up with. I have not tested all of them with all possible patterns, so I am sure some of them will need tweaking.

  typedef scheme {
    type string {
      pattern '([a-zA-Z][a-zA-Z\d+-.]*)';
    }
    description
      "Each URI begins with a scheme name that refers to a 
       specification for assigning identifiers within that scheme.";
    reference
      "RFC 3986, Section 3.1: URI Generic Syntax.";
  }

  typedef userinfo {
    type string {
      pattern '(([a-zA-Z\d\-._~\!$&amp;\'()*+,;=%]*)@?)';
    }
    description
      "The userinfo subcomponent consists of a user name.
       The user information, if present, is followed by an optional
       commercial at-sign ('@') that delimits it from the host.";
    reference
      "RFC 3986, Section 3.2.1: URI Generic Syntax.";
  }

  typedef query {
    type string {
      pattern '\?([a-zA-Z\d\-._~\!$&amp;\'()*+,;=]*)';
    }
    description
      "The query component contains non-hierarchical data that,
       along with data in the path component,
       serves to identify a resource within the scope of the
       URI's scheme and naming authority (if any).";
    reference
      "RFC 3986, Section 3.4: URI Generic Syntax.";
  }

  typedef fragment {
    type string {
      pattern '\#([a-zA-Z\d\-._~\!$&amp;\'()*+,;=]*)?$';
    }
    description
      "The fragment identifier component of a URI allows indirect
       identification of a secondary resource by reference to a
       primary resource and additional identifying information.
       The identified secondary resource may be some portion or
       subset of the primary resource, some view on representations
       of the primary resource, or some other resource defined or
       described by those representations.";
    reference
      "RFC 3986, Section 3.5: URI Generic Syntax.";
  }

Cheers.

> On Oct 1, 2019, at 1:54 AM, Schönwälder, Jürgen <J.Schoenwaelder@jacobs-university.de>; wrote:
> 
> Mahesh,
> 
> can you share you definitions so that people can look at them and take
> an informed decision whether this is something they can use as well?
> Having some concrete use cases (in the IETF) is likely useful to make
> something a common YANG datatype.
> 
> /js
> 
> On Mon, Sep 30, 2019 at 02:27:49PM -0700, Mahesh Jethanandani wrote:
>> Hi Juergen,
>> 
>>> On Sep 28, 2019, at 1:57 AM, Schönwälder, Jürgen <J.Schoenwaelder@jacobs-university.de>; wrote:
>>> 
>>> Hi Mahesh,
>>> 
>>> are these frequently needed? Are there YANG modules that use these
>>> fields already?
>> 
>> Over in ETSI, I just added them to the YANG model that defines VNF Descriptors (VNFD), as part of what is called VnfConfigurableProperties.
>> 
>> In addition, I know that draft-kwatsen-netconf-http-client-server draft tries to define 'user-id'. And there has been discussion around draft-ietf-netconf-https-notif needing to define a ‘path’ attribute, although Martin does not think it is needed. Anyway, these are the instances I know of that could use these definitions. I am sure there are more.
>> 
>> Cheers.
>> 
>>> 
>>> /js
>>> 
>>> On Fri, Sep 27, 2019 at 06:39:54PM -0700, Mahesh Jethanandani wrote:
>>>> Hi Juergen,
>>>> 
>>>> Is there a plan to add more URI syntax components in rfc6991bis? I know there is a typedef for uri, but I was looking specifically for the following that are defined in RFC 3986.
>>>> Scheme
>>>> Authority field including
>>>> User information
>>>> Path
>>>> Query
>>>> Fragment
>>>> 
>>>> Thanks.
>>>> 
>>>> Mahesh Jethanandani
>>>> mjethanandani@gmail.com
>>>> 
>>>> 
>>>> 
>>> 
>>>> _______________________________________________
>>>> netmod mailing list
>>>> netmod@ietf.org
>>>> https://www.ietf.org/mailman/listinfo/netmod
>>> 
>>> 
>>> -- 
>>> Juergen Schoenwaelder           Jacobs University Bremen gGmbH
>>> Phone: +49 421 200 3587         Campus Ring 1 | 28759 Bremen | Germany
>>> Fax:   +49 421 200 3103         <https://www.jacobs-university.de/>
>> 
>> Mahesh Jethanandani
>> mjethanandani@gmail.com
>> 
>> 
>> 
> 
> -- 
> Juergen Schoenwaelder           Jacobs University Bremen gGmbH
> Phone: +49 421 200 3587         Campus Ring 1 | 28759 Bremen | Germany
> Fax:   +49 421 200 3103         <https://www.jacobs-university.de/>

Mahesh Jethanandani
mjethanandani@gmail.com