1@node  Zebra Protocol, Packet Binary Dump Format, SNMP Support, Top
2@comment  node-name,  next,  previous,  up
3@appendix Zebra Protocol
4
5Zebra Protocol is a protocol which is used between protocol daemon and
6zebra.  Each protocol daemon sends selected routes to zebra daemon.  Then
7zebra manages which route is installed into the forwarding table.
8
9Zebra Protocol is a TCP-based protocol.  Below is common header of Zebra
10Protocol.
11
12@example
13@group
140                   1                   2                   3
150 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
16+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
17|           Length (2)          |   Command (1) |
18+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
19@end group
20@end example
21
22Length is total packet length including this header length.  So minimum
23length is three.  Command is Zebra Protocol command.
24
25@example
26ZEBRA_INTERFACE_ADD                1
27ZEBRA_INTERFACE_DELETE             2
28ZEBRA_INTERFACE_ADDRESS_ADD        3
29ZEBRA_INTERFACE_ADDRESS_DELETE     4
30ZEBRA_INTERFACE_UP                 5
31ZEBRA_INTERFACE_DOWN               6
32ZEBRA_IPV4_ROUTE_ADD               7
33ZEBRA_IPV4_ROUTE_DELETE            8
34ZEBRA_IPV6_ROUTE_ADD               9
35ZEBRA_IPV6_ROUTE_DELETE           10
36ZEBRA_REDISTRIBUTE_ADD            11
37ZEBRA_REDISTRIBUTE_DELETE         12
38ZEBRA_REDISTRIBUTE_DEFAULT_ADD    13
39ZEBRA_REDISTRIBUTE_DEFAULT_DELETE 14
40ZEBRA_IPV4_NEXTHOP_LOOKUP         15
41ZEBRA_IPV6_NEXTHOP_LOOKUP         16
42@end example
43
44@example
45@group
460                   1                   2                   3
470 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
48+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
49|             Type              |             Flags             |
50+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
51@end group
52@end example
53