Internet DRAFT - draft-peterson-modern-teri-json

draft-peterson-modern-teri-json







Network Working Group                                        J. Peterson
Internet-Draft                                                   Neustar
Intended status: Informational                              July 3, 2017
Expires: January 4, 2018


                  A JSON Binding and Encoding for TeRI
                 draft-peterson-modern-teri-json-01.txt

Abstract

   The Telephone-Related Information (TeRI) framework defines an
   information model for data objects related to the acquisiton,
   management, and retrieval of telephone numbers and information
   related to them via the Internet.  TeRI provides an abstract
   framework that must be instantiated by a particular binding and
   encoding.  This document defines an HTTP binding for TeRI and a
   JavaScript Object Notation (JSON) encoding for TeRI.

Status of This Memo

   This Internet-Draft is submitted in full conformance with the
   provisions of BCP 78 and BCP 79.

   Internet-Drafts are working documents of the Internet Engineering
   Task Force (IETF).  Note that other groups may also distribute
   working documents as Internet-Drafts.  The list of current Internet-
   Drafts is at http://datatracker.ietf.org/drafts/current/.

   Internet-Drafts are draft documents valid for a maximum of six months
   and may be updated, replaced, or obsoleted by other documents at any
   time.  It is inappropriate to use Internet-Drafts as reference
   material or to cite them other than as "work in progress."

   This Internet-Draft will expire on January 4, 2018.

Copyright Notice

   Copyright (c) 2017 IETF Trust and the persons identified as the
   document authors.  All rights reserved.

   This document is subject to BCP 78 and the IETF Trust's Legal
   Provisions Relating to IETF Documents
   (http://trustee.ietf.org/license-info) in effect on the date of
   publication of this document.  Please review these documents
   carefully, as they describe your rights and restrictions with respect
   to this document.  Code Components extracted from this document must
   include Simplified BSD License text as described in Section 4.e of



Peterson                 Expires January 4, 2018                [Page 1]

Internet-Draft                  JSON TeRI                      July 2017


   the Trust Legal Provisions and are provided without warranty as
   described in the Simplified BSD License.

Table of Contents

   1.  Introduction  . . . . . . . . . . . . . . . . . . . . . . . .   2
   2.  Terminology . . . . . . . . . . . . . . . . . . . . . . . . .   2
   3.  HTTP TeRI Binding . . . . . . . . . . . . . . . . . . . . . .   3
   4.  JSON TeRI Encoding  . . . . . . . . . . . . . . . . . . . . .   3
     4.1.  TeRI Requests . . . . . . . . . . . . . . . . . . . . . .   3
     4.2.  TeRI Responses  . . . . . . . . . . . . . . . . . . . . .   4
     4.3.  TeRI Records  . . . . . . . . . . . . . . . . . . . . . .   4
   5.  Acknowledgments . . . . . . . . . . . . . . . . . . . . . . .   4
   6.  IANA Considerations . . . . . . . . . . . . . . . . . . . . .   5
   7.  Security Considerations . . . . . . . . . . . . . . . . . . .   5
   8.  Informative References  . . . . . . . . . . . . . . . . . . .   5
   Author's Address  . . . . . . . . . . . . . . . . . . . . . . . .   5

1.  Introduction

   The Telephone-Related Information (TeRI) framework
   [I-D.peterson-modern-teri] defines an information model for data
   objects related to the acquisiton, management, and retrieval of
   telephone numbers and information related to them via the Internet.
   TeRI provides an abstract framework that must be instantiated by a
   particular binding and encoding, as described in
   [I-D.peterson-modern-teri] Section 6.2 and 6.3, respectively.  This
   document defines an HTTP binding and JavaScript Object Notation
   (JSON) [RFC7159] encoding for TeRI.  It does not however define any
   particular profile or deployment environment for using TeRI in this
   fashion; this only demonstrates an instantiation of the baseline TeRI
   specification using JSON.

   This is an early stage Internet-Draft that serves primarily as a
   vehicle to give examples of a potential syntax for TeRI Requests and
   Responses in order to facilitate discussion.

2.  Terminology

   In this document, the key words "MAY", "MUST, "MUST NOT", "SHOULD",
   and "SHOULD NOT", are to be interpreted as described in [RFC2119].
   This document also incorporates the terminology of the MODERN
   Framework [I-D.ietf-modern-problem-framework].








Peterson                 Expires January 4, 2018                [Page 2]

Internet-Draft                  JSON TeRI                      July 2017


3.  HTTP TeRI Binding

   This specification defines a RESTful interface for getting and
   putting JSON objects related to TeRI at a web service.

   TBD.

4.  JSON TeRI Encoding

   This specification defines separate JSON objects to carry TeRI
   Requests and Responses.  All JSON objects begin with a "TeRI"
   element, which has a value stating whether the object contains a
   Request or a Response.

4.1.  TeRI Requests

   Per TeRI [I-D.peterson-modern-teri], all requests will have a Source
   and a Subject.  Optionally, a block of Query Restrictions may also
   appear in the Request.

   This simplest TeRI request will therefore have the following form:

   { "TeRI":"Retrieval",
     "Source":[{"Request":"example.com"}],
     "Subject":{"T":"12125551111"}
     }

   The "Source" element is given as an array here because a TeRI Request
   may have multiple Sources, including one "Request" Source and one or
   more "Intermediary" Sources.  All Requests have a single Subject.
   The encoding of a Subject follows the Service Types given in
   [I-D.peterson-modern-teri] Section 4.2.1.  Here, Type "T" signifies a
   single telephone number.

   Most of the complexity in Requests comes from Query Restrictions.
   Query Restrictions appear in their own JSON array, and typically
   serve to qualify a request.  In this example, the TeRI request is
   only asking for Service Records, for an SMS service (see
   [I-D.peterson-modern-teri] Section 5.5.2) associated with the
   telephone number "12125551000".

   { "TeRI":"Retrieval",
     "Source":{"Request":"example.com"},
     "Subject":{T":"12125551000"} ,
     "Restriction":[
             ("Service":"sms"} ]
     }




Peterson                 Expires January 4, 2018                [Page 3]

Internet-Draft                  JSON TeRI                      July 2017


4.2.  TeRI Responses

   All TeRI responses will give a Response Code.  The simplest TeRI
   responses are therefore simple failure responses.

   { "TeRI":"Response",
     "Code":"Unauthorized Source"
     }

   [TBD: Note that TeRI has not allocate Response Codes yet; these will
   accompany the human-readable response indicators like "Unauthorized
   Source"]

   Most interesting TeRI responses contain Records, which are specified
   in Section 4.3.

4.3.  TeRI Records

   A TeRI Record consists of a JSON array containing a set of elements
   as defined in [I-D.peterson-modern-teri].  Records may appear in both
   TeRI Requests and Responses; for Retrieval Operations, it would be
   most common for Records to appear in Responses, when the Request
   indicates a Subject that the Source would like receive Records
   related to.

   { "TeRI":"Response",
     "Code":"Success",
     "Record:{
           "Identifier":"dc9a25c5-e44a-4dc1-9ff7-609da04bd694",
           "Authority":{"x5u":"http://example.com/cert.cert"},
           "Subject":[{T":"12125551000"}],
           "Access":"Public",
           "Service":{"sms":"sip:alice@example.com"},
           "Signature":"dBjftJeZ4CVP-mB92K27uhbUJU1p1r_wW1gFWFOEjXk" }
           }

   This is a simple example of a Record; more complex records may
   contain Priorities or Expiries.  Note that the Service Type here
   follows the [I-D.peterson-modern-teri] Section 4.2.1 Types, as did
   the Restrictions in the Request above.

5.  Acknowledgments

   We would like to thank YOU for your contributions to this
   specification.






Peterson                 Expires January 4, 2018                [Page 4]

Internet-Draft                  JSON TeRI                      July 2017


6.  IANA Considerations

   This memo includes no request to IANA.

7.  Security Considerations

   TBD.

8.  Informative References

   [I-D.ietf-modern-problem-framework]
              Peterson, J. and T. McGarry, "Modern Problem Statement,
              Use Cases, and Framework", draft-ietf-modern-problem-
              framework-02 (work in progress), March 2017.

   [I-D.peterson-modern-teri]
              Peterson, J., "An Architecture and Information Model for
              Telephone-Related Information (TeRI)", draft-peterson-
              modern-teri-02 (work in progress), October 2016.

   [RFC2119]  Bradner, S., "Key words for use in RFCs to Indicate
              Requirement Levels", BCP 14, RFC 2119,
              DOI 10.17487/RFC2119, March 1997,
              <http://www.rfc-editor.org/info/rfc2119>.

   [RFC7159]  Bray, T., Ed., "The JavaScript Object Notation (JSON) Data
              Interchange Format", RFC 7159, DOI 10.17487/RFC7159, March
              2014, <http://www.rfc-editor.org/info/rfc7159>.

Author's Address

   Jon Peterson
   Neustar, Inc.
   1800 Sutter St Suite 570
   Concord, CA  94520
   US

   Email: jon.peterson@neustar.biz













Peterson                 Expires January 4, 2018                [Page 5]