crip/ripv2/types.go
Jim Colderwood 210141b8d5 refactoring
2024-04-25 14:39:46 +01:00

39 lines
418 B
Go

package ripv2
type Command uint8
type FIB uint8
type Version uint8
const (
ZERO Command = iota
REQUEST
RESPONSE
)
const (
NEW FIB = iota
TABLE
DELETE
)
const (
RIPv1 Version = iota + 1
RIPv2
)
type Message struct {
Command Command
Version Version
Zero uint16
RIP []RIP
}
type RIP struct {
AFI uint16
RouteTag uint16
Addr uint32
Subnet uint32
NextHop uint32
Metric uint32
}