]> git.proxmox.com Git - mirror_frr.git/blob - yang/frr-bgp-route-map.yang
Merge pull request #11095 from ecbaldwin/unlock-node-always
[mirror_frr.git] / yang / frr-bgp-route-map.yang
1 module frr-bgp-route-map {
2 yang-version 1.1;
3 namespace "http://frrouting.org/yang/bgp-route-map";
4 prefix frr-bgp-route-map;
5
6 import ietf-inet-types {
7 prefix inet;
8 }
9
10 import frr-route-map {
11 prefix frr-route-map;
12 }
13
14 import frr-filter {
15 prefix filter;
16 }
17
18 import frr-bgp-filter {
19 prefix bgp-filter;
20 }
21
22 import ietf-routing-types {
23 prefix rt-types;
24 }
25
26 organization
27 "Free Range Routing";
28 contact
29 "FRR Users List: <mailto:frog@lists.frrouting.org>
30 FRR Development List: <mailto:dev@lists.frrouting.org>";
31 description
32 "This module defines bgp route map settings";
33
34 revision 2020-01-02 {
35 description
36 "Initial revision";
37 }
38
39 identity match-alias {
40 base frr-route-map:rmap-match-type;
41 description
42 "Match BGP community alias name";
43 }
44
45 identity match-local-preference {
46 base frr-route-map:rmap-match-type;
47 description
48 "Match local-preference of routes";
49 }
50
51 identity match-script {
52 base frr-route-map:rmap-match-type;
53 description
54 "Match script of routes";
55 }
56
57 identity match-origin {
58 base frr-route-map:rmap-match-type;
59 description
60 "Match BGP route origin code";
61 }
62
63 identity rpki {
64 base frr-route-map:rmap-match-type;
65 description
66 "Control rpki specific settings";
67 }
68
69 identity probability {
70 base frr-route-map:rmap-match-type;
71 description
72 "Match portion of routes defined by percentage value";
73 }
74
75 identity source-vrf {
76 base frr-route-map:rmap-match-type;
77 description
78 "Match source vrf of routes";
79 }
80
81 identity peer {
82 base frr-route-map:rmap-match-type;
83 description
84 "Match peer address";
85 }
86
87 identity mac-address-list {
88 base frr-route-map:rmap-match-type;
89 description
90 "Match MAC address access-list";
91 }
92
93 identity ip-route-source {
94 base frr-route-map:rmap-match-type;
95 description
96 "Match advertising source address of route";
97 }
98
99 identity ip-route-source-prefix-list {
100 base frr-route-map:rmap-match-type;
101 description
102 "Match advertising source address of route";
103 }
104
105 identity evpn-route-type {
106 base frr-route-map:rmap-match-type;
107 description
108 "Match EVPN route type";
109 }
110
111 identity evpn-default-route {
112 base frr-route-map:rmap-match-type;
113 description
114 "Match EVPN default Type-5 route";
115 }
116
117 identity evpn-vni {
118 base frr-route-map:rmap-match-type;
119 description
120 "Match EVPN VNI";
121 }
122
123 identity evpn-rd {
124 base frr-route-map:rmap-match-type;
125 description
126 "Match EVPN route distinguisher";
127 }
128
129 identity match-community {
130 base frr-route-map:rmap-match-type;
131 description
132 "Match BGP community list";
133 }
134
135 identity match-large-community {
136 base frr-route-map:rmap-match-type;
137 description
138 "Match BGP large-community list";
139 }
140
141 identity match-extcommunity {
142 base frr-route-map:rmap-match-type;
143 description
144 "Match BGP extcommunity list";
145 }
146
147 identity as-path-list {
148 base frr-route-map:rmap-match-type;
149 description
150 "Match BGP AS path list";
151 }
152
153 identity ipv4-nexthop {
154 base frr-route-map:rmap-match-type;
155 description
156 "Match IPv4 next hop address";
157 }
158
159 identity ipv6-nexthop {
160 base frr-route-map:rmap-match-type;
161 description
162 "Match IPv6 next hop address";
163 }
164
165 identity distance {
166 base frr-route-map:rmap-set-type;
167 description
168 "Set BGP administrative distance to use";
169 }
170
171 identity set-extcommunity-none {
172 base frr-route-map:rmap-set-type;
173 description
174 "Set BGP extended community attribute";
175 }
176
177 identity set-extcommunity-rt {
178 base frr-route-map:rmap-set-type;
179 description
180 "Set BGP extended community attribute";
181 }
182
183 identity set-extcommunity-soo {
184 base frr-route-map:rmap-set-type;
185 description
186 "Set BGP extended community attribute";
187 }
188
189 identity set-extcommunity-lb {
190 base frr-route-map:rmap-set-type;
191 description
192 "Set BGP extended community attribute";
193 }
194
195 identity set-ipv4-nexthop {
196 base frr-route-map:rmap-set-type;
197 description
198 "Set the IPv4 next-hop to peer-address/unchanged";
199 }
200
201 identity ipv4-vpn-address {
202 base frr-route-map:rmap-set-type;
203 description
204 "Set IPv4 VPN next-hop address";
205 }
206
207 identity ipv6-nexthop-global {
208 base frr-route-map:rmap-set-type;
209 description
210 "Set IPv6 next-hop global address";
211 }
212
213 identity ipv6-prefer-global {
214 base frr-route-map:rmap-set-type;
215 description
216 "Set IPv6 next-hop to prefer global address";
217 }
218
219 identity ipv6-peer-address {
220 base frr-route-map:rmap-set-type;
221 description
222 "Set IPv6 next-hop peer address";
223 }
224
225 identity ipv6-vpn-address {
226 base frr-route-map:rmap-set-type;
227 description
228 "Set IPv6 VPN next-hop address";
229 }
230
231 identity label-index {
232 base frr-route-map:rmap-set-type;
233 description
234 "Set the label index to associate with the prefixs";
235 }
236
237 identity set-local-preference {
238 base frr-route-map:rmap-set-type;
239 description
240 "Set the BGP local preference path attribute";
241 }
242
243 identity set-origin {
244 base frr-route-map:rmap-set-type;
245 description
246 "Set BGP route origin code";
247 }
248
249 identity weight {
250 base frr-route-map:rmap-set-type;
251 description
252 "Set the BGP weight attribute";
253 }
254
255 identity originator-id {
256 base frr-route-map:rmap-set-type;
257 description
258 "Set the BGP originator ID attribute";
259 }
260
261 identity table {
262 base frr-route-map:rmap-set-type;
263 description
264 "Export route to non-main kernel table";
265 }
266
267 identity atomic-aggregate {
268 base frr-route-map:rmap-set-type;
269 description
270 "Set BGP atomic-aggregate attribute";
271 }
272
273 identity as-path-prepend {
274 base frr-route-map:rmap-set-type;
275 description
276 "Set the BGP AS-path attribute";
277 }
278
279 identity as-path-exclude {
280 base frr-route-map:rmap-set-type;
281 description
282 "Set the BGP AS-path attribute";
283 }
284
285 identity as-path-replace {
286 base frr-route-map:rmap-set-type;
287 description
288 "Replace ASNs to local AS number";
289 }
290
291 identity set-community {
292 base frr-route-map:rmap-set-type;
293 description
294 "Set the BGP community attribute";
295 }
296
297 identity set-large-community {
298 base frr-route-map:rmap-set-type;
299 description
300 "Set the BGP large-community attribute";
301 }
302
303 identity aggregator {
304 base frr-route-map:rmap-set-type;
305 description
306 "Set the BGP aggregator attribute";
307 }
308
309 identity comm-list-delete {
310 base frr-route-map:rmap-set-type;
311 description
312 "Set BGP community list (for deletion)";
313 }
314
315 identity large-comm-list-delete {
316 base frr-route-map:rmap-set-type;
317 description
318 "Set BGP large community list (for deletion)";
319 }
320
321 identity set-evpn-gateway-ip-ipv4 {
322 base frr-route-map:rmap-set-type;
323 description
324 "Set EVPN gateway IP overlay index IPv4";
325 }
326
327 identity set-evpn-gateway-ip-ipv6 {
328 base frr-route-map:rmap-set-type;
329 description
330 "Set EVPN gateway IP overlay index IPv6";
331 }
332
333 grouping extcommunity-non-transitive-types {
334 leaf two-octet-as-specific {
335 type boolean;
336 description
337 "Non-Transitive Two-Octet AS-Specific Extended Community";
338 }
339 }
340
341 typedef extcommunity-lb-type {
342 type enumeration {
343 enum "explicit-bandwidth" {
344 value 0;
345 description
346 "Bandwidth value in Mbps";
347 }
348 enum "cumulative-bandwidth" {
349 value 1;
350 description
351 "Cumulative bandwidth of all multipaths (outbound-only)";
352 }
353 enum "computed-bandwidth" {
354 value 2;
355 description
356 "Internally computed bandwidth based on number of multipaths (outbound-only)";
357 }
358 }
359 description
360 "ext-community link bandwidth types.";
361 }
362
363 augment "/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:match-condition/frr-route-map:rmap-match-condition/frr-route-map:match-condition" {
364 case local-preference {
365 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:match-condition/frr-route-map:condition, 'frr-bgp-route-map:match-local-preference')";
366 leaf local-preference {
367 type uint32 {
368 range "0..4294967295";
369 }
370 }
371 }
372
373 case alias {
374 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:match-condition/frr-route-map:condition, 'frr-bgp-route-map:match-alias')";
375 leaf alias {
376 type string;
377 }
378 }
379
380 case script {
381 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:match-condition/frr-route-map:condition, 'frr-bgp-route-map:match-script')";
382 leaf script {
383 type string;
384 }
385 }
386
387 case origin {
388 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:match-condition/frr-route-map:condition, 'frr-bgp-route-map:match-origin')";
389 leaf origin {
390 type enumeration {
391 enum "egp" {
392 value 0;
393 description
394 "Remote EGP";
395 }
396 enum "igp" {
397 value 1;
398 description
399 "Local IGP";
400 }
401 enum "incomplete" {
402 value 2;
403 description
404 "Unknown heritage";
405 }
406 }
407 }
408 }
409
410 case rpki {
411 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:match-condition/frr-route-map:condition, 'frr-bgp-route-map:rpki')";
412 leaf rpki {
413 type enumeration {
414 enum "invalid" {
415 value 0;
416 description
417 "Invalid prefix";
418 }
419 enum "notfound" {
420 value 1;
421 description
422 "Prefix not found";
423 }
424 enum "valid" {
425 value 2;
426 description
427 "Valid prefix";
428 }
429 }
430 }
431 }
432
433 case probability {
434 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:match-condition/frr-route-map:condition, 'frr-bgp-route-map:probability')";
435 leaf probability {
436 type uint8 {
437 range "0..100";
438 }
439 }
440 }
441
442 case source-vrf {
443 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:match-condition/frr-route-map:condition, 'frr-bgp-route-map:source-vrf')";
444 leaf source-vrf {
445 type string;
446 }
447 }
448
449 case peer {
450 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:match-condition/frr-route-map:condition, 'frr-bgp-route-map:peer')";
451 choice peer {
452 description
453 "Value of the peer";
454 case peer-ipv4-address {
455 description
456 "IP address of peer";
457 leaf peer-ipv4-address {
458 type inet:ipv4-address;
459 }
460 }
461
462 case peer-interface {
463 description
464 "Interface name of peer";
465 leaf peer-interface {
466 type string;
467 }
468 }
469
470 case peer-ipv6-address {
471 description
472 "IPv6 address of peer";
473 leaf peer-ipv6-address {
474 type inet:ipv6-address;
475 }
476 }
477
478 case peer-local {
479 description
480 "Static or Redistributed routes";
481 leaf peer-local {
482 type boolean;
483 }
484 }
485 }
486 }
487
488 case access-list-name {
489 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:match-condition/frr-route-map:condition, 'frr-bgp-route-map:mac-address-list') or "
490 + "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:match-condition/frr-route-map:condition, 'frr-bgp-route-map:as-path-list') or "
491 + "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:match-condition/frr-route-map:condition, 'frr-bgp-route-map:ip-route-source') or "
492 + "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:match-condition/frr-route-map:condition, 'frr-bgp-route-map:ip-route-source-prefix-list')";
493 description
494 "Access-list name";
495 leaf list-name {
496 type filter:access-list-name;
497 }
498 }
499
500 case evpn-default-route {
501 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:match-condition/frr-route-map:condition, 'frr-bgp-route-map:evpn-default-route')";
502 description
503 "Match default EVPN type-5 route";
504 leaf evpn-default-route {
505 type empty;
506 }
507 }
508
509 case evpn-vni {
510 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:match-condition/frr-route-map:condition, 'frr-bgp-route-map:evpn-vni')";
511 description
512 "Match eVPN VNI";
513 leaf evpn-vni {
514 type uint32 {
515 range "1..16777215";
516 }
517 }
518 }
519
520 case evpn-route-type {
521 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:match-condition/frr-route-map:condition, 'frr-bgp-route-map:evpn-route-type')";
522 description
523 "Match eVPN route-type";
524 leaf evpn-route-type {
525 type enumeration {
526 enum "macip" {
527 value 0;
528 description
529 "Mac-IP route";
530 }
531 enum "multicast" {
532 value 1;
533 description
534 "IMET route";
535 }
536 enum "prefix" {
537 value 2;
538 description
539 "Prefix route";
540 }
541 enum "ead" {
542 value 3;
543 description
544 "Ethernet Auto-Discovery route";
545 }
546 enum "es" {
547 value 4;
548 description
549 "Ethernet Segment route";
550 }
551 }
552 }
553 }
554
555 case evpn-rd {
556 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:match-condition/frr-route-map:condition, 'frr-bgp-route-map:evpn-rd')";
557 description
558 "Match eVPN route-distinguisher";
559 leaf route-distinguisher {
560 type rt-types:route-distinguisher;
561 }
562 }
563
564 case comm-list-name {
565 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:match-condition/frr-route-map:condition, 'frr-bgp-route-map:match-community') or "
566 + "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:match-condition/frr-route-map:condition, 'frr-bgp-route-map:match-large-community') or "
567 + "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:match-condition/frr-route-map:condition, 'frr-bgp-route-map:match-extcommunity')";
568 container comm-list {
569 leaf comm-list-name {
570 type bgp-filter:bgp-list-name;
571 }
572
573 leaf comm-list-name-exact-match {
574 type boolean;
575 description
576 "Do exact matching of communities";
577 }
578 }
579 }
580
581 case ipv4-address {
582 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:match-condition/frr-route-map:condition, 'frr-bgp-route-map:ipv4-nexthop')";
583 leaf ipv4-address {
584 type inet:ipv4-address;
585 description
586 "IPv4 address";
587 }
588 }
589
590 case ipv6-address {
591 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:match-condition/frr-route-map:condition, 'frr-bgp-route-map:ipv6-nexthop')";
592 leaf ipv6-address {
593 type inet:ipv6-address;
594 description
595 "IPv6 address";
596 }
597 }
598 }
599
600 augment "/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:rmap-set-action/frr-route-map:set-action" {
601 case distance {
602 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:distance')";
603 leaf distance {
604 type uint8 {
605 range "0..255";
606 }
607 }
608 }
609
610 case extcommunity-none {
611 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:set-extcommunity-none')";
612 description
613 "Value of the BGP extended community attribute";
614 leaf extcommunity-none {
615 type boolean;
616 description "No extended community attribute";
617 }
618 }
619
620 case extcommunity-rt {
621 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:set-extcommunity-rt')";
622 description
623 "Value of the ext-community";
624 leaf extcommunity-rt {
625 type string;
626 description
627 "Set BGP ext-community route-target attribute";
628 }
629 }
630
631 case extcommunity-soo {
632 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:set-extcommunity-soo')";
633 description
634 "Value of the ext-community";
635 leaf extcommunity-soo {
636 type string;
637 description
638 "Set BGP ext-community site-of-origin attribute";
639 }
640 }
641
642 case extcommunity-lb {
643 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:set-extcommunity-lb')";
644 container extcommunity-lb {
645 description
646 "Value of the ext-community.";
647 leaf lb-type {
648 type frr-bgp-route-map:extcommunity-lb-type;
649 }
650
651 leaf bandwidth {
652 when "../lb-type = 'explicit-bandwidth'";
653 type uint16 {
654 range "1..25600";
655 }
656 description
657 "Bandwidth value in Mbps";
658 }
659 uses extcommunity-non-transitive-types;
660 }
661 }
662
663 case ipv4-address {
664 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:ipv4-vpn-address')";
665 description
666 "Set the IPv4 address";
667 leaf ipv4-address {
668 type inet:ipv4-address;
669 }
670 }
671
672 case ipv4-nexthop {
673 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:set-ipv4-nexthop')";
674 leaf ipv4-nexthop {
675 type string;
676 }
677 }
678
679 case ipv6-address {
680 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:ipv6-nexthop-global') or "
681 + "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:ipv6-vpn-address')";
682 description
683 "Set the IPv6 address";
684 leaf ipv6-address {
685 type inet:ipv6-address;
686 }
687 }
688
689 case preference {
690 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:ipv6-prefer-global') or "
691 + "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:ipv6-peer-address')";
692 leaf preference {
693 type boolean;
694 }
695 }
696
697 case label-index {
698 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:label-index')";
699 leaf label-index {
700 type uint32 {
701 range "0..1048560";
702 }
703 }
704 }
705
706 case local-pref {
707 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:set-local-preference')";
708 leaf local-pref {
709 type string;
710 }
711 }
712
713 case weight {
714 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:weight')";
715 leaf weight {
716 type uint32 {
717 range "0..4294967295";
718 }
719 }
720 }
721
722 case origin {
723 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:set-origin')";
724 leaf origin {
725 type enumeration {
726 enum "egp" {
727 value 0;
728 description
729 "Remote EGP";
730 }
731 enum "igp" {
732 value 1;
733 description
734 "Local IGP";
735 }
736 enum "incomplete" {
737 value 2;
738 description
739 "Unknown heritage";
740 }
741 }
742 }
743 }
744
745 case originator-id {
746 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:originator-id')";
747 leaf originator-id {
748 type inet:ipv4-address;
749 }
750 }
751
752 case table {
753 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:table')";
754 leaf table {
755 type uint32 {
756 range "1..4294967295";
757 }
758 }
759 }
760
761 case atomic-aggregate {
762 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:atomic-aggregate')";
763 leaf atomic-aggregate {
764 type empty;
765 }
766 }
767
768 case as-path-prepend {
769 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:as-path-prepend')";
770 choice as-path-prepend {
771 description
772 "Value of the BGP AS-path attribute";
773 case prepend-as {
774 description
775 "Prepend the mentioned AS-path";
776 leaf prepend-as-path {
777 type string;
778 }
779 }
780
781 case last-as {
782 description
783 "Prepend the last ASN in the AS-path";
784 leaf last-as {
785 type uint8 {
786 range "1..10";
787 }
788 }
789 }
790 }
791 }
792
793 case as-path-exclude {
794 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:as-path-exclude')";
795 leaf exclude-as-path {
796 type string;
797 description
798 "Exclude the mentioned AS-path";
799 }
800 }
801
802 case as-path-replace {
803 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:as-path-replace')";
804 leaf replace-as-path {
805 type string;
806 description
807 "Replace ASNs to local AS number";
808 }
809 }
810
811 case community {
812 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:set-community')";
813 choice community {
814 description
815 "Value of the BGP community attribute";
816 case none {
817 description
818 "No community attribute";
819 leaf community-none {
820 type boolean;
821 }
822 }
823
824 case community-string {
825 description
826 "Community string";
827 leaf community-string {
828 type string;
829 }
830 }
831 }
832 }
833
834 case large-community {
835 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:set-large-community')";
836 choice large-community {
837 description
838 "Value of the BGP large-community attribute";
839 case none {
840 description
841 "No large-community attribute";
842 leaf large-community-none {
843 type boolean;
844 }
845 }
846
847 case large-community-string {
848 description
849 "Large-Community string";
850 leaf large-community-string {
851 type string;
852 }
853 }
854 }
855 }
856
857 case aggregator {
858 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:aggregator')";
859 container aggregator {
860 leaf aggregator-asn {
861 type uint32 {
862 range "1..4294967295";
863 }
864 description
865 "ASN of the aggregator";
866 }
867
868 leaf aggregator-address {
869 when "../aggregator-asn > 0 or "
870 + "../aggregator-asn <= 4294967295";
871 type inet:ipv4-address;
872 description
873 "IPv4 address of the aggregator";
874 }
875 }
876 }
877
878 case comm-list-name {
879 when "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:comm-list-delete') or "
880 + "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action, 'frr-bgp-route-map:large-comm-list-delete')";
881 leaf comm-list-name {
882 type bgp-filter:bgp-list-name;
883 }
884 }
885 case evpn-gateway-ip-ipv4 {
886 when
887 "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action,
888 'frr-bgp-route-map:set-evpn-gateway-ip-ipv4')";
889 description
890 "Set EVPN gateway IP overlay index IPv4";
891 leaf evpn-gateway-ip-ipv4 {
892 type inet:ipv4-address;
893 }
894 }
895 case evpn-gateway-ip-ipv6 {
896 when
897 "derived-from-or-self(/frr-route-map:lib/frr-route-map:route-map/frr-route-map:entry/frr-route-map:set-action/frr-route-map:action,
898 'frr-bgp-route-map:set-evpn-gateway-ip-ipv6')";
899 description
900 "Set EVPN gateway IP overlay index IPv6";
901 leaf evpn-gateway-ip-ipv6 {
902 type inet:ipv6-address;
903 }
904 }
905 }
906 }