sonic-buildimage/dockers
abdosi 7059f42385
[chassis/multi-asic] Make sure iBGP session established as directly connected (#16777)
What I did:
Make Sure for internal iBGP we are one-hop away (directly connected) by using Generic TTL security mechanism.

Why I did:
Without this change it's possible on packet chassis i-BGP can be established even if there no direct connection. Below is the example

- Let's say we have 3 LC's LC1/LC2/LC3 each having i-BGP session session with each other over Loopback4096
- Each LC's have static route towards other LC's Loopback4096 to establish i-BGP session
- LC1 learn default route 0.0.0.0/0 from it's e-BGP peers and send it over to LC2 and LC3 over i-BGP
- Now for some reason on LC2 static route towards LC3 is removed/not-present/some-issue we expect i-BGP session should go down between LC2 and LC3
- However i-BGP between LC2 and LC3 does not go down because of feature ip nht-resolve-via-default  where LC2 will use default route to reach Loopback4096 of LC3. As it's using default route BGP packets from LC2 towards LC3 will first route to LC1 and then go to LC3 from there.

Above scenario can result in packet mis-forwarding on data plane

How I fixed it:-

To make sure BGP packets between i-BGP peers are not going with extra routing hop enable using GTSM feature

neighbor PEER ttl-security hops NUMBER

This command enforces Generalized TTL Security Mechanism (GTSM), as specified in RFC 5082. With this command, only neighbors that are the specified number of hops away will be allowed to become neighbors. This command is mutually exclusive with ebgp-multihop.

We set hop count as 1 which makes FRR to reject BGP connection if we receive BGP packets if it's TTL < 255. Also setting this attribute make sure i-BGP frames are originated with IP TTL of 255.

How I verify:

Manual Verification of above scenario. See blow BGP packets receive with IP TTL 254 (additional routing hop) we are seeing FIN TCP flags as BGP is rejecting the connection

Signed-off-by: Abhishek Dosi <abdosi@microsoft.com>
2023-10-10 11:51:40 -07:00
..
docker-base Improve remote fetch (#12795) 2023-09-23 18:07:04 -07:00
docker-base-bullseye [infra] Support syslog rate limit configuration (#12490) 2022-12-20 10:53:58 +02:00
docker-base-buster Improve remote fetch (#12795) 2023-09-23 18:07:04 -07:00
docker-base-stretch Improve remote fetch (#12795) 2023-09-23 18:07:04 -07:00
docker-basic_router [supervisord]: use abspath as supervisord entrypoint (#5995) 2020-11-22 21:18:44 -08:00
docker-config-engine Install python-redis package to docker containers (#14632) 2023-04-19 18:14:48 -07:00
docker-config-engine-bullseye Load generic omprog in all dockers for rsyslog plugin support (#16601) 2023-09-20 16:27:42 -07:00
docker-config-engine-buster [Build] Fix the PyYang python package installation issue (#15890) 2023-07-19 06:33:49 +08:00
docker-config-engine-stretch Install python-redis package to docker containers (#14632) 2023-04-19 18:14:48 -07:00
docker-database [database] make Redis process runs as non-root user (#16326) 2023-09-01 23:03:15 -07:00
docker-dhcp-relay Fix regex and process name (#16647) 2023-09-26 16:15:27 -07:00
docker-dhcp-server [dhcp_server] Add dhcp_server container (#14031) 2023-09-11 09:15:56 -07:00
docker-eventd Timezone sync issue between the host and containers (#14000) 2023-06-25 16:36:09 -07:00
docker-fpm-frr [chassis/multi-asic] Make sure iBGP session established as directly connected (#16777) 2023-10-10 11:51:40 -07:00
docker-fpm-gobgp Parallel building of sonic dockers using native dockerd(dood). (#10352) 2022-04-28 08:39:37 +08:00
docker-iccpd Timezone sync issue between the host and containers (#14000) 2023-06-25 16:36:09 -07:00
docker-lldp Timezone sync issue between the host and containers (#14000) 2023-06-25 16:36:09 -07:00
docker-macsec Update macsec CAK keys in profile for tests to change to type7 encoded format (#16388) 2023-09-06 21:11:02 -07:00
docker-mux Timezone sync issue between the host and containers (#14000) 2023-06-25 16:36:09 -07:00
docker-nat Timezone sync issue between the host and containers (#14000) 2023-06-25 16:36:09 -07:00
docker-orchagent Enable ZMQ between GNMI and Orchanget (#16661) 2023-10-09 14:22:50 -07:00
docker-pde [infra] Support syslog rate limit configuration (#12490) 2022-12-20 10:53:58 +02:00
docker-platform-monitor [pmon] update gRPC version to 1.57.0 (#16257) 2023-09-15 16:41:51 -07:00
docker-ptf Upgrade gnxi to support dash (#16498) 2023-09-08 08:56:51 -07:00
docker-ptf-sai [build] Fix build issue in docker-ptf-sai caused by setuptools_scm new release (#16636) 2023-09-21 10:38:08 -07:00
docker-router-advertiser Timezone sync issue between the host and containers (#14000) 2023-06-25 16:36:09 -07:00
docker-sflow Timezone sync issue between the host and containers (#14000) 2023-06-25 16:36:09 -07:00
docker-snmp [SNMP][IPv6]: Fix to use link local IPv6 address as snmp agentAddress (#16013) 2023-08-08 14:47:33 -07:00
docker-sonic-mgmt [sonic-mgmt]: Added required python packages to run MSFT hero Test cases (#15883) 2023-09-27 18:13:44 -07:00
docker-sonic-mgmt-framework Timezone sync issue between the host and containers (#14000) 2023-06-25 16:36:09 -07:00
docker-sonic-p4rt Timezone sync issue between the host and containers (#14000) 2023-06-25 16:36:09 -07:00
docker-sonic-restapi [infra] Support syslog rate limit configuration (#12490) 2022-12-20 10:53:58 +02:00
docker-sonic-sdk [Bullseye] Upgrade sonic-sdk image to bullseye (#12649) 2022-11-28 18:57:26 +02:00
docker-sonic-sdk-buildenv Parallel building of sonic dockers using native dockerd(dood). (#10352) 2022-04-28 08:39:37 +08:00
docker-sonic-telemetry Enable ZMQ between GNMI and Orchanget (#16661) 2023-10-09 14:22:50 -07:00
docker-swss-layer-bullseye Add ping to swss-layer docker (#11093) 2022-06-10 07:40:37 -07:00
docker-swss-layer-buster Add ping to swss-layer docker (#11093) 2022-06-10 07:40:37 -07:00
docker-teamd Timezone sync issue between the host and containers (#14000) 2023-06-25 16:36:09 -07:00
dockerfile-macros.j2 [sonic-config-engine] Clean up dependencies, pin versions; install Python 3 package in Buster container (#5656) 2020-10-26 13:48:50 -07:00