Function at 0x40fcf8
Capabilities:
Check if file exists
Check os version
Delete registry key
Get file attributes

Disassembly:
mov eax, 0x410c7c
call fcn.00410480
sub esp, 0x330
push ebx
push esi
push edi
xor edi, edi
mov dword [ebp - 0x10], esp
mov dword [ebp - 4], edi
mov dword [ebp - 0x1c], edi
call fcn.0040b8af
call fcn.00401587
lea eax, [ebp - 0x33c]
push 0x104
push eax
push edi
mov dword [ebp - 0x18], edi
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
push eax
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
test eax, eax
je 0x40fdb0
lea eax, [ebp - 0x33c]
push 0x5c
push eax
call sub.MSVCRT.dll_wcsrchr
pop ecx
cmp eax, edi
pop ecx
je 0x40fd59
mov word [eax + 2], di
lea eax, [ebp - 0x33c]
push str.IDMSetup2.log
push eax
call sub.MSVCRT.dll_wcscat
pop ecx
lea eax, [ebp - 0x33c]
pop ecx
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x40fdc3
lea eax, [ebp - 0x33c]
push 0x5c
push eax
mov dword [ebp - 0x18], 1
call sub.MSVCRT.dll_wcsrchr
pop ecx
cmp eax, edi
pop ecx
je 0x40fd9d
mov word [eax + 2], di
lea eax, [ebp - 0x33c]
push str.IDMSetup.log
push eax
call sub.MSVCRT.dll_wcscat
jmp 0x40fdc1
lea eax, [ebp - 0x33c]
push str.IDMSetup2.log
push eax
call sub.MSVCRT.dll_wcscpy
pop ecx
pop ecx
lea eax, [ebp - 0x33c]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x40ff09
push 1
push edi
push edi
push 3
lea eax, [ebp - 0x1c]
push 0xc0000000
push eax
lea eax, [ebp - 0x33c]
push eax
call fcn.00405485
add esp, 0x1c
cmp eax, edi
mov dword [ebp - 0x20], eax
je 0x40ff09
cmp dword [ebp - 0x18], edi
je 0x40fe55
push edi
mov esi, dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
push edi
push dword [ebp - 0x1c]
push eax
push edi
push edi
call esi
mov ebx, eax
cmp ebx, edi
je 0x40fef5
lea eax, [ebx + ebx + 2]
push eax
call sub.MSVCRT.dll_void____cdecl_operator_new_unsigned_int_
cmp eax, edi
pop ecx
mov dword [ebp - 0x14], eax
je 0x40fef5
push ebx
push eax
push dword [ebp - 0x1c]
push dword [ebp - 0x20]
push edi
push edi
call esi
test eax, eax
jne 0x40fe58
push dword [ebp - 0x14]
call sub.MSVCRT.dll_void___cdecl_operator_delete_void__
pop ecx
mov dword [ebp - 0x14], edi
jmp 0x40fe58
mov dword [ebp - 0x14], eax
cmp dword [ebp - 0x14], edi
je 0x40fef5
mov ebx, 0x400
push ebx
push dword [ebp + 8]
push dword [ebp - 0x14]
call fcn.00410287
add esp, 0xc
cmp eax, edi
jne 0x40fee7
mov edi, 0x401
push edi
push dword [ebp + 8]
push dword [ebp - 0x14]
call fcn.004103ca
mov esi, dword [0x41ccd8]
add esp, 0xc
mov eax, esi
xor edx, edx
push 0x64
pop ecx
div ecx
xor edx, edx
mov ecx, eax
mov eax, esi
inc ecx
div ecx
mov dword [0x41ccd4], ecx
movzx eax, ax
shl eax, 0x10
push eax
push 0
push edi
push 0x407
push dword [0x41ca94]
call dword [sym.imp.USER32.dll_SendDlgItemMessageW]
push ebx
push dword [ebp + 8]
call fcn.0041019b
cmp dword [0x41ccd0], 0
pop ecx
pop ecx
je 0x40fee5
push edi
push dword [ebp + 8]
call fcn.00410028
pop ecx
pop ecx
xor edi, edi
cmp dword [ebp - 0x18], edi
je 0x40fef5
push dword [ebp - 0x14]
call sub.MSVCRT.dll_void___cdecl_operator_delete_void__
pop ecx
push dword [ebp - 0x20]
call dword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
push str.IDMSetup2.log
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
call fcn.0040f5c2
call fcn.0040fc7f
call fcn.0040dfe9
push 0xf003f
call fcn.0040d9d3
pop ecx
call fcn.00403037
cmp eax, edi
je 0x40ff37
push 0xf013f
call fcn.0040d9d3
pop ecx
lea eax, [ebp - 0x134]
mov dword [ebp - 0x134], 0x114
push eax
xor esi, esi
call dword [sym.imp.KERNEL32.dll_GetVersionExW]
test eax, eax
je 0x40ff77
cmp dword [ebp - 0x124], 2
jne 0x40ff77
cmp dword [ebp - 0x130], 6
jb 0x40ff77
cmp dword [ebp - 0x130], 0xa
jb 0x40ff77
push 1
pop esi
call fcn.0040d005
cmp dword [0x41ccd0], edi
je 0x40ff93
cmp esi, edi
je 0x40ff89
push edi
call fcn.0040d093
call fcn.0040f8e5
call fcn.0040fbdf
mov esi, dword [sym.imp.ADVAPI32.dll_RegDeleteKeyW]
mov edi, str.SOFTWAREMICROSOFTWINDOWSCURRENTVERSIONUNINSTALLInternet_Download_Manager
mov ebx, 0x80000002
push edi
push ebx
call esi
push edi
mov edi, 0x80000001
push edi
call esi
xor esi, esi
cmp dword [0x41ccd0], esi
je 0x40ffd0
push str.SoftwareDownloadManager
push edi
mov edi, dword [sym.imp.SHLWAPI.dll_SHDeleteKeyW]
call edi
push str.SOFTWAREInternet_Download_Manager
push ebx
call edi
push esi
push esi
push 0x10
push dword [0x41bc3c]
call dword [sym.imp.USER32.dll_SendMessageW]
call fcn.0040ce71
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
xor eax, eax
mov dword fs:[0], ecx
pop ebx
leave
ret 4