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

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5de511
mov eax, dword fs:[0]
push eax
sub esp, 0x50
mov eax, dword [0x66e8b0]
xor eax, ebp
mov dword [ebp - 0x10], eax
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x5c], ecx
mov dword [ebp - 4], 0
mov byte [ebp - 0x11], 0
mov dword [ebp - 0x1c], 0
mov dword [ebp - 0x20], 0
mov dword [ebp - 0x18], 0
push 0
push 0
lea ecx, [ebp + 8]
call fcn.0040f680
push eax
push 3
push str.WinHTTP_1.0
call dword [sym.imp.WINHTTP.dll_WinHttpOpen]
mov dword [ebp - 0x1c], eax
cmp dword [ebp - 0x1c], 0
je 0x4922a2
push 0
mov eax, dword [ebp - 0x5c]
movzx ecx, word [eax + 0x220]
push ecx
mov edx, dword [ebp - 0x5c]
mov eax, dword [edx + 0x218]
push eax
mov ecx, dword [ebp - 0x1c]
push ecx
call dword [sym.imp.WINHTTP.dll_WinHttpConnect]
mov dword [ebp - 0x20], eax
cmp dword [ebp - 0x20], 0
je 0x4922a2
mov dword [ebp - 0x24], 0
mov edx, dword [ebp - 0x5c]
xor eax, eax
cmp dword [edx + 0x214], 2
setne al
sub eax, 1
and eax, 0x800000
mov dword [ebp - 0x24], eax
mov ecx, dword [ebp - 0x24]
push ecx
push 0
push 0
push 0
mov edx, dword [ebp - 0x5c]
mov eax, dword [edx + 0x234]
push eax
push 0x5f9b20
mov ecx, dword [ebp - 0x20]
push ecx
call dword [sym.imp.WINHTTP.dll_WinHttpOpenRequest]
mov dword [ebp - 0x18], eax
cmp dword [ebp - 0x18], 0
je 0x4922a2
push 4
mov edx, dword [ebp - 0x5c]
add edx, 0x1244
push edx
push 3
mov eax, dword [ebp - 0x1c]
push eax
call dword [sym.imp.WINHTTP.dll_WinHttpSetOption]
push 4
mov ecx, dword [ebp - 0x5c]
add ecx, 0x1244
push ecx
push 6
mov edx, dword [ebp - 0x1c]
push edx
call dword [sym.imp.WINHTTP.dll_WinHttpSetOption]
push 0
push 0
push 0
push 0
push 0
push 0
mov eax, dword [ebp - 0x18]
push eax
call dword [sym.imp.WINHTTP.dll_WinHttpSendRequest]
test eax, eax
je 0x4922a2
push 0
mov ecx, dword [ebp - 0x18]
push ecx
call dword [sym.imp.WINHTTP.dll_WinHttpReceiveResponse]
test eax, eax
je 0x4922a2
push 0
lea edx, [ebp - 0x28]
push edx
push 0
push 0
push 0x16
mov eax, dword [ebp - 0x18]
push eax
call dword [sym.imp.WINHTTP.dll_WinHttpQueryHeaders]
test eax, eax
jne 0x4922a2
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x2c], eax
cmp dword [ebp - 0x2c], 0x7a
jne 0x4922a2
mov eax, dword [ebp - 0x28]
shr eax, 1
xor ecx, ecx
mov edx, 2
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.0059cee6
add esp, 4
mov dword [ebp - 0x50], eax
mov eax, dword [ebp - 0x50]
mov dword [ebp - 0x30], eax
cmp dword [ebp - 0x30], 0
je 0x4922a2
push 0
lea ecx, [ebp - 0x28]
push ecx
mov edx, dword [ebp - 0x30]
push edx
push 0
push 0x16
mov eax, dword [ebp - 0x18]
push eax
call dword [sym.imp.WINHTTP.dll_WinHttpQueryHeaders]
test eax, eax
je 0x492290
mov ecx, dword [ebp - 0x30]
push ecx
lea ecx, [ebp - 0x4c]
call fcn.00492400
mov byte [ebp - 4], 1
lea edx, [ebp - 0x4c]
push edx
mov ecx, dword [ebp - 0x5c]
call fcn.00491240
movzx eax, al
test eax, eax
je 0x492284
mov byte [ebp - 0x11], 1
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x4c]
call fcn.00490dc0
mov ecx, dword [ebp - 0x30]
mov dword [ebp - 0x54], ecx
mov edx, dword [ebp - 0x54]
push edx
call fcn.005a03f1
add esp, 4
cmp dword [ebp - 0x18], 0
je 0x4922b2
mov eax, dword [ebp - 0x18]
push eax
call dword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
cmp dword [ebp - 0x20], 0
je 0x4922c2
mov ecx, dword [ebp - 0x20]
push ecx
call dword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
cmp dword [ebp - 0x1c], 0
je 0x4922d2
mov edx, dword [ebp - 0x1c]
push edx
call dword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
mov al, byte [ebp - 0x11]
mov byte [ebp - 0x55], al
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 8]
call fcn.00490dc0
mov al, byte [ebp - 0x55]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0059e318
mov esp, ebp
pop ebp
ret 0x1c