-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathietf-ospf-msd.yang
304 lines (268 loc) · 9.14 KB
/
ietf-ospf-msd.yang
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
module ietf-ospf-msd {
yang-version 1.1;
namespace "urn:ietf:params:xml:ns:yang:ietf-ospf-msd";
prefix ospf-msd;
import ietf-routing {
prefix rt;
reference "RFC 8349: A YANG Data Model for Routing
Management (NMDA Version)";
}
import ietf-ospf {
prefix ospf;
}
import ietf-ospfv3-extended-lsa {
prefix ospfv3-e-lsa;
}
organization
"IETF LSR - LSR Working Group";
contact
"WG Web: <https://tools.ietf.org/wg/mpls/>
WG List: <mailto:[email protected]>
Author: Yingzhen Qu
<mailto:[email protected]>
Author: Acee Lindem
<mailto:[email protected]>
Author: Stephane Litkowski
<mailto:[email protected]>
Author: Jeff Tantsura
";
description
"The YANG module augments the base OSPF model to
manage different types of MSDs.
This YANG model conforms to the Network Management
Datastore Architecture (NMDA) as described in RFC 8342.
Copyright (c) 2022 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 Revised BSD License set
forth in Section 4.c of the IETF Trust's Legal Provisions
Relating to IETF Documents
(https://trustee.ietf.org/license-info).
This version of this YANG module is part of RFC XXXX;
see the RFC itself for full legal notices.
The key words 'MUST', 'MUST NOT', 'REQUIRED', 'SHALL', 'SHALL
NOT', 'SHOULD', 'SHOULD NOT', 'RECOMMENDED', 'NOT RECOMMENDED',
'MAY', and 'OPTIONAL' in this document are to be interpreted as
described in BCP 14 (RFC 2119) (RFC 8174) when, and only when,
they appear in all capitals, as shown here.";
reference "RFC XXXX: YANG Data Model for OSPF MSD.";
revision 2022-01-02 {
description
"Initial Version";
reference "RFC XXXX: YANG Data Model for OSPF MSD.";
}
identity msd-base-type {
description
"Base identity for MSD Type";
}
identity base-mpls-msd {
base msd-base-type;
description
"Base MPLS Imposition MSD.";
reference
"RFC 8491: Singling MSD using IS-IS.";
}
identity erld-msd {
base msd-base-type;
description
"ERLD-MSD is defined to advertise the ERLD.";
reference
"RFC 8662: Entropy Label for Source Packet Routing in
Networking (SPRING) Tunnels";
}
grouping node-msd-tlv {
description
"Grouping for node MSD.";
container node-msd-tlv {
list node-msds {
key "msd-type";
leaf msd-type {
type identityref {
base msd-base-type;
}
description
"MSD-Types";
}
leaf msd-value {
type uint8;
description
"MSD value, in the range of 0-255.";
}
description
"Node MSD is the smallest link MSD supported by
the node.";
}
description
"Node MSD is the number of SIDs supported by a node.";
reference
"RFC 8476: Signaling Maximum SID Depth (MSD) Using OSPF";
}
}
grouping link-msd-sub-tlv {
description
"Link Maximum SID Depth (MSD) grouping for an interface.";
container link-msd-sub-tlv {
list link-msds {
key "msd-type";
leaf msd-type {
type identityref {
base msd-base-type;
}
description
"MSD-Types";
}
leaf msd-value {
type uint8;
description
"MSD value, in the range of 0-255.";
}
description
"List of link MSDs";
}
description
"Link MSD sub-tlvs.";
}
}
/* Node MSD TLV */
augment "/rt:routing/"
+ "rt:control-plane-protocols/rt:control-plane-protocol/"
+ "ospf:ospf/ospf:areas/"
+ "ospf:area/ospf:database/"
+ "ospf:area-scope-lsa-type/ospf:area-scope-lsas/"
+ "ospf:area-scope-lsa/ospf:version/ospf:ospfv2/"
+ "ospf:ospfv2/ospf:body/ospf:opaque/"
+ "ospf:ri-opaque" {
when "../../../../../../../../../../../"
+ "rt:type = 'ospf:ospfv2'" {
description
"This augmentation is only valid for OSPFv2.";
}
description
"Node MSD TLV is an optional TLV of OSPFv2 RI Opaque
LSA (RFC7770) and has a type of 12.";
uses node-msd-tlv;
}
augment "/rt:routing/"
+ "rt:control-plane-protocols/rt:control-plane-protocol/"
+ "ospf:ospf/ospf:database/"
+ "ospf:as-scope-lsa-type/ospf:as-scope-lsas/"
+ "ospf:as-scope-lsa/ospf:version/ospf:ospfv2/"
+ "ospf:ospfv2/ospf:body/ospf:opaque/"
+ "ospf:ri-opaque" {
when "../../../../../../../../../"
+ "rt:type = 'ospf:ospfv2'" {
description
"This augmentation is only valid for OSPFv2.";
}
description
"Node MSD TLV is an optional TLV of OSPFv2 RI Opaque
LSA (RFC7770) and has a type of 12.";
uses node-msd-tlv;
}
augment "/rt:routing/"
+ "rt:control-plane-protocols/rt:control-plane-protocol/"
+ "ospf:ospf/ospf:areas/"
+ "ospf:area/ospf:database/"
+ "ospf:area-scope-lsa-type/ospf:area-scope-lsas/"
+ "ospf:area-scope-lsa/ospf:version/ospf:ospfv3/"
+ "ospf:ospfv3/ospf:body/ospf:router-information" {
when "../../../../../../../../../../"
+ "rt:type = 'ospf:ospfv3'" {
description
"This augmentation is only valid for OSPFv3.";
}
description
"Node MSD TLV is an optional TLV of OSPFv3 RI Opaque
LSA (RFC7770) and has a type of 12.";
uses node-msd-tlv;
}
augment "/rt:routing/"
+ "rt:control-plane-protocols/rt:control-plane-protocol/"
+ "ospf:ospf/ospf:database/"
+ "ospf:as-scope-lsa-type/ospf:as-scope-lsas/"
+ "ospf:as-scope-lsa/ospf:version/ospf:ospfv3/"
+ "ospf:ospfv3/ospf:body/ospf:router-information" {
when "../../../../../../../../"
+ "rt:type = 'ospf:ospfv3'" {
description
"This augmentation is only valid for OSPFv3.";
}
description
"Node MSD TLV is an optional TLV of OSPFv3 RI Opaque
LSA (RFC7770) and has a type of 12.";
uses node-msd-tlv;
}
/* link MSD sub-tlv */
augment "/rt:routing/"
+ "rt:control-plane-protocols/rt:control-plane-protocol/"
+ "ospf:ospf/ospf:areas/ospf:area/"
+ "ospf:interfaces/ospf:interface/ospf:database/"
+ "ospf:link-scope-lsa-type/ospf:link-scope-lsas/"
+ "ospf:link-scope-lsa/ospf:version/ospf:ospfv2/"
+ "ospf:ospfv2/ospf:body/ospf:opaque/"
+ "ospf:extended-link-opaque/ospf:extended-link-tlv" {
when "../../../../../../../../../../../../../../"
+ "rt:type = 'ospf:ospfv2'" {
description
"This augmentation is only valid for OSPFv2.";
}
description
"Link MSD sub-TLV is an optional sub-TLV of OSPFv2 extended
link TLV as defined in RFC 7684 and has a type of 6.";
uses link-msd-sub-tlv;
}
augment "/rt:routing/"
+ "rt:control-plane-protocols/rt:control-plane-protocol/"
+ "ospf:ospf/ospf:areas/"
+ "ospf:area/ospf:database/"
+ "ospf:area-scope-lsa-type/ospf:area-scope-lsas/"
+ "ospf:area-scope-lsa/ospf:version/ospf:ospfv2/"
+ "ospf:ospfv2/ospf:body/ospf:opaque/"
+ "ospf:extended-link-opaque/ospf:extended-link-tlv" {
when "../../../../../../../../../../../../"
+ "rt:type = 'ospf:ospfv2'" {
description
"This augmentation is only valid for OSPFv2.";
}
description
"Link MSD sub-TLV is an optional sub-TLV of OSPFv2 extended
link TLV as defined in RFC 7684 and has a type of 6.";
uses link-msd-sub-tlv;
}
augment "/rt:routing/"
+ "rt:control-plane-protocols/rt:control-plane-protocol/"
+ "ospf:ospf/ospf:database/"
+ "ospf:as-scope-lsa-type/ospf:as-scope-lsas/"
+ "ospf:as-scope-lsa/ospf:version/ospf:ospfv2/"
+ "ospf:ospfv2/ospf:body/ospf:opaque/"
+ "ospf:extended-link-opaque/ospf:extended-link-tlv" {
when "../../../../../../../../../../"
+ "rt:type = 'ospf:ospfv2'" {
description
"This augmentation is only valid for OSPFv2.";
}
description
"Link MSD sub-TLV is an optional sub-TLV of OSPFv2 extended
link TLV as defined in RFC 7684 and has a type of 6.";
uses link-msd-sub-tlv;
}
augment "/rt:routing/"
+ "rt:control-plane-protocols/rt:control-plane-protocol/"
+ "ospf:ospf/ospf:areas/ospf:area/ospf:database/"
+ "ospf:area-scope-lsa-type/ospf:area-scope-lsas/"
+ "ospf:area-scope-lsa/ospf:version/ospf:ospfv3/"
+ "ospf:ospfv3/ospf:body/ospfv3-e-lsa:e-router"
+ "/ospfv3-e-lsa:e-router-tlvs" {
when "'ospf:../../../../../../../../"
+ "rt:type' = 'ospf:ospfv3'" {
description
"This augmentation is only valid for OSPFv3
E-Router LSAs";
}
description
"Augment OSPFv3 Area scope router-link TLV.";
uses link-msd-sub-tlv;
}
}