Remote code execution in MikroTik RouterOS



Published: 2018-03-16 | Updated: 2022-09-08
Risk Medium
Patch available YES
Number of vulnerabilities 1
CVE-ID CVE-2018-7445
CWE-ID CWE-121
Exploitation vector Local network
Public exploit Vulnerability #1 is being exploited in the wild.
Vulnerable software
Subscribe
MikroTik RouterOS
Hardware solutions / Routers & switches, VoIP, GSM, etc

Vendor MikroTik

Security Bulletin

This security bulletin contains one medium risk vulnerability.

1) Stack-based buffer overflow

EUVDB-ID: #VU11142

Risk: Medium

CVSSv3.1: 8.6 [CVSS:3.1/AV:A/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H/E:H/RL:O/RC:C]

CVE-ID: CVE-2018-7445

CWE-ID: CWE-121 - Stack-based buffer overflow

Exploit availability: No

Description

The vulnerability allows a remote attacker to execute arbitrary code on the target system.

The vulnerability exists due to a stack-based buffer overflow when processing NetBIOS session request messages. A remote unauthenticated attacker can send a specially crafted NetBIOS session request message with malformed NetBIOS names, trigger stack-based buffer overflow and cause denial of service conditions or execute arbitrary code on the target system.

Successful exploitation of the vulnerability may allow an attacker to gain full access to the affected router but requires that SMB service is running.

Mitigation

Update to version 6.40.7 or 6.41.3.

Vulnerable software versions

MikroTik RouterOS: 6.40 - 6.41.2

External links

http://www.coresecurity.com/advisories/mikrotik-routeros-smb-buffer-overflow


Q & A

Can this vulnerability be exploited remotely?

Yes. This vulnerability can be exploited by a remote authenticated user via the local network (LAN).

How the attacker can exploit this vulnerability?

The attacker would have to send a specially crafted request to the affected device in order to exploit this vulnerability.

Is there known malware, which exploits this vulnerability?

Yes. This vulnerability is being exploited in the wild.



###SIDEBAR###