Function at 0x1001d540
Capabilities:
Delete registry key

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x14
mov eax, dword [ebp + 0xc]
push ebx
push esi
push edi
xor ebx, ebx
push 1
push eax
mov dword [ebp - 4], ebx
mov dword [ebp - 0xc], ebx
call sym.vmtools.dll_Unicode_GetAllocBytes
add esp, 8
mov esi, eax
mov dword [ebp - 0x10], esi
cmp dword [0x1008cf80], ebx
jne 0x1001d584
push str.advapi32.dll
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
mov ecx, eax
mov edx, 0x1008cf80
xor eax, eax
lock cmpxchg dword [edx], ecx
mov eax, dword [0x1008cf7c]
mov dword [ebp - 8], eax
cmp eax, ebx
jne 0x1001d60c
mov eax, dword [0x1008cf80]
cmp eax, ebx
je 0x1001d5c9
push str.RegDeleteKeyExW
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov ecx, eax
mov dword [ebp - 8], ecx
mov edx, ecx
mov edi, 0x1008cf7c
xor eax, eax
lock cmpxchg dword [edi], edx
test eax, eax
je 0x1001d5c5
mov eax, dword [0x1008cf7c]
mov dword [ebp - 8], eax
mov ecx, eax
cmp ecx, ebx
jne 0x1001d609
mov edi, dword [ebp + 0x10]
cmp edi, ebx
je 0x1001d61d
cmp edi, 0x200
je 0x1001d61d
mov esi, 0x32
mov edi, dword [ebp - 4]
mov eax, dword [ebp - 0xc]
test eax, eax
je 0x1001d5ee
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
push edi
mov edi, dword [sym.imp.MSVCR90.dll_free]
call edi
mov eax, dword [ebp - 0x10]
push eax
call edi
add esp, 8
pop edi
mov eax, esi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp - 8]
mov ecx, dword [ebp + 0x10]
push ebx
mov ebx, dword [ebp + 8]
push ecx
push esi
push ebx
call eax
mov edi, dword [ebp + 0x10]
jmp 0x1001d628
mov ebx, dword [ebp + 8]
push esi
push ebx
call dword [sym.imp.ADVAPI32.dll_RegDeleteKeyW]
mov esi, eax
test esi, esi
je 0x1001d5dd
cmp dword [ebp + 0x14], 0
je 0x1001d5dd
mov edx, dword [ebp + 0xc]
push 1
push edx
call sym.vmtools.dll_Unicode_GetAllocBytes
add esp, 8
mov esi, eax
lea eax, [ebp - 0xc]
push eax
or edi, 0x20019
push edi
push 0
push esi
push ebx
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
push esi
mov edi, eax
call dword [sym.imp.MSVCR90.dll_free]
add esp, 4
mov esi, edi
test edi, edi
jne 0x1001d5dd
mov eax, dword [ebp - 0xc]
push edi
push edi
push edi
lea ecx, [ebp - 0x14]
push ecx
lea edx, [ebp - 4]
push edx
push edi
push eax
call sym.vmtools.dll_Win32U_EnumKeyExpandBuffer
mov esi, eax
add esp, 0x1c
test esi, esi
jne 0x1001d70c
lea ecx, [ecx]
mov edi, dword [ebp - 4]
test edi, edi
je 0x1001d71b
cmp byte [edi], 0
je 0x1001d71b
cmp dword [ebp - 0x14], 0
je 0x1001d71b
mov ecx, dword [ebp + 0xc]
push edi
push 0x1005d980
push ecx
push str._s_s_s
push 0
call sym.vmtools.dll_Str_SafeAsprintf
mov edx, dword [ebp + 0x14]
mov edi, eax
mov eax, dword [ebp + 0x10]
push edx
push eax
push edi
push ebx
call sym.vmtools.dll_Win32U_RecurseDeleteKeyEx
push edi
mov esi, eax
call dword [sym.imp.MSVCR90.dll_free]
add esp, 0x28
test esi, esi
jne 0x1001d5dd
mov ecx, dword [ebp - 4]
push ecx
call dword [sym.imp.MSVCR90.dll_free]
mov ecx, dword [ebp - 0xc]
push esi
push esi
push esi
lea edx, [ebp - 0x14]
push edx
lea eax, [ebp - 4]
push eax
push esi
push ecx
mov dword [ebp - 4], esi
call sym.vmtools.dll_Win32U_EnumKeyExpandBuffer
mov esi, eax
add esp, 0x20
test esi, esi
je 0x1001d690
cmp esi, 0x103
jne 0x1001d5dd
mov edi, dword [ebp - 4]
mov eax, dword [ebp - 8]
test eax, eax
je 0x1001d736
mov edx, dword [ebp + 0x10]
mov ecx, dword [ebp - 0x10]
push 0
push edx
push ecx
push ebx
call eax
mov esi, eax
jmp 0x1001d5e0
mov edx, dword [ebp - 0x10]
push edx
push ebx
call dword [sym.imp.ADVAPI32.dll_RegDeleteKeyW]
mov esi, eax
jmp 0x1001d5e0