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

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x433f06
mov eax, dword fs:[0]
push eax
sub esp, 0x194
mov eax, dword [0x4420a0]
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 eax, dword [ebp + 0xc]
lea ecx, [ebp - 0xe8]
mov esi, dword [ebp + 0x10]
mov ebx, dword [ebp + 8]
mov dword [ebp - 0x174], eax
mov eax, dword [ebp + 0x14]
push 0
mov dword [ebp - 0x170], eax
mov eax, dword [ebp + 0x18]
push 0x43778c
mov dword [ebp - 0x198], esi
mov dword [ebp - 0x17c], eax
mov dword [ebp - 0xd4], 0xf
mov dword [ebp - 0xd8], 0
mov byte [ebp - 0xe8], 0
call fcn.00406720
mov dword [ebp - 4], 0
test esi, esi
je 0x413913
mov dword [esi], 0xffffffff
xor eax, eax
mov byte [ebp - 0x165], 1
cmp dword [ebx + 0x24], 0x10
mov dword [ebp - 0x184], eax
mov dword [ebp - 0x16c], eax
lea eax, [ebx + 0x10]
jb 0x413933
mov eax, dword [eax]
push eax
lea eax, [ebp - 0x164]
push eax
call fcn.00413070
mov dword [ebp - 0x14], 0xf
mov dword [ebp - 0x18], 0
mov byte [ebp - 0x28], 0
mov dword [ebp - 0x74], 0xf
mov dword [ebp - 0x78], 0
mov byte [ebp - 0x88], 0
cmp dword [ebp - 0x150], 0x10
lea eax, [ebp - 0x164]
push 0
cmovae eax, dword [ebp - 0x164]
push eax
lea eax, [ebp - 0x40]
mov byte [ebp - 4], 3
push eax
call fcn.0042b7c0
add esp, 0x14
xor eax, eax
mov dword [ebp - 0xec], 7
mov dword [ebp - 0xf0], 0
mov word [ebp - 0x100], ax
push eax
push eax
push eax
push eax
push str.user_agent
mov byte [ebp - 4], 5
call dword [sym.imp.WINHTTP.dll_WinHttpOpen]
mov edi, dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, eax
mov dword [ebp - 0x194], ecx
test ecx, ecx
je 0x41417f
cmp dword [ebp - 0x2c], 8
lea eax, [ebp - 0x40]
push 0
push dword [ebp - 0x134]
cmovae eax, dword [ebp - 0x40]
push eax
push ecx
call dword [sym.imp.WINHTTP.dll_WinHttpConnect]
mov esi, eax
mov dword [ebp - 0x184], esi
test esi, esi
je 0x414181
lea eax, [ebx + 8]
push eax
lea eax, [ebp - 0xa0]
push eax
call fcn.00412be0
mov esi, eax
add esp, 8
lea eax, [ebp - 0x28]
cmp eax, esi
je 0x413a47
cmp dword [ebp - 0x14], 0x10
jb 0x413a2c
push dword [ebp - 0x28]
call sub.MSVCR120.dll_void___cdecl_operator_delete_void__
add esp, 4
push esi
lea ecx, [ebp - 0x28]
mov dword [ebp - 0x14], 0xf
mov dword [ebp - 0x18], 0
mov byte [ebp - 0x28], 0
call fcn.00404e00
cmp dword [ebp - 0x8c], 0x10
jb 0x413a5e
push dword [ebp - 0xa0]
call sub.MSVCR120.dll_void___cdecl_operator_delete_void__
add esp, 4
cmp dword [ebp - 0x120], 0
je 0x413b49
cmp dword [ebp - 0x18], 0
je 0x413b36
push 0x438054
lea ecx, [ebp - 0x58]
call fcn.004033a0
push eax
lea eax, [ebp - 0x130]
mov byte [ebp - 4], 6
push eax
lea eax, [ebp - 0xa0]
push eax
call fcn.00410a20
lea ecx, [ebp - 0x28]
mov byte [ebp - 4], 7
push ecx
push eax
lea eax, [ebp - 0xd0]
push eax
call fcn.004109a0
add esp, 0x18
lea ecx, [ebp - 0x28]
push eax
call fcn.00404460
cmp dword [ebp - 0xbc], 0x10
jb 0x413ad2
push dword [ebp - 0xd0]
call sub.MSVCR120.dll_void___cdecl_operator_delete_void__
add esp, 4
cmp dword [ebp - 0x8c], 0x10
mov dword [ebp - 0xbc], 0xf
mov dword [ebp - 0xc0], 0
mov byte [ebp - 0xd0], 0
jb 0x413b04
push dword [ebp - 0xa0]
call sub.MSVCR120.dll_void___cdecl_operator_delete_void__
add esp, 4
cmp dword [ebp - 0x44], 0x10
mov dword [ebp - 0x8c], 0xf
mov dword [ebp - 0x90], 0
mov byte [ebp - 0xa0], 0
mov byte [ebp - 4], 5
jb 0x413b49
push dword [ebp - 0x58]
call sub.MSVCR120.dll_void___cdecl_operator_delete_void__
add esp, 4
jmp 0x413b49
push 0xffffffffffffffff
push 0
lea eax, [ebp - 0x130]
push eax
lea ecx, [ebp - 0x28]
call fcn.004064f0
cmp dword [ebp - 0x13c], 0
je 0x413c18
mov eax, dword [ebp - 0x18]
test eax, eax
je 0x413c05
cmp dword [ebp - 0x14], 0x10
lea eax, [ebp - 0x28]
cmovae eax, dword [ebp - 0x28]
cmp byte [eax], 0x3f
jne 0x413b9b
lea eax, [ebp - 0x28]
push eax
lea eax, [ebp - 0x14c]
push eax
lea eax, [ebp - 0x58]
push eax
call fcn.00410aa0
add esp, 0xc
lea ecx, [ebp - 0x28]
push eax
call fcn.00404460
lea ecx, [ebp - 0x58]
call fcn.00403db0
jmp 0x413c18
push 0x438058
lea ecx, [ebp - 0xd0]
call fcn.004033a0
push eax
lea eax, [ebp - 0x14c]
mov byte [ebp - 4], 8
push eax
lea eax, [ebp - 0xa0]
push eax
call fcn.00410a20
lea ecx, [ebp - 0x28]
mov byte [ebp - 4], 9
push ecx
push eax
lea eax, [ebp - 0x58]
push eax
call fcn.004109a0
add esp, 0x18
lea ecx, [ebp - 0x28]
push eax
call fcn.00404460
lea ecx, [ebp - 0x58]
call fcn.00403db0
lea ecx, [ebp - 0xa0]
call fcn.00403db0
lea ecx, [ebp - 0xd0]
mov byte [ebp - 4], 5
call fcn.00403db0
jmp 0x413c18
push 0xffffffffffffffff
push 0
lea eax, [ebp - 0x14c]
push eax
lea ecx, [ebp - 0x28]
call fcn.004064f0
cmp dword [ebp - 0x14], 0x10
lea eax, [ebp - 0x28]
push 0
cmovae eax, dword [ebp - 0x28]
push eax
lea eax, [ebp - 0x58]
push eax
call fcn.0042b7c0
mov esi, eax
add esp, 0xc
lea eax, [ebp - 0x40]
cmp eax, esi
je 0x413c69
cmp dword [ebp - 0x2c], 8
jb 0x413c4c
push dword [ebp - 0x40]
call sub.MSVCR120.dll_void___cdecl_operator_delete_void__
add esp, 4
xor eax, eax
mov dword [ebp - 0x2c], 7
push esi
lea ecx, [ebp - 0x40]
mov dword [ebp - 0x30], 0
mov word [ebp - 0x40], ax
call fcn.0040de90
cmp dword [ebp - 0x44], 8
jb 0x413c7a
push dword [ebp - 0x58]
call sub.MSVCR120.dll_void___cdecl_operator_delete_void__
add esp, 4
cmp dword [ebp - 0x2c], 8
lea eax, [ebp - 0x40]
push 0
cmovae eax, dword [ebp - 0x40]
push 0
push 0
push 0x43805c
push eax
mov eax, dword [ebp - 0x184]
push 0x438070
push eax
call dword [sym.imp.WINHTTP.dll_WinHttpOpenRequest]
mov dword [ebp - 0x16c], eax
test eax, eax
je 0x414183
lea eax, [ebp - 0x58]
push ebx
push eax
call fcn.00412a60
mov esi, eax
add esp, 8
lea eax, [ebp - 0x28]
cmp eax, esi
je 0x413cf3
cmp dword [ebp - 0x14], 0x10
jb 0x413cd8
push dword [ebp - 0x28]
call sub.MSVCR120.dll_void___cdecl_operator_delete_void__
add esp, 4
push esi
lea ecx, [ebp - 0x28]
mov dword [ebp - 0x14], 0xf
mov dword [ebp - 0x18], 0
mov byte [ebp - 0x28], 0
call fcn.00404e00
cmp dword [ebp - 0x44], 0x10
jb 0x413d04
push dword [ebp - 0x58]
call sub.MSVCR120.dll_void___cdecl_operator_delete_void__
add esp, 4
cmp dword [ebp - 0x14], 0x10
lea eax, [ebp - 0x28]
push 0
cmovae eax, dword [ebp - 0x28]
push eax
lea eax, [ebp - 0x58]
push eax
call fcn.0042b7c0
mov esi, eax
add esp, 0xc
lea eax, [ebp - 0x40]
cmp eax, esi
je 0x413d55
cmp dword [ebp - 0x2c], 8
jb 0x413d38
push dword [ebp - 0x40]
call sub.MSVCR120.dll_void___cdecl_operator_delete_void__
add esp, 4
xor eax, eax
mov dword [ebp - 0x2c], 7
push esi
lea ecx, [ebp - 0x40]
mov dword [ebp - 0x30], 0
mov word [ebp - 0x40], ax
call fcn.0040de90
cmp dword [ebp - 0x44], 8
jb 0x413d66
push dword [ebp - 0x58]
call sub.MSVCR120.dll_void___cdecl_operator_delete_void__
add esp, 4
mov eax, dword [ebx + 0x2c]
lea ecx, [ebp - 0x40]
cmp dword [ebp - 0x2c], 8
push eax
cmovae ecx, dword [ebp - 0x40]
push eax
push eax
push dword [ebx + 0x28]
mov ebx, dword [ebp - 0x16c]
push dword [ebp - 0x30]
push ecx
push ebx
call dword [sym.imp.WINHTTP.dll_WinHttpSendRequest]
test eax, eax
je 0x41418b
push 0
push ebx
call dword [sym.imp.WINHTTP.dll_WinHttpReceiveResponse]
test eax, eax
je 0x414170
mov edi, dword [sym.imp.WINHTTP.dll_WinHttpQueryHeaders]
lea eax, [ebp - 0x180]
push 0
push eax
push 0
push 0
push 0x16
push ebx
mov dword [ebp - 0x180], 0
call edi
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x7a
jne 0x414100
mov esi, dword [ebp - 0x180]
xor ecx, ecx
shr esi, 1
mov edx, 2
mov eax, esi
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.00430658
add esp, 4
mov dword [ebp - 0x178], eax
lea ecx, [ebp - 0x180]
push 0
push ecx
push eax
push 0
push 0x16
push ebx
call edi
push esi
push dword [ebp - 0x178]
lea eax, [ebp - 0x190]
push eax
call fcn.00414980
add esp, 0xc
mov edi, dword [ebp - 0x174]
lea eax, [ebp - 0x190]
push eax
mov byte [ebp - 4], 0xa
lea ecx, [edi + 0x24]
call fcn.00412350
mov esi, dword [ebp - 0x190]
mov eax, dword [esi]
mov dword [ebp - 0x188], eax
cmp eax, esi
je 0x4140c3
mov ebx, edi
jmp 0x413e60
lea edi, [eax + 0x10]
mov dword [ebp - 0xa4], 7
xor eax, eax
mov dword [ebp - 0xa8], 0
push 0xffffffffffffffff
push eax
push edi
lea ecx, [ebp - 0xb8]
mov word [ebp - 0xb8], ax
call fcn.0040ed50
xor eax, eax
mov byte [ebp - 4], 0xb
push 0xffffffffffffffff
push eax
mov word [ebp - 0xa0], ax
lea ecx, [ebp - 0xa0]
lea eax, [edi + 0x18]
mov dword [ebp - 0x8c], 7
push eax
mov dword [ebp - 0x90], 0
call fcn.0040ed50
cmp dword [ebp - 0xa4], 8
lea eax, [ebp - 0xb8]
push dword [ebp - 0x17c]
cmovae eax, dword [ebp - 0xb8]
push eax
lea eax, [ebp - 0x58]
mov byte [ebp - 4], 0xc
push eax
call fcn.0042ba30
mov edi, eax
add esp, 0xc
lea eax, [ebp - 0x28]
cmp eax, edi
je 0x413f22
cmp dword [ebp - 0x14], 0x10
jb 0x413f07
push dword [ebp - 0x28]
call sub.MSVCR120.dll_void___cdecl_operator_delete_void__
add esp, 4
push edi
lea ecx, [ebp - 0x28]
mov dword [ebp - 0x14], 0xf
mov dword [ebp - 0x18], 0
mov byte [ebp - 0x28], 0
call fcn.00404e00
cmp dword [ebp - 0x44], 0x10
jb 0x413f33
push dword [ebp - 0x58]
call sub.MSVCR120.dll_void___cdecl_operator_delete_void__
add esp, 4
cmp dword [ebp - 0x8c], 8
lea eax, [ebp - 0xa0]
push dword [ebp - 0x17c]
cmovae eax, dword [ebp - 0xa0]
push eax
lea eax, [ebp - 0x58]
push eax
call fcn.0042ba30
mov edi, eax
add esp, 0xc
lea eax, [ebp - 0x88]
cmp eax, edi
je 0x413f9b
cmp dword [ebp - 0x74], 0x10
jb 0x413f7a
push dword [ebp - 0x88]
call sub.MSVCR120.dll_void___cdecl_operator_delete_void__
add esp, 4
push edi
lea ecx, [ebp - 0x88]
mov dword [ebp - 0x74], 0xf
mov dword [ebp - 0x78], 0
mov byte [ebp - 0x88], 0
call fcn.00404e00
cmp dword [ebp - 0x44], 0x10
jb 0x413fac
push dword [ebp - 0x58]
call sub.MSVCR120.dll_void___cdecl_operator_delete_void__
add esp, 4
push 0xffffffffffffffff
push 0
lea eax, [ebp - 0x28]
mov dword [ebp - 0x5c], 0xf
push eax
lea ecx, [ebp - 0x70]
mov dword [ebp - 0x60], 0
mov byte [ebp - 0x70], 0
call fcn.004064f0
push 0xffffffffffffffff
push 0
lea eax, [ebp - 0x88]
mov byte [ebp - 4], 0xd
push eax
lea ecx, [ebp - 0x58]
mov dword [ebp - 0x44], 0xf
mov dword [ebp - 0x48], 0
mov byte [ebp - 0x58], 0
call fcn.004064f0
lea eax, [ebp - 0x70]
mov byte [ebp - 4], 0xe
push eax
mov ecx, ebx
call fcn.00410c90
push eax
add eax, 0x10
mov ecx, ebx
push eax
push 0
lea eax, [ebp - 0x1a0]
push eax
call fcn.004112a0
cmp dword [ebp - 0x44], 0x10
jb 0x41402c
push dword [ebp - 0x58]
call sub.MSVCR120.dll_void___cdecl_operator_delete_void__
add esp, 4
cmp dword [ebp - 0x5c], 0x10
mov dword [ebp - 0x44], 0xf
mov dword [ebp - 0x48], 0
mov byte [ebp - 0x58], 0
jb 0x41404f
push dword [ebp - 0x70]
call sub.MSVCR120.dll_void___cdecl_operator_delete_void__
add esp, 4
lea ecx, [ebp - 0x188]
call fcn.004048a0
cmp dword [ebp - 0x8c], 8
mov byte [ebp - 4], 0xa
jb 0x414075
push dword [ebp - 0xa0]
call sub.MSVCR120.dll_void___cdecl_operator_delete_void__
add esp, 4
xor eax, eax
mov dword [ebp - 0x8c], 7
cmp dword [ebp - 0xa4], 8
mov dword [ebp - 0x90], 0
mov word [ebp - 0xa0], ax
jb 0x4140a9
push dword [ebp - 0xb8]
call sub.MSVCR120.dll_void___cdecl_operator_delete_void__
add esp, 4
mov eax, dword [ebp - 0x188]
cmp eax, esi
jne 0x413e60
mov ebx, dword [ebp - 0x16c]
mov edi, dword [ebp - 0x174]
push dword [ebp - 0x178]
call sub.MSVCR120.dll_void___cdecl_operator_delete___void__
mov eax, dword [ebp - 0x190]
lea ecx, [ebp - 0x190]
add esp, 4
mov byte [ebp - 4], 5
push eax
push dword [eax]
lea eax, [ebp - 0x178]
push eax
call fcn.004076c0
push dword [ebp - 0x190]
call sub.MSVCR120.dll_void___cdecl_operator_delete_void__
add esp, 4
jmp 0x414106
mov edi, dword [ebp - 0x174]
lea eax, [ebp - 0x178]
push eax
push 0
push ebx
call fcn.00414680
mov esi, eax
add esp, 0xc
test esi, esi
je 0x41414f
push esi
lea ecx, [edi + 8]
call fcn.004044c0
push dword [ebp - 0x17c]
lea eax, [ebp - 0x58]
push esi
push eax
call fcn.0042b7c0
add esp, 0xc
lea ecx, [edi + 0x2c]
push eax
call fcn.0040da50
lea ecx, [ebp - 0x58]
call fcn.00403de0
xor eax, eax
jmp 0x414194
mov edi, dword [ebp - 0x170]
mov ecx, edi
push str.error_occured_when_recv_http_data:
call fcn.004044c0
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov byte [ebp - 0x165], 0
jmp 0x41419a
mov byte [ebp - 0x165], 0
call dword [sym.imp.KERNEL32.dll_GetLastError]
jmp 0x414194
call edi
call edi
call edi
mov ebx, dword [ebp - 0x16c]
mov byte [ebp - 0x165], 0
call edi
mov edi, dword [ebp - 0x170]
mov ecx, dword [ebp - 0x198]
test ecx, ecx
je 0x4141a6
mov dword [ecx], eax
push eax
lea eax, [ebp - 0x58]
push eax
call fcn.00413610
mov esi, eax
add esp, 8
cmp edi, esi
je 0x4141e2
cmp dword [edi + 0x14], 0x10
jb 0x4141c9
push dword [edi]
call sub.MSVCR120.dll_void___cdecl_operator_delete_void__
add esp, 4
mov dword [edi + 0x14], 0xf
mov ecx, edi
mov dword [edi + 0x10], 0
push esi
mov byte [edi], 0
call fcn.00404e00
cmp dword [ebp - 0x44], 0x10
jb 0x4141f3
push dword [ebp - 0x58]
call sub.MSVCR120.dll_void___cdecl_operator_delete_void__
add esp, 4
mov esi, dword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
test ebx, ebx
je 0x414200
push ebx
call esi
mov eax, dword [ebp - 0x184]
test eax, eax
je 0x41420d
push eax
call esi
mov eax, dword [ebp - 0x194]
test eax, eax
je 0x41421a
push eax
call esi
cmp dword [ebp - 0x2c], 8
jb 0x41422b
push dword [ebp - 0x40]
call sub.MSVCR120.dll_void___cdecl_operator_delete_void__
add esp, 4
xor eax, eax
mov dword [ebp - 0x2c], 7
cmp dword [ebp - 0x74], 0x10
mov dword [ebp - 0x30], 0
mov word [ebp - 0x40], ax
jb 0x414253
push dword [ebp - 0x88]
call sub.MSVCR120.dll_void___cdecl_operator_delete_void__
add esp, 4
cmp dword [ebp - 0x14], 0x10
mov dword [ebp - 0x74], 0xf
mov dword [ebp - 0x78], 0
mov byte [ebp - 0x88], 0
jb 0x414279
push dword [ebp - 0x28]
call sub.MSVCR120.dll_void___cdecl_operator_delete_void__
add esp, 4
lea ecx, [ebp - 0x164]
mov dword [ebp - 0x14], 0xf
mov dword [ebp - 0x18], 0
mov byte [ebp - 0x28], 0
call fcn.00412200
cmp dword [ebp - 0xd4], 0x10
jb 0x4142ad
push dword [ebp - 0xe8]
call sub.MSVCR120.dll_void___cdecl_operator_delete_void__
add esp, 4
mov al, byte [ebp - 0x165]
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.004308d0
mov esp, ebp
pop ebp
ret