Function at 0x405360
Capabilities:
Initialize winhttp library
Prepare http request
Receive http response

Disassembly:
sub esp, 0x10
push ebp
push 0
push 0
push 0
push 0
push str.Hemesoft_HTTP_Client_1.0
call dword [sym.imp.WINHTTP.dll_WinHttpOpen]
mov ebp, eax
test ebp, ebp
je 0x4053b7
push 0x2710
push 0x2710
push 0x1388
push 0x7d0
push ebp
call dword [sym.imp.WINHTTP.dll_WinHttpSetTimeouts]
test eax, eax
jne 0x4053be
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.Error__u_in_WinHttpSetTimeouts._n
call fcn.00401b10
add esp, 8
push ebp
call dword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
xor eax, eax
pop ebp
add esp, 0x10
ret
push esi
push 0
push dword [esp + 0x28]
push dword [esp + 0x24]
push ebp
call dword [sym.imp.WINHTTP.dll_WinHttpConnect]
mov esi, eax
mov dword [esp + 0x14], esi
test esi, esi
jne 0x4053fd
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.Error__u_in_WinHttpConnect._n
call fcn.00401b10
add esp, 8
push ebp
call dword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
pop esi
xor eax, eax
pop ebp
add esp, 0x10
ret
push ebx
push 0
push 0
push 0
push 0
push dword [esp + 0x34]
push 0x41fb80
push esi
call dword [sym.imp.WINHTTP.dll_WinHttpOpenRequest]
mov ebx, eax
test ebx, ebx
jne 0x405445
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.Error__u_in_WinHttpOpenRequest._n
call fcn.00401b10
add esp, 8
push esi
mov esi, dword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
call esi
push ebp
call esi
pop ebx
pop esi
xor eax, eax
pop ebp
add esp, 0x10
ret
push edi
push 0
push 0
push 0
push 0
push 0
push 0
push ebx
call dword [sym.imp.WINHTTP.dll_WinHttpSendRequest]
mov edi, eax
test edi, edi
je 0x4055ae
push 0
push ebx
call dword [sym.imp.WINHTTP.dll_WinHttpReceiveResponse]
mov edi, eax
mov dword [esp + 0x18], edi
test edi, edi
jne 0x40548f
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.Error__u_in_WinHttpReceiveResponse._n
call fcn.00401b10
add esp, 8
jmp 0x405562
mov esi, dword [esp + 0x30]
mov ecx, esi
call fcn.00405d90
mov dword [esp + 0x10], 0
mov dword [esp + 0x14], 0
nop word [eax + eax]
lea eax, [esp + 0x10]
push eax
push ebx
call dword [sym.imp.WINHTTP.dll_WinHttpQueryDataAvailable]
test eax, eax
je 0x405596
mov edi, dword [esi + 0x10]
mov eax, dword [esp + 0x10]
add eax, edi
cmp eax, edi
ja 0x4054ea
mov dword [esi + 0x10], eax
cmp dword [esi + 0x14], 0x10
jb 0x4054e2
mov ecx, dword [esi]
mov byte [ecx + eax], 0
jmp 0x4054f6
mov ecx, esi
mov byte [ecx + eax], 0
jmp 0x4054f6
push 0
sub eax, edi
mov ecx, esi
push eax
call fcn.00405c70
lea eax, [esp + 0x14]
mov ecx, esi
push eax
push dword [esp + 0x14]
call fcn.00405db0
add eax, edi
push eax
push ebx
call dword [sym.imp.WINHTTP.dll_WinHttpReadData]
test eax, eax
je 0x40557e
mov ecx, dword [esp + 0x10]
mov edi, dword [esp + 0x14]
cmp ecx, edi
jbe 0x405556
mov edx, dword [esi + 0x10]
mov eax, edx
sub eax, ecx
add eax, edi
cmp eax, edx
ja 0x405546
mov dword [esi + 0x10], eax
cmp dword [esi + 0x14], 0x10
jb 0x40553e
mov ecx, dword [esi]
mov byte [ecx + eax], 0
jmp 0x405552
mov ecx, esi
mov byte [ecx + eax], 0
jmp 0x405552
push 0
sub eax, edx
mov ecx, esi
push eax
call fcn.00405c70
mov ecx, dword [esp + 0x10]
test ecx, ecx
jne 0x4054b0
mov edi, dword [esp + 0x18]
mov esi, dword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
push ebx
call esi
push dword [esp + 0x1c]
call esi
push ebp
call esi
mov eax, edi
pop edi
pop ebx
pop esi
pop ebp
add esp, 0x10
ret
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.Error__u_in_WinHttpReadData._n
call fcn.00401b10
add esp, 8
xor edi, edi
jmp 0x405562
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.Error__u_in_WinHttpQueryDataAvailable._n
call fcn.00401b10
add esp, 8
xor edi, edi
jmp 0x405562
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.Error__u_in_WinHttpSendRequest._n
call fcn.00401b10
add esp, 8
jmp 0x405562