Function at 0x408d80
Capabilities:
Check if file exists
Delete file
Delete registry key
Get file attributes
Query or enumerate registry key
Set file attributes
Set registry value

Disassembly:
push 0xffffffffffffffff
push 0x42e3db
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x140
mov eax, dword [0x43ab24]
push ebx
push ebp
push esi
push edi
mov esi, ecx
mov dword [esp + 0x18], eax
push str.COMPANY_NAME
lea ecx, [esp + 0x28]
push str.INSTALL
push ecx
mov ecx, esi
mov dword [esp + 0x164], 0
call fcn.00402890
lea edx, [esp + 0x24]
lea eax, [esp + 0x14]
push edx
push str.Software_
push eax
mov byte [esp + 0x164], 1
call fcn.0041e7eb
push str.COUNTER
lea ecx, [esp + 0x24]
mov bl, 2
push eax
push ecx
mov byte [esp + 0x164], bl
call fcn.0041e777
push eax
lea ecx, [esp + 0x1c]
mov byte [esp + 0x15c], 3
call fcn.0041e61b
lea ecx, [esp + 0x20]
mov byte [esp + 0x158], bl
call fcn.0041e52e
lea ecx, [esp + 0x14]
mov byte [esp + 0x158], 1
call fcn.0041e52e
mov eax, dword [esi + 0x9f4]
xor ecx, ecx
test eax, eax
mov dword [esp + 0x20], ecx
jle 0x409191
mov bl, 9
lea edx, [esp + 0x14]
push ecx
push edx
lea ecx, [esi + 0x9ec]
call fcn.00401720
push ecx
lea eax, [esp + 0x18]
mov ecx, esp
mov dword [esp + 0x14], esp
push eax
mov byte [esp + 0x160], 4
call fcn.0041e2a3
mov ecx, esi
call fcn.00406940
cmp eax, 0xffffffff
je 0x408eb1
lea ecx, [esp + 0x44]
push eax
push ecx
lea ecx, [esp + 0x1c]
call fcn.0041b646
push eax
lea ecx, [esp + 0x18]
mov byte [esp + 0x15c], 5
call fcn.0041e61b
lea ecx, [esp + 0x44]
mov byte [esp + 0x158], 4
call fcn.0041e52e
lea ecx, [esp + 0x14]
call fcn.0041ea04
push ecx
lea edx, [esp + 0x18]
mov ecx, esp
mov dword [esp + 0x14], esp
push edx
call fcn.0041e2a3
mov ecx, esi
call fcn.00408a10
mov edi, eax
lea eax, [esp + 0x24]
push eax
lea ecx, [esp + 0x44]
push str.Software_
push ecx
call fcn.0041e7eb
push str.COUNTER_
lea edx, [esp + 0x38]
push eax
push edx
mov byte [esp + 0x164], 6
call fcn.0041e777
lea ecx, [esp + 0x14]
lea edx, [esp + 0x48]
push ecx
push eax
push edx
mov byte [esp + 0x164], 7
call fcn.0041e711
push eax
lea ecx, [esp + 0x1c]
mov byte [esp + 0x15c], 8
call fcn.0041e61b
lea ecx, [esp + 0x48]
mov byte [esp + 0x158], 7
call fcn.0041e52e
lea ecx, [esp + 0x34]
mov byte [esp + 0x158], 6
call fcn.0041e52e
lea ecx, [esp + 0x40]
mov byte [esp + 0x158], 4
call fcn.0041e52e
mov ecx, dword [esp + 0x18]
lea eax, [esp + 0x28]
push eax
push 0xf003f
push 0
push ecx
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x409169
mov ecx, dword [edi + 4]
test ecx, ecx
jle 0x408fc7
mov eax, dword [esi + 0x154a4]
test eax, eax
jne 0x408fc5
mov eax, dword [edi + 8]
cmp eax, ecx
jle 0x409169
lea edx, [esp + 0x10]
dec eax
push 4
push edx
mov dword [edi + 8], eax
mov dword [esp + 0x18], eax
mov eax, dword [esp + 0x30]
push 4
push 0
push str.SRCHCOUNTER
push eax
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
jmp 0x409169
test ecx, ecx
je 0x408fe0
cmp ecx, 1
jne 0x409169
mov eax, dword [esi + 0x154a4]
test eax, eax
je 0x409169
mov ecx, dword [esp + 0x18]
push ecx
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegDeleteKeyA]
mov eax, dword [esi + 0x9e0]
xor edi, edi
test eax, eax
jle 0x409169
lea ebp, [esi + 0x9d8]
mov edx, dword [0x43ab24]
mov dword [esp + 0x10], edx
lea eax, [esp + 0x3c]
push edi
push eax
mov ecx, ebp
mov byte [esp + 0x160], bl
call fcn.00401720
push eax
lea ecx, [esp + 0x14]
mov byte [esp + 0x15c], 0xa
call fcn.0041e61b
lea ecx, [esp + 0x3c]
mov byte [esp + 0x158], bl
call fcn.0041e52e
push ecx
lea edx, [esp + 0x14]
mov ecx, esp
mov dword [esp + 0x34], esp
push edx
call fcn.0041e2a3
mov ecx, esi
call fcn.00406940
cmp eax, 0xffffffff
je 0x409094
push eax
lea eax, [esp + 0x30]
push eax
lea ecx, [esp + 0x18]
call fcn.0041b646
push eax
lea ecx, [esp + 0x14]
mov byte [esp + 0x15c], 0xb
call fcn.0041e61b
lea ecx, [esp + 0x2c]
mov byte [esp + 0x158], bl
call fcn.0041e52e
lea ecx, [esp + 0x10]
call fcn.0041ea04
mov ecx, dword [esp + 0x10]
mov edx, dword [esp + 0x14]
push ecx
push edx
call fcn.0040ded2
add esp, 8
test eax, eax
je 0x4090d8
lea ecx, [esp + 0x10]
mov byte [esp + 0x158], 4
call fcn.0041e52e
mov eax, dword [esi + 0x9e0]
inc edi
cmp edi, eax
jl 0x409006
jmp 0x409169
lea eax, [esp + 0x1c]
push edi
push eax
mov ecx, ebp
call fcn.00401720
push eax
lea ecx, [esp + 0x14]
mov byte [esp + 0x15c], 0xc
call fcn.0041e61b
lea ecx, [esp + 0x1c]
mov byte [esp + 0x158], bl
call fcn.0041e52e
push 0
push ecx
lea edx, [esp + 0x18]
mov ecx, esp
mov dword [esp + 0x38], esp
push edx
call fcn.0041e2a3
mov ecx, esi
call fcn.00407450
mov eax, dword [esp + 0x10]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
je 0x40914e
test al, 1
je 0x409143
mov ecx, dword [esp + 0x10]
and al, 0xfe
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
mov edx, dword [esp + 0x10]
push edx
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
push 1
push edi
mov ecx, ebp
call fcn.0041c458
lea ecx, [esp + 0x10]
mov byte [esp + 0x158], 4
call fcn.0041e52e
lea ecx, [esp + 0x14]
mov byte [esp + 0x158], 1
call fcn.0041e52e
mov ecx, dword [esp + 0x20]
mov eax, dword [esi + 0x9f4]
inc ecx
cmp ecx, eax
mov dword [esp + 0x20], ecx
jl 0x408e49
lea eax, [esp + 0x24]
lea ecx, [esp + 0x2c]
push eax
push str.Software_
push ecx
call fcn.0041e7eb
push str.COUNTER
lea edx, [esp + 0x20]
mov bl, 0xd
push eax
push edx
mov byte [esp + 0x164], bl
call fcn.0041e777
push eax
lea ecx, [esp + 0x1c]
mov byte [esp + 0x15c], 0xe
call fcn.0041e61b
lea ecx, [esp + 0x1c]
mov byte [esp + 0x158], bl
call fcn.0041e52e
lea ecx, [esp + 0x2c]
mov byte [esp + 0x158], 1
call fcn.0041e52e
mov ecx, dword [esp + 0x18]
lea eax, [esp + 0x28]
xor ebp, ebp
push eax
push 0xf003f
push ebp
push ecx
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x409269
mov ebx, dword [sym.imp.ADVAPI32.dll_RegEnumKeyExA]
mov ecx, 0x3e
xor eax, eax
lea edi, [esp + 0x54]
lea edx, [esp + 0x4c]
rep stosd dword es:[edi], eax
push edx
mov edx, dword [esp + 0x2c]
stosw word es:[edi], ax
push 0
push 0
lea eax, [esp + 0x44]
push 0
lea ecx, [esp + 0x64]
push eax
push ecx
push ebp
push edx
mov dword [esp + 0x58], 0xfa
call ebx
cmp eax, 0x103
je 0x409261
cmp eax, 0xea
je 0x40925e
test eax, eax
jne 0x409261
inc ebp
jmp 0x409218
test ebp, ebp
jne 0x40930a
mov eax, dword [esp + 0x18]
push eax
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegDeleteKeyA]
mov eax, dword [esi + 0x9e0]
xor edi, edi
test eax, eax
jle 0x409303
lea ebp, [esi + 0x9d8]
mov bl, 0xf
mov ecx, dword [0x43ab24]
mov dword [esp + 0x14], ecx
lea edx, [esp + 0x1c]
push edi
push edx
mov ecx, ebp
mov byte [esp + 0x160], bl
call fcn.00401720
push eax
lea ecx, [esp + 0x18]
mov byte [esp + 0x15c], 0x10
call fcn.0041e61b
lea ecx, [esp + 0x1c]
mov byte [esp + 0x158], bl
call fcn.0041e52e
push 0
push ecx
lea eax, [esp + 0x1c]
mov ecx, esp
mov dword [esp + 0x38], esp
push eax
call fcn.0041e2a3
mov ecx, esi
call fcn.00407450
lea ecx, [esp + 0x14]
mov byte [esp + 0x158], 1
call fcn.0041e52e
mov eax, dword [esi + 0x9e0]
inc edi
cmp edi, eax
jl 0x40928d
mov ecx, esi
call fcn.004083d0
lea ecx, [esp + 0x24]
mov byte [esp + 0x158], 0
call fcn.0041e52e
lea ecx, [esp + 0x18]
mov dword [esp + 0x158], 0xffffffff
call fcn.0041e52e
mov ecx, dword [esp + 0x150]
pop edi
pop esi
pop ebp
mov dword fs:[0], ecx
pop ebx
add esp, 0x14c
ret