-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1519 from yang-catalog/main
Cronjob - daily update of yang files.
- Loading branch information
Showing
6 changed files
with
622 additions
and
142 deletions.
There are no files selected for viewing
268 changes: 268 additions & 0 deletions
268
experimental/ietf-extracted-YANG-modules/[email protected]
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,268 @@ | ||
module ietf-bgp-aspa { | ||
yang-version "1.1"; | ||
namespace "urn:ietf:params:xml:ns:yang:" | ||
+ "ietf-bgp-aspa"; | ||
prefix "oav"; | ||
|
||
import ietf-routing { | ||
prefix "rt"; | ||
reference | ||
"RFC 8349, A YANG Data Model for Routing Management | ||
(NMDA Version)."; | ||
} | ||
|
||
import ietf-bgp { | ||
prefix "bgp"; | ||
reference | ||
"RFC XXXX: YANG Model for Border Gateway Protocol (BGP-4)"; | ||
} | ||
|
||
import iana-bgp-types { | ||
prefix "bt"; | ||
reference | ||
"RFC XXXX: YANG Model for Border Gateway Protocol (BGP-4)"; | ||
} | ||
|
||
import iana-bgp-rib-types { | ||
prefix "brt"; | ||
reference | ||
"RFC XXXX: YANG Model for Border Gateway Protocol (BGP-4)"; | ||
} | ||
|
||
organization | ||
"IETF SIDROPS Working Group"; | ||
|
||
contact | ||
"TBD"; | ||
|
||
description | ||
"This module describes configuration of the BGP AS PATH | ||
Verification Based on ASPA. | ||
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"; | ||
|
||
revision 2022-10-18 { | ||
description | ||
"Initial Version"; | ||
reference | ||
"RFC XXXX, YANG Data Model for RPKI to Router Protocol"; | ||
} | ||
|
||
identity ineligible-aspa { | ||
base brt:ineligible-route-reason; | ||
description | ||
"Route was ineligible due to ASPA verification"; | ||
} | ||
|
||
typedef peer-role { | ||
type enumeration { | ||
enum customer { | ||
description | ||
"The role of the BGP peer is customer."; | ||
} | ||
enum provider { | ||
description | ||
"The role of the BGP peer is provider."; | ||
} | ||
enum lateral-peer { | ||
description | ||
"The role of the BGP peer is lateral peer."; | ||
} | ||
enum rs { | ||
description | ||
"The role of the BGP peer is Route Server (RS)."; | ||
} | ||
enum rs-client { | ||
description | ||
"The role of the BGP peer is RS-client."; | ||
} | ||
enum mutual-transit { | ||
description | ||
"The role of the BGP peer is mutual-transit."; | ||
} | ||
} | ||
description | ||
"Roles of BGP peers."; | ||
reference | ||
"RFC XXXX, BGP AS_PATH Verification Based on Autonomous | ||
System Provider Authorization (ASPA) Objects."; | ||
} | ||
|
||
typedef aspa-verification-state { | ||
type enumeration { | ||
enum valid { | ||
description | ||
"The ASPA verification outcome is valid."; | ||
} | ||
enum invalid { | ||
description | ||
"The ASPA verification outcome is invalid."; | ||
} | ||
enum unknown { | ||
description | ||
"The ASPA verification outcome is unknown."; | ||
} | ||
enum disabled { | ||
description | ||
"BGP ASPA verification is not enabled."; | ||
} | ||
} | ||
description | ||
"ASPA verification state of BGP routes."; | ||
reference | ||
"RFC XXXX, BGP AS_PATH Verification Based on Autonomous | ||
System Provider Authorization (ASPA) Objects."; | ||
} | ||
|
||
grouping aspa-config { | ||
description | ||
"ASPA verification of BGP prefix."; | ||
container aspa-verification { | ||
leaf enabled { | ||
type boolean; | ||
default "false"; | ||
description | ||
"Whether ASPA verification of BGP prefix is enabled."; | ||
} | ||
description | ||
"ASPA verification of BGP prefix."; | ||
} | ||
} | ||
|
||
grouping aspa-selection-option { | ||
description | ||
"ASPA option for BGP route selection."; | ||
container aspa { | ||
leaf enabled { | ||
type boolean; | ||
default "false"; | ||
description | ||
"When enabled allows the ASPA verification states to be | ||
taken into consideration in the best-path calculation."; | ||
} | ||
leaf allow-invalid { | ||
type boolean; | ||
default "false"; | ||
description | ||
"When enabled allows the route with 'invalid' ASPA | ||
verification state to be taken into consideration in | ||
the best-path calculation."; | ||
} | ||
leaf allow-unknown { | ||
type boolean; | ||
default "true"; | ||
description | ||
"When enabled allows the route with 'unknown' ASPA | ||
verification state to be taken into consideration in | ||
the best-path calculation."; | ||
} | ||
description | ||
"ASPA option for BGP route selection."; | ||
} | ||
} | ||
|
||
augment "/rt:routing/rt:control-plane-protocols" | ||
+ "/rt:control-plane-protocol/bgp:bgp/bgp:neighbors" | ||
+ "/bgp:neighbor" { | ||
description | ||
"augmentation of BGP peer roles for neighbors"; | ||
leaf peer-role { | ||
type peer-role; | ||
description | ||
"Role of the peer"; | ||
} | ||
} | ||
|
||
augment "/rt:routing/rt:control-plane-protocols" | ||
+ "/rt:control-plane-protocol/bgp:bgp/bgp:peer-groups" | ||
+ "/bgp:peer-group" { | ||
description | ||
"augmentation of BGP peer roles for peer groups"; | ||
leaf peer-role { | ||
type peer-role; | ||
description | ||
"Role of the peer group"; | ||
} | ||
} | ||
|
||
augment "/rt:routing/rt:control-plane-protocols" | ||
+ "/rt:control-plane-protocol/bgp:bgp/bgp:global" | ||
+ "/bgp:afi-safis/bgp:afi-safi/bgp:ipv4-unicast" { | ||
description | ||
"ASPA verification augmentation of BGP IPv4 Unicast | ||
Address Family."; | ||
uses aspa-config; | ||
} | ||
|
||
augment "/rt:routing/rt:control-plane-protocols" | ||
+ "/rt:control-plane-protocol/bgp:bgp/bgp:global" | ||
+ "/bgp:afi-safis/bgp:afi-safi/bgp:ipv6-unicast" { | ||
description | ||
"ASPA verification augmentation of BGP IPv6 Unicast | ||
Address Family."; | ||
uses aspa-config; | ||
} | ||
|
||
augment "/rt:routing/rt:control-plane-protocols" | ||
+ "/rt:control-plane-protocol/bgp:bgp/bgp:rib" | ||
+ "/bgp:afi-safis/bgp:afi-safi/bgp:ipv4-unicast" | ||
+ "/bgp:loc-rib/bgp:routes/bgp:route" { | ||
description | ||
"ASPA verification state augmentation of BGP IPv4 | ||
Unicast route."; | ||
leaf aspa-verification-state { | ||
type aspa-verification-state; | ||
description | ||
"ASPA verification state of BGP IPv4 Unicast prefix."; | ||
} | ||
} | ||
|
||
augment "/rt:routing/rt:control-plane-protocols" | ||
+ "/rt:control-plane-protocol/bgp:bgp/bgp:rib" | ||
+ "/bgp:afi-safis/bgp:afi-safi/bgp:ipv6-unicast" | ||
+ "/bgp:loc-rib/bgp:routes/bgp:route" { | ||
description | ||
"ASPA verification state augmentation of BGP IPv6 | ||
Unicast route."; | ||
leaf aspa-verification-state { | ||
type aspa-verification-state; | ||
description | ||
"ASPA verification state of BGP IPv6 Unicast prefix."; | ||
} | ||
} | ||
|
||
augment "/rt:routing/rt:control-plane-protocols" | ||
+ "/rt:control-plane-protocol/bgp:bgp/bgp:global" | ||
+ "/bgp:afi-safis/bgp:afi-safi" | ||
+ "/bgp:route-selection-options" { | ||
when "derived-from-or-self(../bgp:name, 'bt:ipv4-unicast') or " | ||
+ "derived-from-or-self(../bgp:name, 'bt:ipv6-unicast')" { | ||
description | ||
"This augmentation is valid for IPv4 and IPv6 Unicast."; | ||
} | ||
description | ||
"augmentation of BGP route selection options"; | ||
uses aspa-selection-option; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.