Function at 0x4151f0
Capabilities:
Read http header

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x51b6f0
mov eax, dword fs:[0]
push eax
sub esp, 0x30
push ebx
push esi
push edi
mov eax, dword [0x587978]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov ebx, ecx
mov dword [ebp - 0x2c], ebx
mov eax, dword [ebx + 0x2c]
push 0
lea ecx, [ebp - 0x14]
push ecx
lea edx, [ebp - 0x28]
push edx
push 0
push 0x16
push eax
mov dword [ebp - 0x28], 0
mov dword [ebp - 0x14], 2
call dword [sym.imp.WINHTTP.dll_WinHttpQueryHeaders]
test eax, eax
jne 0x41552f
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x7a
jne 0x41552f
mov eax, dword [0x587944]
mov edx, dword [eax + 0xc]
mov ecx, 0x587944
call edx
lea edi, [eax + 0x10]
mov dword [ebp - 0x1c], edi
mov ecx, 1
mov dword [ebp - 4], ecx
mov esi, dword [ebp - 0x14]
add esi, ecx
mov dword [ebp - 0x14], esi
jns 0x41528b
push 0x80070057
call fcn.00406170
mov eax, dword [edi - 8]
sub ecx, dword [edi - 4]
sub eax, esi
or eax, ecx
jge 0x4152a3
push esi
lea ecx, [ebp - 0x1c]
call fcn.00406e00
mov edi, dword [ebp - 0x1c]
cmp esi, dword [edi - 8]
jg 0x415281
push 0
lea ecx, [ebp - 0x14]
push ecx
push edi
xor eax, eax
mov dword [edi - 0xc], esi
push 0
mov word [edi + esi*2], ax
mov eax, dword [ebx + 0x2c]
push 0x16
push eax
call dword [sym.imp.WINHTTP.dll_WinHttpQueryHeaders]
test eax, eax
mov eax, dword [edi - 8]
push eax
push edi
jne 0x415337
call fcn.004eb8eb
add esp, 8
test eax, eax
js 0x415281
cmp eax, dword [edi - 8]
jg 0x415281
xor edx, edx
mov dword [edi - 0xc], eax
mov word [edi + eax*2], dx
mov eax, dword [ebx + 0x2c]
test eax, eax
je 0x4152fe
push eax
call dword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
mov dword [ebx + 0x2c], 0
mov dword [ebp - 4], 0xffffffff
add edi, 0xfffffff0
lea eax, [edi + 0xc]
or ecx, 0xffffffff
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x41552f
mov ecx, dword [edi]
mov edx, dword [ecx]
mov eax, dword [edx + 4]
push edi
call eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
call fcn.004eb8eb
add esp, 8
test eax, eax
js 0x415281
cmp eax, dword [edi - 8]
jg 0x415281
xor ecx, ecx
lea edx, [ebp - 0x24]
mov dword [edi - 0xc], eax
push edx
mov word [edi + eax*2], cx
push 0x531f38
lea eax, [ebp - 0x10]
mov dword [ebp - 0x24], ecx
push eax
lea ecx, [ebp - 0x1c]
call fcn.00413650
mov byte [ebp - 4], 3
mov ecx, dword [ebp - 0x10]
mov eax, dword [ecx - 0xc]
test eax, eax
je 0x4154e9
js 0x415496
push 0x531f34
push ecx
call fcn.004ec277
add esp, 8
test eax, eax
je 0x415496
sub eax, dword [ebp - 0x10]
sar eax, 1
mov esi, eax
cmp esi, 0xffffffff
je 0x415496
push esi
lea ecx, [ebp - 0x18]
push ecx
lea ecx, [ebp - 0x10]
call fcn.00411010
mov byte [ebp - 4], 4
lea ecx, [ebp - 0x18]
call fcn.004114b0
mov ecx, eax
call fcn.00411530
inc esi
push esi
lea edx, [ebp - 0x20]
push edx
lea ecx, [ebp - 0x10]
call fcn.004120d0
mov byte [ebp - 4], 5
lea ecx, [ebp - 0x20]
call fcn.004114b0
mov ecx, eax
call fcn.00411530
lea ecx, [ebp - 0x18]
call fcn.00410fb0
mov eax, dword [ebp - 0x18]
mov esi, dword [ebp - 0x2c]
lea ecx, [ebp - 0x3c]
push ecx
lea edx, [ebp - 0x30]
push edx
lea ecx, [ebp - 0x34]
push ecx
add esi, 0x40
push eax
mov ecx, esi
mov ebx, eax
call fcn.0040c9d0
test eax, eax
jne 0x415444
cmp dword [esi], eax
jne 0x415434
mov edx, dword [esi + 8]
push 1
push edx
mov ecx, esi
call fcn.0046b2f0
test al, al
je 0x415541
mov eax, dword [ebp - 0x30]
mov ecx, dword [ebp - 0x34]
push eax
push ecx
push ebx
mov ecx, esi
call fcn.004150a0
lea edx, [ebp - 0x20]
lea ecx, [eax + 4]
push edx
call fcn.00411920
mov byte [ebp - 4], 4
mov eax, dword [ebp - 0x20]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x415473
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [ebp - 4], 3
mov eax, dword [ebp - 0x18]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x415496
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
lea ecx, [ebp - 0x24]
push ecx
push 0x531f38
lea edx, [ebp - 0x38]
push edx
lea ecx, [ebp - 0x1c]
call fcn.00413650
mov byte [ebp - 4], 8
push eax
lea ecx, [ebp - 0x10]
call fcn.00411920
mov byte [ebp - 4], 3
mov eax, dword [ebp - 0x38]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4154db
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov ecx, dword [ebp - 0x10]
mov eax, dword [ecx - 0xc]
test eax, eax
jne 0x415383
mov byte [ebp - 4], 1
mov eax, dword [ebp - 0x10]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x41550c
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov dword [ebp - 4], 0xffffffff
add edi, 0xfffffff0
lea ecx, [edi + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x41552f
mov ecx, dword [edi]
mov eax, dword [ecx]
mov edx, dword [eax + 4]
push edi
call edx
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push 0x8007000e
call fcn.00406170
int3