Function at 0x4014ec
Capabilities:
Initialize winhttp library
Prepare http request
Read http header
Receive http response

Disassembly:
sub esp, 0x1c
or dword [esp + 4], 0xffffffff
mov eax, edx
push ebx
push ebp
push esi
push edi
mov esi, ecx
mov dword [esp + 0x20], eax
xor ecx, ecx
push ecx
push ecx
mov dword [eax], ecx
mov edi, ecx
mov eax, dword [esp + 0x38]
mov ebp, ecx
push ecx
push ecx
push ecx
mov dword [esp + 0x2c], ecx
mov dword [eax], ecx
call dword [sym.imp.WINHTTP.dll_WinHttpOpen]
mov ebx, eax
mov dword [esp + 0x28], ebx
test ebx, ebx
je 0x401719
cmp dword [esi + 0x1c], edi
je 0x401543
cmp dword [esi + 0x20], edi
je 0x401543
push ebp
push dword [esi + 0x20]
push dword [esi + 0x1c]
push ebx
call dword [sym.imp.WINHTTP.dll_WinHttpSetStatusCallback]
movzx eax, word [esi + 0xc]
push 0
push eax
push dword [esi]
push ebx
call dword [sym.imp.WINHTTP.dll_WinHttpConnect]
mov edx, eax
mov dword [esp + 0x24], edx
test edx, edx
je 0x401712
mov eax, dword [esi + 0x10]
mov ecx, str.POST
neg eax
sbb eax, eax
xor ebx, ebx
and eax, 0x800000
mov dword [esp + 0x1c], eax
cmp dword [esi + 0x18], ebx
jne 0x401582
mov ecx, 0x404514
push eax
push ebx
push ebx
push ebx
push dword [esi + 4]
push ecx
push edx
call dword [sym.imp.WINHTTP.dll_WinHttpOpenRequest]
mov ebx, eax
test ebx, ebx
je 0x401704
cmp dword [esi + 0x10], edi
je 0x4015b8
push 4
lea eax, [esp + 0x20]
mov dword [esp + 0x20], 0x3300
push eax
push 0x1f
push ebx
call dword [sym.imp.WINHTTP.dll_WinHttpSetOption]
mov eax, dword [esi + 8]
push 0
push dword [esi + 0x18]
neg eax
push dword [esi + 0x18]
sbb eax, eax
push dword [esi + 0x14]
push eax
push dword [esi + 8]
push ebx
call dword [sym.imp.WINHTTP.dll_WinHttpSendRequest]
test eax, eax
je 0x4016fd
xor esi, esi
push esi
push ebx
call dword [sym.imp.WINHTTP.dll_WinHttpReceiveResponse]
test eax, eax
je 0x4016fd
push esi
lea eax, [esp + 0x14]
mov dword [esp + 0x14], 4
push eax
lea eax, [esp + 0x1c]
push eax
push esi
mov esi, dword [sym.imp.WINHTTP.dll_WinHttpQueryHeaders]
push 0x20000013
push ebx
call esi
neg eax
mov dword [esp + 0x10], 4
push 0
sbb eax, eax
and dword [esp + 0x18], eax
lea eax, [esp + 0x14]
push eax
lea eax, [esp + 0x20]
push eax
push 0
push 0x20000005
push ebx
call esi
neg eax
sbb eax, eax
and dword [esp + 0x10], edi
and dword [esp + 0x18], eax
lea eax, [esp + 0x10]
push eax
push ebx
call dword [sym.imp.WINHTTP.dll_WinHttpQueryDataAvailable]
mov esi, dword [sym.imp.KERNEL32.dll_GetProcessHeap]
jmp 0x4016bd
mov eax, dword [esp + 0x10]
test eax, eax
je 0x4016c5
inc eax
add eax, ebp
je 0x4016c3
inc eax
push eax
test edi, edi
je 0x401678
push edi
push 8
call esi
push eax
call dword [sym.imp.KERNEL32.dll_HeapReAlloc]
jmp 0x401683
push 8
call esi
push eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov edi, eax
test edi, edi
je 0x4016c5
lea eax, [esp + 0x10]
push eax
push dword [esp + 0x14]
lea eax, [edi + ebp]
push eax
push ebx
call dword [sym.imp.WINHTTP.dll_WinHttpReadData]
test eax, eax
je 0x4016c5
cmp dword [esp + 0x10], 0
je 0x4016c5
add ebp, dword [esp + 0x10]
lea eax, [esp + 0x10]
and dword [esp + 0x10], 0
push eax
push ebx
call dword [sym.imp.WINHTTP.dll_WinHttpQueryDataAvailable]
test eax, eax
jne 0x401657
jmp 0x4016c5
xor edi, edi
cmp dword [esp + 0x18], 0
je 0x4016e9
cmp dword [esp + 0x18], ebp
je 0x4016e9
test edi, edi
je 0x4016e2
push edi
push 0
call esi
push eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
or dword [esp + 0x14], 0xffffffff
jmp 0x4016fd
test edi, edi
je 0x4016f1
mov byte [edi + ebp], 0
mov eax, dword [esp + 0x20]
mov dword [eax], edi
mov eax, dword [esp + 0x30]
mov dword [eax], ebp
push ebx
call dword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
push dword [esp + 0x24]
call dword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
mov ebx, dword [esp + 0x28]
push ebx
call dword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
mov eax, dword [esp + 0x14]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x1c
ret