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

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x457030
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 [0x46fb44]
mov dword [ebp - 0x18], eax
push 1
lea eax, [ebp - 0x1c]
push eax
lea ecx, [ebp + 8]
call fcn.00407970
mov esi, eax
mov byte [ebp - 4], 1
call fcn.004148d0
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 0x40c54c
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
test bl, bl
je 0x40c55f
push 1
push 0x45fd14
lea ecx, [ebp + 8]
call fcn.004080c0
mov ebx, dword [ebp + 8]
test ebx, ebx
je 0x40c5aa
push ebx
call dword [sym.imp.KERNEL32.dll_lstrlenW]
add eax, 1
cmp eax, 0x3fffffff
jg 0x40c5aa
lea edi, [eax + eax]
mov eax, edi
call fcn.004411d0
mov esi, esp
test esi, esi
mov dword [ebp - 0x10], esp
je 0x40c5aa
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 0x40c5ac
xor eax, eax
push eax
call dword [sym.imp.dbghelp.dll_MakeSureDirectoryPathExists]
push 0x460d94
push 0x384
push 0
call dword [sym.imp.KERNEL32.dll_FindResourceW]
mov esi, eax
test esi, esi
jne 0x40c5ec
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.0043a782
push 0x468880
lea eax, [ebp - 0x58]
push eax
call fcn.0043e4e2
push esi
push 0
call dword [sym.imp.KERNEL32.dll_LoadResource]
test eax, eax
je 0x40c857
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.00425a6d
push str.data.7z
lea ecx, [ebp + 8]
push ecx
lea edx, [ebp - 0x18]
push edx
mov byte [ebp - 4], 2
call fcn.004021d0
add esp, 0xc
push 0
mov byte [ebp - 4], 3
mov eax, dword [eax]
push 0x1002
push eax
lea ecx, [ebp - 0x2c]
call fcn.00425eec
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 0x40c66d
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
test ebx, ebx
je 0x40c806
push esi
push edi
lea ecx, [ebp - 0x2c]
call fcn.004257bb
lea ecx, [ebp - 0x2c]
call fcn.004258a1
lea ecx, [ebp - 0x2c]
call fcn.00425a0b
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 0x40c6bf
xor eax, eax
jmp 0x40c6d9
mov eax, esi
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x40c6c4
sub eax, edx
sar eax, 1
js 0x40c7fc
cmp eax, dword [esi - 8]
jg 0x40c7fc
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.00402490
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.004021d0
add esp, 0xc
mov byte [ebp - 4], 5
call fcn.0040b330
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.004021d0
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 0x40c77c
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 0x40c809
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
jmp 0x40c809
push 0x80070057
call fcn.00401350
mov ebx, dword [ebp + 8]
lea ecx, [ebp - 0x2c]
mov byte [ebp - 4], 0
call fcn.00425b7a
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 0x40c838
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.00439e3e
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.0043a782
push 0x468880
lea ecx, [ebp - 0x4c]
push ecx
call fcn.0043e4e2
int3