netconfcentral logo

ietf-voucher@2017-10-25



  module ietf-voucher {

    yang-version 1.1;

    namespace
      "urn:ietf:params:xml:ns:yang:ietf-voucher";

    prefix vch;

    import ietf-yang-types {
      prefix yang;
      reference
        "RFC 6991: Common YANG Data Types";


    }
    import ietf-restconf {
      prefix rc;
      description
        "This import statement is only present to access
the yang-data extension defined in RFC 8040.";
      reference
        "RFC 8040: RESTCONF Protocol";


    }

    organization "IETF ANIMA Working Group";

    contact
      "WG Web:   <http://tools.ietf.org/wg/anima/>
    WG List:  <mailto:anima@ietf.org>
    Author:   Kent Watsen
              <mailto:kwatsen@juniper.net>
    Author:   Max Pritikin
              <mailto:pritikin@cisco.com>
    Author:   Michael Richardson
              <mailto:mcr+ietf@sandelman.ca>
    Author:   Toerless Eckert
              <mailto:tte+ietf@cs.fau.de>";

    description
      "This module defines the format for a voucher, which is produced by
    a pledge's manufacturer or delegate (MASA) to securely assign a
    pledge to an 'owner', so that the pledge may establish a secure
    connection to the owner's network infrastructure.

    The key words 'MUST', 'MUST NOT', 'REQUIRED', 'SHALL', 'SHALL NOT',
    'SHOULD', 'SHOULD NOT', 'RECOMMENDED', 'MAY', and 'OPTIONAL' in
    the module text are to be interpreted as described in RFC 2119.

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

    Redistribution and use in source and binary forms, with or without
    modification, is permitted pursuant to, and subject to the license
    terms contained in, the Simplified BSD License set forth in Section
    4.c of the IETF Trust's Legal Provisions Relating to IETF Documents
    (http://trustee.ietf.org/license-info).

    This version of this YANG module is part of RFC XXXX; see the RFC
    itself for full legal notices.";

    revision "2017-10-25" {
      description "Initial version";
      reference
        "RFC XXXX: Voucher Profile for Bootstrapping Protocols";

    }

    rc:yang-data "voucher-artifact";

    uses voucher-artifact-grouping;

    grouping voucher-artifact-grouping {
      description
        "Grouping to allow reuse/extensions in future work.";
      container voucher {
        description
          "A voucher assigns a pledge to an owner (pinned-domain-cert).";
        leaf created-on {
          type yang:date-and-time;
          mandatory true;
          description
            "A value indicating the date this voucher was created.  This
           node is primarily for human consumption and auditing. Future
           work MAY create verification requirements based on this
           node.";
        }

        leaf expires-on {
          type yang:date-and-time;
          must "not(../nonce)";
          description
            "A value indicating when this voucher expires.  The node is
           optional as not all pledges support expirations, such as
           pledges lacking a reliable clock.

           If this field exists, then the the pledges MUST ensure that
           the expires-on time has not yet passed. A pledge without
           an accurate clock cannot meet this requirement.

           The expires-on value MUST NOT exceed the expiration date
           of any of the listed 'pinned-domain-cert' certificates.";
        }

        leaf assertion {
          type enumeration {
            enum "verified" {
              value 0;
              description
                "Indicates that the ownership has been positively
               verified by the MASA (e.g., through sales channel
               integration).";
            }
            enum "logged" {
              value 1;
              description
                "Indicates that this ownership assignment has been
               logged into a database maintained by the MASA, after
               first verifying that there has not been a previous
               claim in the database for the same pledge (voucher
               transparency).";
            }
            enum "proximity" {
              value 2;
              description
                "Indicates that this assertion is made based on
               the proximity of the signer as determined by
               local network information. This is useful for
               a pledge device to indicate it 'sees' a specific
               registrar on a TLS connection, or for a registrar
               to indicate it 'sees' a pledge.";
            }
          }
          mandatory true;
          description
            "The assertion is a statement from the MASA regarding how
           the owner was verified.   This statement enables pledges
           to support more detailed policy checks.  Pledges MUST
           ensure that the assertion provided is acceptable before
           processing the voucher.";
        }

        leaf serial-number {
          type string;
          mandatory true;
          description
            "The serial number of the hardware.  When processing a
           voucher, a pledge MUST ensure that its serial number
           matches this value.  If no match occurs, then the
           pledge MUST NOT process this voucher.";
        }

        leaf idevid-issuer {
          type binary;
          description
            "The RFC5280 4.2.1.1 Authority Key Identifier OCTET STRING
           from the pledge's IDevID certificate.  Optional since some
           serial-numbers are already unique within the scope of a
           MASA.  Inclusion of the statistically unique key identifier
           ensures statistically unique identification of the hardware.
           When processing a voucher, a pledge MUST ensure that its
           IDevID Authority Key Identifier matches this value.  If no
           match occurs, then the pledge MUST NOT process this voucher.

           When issuing a voucher, the MASA MUST ensure that this field
           is populated for serial numbers that are not otherwise unique
           within the scope of the MASA.";
        }

        leaf pinned-domain-cert {
          type binary;
          mandatory true;
          description
            "An X.509 v3 certificate structure as specified by RFC 5280,
           Section 4 encoded using the ASN.1 distinguished encoding
           rules (DER), as specified in ITU-T X.690.

           This certificate is used by a pledge to trust a public key
           infrastructure, in order to verify a domain certificate
           supplied to the pledge separately by the bootstrapping
           protocol.  The domain certificate MUST have this certificate
           somewhere in its chain of certificates.  This certificate
           MAY be an end-entity certificate, including a self-signed
           entity.";
          reference
            "RFC 5280:
              Internet X.509 Public Key Infrastructure Certificate
              and Certificate Revocation List (CRL) Profile.
            ITU-T X.690:
               Information technology - ASN.1 encoding rules:
               Specification of Basic Encoding Rules (BER),
               Canonical Encoding Rules (CER) and Distinguished
               Encoding Rules (DER).";

        }

        leaf domain-cert-revocation-checks {
          type boolean;
          must "../expires-on";
          description
            "A processing instruction to the pledge that it MUST verify
           the revocation status for the domain certificate.  This
           instruction is only available for vouchers that expire. If
           this field is not set, then normal PKIX behaviour applies
           to validation of the domain certificate.";
        }

        leaf nonce {
          type binary {
            length "8..32";
          }
          must "not(../expires-on)";
          description
            "A value that can be used by a pledge in some bootstrapping
           protocols to enable anti-replay protection.  This node is
           optional because it is not used by all bootstrapping
           protocols.

           When present, the pledge MUST compare the provided nonce
           value with another value that the pledge randomly generated
           and sent to a bootstrap server in an earlier bootstrapping
           message.  If the values do not match, then the pledge MUST
           NOT process this voucher.";
        }

        leaf last-renewal-date {
          type yang:date-and-time;
          must "../expires-on";
          description
            "The date that the MASA projects to be the last date it
           will renew a voucher on. This field is merely informative, it
           is not processed by pledges.

           Circumstances may occur after a voucher is generated that
           may alter a voucher's validity period.  For instance, a
           vendor may associate validity periods with support contracts,
           which may be terminated or extended over time.";
        }
      }  // container voucher
    }  // grouping voucher-artifact-grouping
  }  // module ietf-voucher