Function at 0x40c230
Capabilities:
Delete file
Extract resource via kernel32 functions
Get common file path
Set current directory

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x456ea0
mov eax, dword fs:[0]
push eax
sub esp, 0x4c
mov eax, dword [0x46e780]
xor eax, ebp
mov dword [ebp - 0x14], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x10], esp
mov dword [ebp - 4], 0
call dword [0x46fb34]
mov dword [ebp - 0x18], eax
push 1
lea eax, [ebp - 0x1c]
push eax
lea ecx, [ebp + 8]
call fcn.004077d0
mov esi, eax
mov byte [ebp - 4], 1
call fcn.00414620
mov bl, al
mov byte [ebp - 4], 0
mov eax, dword [ebp - 0x1c]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40c2ac
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
test bl, bl
je 0x40c2bf
push 1
push 0x45fcf4
lea ecx, [ebp + 8]
call fcn.00407e20
mov ebx, dword [ebp + 8]
test ebx, ebx
je 0x40c30a
push ebx
call dword [sym.imp.KERNEL32.dll_lstrlenW]
add eax, 1
cmp eax, 0x3fffffff
jg 0x40c30a
lea edi, [eax + eax]
mov eax, edi
call fcn.00441030
mov esi, esp
test esi, esi
mov dword [ebp - 0x10], esp
je 0x40c30a
mov ecx, dword [ebp - 0x18]
push 0
push 0
push edi
push esi
push 0xffffffffffffffff
push ebx
push 0
push ecx
mov byte [esi], 0
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
neg eax
sbb eax, eax
and eax, esi
jmp 0x40c30c
xor eax, eax
push eax
call dword [sym.imp.dbghelp.dll_MakeSureDirectoryPathExists]
push 0x460bd4
push 0x384
push 0
call dword [sym.imp.KERNEL32.dll_FindResourceW]
mov esi, eax
test esi, esi
jne 0x40c34c
lea edx, [ebp - 0x18]
push edx
lea ecx, [ebp - 0x58]
mov dword [ebp - 0x18], str._Out__DATA_resource_not_found_in_current_executable
call fcn.0043b4a4
push 0x4686c8
lea eax, [ebp - 0x58]
push eax
call fcn.0043e342
push esi
push 0
call dword [sym.imp.KERNEL32.dll_LoadResource]
test eax, eax
je 0x40c5b7
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
push esi
push 0
mov edi, eax
call dword [sym.imp.KERNEL32.dll_SizeofResource]
lea ecx, [ebp - 0x2c]
mov esi, eax
call fcn.004276d0
push str.data.7z
lea ecx, [ebp + 8]
push ecx
lea edx, [ebp - 0x18]
push edx
mov byte [ebp - 4], 2
call fcn.004021b0
add esp, 0xc
push 0
mov byte [ebp - 4], 3
mov eax, dword [eax]
push 0x1002
push eax
lea ecx, [ebp - 0x2c]
call fcn.00427b4f
mov ebx, eax
mov byte [ebp - 4], 2
mov eax, dword [ebp - 0x18]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40c3cd
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
test ebx, ebx
je 0x40c566
push esi
push edi
lea ecx, [ebp - 0x2c]
call fcn.0042741e
lea ecx, [ebp - 0x2c]
call fcn.00427504
lea ecx, [ebp - 0x2c]
call fcn.0042766e
lea ecx, [ebp - 0x1c]
call fcn.00401680
push 0x104
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], 4
call fcn.004013a0
push eax
push 0x104
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
mov esi, dword [ebp - 0x1c]
test esi, esi
jne 0x40c41f
xor eax, eax
jmp 0x40c439
mov eax, esi
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x40c424
sub eax, edx
sar eax, 1
js 0x40c55c
cmp eax, dword [esi - 8]
jg 0x40c55c
mov ebx, dword [ebp + 8]
mov dword [esi - 0xc], eax
push ebx
mov word [esi + eax*2], 0
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryW]
push ecx
mov byte [ebp - 4], 5
lea eax, [ebx - 0x10]
mov dword [ebp - 0x18], esp
mov edi, esp
push eax
call fcn.00402470
add eax, 0x10
add esp, 4
mov dword [edi], eax
push ecx
mov ecx, esp
mov dword [ebp - 0x34], esp
push str.data.7z
lea edx, [ebp + 8]
push edx
push ecx
mov byte [ebp - 4], 6
call fcn.004021b0
add esp, 0xc
mov byte [ebp - 4], 5
call fcn.0040b090
add esp, 8
push str.data.7z
lea eax, [ebp + 8]
push eax
lea ecx, [ebp - 0x18]
push ecx
mov dword [ebp - 4], 4
call fcn.004021b0
mov eax, dword [eax]
add esp, 0xc
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
mov eax, dword [ebp - 0x18]
add eax, 0xfffffff0
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x40c4dc
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
push esi
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryW]
lea eax, [esi - 0x10]
mov byte [ebp - 4], 2
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40c569
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
jmp 0x40c569
push 0x80070057
call fcn.00401350
mov ebx, dword [ebp + 8]
lea ecx, [ebp - 0x2c]
mov byte [ebp - 4], 0
call fcn.004277dd
lea eax, [ebx - 0x10]
mov dword [ebp - 4], 0xffffffff
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x40c598
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
lea esp, [ebp - 0x68]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.00439c98
mov esp, ebp
pop ebp
ret
lea eax, [ebp - 0x18]
push eax
lea ecx, [ebp - 0x4c]
mov dword [ebp - 0x18], str.Unable_to_extract_install_resource_
call fcn.0043b4a4
push 0x4686c8
lea ecx, [ebp - 0x4c]
push ecx
call fcn.0043e342
int3