module ietf-tls-client {
yang-version 1.1;
namespace "urn:ietf:params:xml:ns:yang:ietf-tls-client";
prefix "tlsc";
import ietf-tls-common {
prefix tlscmn;
revision-date 2018-09-20; // stable grouping definitions
reference
"RFC XXXX: YANG Groupings for TLS Clients and TLS Servers";
}
import ietf-trust-anchors {
prefix ta;
reference
"RFC YYYY: YANG Data Model for Global Trust Anchors";
}
import ietf-keystore {
prefix ks;
reference
"RFC ZZZZ: YANG Data Model for a 'Keystore' Mechanism";
}
organization
"IETF NETCONF (Network Configuration) Working Group";
contact
"WG Web:
WG List:
Author: Kent Watsen
Author: Gary Wu
";
description
"This module defines a reusable grouping for a TLS client that
can be used as a basis for specific TLS client instances.
Copyright (c) 2018 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 "2018-09-20" {
description
"Initial version";
reference
"RFC XXXX: YANG Groupings for TLS Clients and TLS Servers";
}
// features
feature tls-client-hello-params-config {
description
"TLS hello message parameters are configurable on a TLS
client.";
}
// groupings
grouping tls-client-grouping {
description
"A reusable grouping for configuring a TLS client without
any consideration for how an underlying TCP session is
established.";
uses client-identity-grouping;
uses server-auth-grouping;
uses hello-params-grouping;
}
grouping client-identity-grouping {
description
"A reusable grouping for configuring a TLS client identity.";
container client-identity {
description
"The credentials used by the client to authenticate to
the TLS server.";
choice auth-type {
description
"The authentication type.";
container certificate {
uses ks:local-or-keystore-end-entity-certificate-grouping;
description
"A locally-defined or referenced certificate
to be used for client authentication.";
reference
"RFC ZZZZ: YANG Data Model for a 'Keystore' Mechanism";
}
}
} // end client-identity
} // end client-identity-grouping
grouping server-auth-grouping {
description
"A reusable grouping for configuring TLS server
authentication.";
container server-auth {
must 'pinned-ca-certs or pinned-server-certs';
description
"Trusted server identities.";
leaf pinned-ca-certs {
if-feature "ta:x509-certificates";
type ta:pinned-certificates-ref;
description
"A reference to a list of certificate authority (CA)
certificates used by the TLS client to authenticate
TLS server certificates. A server certificate is
authenticated if it has a valid chain of trust to
a configured pinned CA certificate.";
}
leaf pinned-server-certs {
if-feature "ta:x509-certificates";
type ta:pinned-certificates-ref;
description
"A reference to a list of server certificates used by
the TLS client to authenticate TLS server certificates.
A server certificate is authenticated if it is an
exact match to a configured pinned server certificate.";
}
}
} // end server-auth-grouping
grouping hello-params-grouping {
description
"A reusable grouping for configuring a TLS transport
parameters.";
container hello-params {
if-feature tls-client-hello-params-config;
uses tlscmn:hello-params-grouping;
description
"Configurable parameters for the TLS hello message.";
}
} // end transport-params-grouping
}