Function at 0x413130
Capabilities:
Delete registry key

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x535bb8
mov eax, dword fs:[0]
push eax
sub esp, 0x20
push ebx
push esi
push edi
mov eax, dword [0x59dbf0]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, ecx
push edi
lea ecx, [ebp - 0x1c]
call fcn.004122b0
cmp dword [edi + 4], 0xffffffff
mov dword [ebp - 4], 0
jne 0x41317a
mov esi, 0x80004005
jmp 0x413303
push dword [ebp + 8]
lea eax, [ebp - 0x10]
push eax
mov ecx, edi
xor bl, bl
call fcn.00413aa0
mov ecx, dword [ebp - 0x10]
mov byte [ebp - 4], 1
test ecx, ecx
je 0x413216
mov dword [ebp - 0x28], 0
mov dword [ebp - 0x24], 0
mov dword [ebp - 0x20], 0
mov dword [ebp - 0x2c], vtable.MA::StringArrayT_wchar_t__char_.0
lea eax, [ebp - 0x2c]
push eax
mov byte [ebp - 4], 2
call fcn.00413f50
mov eax, dword [ebp - 0x24]
sub eax, dword [ebp - 0x28]
xor esi, esi
sar eax, 3
test eax, eax
je 0x4131fb
mov eax, dword [ebp - 0x2c]
lea ecx, [ebp - 0x2c]
call dword [eax + 0x64]
mov ecx, dword [ebp - 0x10]
lea eax, [eax + esi*8]
push eax
call fcn.00413130
test eax, eax
sets al
or bl, al
mov eax, dword [ebp - 0x24]
sub eax, dword [ebp - 0x28]
inc esi
sar eax, 3
cmp esi, eax
jb 0x4131d1
lea ecx, [ebp - 0x28]
mov byte [ebp - 4], 1
mov dword [ebp - 0x2c], vtable.MA::Array_class_MA::StringT_wchar_t__char__.0
call fcn.00409edd
test bl, bl
jne 0x4132e3
push str.IsWow64Process
push str.kernel32
mov dword [ebp - 0x14], 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov esi, eax
test esi, esi
je 0x413247
lea eax, [ebp - 0x14]
push eax
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call esi
cmp dword [ebp - 0x14], 0
je 0x4132be
push str.AdvAPI32.dll
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov ebx, eax
test ebx, ebx
je 0x4132e3
push str.RegDeleteKeyExW
push ebx
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [ebp - 0x14], eax
test eax, eax
jne 0x413283
push ebx
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
mov esi, 0x80004005
jmp 0x4132ec
cmp dword [edi + 0x14], 0
mov eax, 0xf013f
mov esi, 0xf003f
cmovne esi, eax
mov eax, dword [ebp + 8]
mov ecx, dword [eax + 4]
add ecx, 4
mov eax, dword [ecx]
mov eax, dword [eax + 4]
add ecx, eax
mov eax, dword [ecx]
call dword [eax + 0x18]
push 0
push esi
push eax
push dword [edi + 4]
call dword [ebp - 0x14]
push ebx
mov esi, eax
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
jmp 0x4132df
mov eax, dword [ebp + 8]
mov ecx, dword [eax + 4]
add ecx, 4
mov eax, dword [ecx]
mov eax, dword [eax + 4]
add ecx, eax
mov eax, dword [ecx]
call dword [eax + 0x18]
push eax
push dword [edi + 4]
call dword [sym.imp.ADVAPI32.dll_RegDeleteKeyW]
mov esi, eax
test esi, esi
je 0x4132ea
mov esi, 0x80004005
jmp 0x4132ec
xor esi, esi
mov eax, dword [ebp - 0x10]
mov byte [ebp - 4], 0
test eax, eax
je 0x413303
mov ecx, dword [eax]
mov ecx, dword [ecx + 4]
add ecx, eax
mov eax, dword [ecx]
call dword [eax + 0xc]
cmp byte [ebp - 0x1c], 0
mov edi, dword [ebp - 0x18]
jne 0x413322
mov eax, dword [edi + 4]
cmp eax, 0xffffffff
je 0x413322
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov dword [edi + 4], 0xffffffff
lea ecx, [edi + 0x18]
push ecx
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4