Junos OS routing IDL - Protocol Documentation

Table of Contents

prpd_common.proto

Top

$Id$

Copyright (c) 2016, Juniper Networks, Inc. All rights reserved.

L3vpnAddress

L3VPN route destination address prefix composed of a route distinguisher (RD) and IP address.

FieldTypeLabelDescription
rd RouteDistinguisher optional

Route distinguisher. [REQUIRED]

vpn_addr IpAddress optional

IPv4 or IPv6 VPN customer address. [REQUIRED].

LabelEntry

A single MPLS Label entry as defined by RFC 3032

FieldTypeLabelDescription
label uint32 optional

One of either well_known_labels or else a valid 20-bit unsigned label value that must be less than decimal value 1048576 and not within the reserved label range of 4 through 15 (inclusive). [REQUIRED]

traffic_class uint32 optional

A valid 3-bit unsigned traffic class/QoS value less than decimal value 8. [OPTIONAL] (defaults to 0). READ-ONLY

ttl uint32 optional

A valid 8-bit unsigned TTL value less than decimal value 256. [OPTIONAL] (defaults to 0). READ-ONLY

bottom_of_stack bool optional

Indicates that this Label stack entry the bottom of the label stack. Bottom-of-Stack will always be set by the library and must never set by the client. READ-ONLY

LabelStack

A label stack constructed according to the rules of RFC 3032.

FieldTypeLabelDescription
entries LabelStackEntry repeated

An ordered list of one or more label stack entries beginning with the bottom of the stack and ending with the top of the stack. [REQUIRED] (one or more entry)

LabelStackEntry

A single MPLS Label stack entry with the operation for the label entry

FieldTypeLabelDescription
opcode LabelOperation optional

Label Operation

label_entry LabelEntry optional

Label Entry

MplsAddress

Holds the mpls label used to represent label address in route lookups

FieldTypeLabelDescription
label uint32 optional

A valid 20-bit unsigned label value that must be less than decimal value 1048576 and not within the reserved label range of 4 through 15 (inclusive). [REQUIRED]

NetworkAddress

Network Address defined for each supported address family

FieldTypeLabelDescription
inet IpAddress optional

IPv4 destination prefix

inet6 IpAddress optional

IPv6 destination prefix

mpls MplsAddress optional

Mpls label. For modifying route table contents, the only valid prefix length is 52 (20 bit label + 32 bit interface index). Interface index is currently implicit and defaults to 0. For route lookups, use a prefix length of 52 for exact lookups and 0 for matching all the routes.

RdType0

RFC 4364 Route type 0: 2-byte AS and assigned number

FieldTypeLabelDescription
as_number uint32 optional

2 byte AS number

assigned_number uint32 optional

4 byte assigned number subfield

RdType1

RFC 4364 Route type 1: IPv4 address and assigned number

FieldTypeLabelDescription
ip_address IpAddress optional

4 byte IP address

assigned_number uint32 optional

2 byte assigned number subfield

RdType2

RFC 4364 Route type 2: 4-byte AS and assigned number

FieldTypeLabelDescription
as_number uint32 optional

4 byte AS number

assigned_number uint32 optional

RouteDistinguisher

An RFC 4364 route distinguisher to distinguish customer VPN routes within the BGP NLRIs. Valid RD can be type 0, type 1, or type 2.

FieldTypeLabelDescription
rd0 RdType0 optional

Type 0 RD

rd1 RdType1 optional

Type 1 RD

rd2 RdType2 optional

Type 2 RD

RoutePrefix

Route destination prefix defined for each supported address family

FieldTypeLabelDescription
inet IpAddress optional

IPv4 destination prefix

inet6 IpAddress optional

IPv6 destination prefix

inetvpn L3vpnAddress optional

IPv4 VPN (L3VPN) destination prefix

inet6vpn L3vpnAddress optional

IPv6 VPN (L3VPN) destination prefix

labeled_inet IpAddress optional

IPv4 Labeled-Unicast destination prefix.

labeled_inet6 IpAddress optional

IPv6 Labeled-Unicast destination prefix.

RouteTable

Routing table (RIB), which may either be specified as a string or RPD table ID.

FieldTypeLabelDescription
rtt_id RouteTableId optional

Table id to which the route belongs

rtt_name RouteTableName optional

Table name to which the route belongs

RouteTableId

Routing table identifier as an integer value uniquely identifying a table.

FieldTypeLabelDescription
id uint32 optional

Table identifier. [REQUIRED]

RouteTableName

Routing table (RIB) name uniquely identifying a route table, formatted as a string per JUNOS convention.

FieldTypeLabelDescription
name string optional

Table name. [REQUIRED]

LabelEntry.WellKnownLabels

Well-known label values defined by RFC 3032. These must only be used in label stacks in accordance with the rules of RFC 3032.

NameNumberDescription
IPV4_EXPLICIT_NULL_LABEL 0

IPv4 Explicit NULL: valid only at bottom of stack

ROUTER_ALERT_LABEL 1

Router Alert: valid anywhere in a label stack except bottom

IPV6_EXPLICIT_NULL_LABEL 2

IPv6 Explict NULL: valid only at bottom of stack

IMPLICIT_NULL_LABEL 3

Implicit NULL: See RFC 3032

LabelOperation

Label operations

NameNumberDescription
NOOP 0

No Operation

POP 1

POP

PUSH 2

PUSH

SWAP 3

SWAP

ReturnCode

Different types of return codes to be sent back to client based on the operation was successful or not and if not, possibly more specific reasons as to why it failed.

NameNumberDescription
RET_SUCCESS 0

Operation was executed successfully

RET_FAILURE 1

General failure : operation not executed successfully

RET_NOT_FOUND 2

Entry was not found

RET_INVALID_PARAMS 3

Invalid input paramters

RouteAfType

Routing table destination address families.

NameNumberDescription
RT_AF_UNSPEC 0

Unspecified

RT_AF_INET 1

IPv4 destination prefix

RT_AF_INET6 2

IPv6 destination prefix

RT_AF_INETVPN 3

IPv4 VPN (L3VPN) destination prefix

RT_AF_INET6VPN 4

IPv6 VPN (L3VPN) destination prefix

RT_AF_LABELED_INET 5

IPv4 Labeled-Unicast destination prefix.

RT_AF_LABELED_INET6 6

IPv6 Labeled-Unicast destination prefix.

RouteProtoType

Protocol types that define protocols that added the route. RTPROTO_OTHER denotes other internal protocols currently not exposed to API.

NameNumberDescription
ANY 0

Matches any protocol

DIRECT 1

route is directly connected

LOCAL 2

route to local side of P2P interface

KERNEL 3

route was installed in kernel previously

REDIRECT 4

route was received via a redirect

OSPF 5

OSPF2 AS Internal routes

OSPF3 6

OSPF3 AS Internal routes

OSPF_ANY 7

OSPF AS Internal routes

RIP 8

Routing Information protocol

RIPNG 9

Routing Information protocol for v6

BGP 10

Border gateway protocol

STATIC 11

route is static

ISIS 12

IS-IS

IGMP 13

For IGMP stuff

AGGREGATE 14

Aggregate route

DVMRP 15

Distance Vector Multicast Routing Protocol

PIM 16

Protocol Independent Multicast

MSDP 17

Multicast Source Discovery Protocol

MPLS 18

MPLS switching

RSVP 19

RSVP

CCC 20

Circuit Cross-Connect

LDP 21

LDP

VPN 22

VPN protocol, L3

MVPN 23

MVPN protocol, L3

MCAST 24

multicast info

L2VPN 25

VPN protocol, L2

L2CKT 26

l2circuit protocol

BGP_STATIC 27

BGP Static

OTHER 28

Protocols not exposed and internal to Routing backend

RouteTableFormat

The table format allows the client to request the format that the server should use to represent tables in replies sent by the server to the client.

NameNumberDescription
TABLE_STRING 0

The server will represent tables by name as strings

TABLE_ID 1

The server will represent tables by RPD table ID

Scalar Value Types

.proto TypeNotesC++ TypeJava TypePython Type
double double double float
float float float float
int32 Uses variable-length encoding. Inefficient for encoding negative numbers – if your field is likely to have negative values, use sint32 instead. int32 int int
int64 Uses variable-length encoding. Inefficient for encoding negative numbers – if your field is likely to have negative values, use sint64 instead. int64 long int/long
uint32 Uses variable-length encoding. uint32 int int/long
uint64 Uses variable-length encoding. uint64 long int/long
sint32 Uses variable-length encoding. Signed int value. These more efficiently encode negative numbers than regular int32s. int32 int int
sint64 Uses variable-length encoding. Signed int value. These more efficiently encode negative numbers than regular int64s. int64 long int/long
fixed32 Always four bytes. More efficient than uint32 if values are often greater than 2^28. uint32 int int
fixed64 Always eight bytes. More efficient than uint64 if values are often greater than 2^56. uint64 long int/long
sfixed32 Always four bytes. int32 int int
sfixed64 Always eight bytes. int64 long int/long
bool bool boolean boolean
string A string must always contain UTF-8 encoded or 7-bit ASCII text. string String str/unicode
bytes May contain any arbitrary sequence of bytes. string ByteString str