1
0
mirror of https://gitlab.labs.nic.cz/labs/bird.git synced 2024-05-11 16:54:54 +00:00

OSPF: Opaque LSAs and Router Information LSA

Add support for OSPFv2 Opaque LSAs (RFC 5250) and for Router Information
LSA (RFC 7770). The second part is here mainly for testing opaque LSAs.
This commit is contained in:
Ondrej Zajicek (work)
2019-01-24 22:34:33 +01:00
parent 3e60932a28
commit 5a50a98980
9 changed files with 224 additions and 40 deletions

View File

@@ -127,7 +127,7 @@ ospf_prepare_dbdes(struct ospf_proto *p, struct ospf_neighbor *n)
{
struct ospf_dbdes2_packet *ps = (void *) pkt;
ps->iface_mtu = htons(iface_mtu);
ps->options = ifa->oa->options;
ps->options = ifa->oa->options | OPT_O;
ps->imms = 0; /* Will be set later */
ps->ddseq = htonl(n->dds);
length = sizeof(struct ospf_dbdes2_packet);
@@ -162,7 +162,8 @@ ospf_prepare_dbdes(struct ospf_proto *p, struct ospf_neighbor *n)
}
if ((en->lsa.age < LSA_MAXAGE) &&
lsa_flooding_allowed(en->lsa_type, en->domain, ifa))
lsa_flooding_allowed(en->lsa_type, en->domain, ifa) &&
lsa_is_acceptable(en->lsa_type, n, p))
{
lsa_hton_hdr(&(en->lsa), lsas + i);
i++;