Function at 0x498660
Capabilities:
Delete registry key
Query or enumerate registry key

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
and esp, 0xfffffff8
sub esp, 0x30
mov ebx, dword [ebp + 0x10]
mov edi, dword [ebp + 0xc]
mov esi, dword [ebp + 8]
mov eax, dword [0x6401e4]
xor eax, ebp
mov dword [esp + 0x28], eax
push 0
push ebx
push edi
push esi
call dword [sym.imp.ADVAPI32.dll_RegDeleteKeyExW]
test eax, eax
je 0x4986c2
mov dword [esp + 0x24], 0
mov eax, ebx
or eax, 8
lea ecx, [esp + 0x24]
push ecx
push eax
push 0
push edi
push esi
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
je 0x4986c9
xor esi, esi
cmp eax, 2
je 0x498904
mov esi, eax
jmp 0x498904
xor esi, esi
jmp 0x498904
mov dword [esp + 0x1c], 0
mov dword [esp + 0x18], 0
mov dword [esp + 0x20], 0
push edi
call fcn.005b0e94
add esp, 4
cmp eax, 0x7ffffff0
jae 0x498919
mov ebx, eax
cmp eax, 5
jae 0x49870d
lea esi, [esp + 0x18]
mov byte [esp + 0x23], bl
mov dword [esp], esi
test ebx, ebx
jne 0x498743
jmp 0x498752
lea edi, [ebx + 8]
and edi, 0xfffffff8
js 0x498922
lea eax, [edi + edi]
push eax
call fcn.00596296
add esp, 4
mov esi, eax
mov dword [esp + 0x18], eax
or edi, 0x80000000
mov dword [esp + 0x20], edi
mov dword [esp + 0x1c], ebx
lea eax, [esp + 0x18]
mov dword [esp], eax
mov edi, dword [ebp + 0xc]
mov eax, ebx
add eax, ebx
push eax
push edi
push esi
call fcn.00599c40
add esp, 0xc
mov word [esi + ebx*2], 0
mov eax, dword [esp]
mov al, byte [eax + 0xb]
test al, al
js 0x49878c
test al, al
je 0x4987a8
movzx ecx, al
lea edx, [esp + 0x18]
cmp word [edx + ecx*2 - 2], 0x5c
je 0x498786
lea ecx, [esp + 0x18]
push 0x5c
call fcn.004795f8
mov eax, dword [esp]
mov al, byte [eax + 0xb]
test al, al
jns 0x4987aa
jmp 0x4987a2
mov ecx, dword [esp + 0x1c]
test ecx, ecx
je 0x4987a2
mov edx, dword [esp + 0x18]
cmp word [edx + ecx*2 - 2], 0x5c
jne 0x498775
jmp 0x498786
mov ebx, dword [esp + 0x1c]
jmp 0x4987ad
xor eax, eax
movzx ebx, al
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0
mov dword [esp + 0x10], 0
mov dword [esp + 4], 0x104
lea esi, [esp + 8]
push 0x104
push esi
call fcn.0048b0f0
add esp, 8
mov ecx, dword [esp + 0x24]
sub esp, 0x20
xorps xmm0, xmm0
movups xmmword [esp + 0x10], xmm0
lea edx, [esp + 0x24]
mov dword [esp + 0xc], edx
mov dword [esp + 8], eax
mov dword [esp], ecx
mov dword [esp + 4], 0
call dword [sym.imp.ADVAPI32.dll_RegEnumKeyExW]
test eax, eax
jne 0x4988bf
lea edi, [esp + 0x18]
nop word [eax + eax]
mov ecx, esi
push 0
push dword [esp + 8]
call fcn.00479058
mov ecx, edi
push 0
push ebx
call fcn.00479058
movzx eax, byte [esp + 0x13]
mov edx, esi
test al, al
jns 0x49884a
mov eax, dword [esp + 0xc]
mov edx, dword [esp + 8]
mov ecx, edi
push eax
push edx
call fcn.00479328
mov eax, dword [esp]
cmp byte [eax + 0xb], 0
mov eax, edi
jns 0x498862
mov eax, dword [esp + 0x18]
push dword [ebp + 0x10]
push eax
push dword [ebp + 8]
call fcn.00498660
add esp, 0xc
test eax, eax
jne 0x4988bf
mov dword [esp + 4], 0x104
push 0x104
push esi
call fcn.0048b0f0
add esp, 8
mov ecx, dword [esp + 0x24]
sub esp, 0x20
xorps xmm0, xmm0
movups xmmword [esp + 0x10], xmm0
lea edx, [esp + 0x24]
mov dword [esp + 0xc], edx
mov dword [esp + 8], eax
mov dword [esp], ecx
mov dword [esp + 4], 0
call dword [sym.imp.ADVAPI32.dll_RegEnumKeyExW]
test eax, eax
je 0x498820
push dword [esp + 0x24]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
push 0
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_RegDeleteKeyExW]
mov esi, eax
cmp byte [esp + 0x13], 0
jns 0x4988ef
push dword [esp + 8]
call fcn.00596316
add esp, 4
mov eax, dword [esp]
cmp byte [eax + 0xb], 0
jns 0x498904
push dword [esp + 0x18]
call fcn.00596316
add esp, 4
mov ecx, dword [esp + 0x28]
xor ecx, ebp
call fcn.00596351
mov eax, esi
lea esp, [ebp - 0xc]
pop esi
pop edi
pop ebx
pop ebp
ret
lea ecx, [esp + 0x18]
call fcn.00478354
call fcn.005aa3fa
int3