Function at 0x40b090
Capabilities:
Initialize winhttp library
Prepare http request
Receive http response
Reference http user-agent string

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4cbb6b
mov eax, dword fs:[0]
push eax
sub esp, 0x828
mov eax, dword [0x4fd5c0]
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 ebx, dword [ebp + 0x14]
mov eax, dword [ebp + 0xc]
mov edi, dword [ebp + 8]
mov dword [ebp - 0x800], eax
cmp dword [ebx + 0x14], 0x10
mov eax, dword [ebp + 0x10]
mov dword [ebp - 0x82c], eax
mov dword [ebx + 0x10], 0
jb 0x40b0e7
mov eax, dword [ebx]
jmp 0x40b0e9
mov eax, ebx
mov byte [eax], 0
mov dword [ebp - 0x824], 0
mov dword [ebp - 0x820], 0
mov dword [ebp - 0x828], 0
call fcn.0040cae0
neg eax
sbb esi, esi
lea eax, [ebp - 0x828]
push eax
lea eax, [ebp - 0x820]
and esi, 0x20
push eax
lea eax, [ebp - 0x824]
add esi, 0x20
push eax
call fcn.0040ca90
push 0x20a
lea eax, [ebp - 0x21c]
push 0
push eax
call fcn.004a3390
push esi
push dword [ebp - 0x820]
lea eax, [ebp - 0x21c]
push dword [ebp - 0x824]
push str.Mozilla_5.0__compatible__MSIE_9.0__Windows_NT__d._d__WOW_d__Trident_5.0_
push 0xffffffffffffffff
push 0x104
push eax
call fcn.004036e0
add esp, 0x34
lea eax, [ebp - 0x21c]
push 0
push 0
push 0
push 0
push eax
call dword [sym.imp.WINHTTP.dll_WinHttpOpen]
mov esi, eax
mov dword [ebp - 0x834], esi
test esi, esi
je 0x40b3b8
push 0x2710
push 0x2710
push 0x2710
push 0x2710
push esi
call dword [sym.imp.WINHTTP.dll_WinHttpSetTimeouts]
push 0
push dword [ebp + 0x18]
push edi
push esi
call dword [sym.imp.WINHTTP.dll_WinHttpConnect]
mov esi, dword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
mov dword [ebp - 0x830], eax
test eax, eax
je 0x40b3b0
mov ecx, dword [ebp + 0x1c]
neg ecx
sbb ecx, ecx
and ecx, 0x800000
push ecx
push 0
push 0
push 0
push dword [ebp - 0x800]
push 0x4d0eb4
push eax
call dword [sym.imp.WINHTTP.dll_WinHttpOpenRequest]
mov edi, eax
test edi, edi
je 0x40b3a8
push 0x32
xor eax, eax
mov dword [ebp - 0x804], 7
push str.Content_Type:application_x_www_form_urlencoded_r_n_r_n
lea ecx, [ebp - 0x818]
mov dword [ebp - 0x808], 0
mov word [ebp - 0x818], ax
call fcn.004033f0
mov ecx, dword [ebp - 0x82c]
lea esi, [ebp - 0x818]
cmp dword [ebp - 0x804], 8
push 0
cmovae esi, dword [ebp - 0x818]
mov eax, dword [ecx + 0x10]
push eax
push eax
mov dword [ebp - 4], 0
call fcn.0040af30
push eax
push dword [ebp - 0x808]
push esi
push edi
call dword [sym.imp.WINHTTP.dll_WinHttpSendRequest]
test eax, eax
jne 0x40b295
mov eax, dword [ebp - 0x804]
cmp eax, 8
jb 0x40b386
inc eax
lea ecx, [ebp - 0x818]
push eax
push dword [ebp - 0x818]
call fcn.004034f0
jmp 0x40b386
push 0
push edi
call dword [sym.imp.WINHTTP.dll_WinHttpReceiveResponse]
test eax, eax
je 0x40b26e
mov esi, dword [sym.imp.WINHTTP.dll_WinHttpQueryDataAvailable]
mov dword [ebp - 0x81c], 0
push 0x5dd
lea eax, [ebp - 0x7fc]
push 0
push eax
call fcn.004a3390
add esp, 0xc
lea eax, [ebp - 0x81c]
push eax
push edi
call esi
test eax, eax
je 0x40b324
cmp dword [ebp - 0x81c], 0
je 0x40b324
lea eax, [ebp - 0x800]
mov dword [ebp - 0x800], 0
push eax
push 0x5dc
lea eax, [ebp - 0x7fc]
push eax
push edi
call dword [sym.imp.WINHTTP.dll_WinHttpReadData]
test eax, eax
je 0x40b324
push dword [ebp - 0x800]
lea eax, [ebp - 0x7fc]
mov ecx, ebx
push eax
call fcn.004014f0
cmp dword [ebp - 0x81c], 0
ja 0x40b2b2
mov eax, dword [ebp - 0x804]
cmp eax, 8
jb 0x40b386
mov ecx, dword [ebp - 0x818]
inc eax
cmp eax, 0x7fffffff
jbe 0x40b342
call fcn.004a7532
add eax, eax
cmp eax, 0x1000
jb 0x40b37d
test byte [ebp - 0x818], 0x1f
je 0x40b359
call fcn.004a7532
mov eax, dword [ecx - 4]
cmp eax, ecx
jb 0x40b365
call fcn.004a7532
sub ecx, eax
cmp ecx, 4
jae 0x40b371
call fcn.004a7532
cmp ecx, 0x23
jbe 0x40b37b
call fcn.004a7532
mov ecx, eax
push ecx
call fcn.004a10ce
add esp, 4
mov esi, dword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
xor eax, eax
push edi
mov dword [ebp - 0x804], 7
mov dword [ebp - 0x808], eax
mov word [ebp - 0x818], ax
call esi
push dword [ebp - 0x830]
call esi
push dword [ebp - 0x834]
call esi
mov eax, dword [ebx + 0x10]
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.004a10e1
mov esp, ebp
pop ebp
ret