Function at 0x4f7ba0
Capabilities:
Read http header

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x64d00d
mov eax, dword fs:[0]
push eax
sub esp, 0x40
mov eax, dword [0x6d3438]
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 - 0x14]
mov esi, dword [ebp + 8]
push 0
push ecx
push 0
push 0
push dword [ebp + 0x10]
mov dword [ebp - 0x30], esi
push eax
mov dword [ebp - 0x30], eax
mov dword [ebp - 0x14], 0
call dword [sym.imp.WINHTTP.dll_WinHttpQueryHeaders]
test eax, eax
jne 0x4f7d37
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x2f76
jne 0x4f7c3e
xor eax, eax
mov dword [esi], 0
mov dword [esi + 0x10], 0
mov dword [esi + 0x14], 7
mov word [esi], ax
mov eax, esi
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.00608185
mov esp, ebp
pop ebp
ret
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x7a
jne 0x4f7d52
mov ebx, dword [ebp - 0x14]
xor eax, eax
shr ebx, 1
dec ebx
mov dword [ebp - 0x2c], 0
mov dword [ebp - 0x1c], 0
mov dword [ebp - 0x18], 7
mov word [ebp - 0x2c], ax
cmp ebx, 7
ja 0x4f7c94
mov dword [ebp - 0x1c], ebx
test ebx, ebx
je 0x4f7c88
mov ecx, ebx
lea edi, [ebp - 0x2c]
shr ecx, 1
rep stosd dword es:[edi], eax
adc ecx, ecx
rep stosw word es:[edi], ax
xor eax, eax
mov word [ebp + ebx*2 - 0x2c], ax
mov edx, dword [ebp - 0x2c]
jmp 0x4f7cf5
cmp ebx, 0x7ffffffe
ja 0x4f7d86
mov edi, ebx
or edi, 7
cmp edi, 0x7ffffffe
jbe 0x4f7cb4
mov edi, accept
jmp 0x4f7cbe
mov eax, 0xa
cmp edi, eax
cmovb edi, eax
xor ecx, ecx
mov eax, edi
add eax, 1
setb cl
neg ecx
or ecx, eax
push ecx
lea ecx, [ebp - 0x2c]
call fcn.0042ea70
mov edx, eax
mov dword [ebp - 0x18], edi
xor eax, eax
mov dword [ebp - 0x1c], ebx
mov ecx, ebx
mov edi, edx
shr ecx, 1
rep stosd dword es:[edi], eax
adc ecx, ecx
rep stosw word es:[edi], ax
xor eax, eax
mov word [edx + ebx*2], ax
mov dword [ebp - 0x2c], edx
cmp dword [ebp - 0x18], 8
lea ecx, [ebp - 0x14]
push 0
push ecx
lea eax, [ebp - 0x2c]
mov dword [ebp - 4], 0
cmovae eax, edx
push eax
push 0
push dword [ebp + 0x10]
push dword [ebp - 0x30]
call dword [sym.imp.WINHTTP.dll_WinHttpQueryHeaders]
test eax, eax
je 0x4f7d8b
lea eax, [ebp - 0x2c]
mov ecx, esi
push eax
call fcn.0042a550
lea ecx, [ebp - 0x2c]
call fcn.0042f960
jmp 0x4f7c20
push str.WinHttp:_WinHttpQueryHeader_unexpectedly_returned_true
lea ecx, [ebp - 0x34]
call fcn.00447240
push 0x6cd5f0
lea eax, [ebp - 0x34]
push eax
call fcn.0060a2f4
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call fcn.004dd150
add esp, 4
mov esi, eax
call dword [sym.imp.KERNEL32.dll_GetLastError]
push str.WinHttp:_Failed_to_query_header_length
push esi
push eax
lea ecx, [ebp - 0x3c]
call fcn.004857d0
push 0x6cd794
lea eax, [ebp - 0x3c]
push eax
call fcn.0060a2f4
call fcn.0042f3b0
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call fcn.004dd150
add esp, 4
mov esi, eax
call dword [sym.imp.KERNEL32.dll_GetLastError]
push str.WinHttp:_Failed_to_query_header_value
push esi
push eax
lea ecx, [ebp - 0x4c]
call fcn.004857d0
push 0x6cd794
lea eax, [ebp - 0x4c]
push eax
call fcn.0060a2f4
int3