Function at 0x40511f
Capabilities:
Connect to http server

Disassembly:
mov eax, 0x417488
call fcn.0040c000
sub esp, 0xcc
push ebx
push esi
push edi
mov esi, ecx
xor edi, edi
cmp dword [esi + 0x94], edi
je 0x405146
cmp dword [esi + 0x98], edi
je 0x40514e
push 3
pop eax
jmp 0x4052a6
lea ecx, [ebp - 0x1c]
call sub.MFC42.DLL_CString::CString_3
lea ecx, [ebp - 0x18]
mov dword [ebp - 4], edi
call sub.MFC42.DLL_CString::CString_3
lea ecx, [ebp - 0x10]
mov byte [ebp - 4], 1
call sub.MFC42.DLL_CString::CString_3
lea ecx, [ebp - 0x14]
mov byte [ebp - 4], 2
call sub.MFC42.DLL_CString::CString_3
push 3
lea ecx, [ebp - 0x18]
pop ebx
mov eax, dword [esi + 0xcc]
push 0x20000000
push ecx
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], bl
push ecx
lea ecx, [ebp - 0x30]
push ecx
lea ecx, [ebp - 0x14]
push ecx
lea ecx, [ebp - 0x10]
push ecx
lea ecx, [ebp - 0x44]
push ecx
push eax
call sub.MFC42.DLL_AfxParseURLEx
test eax, eax
je 0x405272
cmp dword [ebp - 0x44], ebx
jne 0x405272
lea eax, [ebp - 0x14]
lea ecx, [esi + 0x5c]
push eax
call sub.MFC42.DLL_CString::operator
lea eax, [ebp - 0x10]
lea ecx, [esi + 0x60]
push eax
call sub.MFC42.DLL_CString::operator
mov ecx, dword [ebp - 0x18]
mov edx, dword [ebp - 0x1c]
push esi
push edi
mov eax, dword [ecx - 8]
push ebx
neg eax
sbb eax, eax
and eax, ecx
mov ecx, dword [edx - 8]
neg ecx
sbb ecx, ecx
push eax
and ecx, edx
push ecx
push dword [ebp - 0x30]
push dword [ebp - 0x10]
push dword [esi + 0x94]
call dword [sym.imp.WININET.dll_InternetConnectA]
cmp eax, edi
mov dword [esi + 0x98], eax
jne 0x405252
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x3e5
je 0x40521e
push eax
push edi
call sub.MFC42.DLL_AfxThrowInternetException
lea eax, [ebp - 0x3c]
push 1
push eax
mov ecx, esi
call fcn.0040b97d
test eax, eax
je 0x405236
push 6
jmp 0x4053b8
mov eax, dword [ebp - 0x3c]
cmp eax, dword [esi + 0x130]
jne 0x405266
mov eax, dword [esi + 0x128]
cmp eax, edi
je 0x405252
push eax
push edi
call sub.MFC42.DLL_AfxThrowInternetException
push dword [esi + 0x130]
call dword [sym.imp.KERNEL32.dll_ResetEvent]
cmp dword [esi + 0x98], edi
jne 0x4052b5
push 0x422a40
mov ecx, esi
call fcn.0040440e
mov esi, ebx
lea ecx, [ebp - 0x14]
mov byte [ebp - 4], 2
call sub.MFC42.DLL_CString::CString
lea ecx, [ebp - 0x10]
mov byte [ebp - 4], 1
call sub.MFC42.DLL_CString::CString
and byte [ebp - 4], 0
lea ecx, [ebp - 0x18]
call sub.MFC42.DLL_CString::CString
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x1c]
call sub.MFC42.DLL_CString::CString
mov eax, esi
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
pop ebx
mov dword fs:[0], ecx
leave
ret
lea eax, [ebp - 0xd8]
mov dword [ebp - 0xd8], 0x94
push eax
call dword [sym.imp.KERNEL32.dll_GetVersionExA]
cmp dword [ebp - 0xc8], 1
je 0x4052e1
cmp dword [ebp - 0xc8], edi
jne 0x4053b6
push 4
lea eax, [ebp - 0x2c]
pop ebx
mov dword [ebp - 0x28], edi
mov edi, dword [sym.imp.WININET.dll_InternetQueryOptionA]
push eax
lea eax, [ebp - 0x28]
mov dword [ebp - 0x2c], ebx
push eax
push 2
push dword [esi + 0x98]
call edi
lea eax, [ebp - 0x2c]
push eax
lea eax, [ebp - 0x28]
push eax
push 5
push dword [esi + 0x98]
call edi
lea eax, [ebp - 0x2c]
push eax
lea eax, [ebp - 0x28]
push eax
push 6
push dword [esi + 0x98]
call edi
mov eax, 0x7530
push ebx
mov ebx, dword [sym.imp.WININET.dll_InternetSetOptionA]
mov dword [ebp - 0x40], eax
mov dword [ebp - 0x38], eax
lea eax, [ebp - 0x34]
push eax
push 6
push dword [esi + 0x98]
mov dword [ebp - 0x34], 0xea60
call ebx
test eax, eax
je 0x405375
lea eax, [ebp - 0x38]
push 4
push eax
push 5
push dword [esi + 0x98]
call ebx
test eax, eax
je 0x405375
lea eax, [ebp - 0x40]
push 4
push eax
push 2
push dword [esi + 0x98]
call ebx
lea eax, [ebp - 0x24]
and dword [ebp - 0x20], 0
push eax
lea eax, [ebp - 0x20]
push eax
push 2
push dword [esi + 0x98]
mov dword [ebp - 0x24], 4
call edi
lea eax, [ebp - 0x24]
push eax
lea eax, [ebp - 0x20]
push eax
push 5
push dword [esi + 0x98]
call edi
lea eax, [ebp - 0x24]
push eax
lea eax, [ebp - 0x20]
push eax
push 6
push dword [esi + 0x98]
call edi
push 2
pop esi
jmp 0x405274