forked from Mirror/frr
ripd: add non-zero check for RIPv1 reserved field,
According to RFC2453 3.6, the tag of a RIP-1 entry should be zero Signed-off-by: zmw12306 <zmw12306@gmail.com>
This commit is contained in:
parent
9b96394d05
commit
762f54f088
|
@ -1171,6 +1171,12 @@ static void rip_response_process(struct rip_packet *packet, int size,
|
|||
continue;
|
||||
}
|
||||
|
||||
if (packet->version == RIPv1 && rte->tag != 0) {
|
||||
zlog_warn("RIPv1 reserved field is nonzero: %d",
|
||||
ntohs(rte->tag));
|
||||
continue;
|
||||
}
|
||||
|
||||
/* - is the destination address valid (e.g., unicast; not net 0
|
||||
or 127) */
|
||||
if (!rip_destination_check(rte->prefix)) {
|
||||
|
|
Loading…
Reference in a new issue