Function at 0x413d80
Capabilities:
Check http status code
Connect to http server
Parse url
Send data
Send http request

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x104c
call fcn.00486ac0
mov eax, dword [0x4cc1c0]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, dword [ebp + 0xc]
push esi
mov esi, ecx
push edi
mov edi, dword [ebp + 8]
cmp dword [esi], 0
je 0x413f3d
push dword [esi + 0xc]
call dword [sym.imp.KERNEL32.dll_ResetEvent]
push dword [esi + 0x10]
call dword [sym.imp.KERNEL32.dll_ResetEvent]
push dword [esi + 0x14]
call dword [sym.imp.KERNEL32.dll_ResetEvent]
push 0x3c
lea eax, [ebp - 0x104c]
push 0
push eax
call fcn.00466700
add esp, 0xc
mov dword [ebp - 0x104c], 0x3c
lea eax, [ebp - 0x104c]
mov dword [ebp - 0x1038], 1
mov ecx, edi
mov dword [ebp - 0x101c], 1
push eax
push 0
push 0
call fcn.0040b7e0
push eax
call dword [sym.imp.WININET.dll_InternetCrackUrlW]
test eax, eax
je 0x413f3d
mov edi, dword [ebp - 0x1038]
cmp edi, 0x400
jae 0x413f3d
cmp dword [ebp - 0x101c], 0x400
jae 0x413f3d
xor eax, eax
cmp dword [esi], eax
je 0x413f3f
push 0x7fe
push eax
mov word [ebp - 0x1008], ax
lea eax, [ebp - 0x1006]
push eax
call fcn.00466700
add esp, 0xc
lea eax, [ebp - 0x1008]
push edi
push dword [ebp - 0x103c]
push 0x400
push eax
call fcn.00466911
mov eax, dword [ebp - 0x1038]
add esp, 0x10
add eax, eax
cmp eax, 0x800
jae 0x4140a1
xor ecx, ecx
mov word [ebp + eax - 0x1008], cx
xor eax, eax
push 0x7fe
push eax
mov word [ebp - 0x808], ax
lea eax, [ebp - 0x806]
push eax
call fcn.00466700
add esp, 0xc
lea eax, [ebp - 0x808]
push dword [ebp - 0x101c]
push dword [ebp - 0x1020]
push 0x400
push eax
call fcn.00466911
mov eax, dword [ebp - 0x101c]
add esp, 0x10
add eax, eax
cmp eax, 0x800
jae 0x4140a1
mov edi, dword [sym.imp.KERNEL32.dll_InterlockedExchange]
xor ecx, ecx
mov word [ebp + eax - 0x808], cx
lea eax, [esi + 8]
push ecx
push eax
call edi
push esi
push 0
push 3
push 0
push 0
push 0
lea eax, [ebp - 0x1008]
push eax
push dword [esi]
call dword [sym.imp.WININET.dll_InternetConnectW]
test eax, eax
jne 0x413f52
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x3e5
jne 0x413f36
mov ecx, esi
call fcn.00413d20
test eax, eax
je 0x413f59
mov ecx, esi
call fcn.004140b0
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004654b1
mov esp, ebp
pop ebp
ret 8
push eax
lea eax, [esi + 8]
push eax
call edi
push esi
push 0x4000000
push 0
push 0
push str.HTTP_1.0
lea eax, [ebp - 0x808]
push eax
mov eax, dword [esi + 8]
push 0x4b5980
push eax
call dword [sym.imp.WININET.dll_HttpOpenRequestW]
mov edi, eax
test edi, edi
jne 0x413f9e
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x3e5
jne 0x413f36
mov ecx, esi
call fcn.00413d20
test eax, eax
jne 0x413f36
jmp 0x413fa9
push edi
lea eax, [esi + 4]
push eax
call dword [sym.imp.KERNEL32.dll_InterlockedExchange]
test ebx, ebx
je 0x413fc2
cmp word [ebx], 0
je 0x413fc2
push 0xa0000000
push 0xffffffffffffffff
push ebx
push edi
call dword [sym.imp.WININET.dll_HttpAddRequestHeadersW]
push dword [esi + 0xc]
call dword [sym.imp.KERNEL32.dll_ResetEvent]
mov eax, dword [esi + 4]
push 0
push 0
push 0
push 0
push eax
call dword [sym.imp.WININET.dll_HttpSendRequestW]
test eax, eax
jne 0x414001
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x3e5
jne 0x413f36
mov ecx, esi
call fcn.00413d20
test eax, eax
jne 0x413f36
push 0
lea eax, [ebp - 0x1010]
mov dword [ebp - 0x1010], 4
push eax
lea eax, [ebp - 0x100c]
mov dword [ebp - 0x100c], 0
push eax
mov eax, dword [esi + 4]
push 0x20000013
push eax
call dword [sym.imp.WININET.dll_HttpQueryInfoW]
test eax, eax
je 0x413f36
push dword [ebp - 0x100c]
push str.HttpQueryInfo__return_StatusCode_d
push 0xca
push str.HttpHttpWinet.cpp
call fcn.0040fa10
mov eax, dword [ebp - 0x100c]
add esp, 0x10
cmp eax, 0xc8
je 0x414089
cmp eax, 0xce
je 0x414089
push str.DownloadFile_error4
push 0xca
push str.HttpHttpWinet.cpp
call fcn.0040fa10
add esp, 0xc
jmp 0x413f36
mov ecx, dword [ebp - 4]
mov eax, 1
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.004654b1
mov esp, ebp
pop ebp
ret 8
call fcn.0046ba17
int3