Function at 0x40b716
Capabilities:
Create bits job
Create directory
Delete file
Get common file path
Move file

Disassembly:
push 0x38
mov eax, 0x46601b
call fcn.00463b54
mov dword [ebp - 0x3c], edx
mov dword [ebp - 0x44], ecx
xor esi, esi
mov dword [ebp - 0x30], esi
xor ebx, ebx
inc ebx
mov dword [ebp - 4], ebx
mov dword [ebp - 0x24], esi
mov byte [ebp - 4], 3
mov dword [ebp - 0x40], esi
mov byte [ebp - 4], 5
call fcn.004068d0
push eax
lea ecx, [ebp - 0x28]
call fcn.00405f99
mov byte [ebp - 4], 7
mov eax, 0x36ee80
cmp dword [ebp + 8], esi
push esi
cmovne eax, dword [ebp + 8]
push esi
push ebx
push esi
mov dword [ebp - 0x38], eax
call dword [sym.imp.KERNEL32.dll_CreateEventW]
mov dword [ebp - 0x34], eax
test eax, eax
jne 0x40b7da
mov ebx, 0x80070006
mov edi, dword [ebp - 0x28]
mov eax, dword [ebp - 0x24]
test eax, eax
je 0x40b788
mov ecx, dword [eax]
push eax
call dword [ecx + 0x20]
mov eax, dword [ebp - 0x34]
test eax, eax
je 0x40b796
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov byte [ebp - 4], 5
lea ecx, [edi - 0x10]
call fcn.00406985
mov byte [ebp - 4], 3
test esi, esi
je 0x40b7b0
mov eax, dword [esi]
push esi
call dword [eax + 8]
mov byte [ebp - 4], 1
mov eax, dword [ebp - 0x24]
test eax, eax
je 0x40b7c1
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
or dword [ebp - 4], 0xffffffff
mov eax, dword [ebp - 0x30]
test eax, eax
je 0x40b7d2
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
mov eax, ebx
call fcn.00463afe
ret
mov edi, 0x104
lea ecx, [ebp - 0x28]
push edi
call fcn.0040655c
push eax
push edi
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
push ecx
lea ecx, [ebp - 0x28]
call fcn.00405ee3
mov edi, dword [ebp - 0x28]
cmp dword [edi - 0xc], 0
jne 0x40b80c
mov ebx, 0x8000ffff
jmp 0x40b77b
push esi
push edi
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
push ecx
xor edx, edx
lea ecx, [ebp - 0x2c]
call fcn.0041c13c
pop ecx
mov byte [ebp - 4], 8
lea ecx, [ebp - 0x28]
mov eax, dword [eax]
push dword [eax - 0xc]
push eax
call fcn.00409578
mov byte [ebp - 4], 7
mov ecx, dword [ebp - 0x2c]
lea ecx, [ecx - 0x10]
call fcn.00406985
lea eax, [ebp - 0x30]
push eax
push 0x4788a4
push 4
push esi
push 0x4788b4
call dword [sym.imp.ole32.dll_CoCreateInstance]
mov ebx, eax
test ebx, ebx
js 0x40b778
mov eax, dword [ebp - 0x30]
lea edx, [ebp - 0x24]
push edx
lea edx, [ebp - 0x20]
push edx
mov ecx, dword [eax]
push esi
push str.AvEmUpdate_download
push eax
call dword [ecx + 0xc]
mov ecx, dword [ebp - 0x30]
mov ebx, eax
test ecx, ecx
je 0x40b88b
mov dword [ebp - 0x30], esi
mov eax, dword [ecx]
push ecx
call dword [eax + 8]
test ebx, ebx
js 0x40b778
mov eax, dword [ebp - 0x24]
push esi
push eax
mov ecx, dword [eax]
call dword [ecx + 0x54]
mov ebx, eax
test ebx, ebx
js 0x40b778
push 0x10
call fcn.0043fee7
mov ebx, eax
pop ecx
mov dword [ebp - 0x2c], ebx
mov byte [ebp - 4], 0xa
lea eax, [ebx + 0xc]
mov edi, dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push 2
push esi
push esi
push eax
mov dword [ebx], vtable.CNotifyInterface.0
mov dword [ebx + 4], 1
mov dword [ebx + 8], reloc.OLEAUT32.dll_VariantCopyInd
mov dword [eax], esi
call edi
push eax
push dword [ebp - 0x34]
call edi
push eax
call dword [sym.imp.KERNEL32.dll_DuplicateHandle]
test eax, eax
jne 0x40b8fb
push dword [ebp - 0x34]
call dword [sym.imp.KERNEL32.dll_SetEvent]
mov dword [ebx + 0xc], esi
mov byte [ebp - 4], 7
mov esi, ebx
mov dword [ebp - 0x40], esi
mov eax, dword [ebp - 0x24]
push ebx
push eax
mov ecx, dword [eax]
call dword [ecx + 0x64]
mov ebx, eax
test ebx, ebx
js 0x40b778
mov eax, dword [ebp - 0x24]
push 3
push eax
mov ecx, dword [eax]
call dword [ecx + 0x5c]
mov ebx, eax
test ebx, ebx
js 0x40b778
mov eax, dword [ebp - 0x24]
mov edi, dword [ebp - 0x28]
push edi
push dword [ebp - 0x44]
mov ecx, dword [eax]
push eax
call dword [ecx + 0x10]
mov ebx, eax
test ebx, ebx
js 0x40b77b
mov eax, dword [ebp - 0x24]
push eax
mov ecx, dword [eax]
call dword [ecx + 0x1c]
mov ebx, eax
test ebx, ebx
js 0x40b77b
push dword [ebp - 0x38]
push dword [ebp - 0x34]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov ebx, dword [ebp - 0x2c]
mov ebx, dword [ebx + 8]
mov dword [ebp - 0x38], ebx
test ebx, ebx
jns 0x40b986
cmp ebx, reloc.OLEAUT32.dll_VariantCopyInd
jne 0x40b9ea
mov eax, dword [ebp - 0x24]
push eax
mov ecx, dword [eax]
call dword [ecx + 0x20]
jmp 0x40b9ea
mov eax, dword [ebp - 0x3c]
test eax, eax
je 0x40b9de
mov dword [ebp - 0x2c], 9
push 2
push eax
push edi
call dword [sym.imp.KERNEL32.dll_MoveFileExW]
mov ebx, eax
call dword [sym.imp.KERNEL32.dll_GetLastError]
test ebx, ebx
jne 0x40b9e7
cmp eax, 0x20
je 0x40b9b4
cmp eax, 5
jne 0x40b9c8
push 0xc8
call dword [sym.imp.KERNEL32.dll_Sleep]
sub dword [ebp - 0x2c], 1
mov eax, dword [ebp - 0x3c]
jns 0x40b994
call dword [sym.imp.KERNEL32.dll_GetLastError]
movzx ebx, ax
or ebx, 0x80070000
test eax, eax
cmovle ebx, eax
jmp 0x40b9ea
push edi
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
jmp 0x40b9ea
mov ebx, dword [ebp - 0x38]
test ebx, ebx
jns 0x40b788
jmp 0x40b77b