Description
Meshtastic is an open source mesh networking solution. Prior to v2.6.3, an attacker can send NodeInfo with a empty publicKey first, then overwrite it with a new key. First sending a empty key bypasses 'if (p.public_key.size > 0) {', clearing the existing publicKey (and resetting the size to 0) for a known node. Then a new key bypasses 'if (info->user.public_key.size > 0) {', and this malicious key is stored in NodeDB. This vulnerability is fixed in 2.6.3.
EPSS Score:
0%
Comprehensive Technical Analysis of EUVD-2025-25140
1. Vulnerability Assessment and Severity Evaluation
The vulnerability described in EUVD-2025-25140 affects Meshtastic, an open-source mesh networking solution. The issue arises from a flaw in the handling of NodeInfo messages, specifically in the way public keys are processed. An attacker can exploit this vulnerability by first sending a NodeInfo message with an empty public key, which bypasses a conditional check and clears the existing public key for a known node. Subsequently, the attacker can send a new public key, which is then stored in the NodeDB without proper validation.
Severity Evaluation:
- Base Score: 9.4 (CVSS:3.1)
- Vector String: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:L
The high base score indicates a critical vulnerability due to the following factors:
- Attack Vector (AV:N): The vulnerability can be exploited over the network.
- Attack Complexity (AC:L): The attack is relatively simple to execute.
- Privileges Required (PR:N): No special privileges are required.
- User Interaction (UI:N): No user interaction is needed.
- Scope (S:U): The impact is unchanged.
- Confidentiality (C:H): High impact on confidentiality.
- Integrity (I:H): High impact on integrity.
- Availability (A:L): Low impact on availability.
2. Potential Attack Vectors and Exploitation Methods
Attack Vectors:
- Network-Based Attack: An attacker can send malicious
NodeInfomessages over the network to exploit the vulnerability. - Man-in-the-Middle (MitM) Attack: An attacker intercepting network traffic can inject malicious
NodeInfomessages.
Exploitation Methods:
- Initial Exploitation: Send a
NodeInfomessage with an empty public key to bypass the initial check and clear the existing public key. - Secondary Exploitation: Send a new
NodeInfomessage with a malicious public key, which is then stored in theNodeDB.
3. Affected Systems and Software Versions
Affected Systems:
- Meshtastic firmware versions prior to 2.6.3.
Software Versions:
- All versions of Meshtastic firmware before 2.6.3 are vulnerable.
4. Recommended Mitigation Strategies
Immediate Mitigation:
- Upgrade Firmware: Upgrade to Meshtastic firmware version 2.6.3 or later, which includes the fix for this vulnerability.
Long-Term Mitigation:
- Network Segmentation: Implement network segmentation to limit the exposure of vulnerable devices.
- Monitoring and Logging: Enhance monitoring and logging to detect and respond to suspicious network activities.
- Access Controls: Implement strict access controls to limit unauthorized access to the network.
5. Impact on European Cybersecurity Landscape
The vulnerability in Meshtastic, an open-source mesh networking solution, poses a significant risk to the European cybersecurity landscape, particularly in environments where mesh networking is used for critical infrastructure, IoT devices, and other sensitive applications. The ability to manipulate public keys can lead to unauthorized access, data breaches, and potential disruption of services.
Regulatory Compliance:
- Organizations using Meshtastic should ensure compliance with relevant EU regulations, such as GDPR and NIS Directive, by implementing appropriate security measures and incident response plans.
6. Technical Details for Security Professionals
Vulnerability Details:
- The vulnerability arises from improper handling of
NodeInfomessages, specifically in the way public keys are processed. - The conditional checks
if (p.public_key.size > 0)andif (info->user.public_key.size > 0)are bypassed by sending an empty public key, which clears the existing key and allows a new malicious key to be stored.
Code Analysis:
- Review the codebase for similar conditional checks and ensure proper validation of public keys.
- Implement additional security checks to prevent the storage of malicious keys in the
NodeDB.
References:
Conclusion: The vulnerability in Meshtastic firmware versions prior to 2.6.3 is critical and requires immediate attention. Organizations should prioritize upgrading to the latest firmware version and implement additional security measures to mitigate the risk. The European cybersecurity landscape must remain vigilant against such vulnerabilities to protect critical infrastructure and sensitive data.