Adding TestVNF netconf server
[demo.git] / vnfs / TestVNF / netconftemplates / netconftemplates / ietf-tls-server@2016-11-02.yang
1 <rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="m-1">
2   <data xmlns="urn:ietf:params:xml:ns:yang:ietf-netconf-monitoring">module ietf-tls-server {
3   yang-version 1.1;
4   namespace "urn:ietf:params:xml:ns:yang:ietf-tls-server";
5   prefix tlss;
6
7   import ietf-inet-types {
8     prefix inet;
9     reference
10       "RFC 6991: Common YANG Data Types";
11   }
12
13   import ietf-keystore {
14     prefix ks;
15     reference
16       "RFC YYYY: Keystore Model";
17   }
18
19   organization
20     "IETF NETCONF (Network Configuration) Working Group";
21   contact
22     "WG Web:   &lt;http://tools.ietf.org/wg/netconf/&gt;
23      WG List:  &lt;mailto:netconf@ietf.org&gt;
24
25      WG Chair: Mehmet Ersue
26                &lt;mailto:mehmet.ersue@nsn.com&gt;
27
28      WG Chair: Mahesh Jethanandani
29                &lt;mailto:mjethanandani@gmail.com&gt;
30
31      Editor:   Kent Watsen
32                &lt;mailto:kwatsen@juniper.net&gt;";
33   description
34     "This module defines a reusable grouping for a TLS server that
35      can be used as a basis for specific TLS server instances.
36
37      Copyright (c) 2014 IETF Trust and the persons identified as
38      authors of the code. All rights reserved.
39
40      Redistribution and use in source and binary forms, with or
41      without modification, is permitted pursuant to, and subject
42      to the license terms contained in, the Simplified BSD
43      License set forth in Section 4.c of the IETF Trust's
44      Legal Provisions Relating to IETF Documents
45      (http://trustee.ietf.org/license-info).
46
47      This version of this YANG module is part of RFC XXXX; see
48      the RFC itself for full legal notices.";
49
50   revision 2016-11-02 {
51     description
52       "Initial version";
53     reference
54       "RFC XXXX: TLS Client and Server Models";
55   }
56
57   grouping non-listening-tls-server-grouping {
58     description
59       "A reusable grouping for a TLS server that can be used as a
60        basis for specific TLS server instances.";
61     container certificates {
62       description
63         "The list of certificates the TLS server will present when
64          establishing a TLS connection in its Certificate message,
65          as defined in Section 7.4.2 in RRC 5246.";
66       reference
67         "RFC 5246:
68            The Transport Layer Security (TLS) Protocol Version 1.2";
69       list certificate {
70         key "name";
71         min-elements 1;
72         description
73           "An unordered list of certificates the TLS server can pick
74            from when sending its Server Certificate message.";
75         reference
76           "RFC 5246: The TLS Protocol, Section 7.4.2";
77         leaf name {
78           type leafref {
79             path "/ks:keystore/ks:private-keys/ks:private-key/ks:certificate-chains/ks:certificate-chain/ks:name";
80           }
81           description
82             "The name of the certificate in the keystore.";
83         }
84       }
85     }
86
87     container client-auth {
88       description
89         "A reference to a list of trusted certificate authority (CA)
90          certificates and a reference to a list of trusted client
91          certificates.";
92       leaf trusted-ca-certs {
93         type leafref {
94           path "/ks:keystore/ks:trusted-certificates/ks:name";
95         }
96         description
97           "A reference to a list of certificate authority (CA)
98            certificates used by the TLS server to authenticate
99            TLS client certificates.";
100       }
101
102       leaf trusted-client-certs {
103         type leafref {
104           path "/ks:keystore/ks:trusted-certificates/ks:name";
105         }
106         description
107           "A reference to a list of client certificates used by
108            the TLS server to authenticate TLS client certificates.
109            A clients certificate is authenticated if it is an
110            exact match to a configured trusted client certificate.";
111       }
112     }
113   }
114
115   grouping listening-tls-server-grouping {
116     description
117       "A reusable grouping for a TLS server that can be used as a
118        basis for specific TLS server instances.";
119     leaf address {
120       type inet:ip-address;
121       description
122         "The IP address of the interface to listen on.  The TLS
123          server will listen on all interfaces if no value is
124          specified. Please note that some addresses have special
125          meanings (e.g., '0.0.0.0' and '::').";
126     }
127
128     leaf port {
129       type inet:port-number;
130       description
131         "The local port number on this interface the TLS server
132          listens on.  When this grouping is used, it is RECOMMENDED
133          that refine statement is used to either set a default port
134          value or to set mandatory true.";
135     }
136
137     uses non-listening-tls-server-grouping;
138   }
139 }
140 </data>
141 </rpc-reply>