Function at 0x402290
Capabilities:
Check http status code
Initialize winhttp library
Prepare http request
Read http header
Receive http response

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
mov ebx, eax
mov esi, dword fs:[0x18]
movzx ebx, bx
sub esp, 0x130
mov dword [esp + 0x10], 0
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0
mov dword [esp + 4], 1
mov dword [esp], 0
call dword [sym.imp.winhttp.dll_WinHttpOpen]
sub esp, 0x14
mov edi, eax
call fcn.00431c30
mov dword [eax], 0x436036
mov dword [eax + 4], 0x624
mov eax, dword [esi + 0x34]
mov dword [esp + 4], 0x4361bc
mov dword [esp + 8], eax
xor eax, eax
test edi, edi
setne al
mov dword [esp], eax
call fcn.00401be0
mov dword [esp + 8], ebx
mov dword [esp + 0xc], 0
mov dword [esp + 4], 0x4361d8
mov dword [ebp - 0x11c], edi
mov dword [esp], edi
call dword [sym.imp.winhttp.dll_WinHttpConnect]
sub esp, 0x10
mov ebx, eax
call fcn.00431c30
mov dword [eax], 0x436036
mov dword [eax + 4], 0x627
mov eax, dword [esi + 0x34]
mov dword [esp + 4], 0x4361ec
mov dword [esp + 8], eax
xor eax, eax
test ebx, ebx
setne al
mov dword [esp], eax
call fcn.00401be0
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], 0
mov dword [esp + 0x10], 0
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0x4362ce
mov dword [esp + 4], 0
mov dword [ebp - 0x120], ebx
mov dword [esp], ebx
call dword [sym.imp.winhttp.dll_WinHttpOpenRequest]
sub esp, 0x1c
mov ebx, eax
call fcn.00431c30
mov dword [eax], 0x436036
mov dword [eax + 4], 0x62a
mov eax, dword [esi + 0x34]
mov dword [esp + 4], 0x43620d
mov dword [esp + 8], eax
xor eax, eax
test ebx, ebx
setne al
mov dword [esp], eax
call fcn.00401be0
mov dword [esp], ebx
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], 0
mov dword [esp + 0x10], 0
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0
mov dword [esp + 4], 0
call dword [sym.imp.winhttp.dll_WinHttpSendRequest]
sub esp, 0x1c
mov edi, eax
call fcn.00431c30
mov dword [eax], 0x436036
mov dword [eax + 4], 0x62d
mov eax, dword [esi + 0x34]
mov dword [esp], edi
mov dword [esp + 8], eax
mov dword [esp + 4], 0x43622b
call fcn.00401be0
mov dword [esp], ebx
mov dword [esp + 4], 0
call dword [sym.imp.winhttp.dll_WinHttpReceiveResponse]
sub esp, 8
mov edi, eax
call fcn.00431c30
mov dword [eax], 0x436036
mov dword [eax + 4], 0x630
mov eax, dword [esi + 0x34]
mov dword [esp], edi
mov dword [esp + 8], eax
mov dword [esp + 4], 0x4362dc
call fcn.00401be0
lea eax, [ebp - 0x110]
mov dword [ebp - 0x114], 0xdeadbeef
mov dword [ebp - 0x110], 4
mov dword [esp + 0x10], eax
lea eax, [ebp - 0x114]
mov dword [esp], ebx
mov dword [esp + 0x14], 0
mov dword [esp + 0xc], eax
mov dword [esp + 8], 0
mov dword [esp + 4], 0x20000013
call dword [sym.imp.winhttp.dll_WinHttpQueryHeaders]
sub esp, 0x18
mov edi, eax
call fcn.00431c30
mov dword [eax], 0x436036
mov dword [eax + 4], 0x635
mov eax, dword [esi + 0x34]
mov dword [esp], edi
lea edi, [ebp - 0x10c]
mov dword [esp + 8], eax
mov dword [esp + 4], 0x4362fc
call fcn.00401be0
call fcn.00431c30
mov dword [eax], 0x436036
mov dword [eax + 4], 0x636
mov eax, dword [ebp - 0x114]
mov dword [esp + 4], 0x436320
cmp eax, 0xc8
mov dword [esp + 8], eax
sete al
movzx eax, al
mov dword [esp], eax
call fcn.00401be0
xor eax, eax
mov ecx, 0x40
lea edx, [ebp - 0x10c]
rep stosd dword es:[edi], eax
lea eax, [ebp - 0x118]
mov dword [ebp - 0x118], 0
mov dword [esp + 4], edx
mov dword [esp], ebx
mov dword [esp + 0xc], eax
mov dword [esp + 8], 0x100
call dword [sym.imp.winhttp.dll_WinHttpReadData]
sub esp, 0x10
mov edi, eax
call fcn.00431c30
mov dword [eax], 0x436036
mov dword [eax + 4], 0x63b
mov eax, dword [esi + 0x34]
mov dword [esp], edi
mov dword [esp + 8], eax
mov dword [esp + 4], 0x436268
call fcn.00401be0
call fcn.00431c30
mov dword [eax], 0x436036
mov dword [eax + 4], 0x63c
xor eax, eax
mov dword [esp + 4], str.count_was_wrong_n
cmp dword [ebp - 0x118], 0x80
sete al
mov dword [esp], eax
call fcn.00401be0
call fcn.00431c30
lea edx, [ebp - 0x10c]
mov dword [eax], 0x436036
mov dword [eax + 4], 0x63d
mov dword [esp], edx
mov dword [esp + 8], 0x81
mov dword [esp + 4], 0x436e80
call sub.msvcrt.dll_memcmp
mov dword [esp + 4], 0x436352
test eax, eax
sete al
movzx eax, al
mov dword [esp], eax
call fcn.00401be0
mov dword [esp], ebx
mov ebx, dword [sym.imp.winhttp.dll_WinHttpCloseHandle]
call ebx
mov eax, dword [ebp - 0x120]
sub esp, 4
mov dword [esp], eax
call ebx
mov edi, dword [ebp - 0x11c]
sub esp, 4
mov dword [esp], edi
call ebx
sub esp, 4
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret