]> git.ipfire.org Git - thirdparty/bird.git/commitdiff
BGP: strict bind clarification comment
authorMaria Matejka <mq@ucw.cz>
Tue, 7 Oct 2025 10:30:13 +0000 (12:30 +0200)
committerMaria Matejka <mq@ucw.cz>
Thu, 13 Nov 2025 11:25:03 +0000 (12:25 +0100)
proto/bgp/bgp.c

index 32e61f700402fde2653eb7af84679f537679cb53..7bd7f37431cf109302a9b5663212090efdcb3fc4 100644 (file)
@@ -688,7 +688,11 @@ bgp_open(struct bgp_proto *p)
   LOCK_DOMAIN(rtable, bgp_listen_domain);
 
   struct bgp_listen_request *req = &p->listen;
-  /* We assume that cf->iface is defined iff cf->local_ip is link-local */
+
+  /* If strict_bind is set, we need local_ip and maybe also iface. Mandatory if
+   * local_ip is link-local. If strict_bind is not set, we bind to all addresses
+   * of that family and match the local IP later when accepting the connection. */
+
   req->params.iface = p->cf->strict_bind ? p->cf->iface : NULL;
   req->params.vrf = p->p.vrf;
   req->params.addr = p->cf->strict_bind ? p->cf->local_ip :