Skip to content
Permalink
Branch: master
Find file Copy path
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
138 lines (116 sloc) 8.59 KB
syntax = "proto3";
package vpp.srv6;
option go_package = "github.com/ligato/vpp-agent/api/models/vpp/srv6;vpp_srv6";
import "github.com/gogo/protobuf/gogoproto/gogo.proto";
option (gogoproto.messagename_all) = true;
message LocalSID {
string sid = 1; /* segment id (IPv6 Address) */
uint32 installation_vrf_id = 2; /* ID of IPv6 VRF table where to install LocalSID routing components
(LocalSids with End.AD function ignore this setting due to missing setting
in the API. The End.AD functionality is separated from the SRv6 functionality
and have no binary API. It has only the CLI API and that doesn't have
the installation vrf id (in VPP API called FIB table) setting configurable.)
Non-zero VRF has to be explicitly created (see api/models/vpp/l3/vrf.proto) */
/* Configuration for end functions (all end functions are mutually exclusive) */
oneof end_function {
End base_end_function = 3;
EndX end_function_X = 4;
EndT end_function_T = 5;
EndDX2 end_function_DX2 = 6;
EndDX4 end_function_DX4 = 7;
EndDX6 end_function_DX6 = 8;
EndDT4 end_function_DT4 = 9;
EndDT6 end_function_DT6 = 10;
EndAD end_function_AD = 11;
}
/* TODO recheck whether PSP is not Localsid-scoped setting instead of some-end-functions-scoped setting */
/* End function behavior of simple endpoint */
message End {
bool psp = 1; /* use PSP (penultimate segment POP of the SRH) or by default use USP (Ultimate Segment Pop of the SRH) */
}
/* End function behavior of endpoint with Layer-3 cross-connect (IPv6) */
message EndX {
bool psp = 1; /* use PSP (penultimate segment POP of the SRH) or by default use USP (Ultimate Segment Pop of the SRH) */
string outgoing_interface = 2; /* name of cross-connected outgoing interface */
string next_hop = 3; /* IPv6 next hop address for cross-connected link */
}
/* End function behavior of endpoint with specific IPv6 table lookup*/
message EndT {
bool psp = 1; /* use PSP (penultimate segment POP of the SRH) or by default use USP (Ultimate Segment Pop of the SRH) */
uint32 vrf_id = 2; /* vrf index of IPv6 table that should be used for lookup.
vrf_index and fib_table_id should refer to the same routing table. VRF index refer to it from client side
and FIB table id from VPP-internal side (index of memory allocated structure from pool)(source: https://wiki.fd.io/view/VPP/Per-feature_Notes).
Non-zero VRF has to be explicitly created (see api/models/vpp/l3/vrf.proto) */
}
/* End function behavior of endpoint with decapsulation and Layer-2 cross-connect (or DX2 with egress VLAN rewrite when VLAN notzero - not supported this variant yet)*/
message EndDX2 {
uint32 vlan_tag = 1; /* Outgoing VLAN tag */
string outgoing_interface = 2; /* name of cross-connected outgoing interface */
}
/* End function behavior of endpoint with decapsulation and IPv4 cross-connect*/
message EndDX4 {
string outgoing_interface = 1; /* name of cross-connected outgoing interface */
string next_hop = 2; /* next hop address for cross-connected link */
}
/* End function behavior of endpoint with decapsulation and IPv6 cross-connect*/
message EndDX6 {
string outgoing_interface = 1; /* name of cross-connected outgoing interface */
string next_hop = 2; /* next hop address for cross-connected link */
}
/* End function behavior of endpoint with decapsulation and specific IPv4 table lookup*/
message EndDT4 {
uint32 vrf_id = 1; /* vrf index of IPv4 table that should be used for lookup.
vrf_index and fib_table_id should refer to the same routing table. VRF index refer to it from client side
and FIB table id from VPP-internal side (index of memory allocated structure from pool)(source: https://wiki.fd.io/view/VPP/Per-feature_Notes).
Non-zero VRF has to be explicitly created (see api/models/vpp/l3/vrf.proto) */
}
/* End function behavior of endpoint with decapsulation and specific IPv6 table lookup*/
message EndDT6 {
uint32 vrf_id = 1; /* vrf index of IPv6 table that should be used for lookup.
vrf_index and fib_table_id should refer to the same routing table. VRF index refer to it from client side
and FIB table id from VPP-internal side (index of memory allocated structure from pool)(source: https://wiki.fd.io/view/VPP/Per-feature_Notes).
Non-zero VRF has to be explicitly created (see api/models/vpp/l3/vrf.proto) */
}
/* End function behavior of dynamic segment routing proxy endpoint */
message EndAD {
string outgoing_interface = 2; /* name of interface on segment routing proxy side sending data to segment routing unaware service */
string incoming_interface = 3; /* name of interface on segment routing proxy side receiving data from segment routing unaware service */
string l3_service_address = 4; /* IPv6/IPv4 address of L3 SR-unaware service (address type depends whether service is IPv4 or IPv6 service), in case of L2 service it must be empty */
}
}
/* Model for SRv6 policy (policy without at least one policy segment is only cached in ligato and not written to VPP)*/
message Policy {
string bsid = 1; /* binding SID (IPv6 Address) */
uint32 installation_vrf_id = 2; /* ID of IPv6 VRF table where to install Policy routing components (for loadbalancing/spray are used VPP features that are using VRF table)
Non-zero VRF has to be explicitly created (see api/models/vpp/l3/vrf.proto) */
bool srh_encapsulation = 3; /* are SR headers handled by encapsulation? (no means insertion of SR headers) */
bool spray_behaviour = 4; /* spray(multicast) to all policy segments? (no means to use PolicySegment.weight to loadbalance traffic)*/
/* Model for SRv6 Segment List */
message SegmentList {
uint32 weight = 1; /* used for loadbalancing in case of multiple policy segments in routing process (ignored in case of spray policies) */
repeated string segments = 2; /* list of sids creating one segmented road */
}
repeated SegmentList segment_lists = 5;
}
/* Model for steering traffic to SRv6 policy */
message Steering {
string name = 5; /* globally unique steering identification (used in keys when is steering stored in key-value stores(i.e. ETCD)) */
/* Referencing policy that should be used for steering traffic into (all policy references are mutual exclusive)*/
oneof policy_ref {
string policy_bsid = 1; /* BSID identifier for policy to which we want to steer routing into (policyBSID and policyIndex are mutual exclusive) */
uint32 policy_index = 2; /* (vpp-internal)Index identifier for policy to which we want to steer routing into (policyBSID and policyIndex are mutual exclusive) */
}
/* Traffic configuration (all traffic messages are mutual exclusive)*/
oneof traffic {
L2Traffic l2_traffic = 3;
L3Traffic l3_traffic = 4;
}
message L2Traffic { /* L2 traffic that should be steered into SR policy */
string interface_name = 1; /* name of interface with incoming traffic that should be steered to SR policy */
}
message L3Traffic { /* L3 traffic that should be steered into SR policy */
uint32 installation_vrf_id = 1; /* ID of IPv4/IPv6 VRF table where to install L3 Steering routing components (VRF table type (IPv4/IPv6) is decided by prefix_address value)
Non-zero VRF has to be explicitly created (see api/models/vpp/l3/vrf.proto) */
string prefix_address = 2; /* IPv4/IPv6 prefix address(CIRD format) of traffic destination. All traffic with given destination will be steered to given SR policy */
}
}
You can’t perform that action at this time.