diff options
author | Ondrej Zajicek (work) <santiago@crfreenet.org> | 2019-01-24 22:34:33 +0100 |
---|---|---|
committer | Ondrej Zajicek (work) <santiago@crfreenet.org> | 2019-01-24 22:45:27 +0100 |
commit | 5a50a98980a3554b66cedda6992ece4063a0e85a (patch) | |
tree | d8ff938c5b9712ca7788256aab3fff96f98ad7ac /proto/ospf/dbdes.c | |
parent | 3e60932a289e55e212dec1cbaf3bca44b2bbaeb8 (diff) |
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.
Diffstat (limited to 'proto/ospf/dbdes.c')
-rw-r--r-- | proto/ospf/dbdes.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/proto/ospf/dbdes.c b/proto/ospf/dbdes.c index 019aff04..34665dad 100644 --- a/proto/ospf/dbdes.c +++ b/proto/ospf/dbdes.c @@ -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++; |