CVE-2023-47234
📋 TL;DR
A vulnerability in FRRouting FRR allows remote attackers to cause a denial of service (crash) by sending a specially crafted BGP UPDATE message with a MP_UNREACH_NLRI attribute containing malformed NLRI data. This affects FRR installations that process BGP traffic, primarily network routers and devices running vulnerable FRR versions.
💻 Affected Systems
- FRRouting FRR
📦 What is this software?
Frrouting by Frrouting
⚠️ Risk & Real-World Impact
Worst Case
Complete service disruption of BGP routing, causing network outages and potential cascading failures in dependent systems.
Likely Case
Service crash requiring manual restart of FRR daemon, leading to temporary routing instability and packet loss.
If Mitigated
Isolated crash of FRR process with automatic restart mechanisms limiting downtime to seconds/minutes.
🎯 Exploit Status
Exploitation requires sending a crafted BGP packet to a vulnerable peer, which is straightforward for attackers with BGP protocol knowledge.
🛠️ Fix & Mitigation
✅ Official Fix
Patch Version: Fixed in commit c37119df45bbf4ef713bc10475af2ee06e12f3bf and later versions
Vendor Advisory: https://github.com/FRRouting/frr/pull/14716/commits/c37119df45bbf4ef713bc10475af2ee06e12f3bf
Restart Required: Yes
Instructions:
1. Update FRR to version after 9.0.1 or apply commit c37119df45bbf4ef713bc10475af2ee06e12f3bf. 2. Restart FRR services (bgpd). 3. Verify BGP sessions re-establish properly.
🔧 Temporary Workarounds
BGP Peer Filtering
linuxRestrict BGP connections to trusted peers only using access control lists
ip prefix-list TRUSTED-PEERS seq 5 permit 192.0.2.0/24
router bgp 65001
neighbor 192.0.2.1 prefix-list TRUSTED-PEERS in
TCP MD5 Authentication
linuxEnable TCP MD5 authentication for BGP sessions to prevent unauthorized connections
router bgp 65001
neighbor 192.0.2.1 password mysecretpassword
🧯 If You Can't Patch
- Implement strict BGP peer filtering to only allow connections from trusted sources
- Deploy network monitoring to detect anomalous BGP traffic patterns and restart FRR if crashes occur
🔍 How to Verify
Check if Vulnerable:
Check FRR version: frr --version. If version is 9.0.1 or earlier and BGP is enabled, system is vulnerable.
Check Version:
frr --version
Verify Fix Applied:
Verify FRR version is after 9.0.1 and check commit history includes c37119df45bbf4ef713bc10475af2ee06e12f3bf.
📡 Detection & Monitoring
Log Indicators:
- FRR bgpd process crashes
- BGP session resets with malformed UPDATE messages in logs
- Unexpected bgpd restarts in system logs
Network Indicators:
- BGP UPDATE messages with MP_UNREACH_NLRI attribute from untrusted sources
- Abnormal BGP packet sizes or structures
SIEM Query:
source="frr.log" AND "bgpd" AND ("crash" OR "segmentation fault" OR "malformed UPDATE")
🔗 References
- https://github.com/FRRouting/frr/pull/14716/commits/c37119df45bbf4ef713bc10475af2ee06e12f3bf
- https://lists.debian.org/debian-lts-announce/2024/04/msg00019.html
- https://github.com/FRRouting/frr/pull/14716/commits/c37119df45bbf4ef713bc10475af2ee06e12f3bf
- https://lists.debian.org/debian-lts-announce/2024/04/msg00019.html
- https://lists.debian.org/debian-lts-announce/2024/09/msg00007.html