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

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x438776
mov eax, dword fs:[0]
push eax
mov eax, 0x10010
call fcn.0042f880
mov eax, dword [0x44c4c0]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, ecx
mov eax, dword [ebp + 0xc]
mov dword [ebp - 0x10018], eax
xor ebx, ebx
mov dword [ebp - 4], ebx
mov eax, dword [ebp + 8]
cmp dword [eax - 4], 1
jle 0x40e394
push dword [eax - 0xc]
lea ecx, [ebp + 8]
call fcn.0040299d
mov eax, dword [ebp + 8]
push eax
mov ecx, edi
call fcn.004026f7
push eax
push str._nGenericAPICaller::MakeApiRequest_http:___s_s
call fcn.00419acb
push 0x10000
lea eax, [ebp - 0x10010]
mov dword [ebp - 0x10014], ebx
push ebx
push eax
mov esi, ebx
mov dword [ebp - 0x1001c], ebx
call fcn.0041ed30
add esp, 0x18
push ebx
push ebx
push ebx
push ebx
push str.VersionDwl
call dword [sym.imp.WINHTTP.dll_WinHttpOpen]
test eax, eax
jne 0x40e3f7
call dword [sym.imp.KERNEL32.dll_GetLastError]
push ebx
push str.Error__u_in_WinHttpOpen._n
mov esi, eax
call fcn.0041999f
pop ecx
pop ecx
jmp 0x40e51c
push ebx
push 0x50
push dword [edi]
push eax
call dword [sym.imp.WINHTTP.dll_WinHttpConnect]
test eax, eax
jne 0x40e415
call dword [sym.imp.KERNEL32.dll_GetLastError]
push ebx
push str.Error__u_in_WinHttpConnect._n
jmp 0x40e3e9
push ebx
push ebx
push ebx
push ebx
push dword [ebp + 8]
push 0x442b04
push eax
call dword [sym.imp.WINHTTP.dll_WinHttpOpenRequest]
mov edi, eax
test edi, edi
jne 0x40e43c
call dword [sym.imp.KERNEL32.dll_GetLastError]
push ebx
push str.Error__u_in_WinHttpOpenRequest._n
jmp 0x40e3e9
push ebx
push ebx
push ebx
push ebx
push ebx
push ebx
push edi
call dword [sym.imp.WINHTTP.dll_WinHttpSendRequest]
cmp eax, 1
je 0x40e45c
call dword [sym.imp.KERNEL32.dll_GetLastError]
push ebx
push str.Error__u_in_WinHttpSendRequest._n
jmp 0x40e3e9
push ebx
push edi
call dword [sym.imp.WINHTTP.dll_WinHttpReceiveResponse]
mov ecx, dword [ebp - 0x10014]
xor edx, edx
test eax, eax
lea eax, [ebp - 0x10014]
push eax
cmovne ecx, edx
push edi
mov dword [ebp - 0x10014], ecx
call dword [sym.imp.WINHTTP.dll_WinHttpQueryDataAvailable]
test eax, eax
jne 0x40e49c
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
push esi
push str.Error__u_in_WinHttpQueryDataAvailable._n
jmp 0x40e3eb
mov eax, dword [ebp - 0x10014]
test eax, eax
je 0x40e517
lea ecx, [ebp - 0x1001c]
push ecx
push eax
lea eax, [ebp - 0x10010]
add eax, ebx
push eax
push edi
call dword [sym.imp.WINHTTP.dll_WinHttpReadData]
test eax, eax
je 0x40e4e8
add ebx, dword [ebp - 0x10014]
lea eax, [ebp - 0x10014]
and dword [ebp - 0x10014], esi
push eax
push edi
call dword [sym.imp.WINHTTP.dll_WinHttpQueryDataAvailable]
mov eax, dword [ebp - 0x10014]
test eax, eax
jne 0x40e4a6
jmp 0x40e4fd
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
push esi
push str.Error__u_in_WinHttpReadData._n
call fcn.0041999f
pop ecx
pop ecx
test ebx, ebx
je 0x40e517
mov edi, dword [ebp - 0x10018]
lea eax, [ebp - 0x10010]
push eax
mov ecx, edi
call fcn.0040e561
jmp 0x40e522
mov esi, 0xe8
mov edi, dword [ebp - 0x10018]
mov ecx, edi
call fcn.004026f7
push eax
push str.GenericAPICaller::MakeApiRequest_returned__s_n
call fcn.00419acb
pop ecx
pop ecx
mov ecx, dword [ebp + 8]
lea ecx, [ecx - 0x10]
call fcn.00404b8d
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0041c169
mov esp, ebp
pop ebp
ret 8