Function at 0x405059
Capabilities:
Connect to http server
Create http request
Delete file
Parse url

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x6c
push ebx
push esi
mov esi, dword [sym.imp.KERNEL32.DLL_LocalAlloc]
mov ebx, 0x5000
push edi
push ebx
mov edi, ecx
push 0x40
call esi
push ebx
push 0x40
mov dword [ebp - 0x14], eax
call esi
push ebx
push 0x40
mov dword [ebp - 4], eax
call esi
mov ebx, 0x208
mov dword [ebp - 0x18], eax
push ebx
push 0x40
call esi
push ebx
push 0x40
mov dword [ebp - 8], eax
call esi
mov esi, dword [edi]
xor ebx, ebx
push ebx
push ebx
push ebx
push ebx
push str.ZONA_httpget
mov dword [ebp - 0xc], eax
mov byte [edi + 8], bl
mov dword [edi + 0xc], ebx
call dword [sym.imp.WININET.dll_InternetOpenW]
cmp eax, ebx
mov dword [ebp - 0x10], eax
je 0x4052fd
lea ecx, [ebp - 0x28]
mov dword [ebp - 0x28], 4
push ecx
lea ecx, [ebp - 0x20]
push ecx
push 0x32
push eax
mov dword [ebp - 0x20], ebx
call dword [sym.imp.WININET.dll_InternetQueryOptionW]
test eax, eax
je 0x405100
test byte [ebp - 0x20], 0x10
je 0x405100
lea eax, [ebp - 0x30]
push 8
push eax
push 0x32
push dword [ebp - 0x10]
mov dword [ebp - 0x30], 1
mov dword [ebp - 0x2c], ebx
call dword [sym.imp.WININET.dll_InternetSetOptionW]
push str.wininet.dll
call dword [sym.imp.KERNEL32.DLL_LoadLibraryW]
mov eax, dword [ebp - 0x18]
push ebx
push ebx
push 2
mov word [eax], bx
mov eax, dword [ebp - 4]
push ebx
push 1
mov word [eax], bx
mov eax, dword [ebp - 0xc]
push 0x40000000
mov word [eax], bx
mov eax, dword [ebp - 8]
mov word [eax], bx
mov eax, dword [ebp - 0x14]
mov word [eax], bx
push dword [esi + 8]
call dword [sym.imp.KERNEL32.DLL_CreateFileW]
cmp eax, 0xffffffff
mov dword [ebp - 0x1c], eax
je 0x4052f6
mov eax, dword [ebp - 0x14]
mov dword [ebp - 0x6c], 0x3c
mov dword [ebp - 0x5c], eax
mov eax, dword [ebp - 8]
mov dword [ebp - 0x50], eax
mov eax, dword [ebp - 0xc]
mov dword [ebp - 0x48], eax
mov eax, dword [ebp - 4]
mov dword [ebp - 0x40], eax
mov eax, dword [ebp - 0x18]
mov dword [ebp - 0x38], eax
mov eax, 0x2800
mov dword [ebp - 0x34], eax
mov dword [ebp - 0x3c], eax
mov dword [ebp - 0x58], eax
mov eax, 0x104
mov dword [ebp - 0x44], eax
mov dword [ebp - 0x4c], eax
lea eax, [ebp - 0x6c]
mov dword [ebp - 0x68], ebx
push eax
push ebx
push ebx
mov dword [ebp - 0x64], ebx
push dword [esi + 4]
mov dword [ebp - 0x60], ebx
mov word [ebp - 0x54], bx
call dword [sym.imp.WININET.dll_InternetCrackUrlW]
test eax, eax
je 0x4052b9
push dword [ebp - 0x18]
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.DLL_lstrcatW]
lea eax, [esi + 0xc]
push 4
push eax
push 2
push dword [ebp - 0x10]
call dword [sym.imp.WININET.dll_InternetSetOptionW]
test eax, eax
jne 0x4051d7
push str.InternetSetOption1
jmp 0x405284
lea eax, [esi + 0x10]
push 4
push eax
push 6
push dword [ebp - 0x10]
call dword [sym.imp.WININET.dll_InternetSetOptionW]
test eax, eax
jne 0x4051f6
push str.InternetSetOption2
jmp 0x405284
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.DLL_lstrlenW]
test eax, eax
jle 0x40520b
mov eax, dword [ebp - 0xc]
mov dword [ebp - 0x24], eax
jmp 0x40520e
mov dword [ebp - 0x24], ebx
push dword [ebp - 8]
call dword [sym.imp.KERNEL32.DLL_lstrlenW]
test eax, eax
jle 0x405220
mov eax, dword [ebp - 8]
jmp 0x405222
xor eax, eax
push ebx
push ebx
push 3
push dword [ebp - 0x24]
push eax
push dword [ebp - 0x54]
push dword [ebp - 0x14]
push dword [ebp - 0x10]
call dword [sym.imp.WININET.dll_InternetConnectW]
cmp eax, ebx
mov dword [ebp - 0x2c], eax
je 0x40527f
push dword [ebp - 4]
mov ecx, edi
push eax
call fcn.0040545d
cmp eax, ebx
mov dword [ebp - 0x24], eax
je 0x405274
push ebx
push ebx
push ebx
push dword [ebp - 0x1c]
call dword [sym.imp.KERNEL32.DLL_SetFilePointer]
push dword [ebp - 0x24]
mov ecx, edi
push dword [ebp - 0x1c]
call fcn.00405339
push dword [ebp - 0x24]
call dword [sym.imp.WININET.dll_InternetCloseHandle]
push dword [ebp - 0x2c]
call dword [sym.imp.WININET.dll_InternetCloseHandle]
jmp 0x40529e
push str.InternetConnect
call fcn.004072ab
mov ecx, eax
call fcn.004072c2
mov ecx, edi
call fcn.00404fb9
mov ecx, edi
call fcn.004055c1
cmp byte [edi + 8], bl
je 0x4052ae
mov ecx, edi
call fcn.004055a4
test al, al
jne 0x4052d1
cmp dword [esi + 0x14], ebx
jg 0x4051b8
jmp 0x4052d1
push str.InternetCrackUrl
call fcn.004072ab
mov ecx, eax
call fcn.004072c2
mov ecx, edi
call fcn.00404fb9
push dword [ebp - 0x1c]
call dword [sym.imp.KERNEL32.DLL_CloseHandle]
cmp byte [edi + 8], bl
jne 0x4052e8
push dword [esi + 8]
call dword [sym.imp.KERNEL32.DLL_DeleteFileW]
mov eax, dword [esi + 0x1c]
cmp eax, ebx
je 0x405315
push esi
push 0x64
call eax
jmp 0x405315
push str.CreateFile
jmp 0x405302
push str.InternetOpen
call fcn.004072ab
mov ecx, eax
call fcn.004072c2
mov ecx, edi
call fcn.00404fb9
push dword [ebp - 0x14]
mov esi, dword [sym.imp.KERNEL32.DLL_LocalFree]
call esi
push dword [ebp - 4]
call esi
push dword [ebp - 8]
call esi
push dword [ebp - 0xc]
call esi
push dword [ebp - 0x18]
call esi
pop edi
pop esi
pop ebx
leave
ret