Function at 0x40d1e9
Capabilities:
Check http status code
Connect to http server
Create http request
Parse url
Read data from internet
Receive data
Send data
Send http request

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x410a00
push 0x40e836
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x484
push ebx
push esi
push edi
mov dword [ebp - 0x128], 4
push dword [ebp + 8]
mov ebx, dword [sym.imp.KERNEL32.dll_lstrlenA]
call ebx
test eax, eax
je 0x40d6de
push dword [ebp + 8]
call fcn.0040aac1
pop ecx
test eax, eax
je 0x40d6de
xor esi, esi
mov dword [ebp - 0x11c], esi
mov dword [ebp - 0x12c], esi
mov dword [ebp - 0x124], esi
mov dword [ebp - 0x120], 0x80004005
mov dword [ebp - 4], esi
push esi
push esi
push esi
push esi
push 0x415a08
call dword [sym.imp.WININET.dll_InternetOpenA]
mov dword [ebp - 0x11c], eax
cmp eax, esi
je 0x40d68e
push 0xf
pop ecx
xor eax, eax
lea edi, [ebp - 0x26c]
rep stosd dword es:[edi], eax
push 0x3c
pop edi
mov dword [ebp - 0x26c], edi
lea eax, [ebp - 0x230]
mov dword [ebp - 0x25c], eax
mov eax, 0x100
mov dword [ebp - 0x258], eax
mov word [ebp - 0x254], si
lea ecx, [ebp - 0x470]
mov dword [ebp - 0x240], ecx
mov dword [ebp - 0x23c], eax
lea ecx, [ebp - 0x36c]
mov dword [ebp - 0x238], ecx
mov dword [ebp - 0x234], eax
lea eax, [ebp - 0x26c]
push eax
push esi
push dword [ebp + 8]
call ebx
push eax
push dword [ebp + 8]
call dword [sym.imp.WININET.dll_InternetCrackUrlA]
push esi
push esi
push 3
push 0x415d84
push 0x415d88
push dword [ebp - 0x254]
push dword [ebp - 0x25c]
push dword [ebp - 0x11c]
call dword [sym.imp.WININET.dll_InternetConnectA]
mov dword [ebp - 0x12c], eax
cmp eax, esi
je 0x40d68e
cmp dword [ebp - 0x23c], esi
je 0x40d32e
push dword [ebp - 0x240]
jmp 0x40d333
push 0x415a10
lea eax, [ebp - 0x118]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
cmp dword [ebp - 0x234], esi
je 0x40d35b
push dword [ebp - 0x238]
lea eax, [ebp - 0x118]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcatA]
mov dword [ebp - 0x370], esi
mov dword [ebp - 0x130], esi
mov dword [ebp - 0x474], edi
mov dword [ebp - 0x370], esi
push esi
push 0x4400000
push esi
push 0x415d8c
push str.HTTP_1.1
lea eax, [ebp - 0x118]
push eax
push 0x415a20
push dword [ebp - 0x12c]
call dword [sym.imp.WININET.dll_HttpOpenRequestA]
mov dword [ebp - 0x124], eax
cmp eax, esi
je 0x40d68e
push 1
pop edi
mov dword [ebp - 0x478], edi
push esi
push esi
push esi
push esi
push dword [ebp - 0x124]
call dword [sym.imp.WININET.dll_HttpSendRequestA]
test eax, eax
jne 0x40d432
cmp dword [ebp - 0x478], esi
je 0x40d68e
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x484], eax
mov ecx, eax
sub ecx, 0x2ee2
je 0x40d419
sub ecx, 5
je 0x40d419
sub ecx, 0x16
je 0x40d419
mov dword [ebp - 0x478], esi
push esi
push 7
push eax
push dword [ebp - 0x124]
call dword [sym.imp.USER32.dll_GetDesktopWindow]
push eax
call dword [sym.imp.WININET.dll_InternetErrorDlg]
cmp eax, 0x2f00
jne 0x40d3b3
jmp 0x40d3ad
mov dword [ebp - 0x478], esi
cmp dword [ebp + 0x14], esi
je 0x40d3b3
push esi
push esi
push eax
push esi
call fcn.0040d037
add esp, 0x10
jmp 0x40d3b3
cmp dword [ebp - 0x478], esi
je 0x40d68e
mov ebx, dword [sym.imp.KERNEL32.dll_GetLastError]
call ebx
mov dword [ebp - 0x480], eax
mov dword [ebp - 0x47c], esi
push esi
lea eax, [ebp - 0x128]
push eax
lea eax, [ebp - 0x47c]
push eax
push 0x20000013
mov edi, dword [ebp - 0x124]
push edi
call dword [sym.imp.WININET.dll_HttpQueryInfoA]
test eax, eax
jne 0x40d47f
call ebx
mov dword [ebp - 0x480], eax
push 1
pop ebx
mov dword [ebp - 0x478], ebx
mov edx, dword [ebp - 0x47c]
cmp edx, 0x197
jne 0x40d4f6
cmp dword [ebp - 0x478], esi
je 0x40d4f6
push esi
push 7
push dword [ebp - 0x480]
push edi
call dword [sym.imp.USER32.dll_GetDesktopWindow]
push eax
call dword [sym.imp.WININET.dll_InternetErrorDlg]
cmp eax, 0x2f00
je 0x40d4c4
mov dword [ebp - 0x478], esi
jmp 0x40d488
push esi
push esi
push esi
push esi
push edi
call dword [sym.imp.WININET.dll_HttpSendRequestA]
mov dword [ebp - 0x128], 4
push esi
lea eax, [ebp - 0x128]
push eax
lea eax, [ebp - 0x47c]
push eax
push 0x20000013
push edi
call dword [sym.imp.WININET.dll_HttpQueryInfoA]
jmp 0x40d488
cmp edx, 0xc8
jne 0x40d55d
mov dword [ebp - 0x488], esi
xor ebx, ebx
mov dword [ebp - 0x490], ebx
mov dword [ebp - 0x488], esi
mov eax, dword [ebp + 0xc]
add eax, ebx
mov dword [ebp - 0x48c], eax
lea ecx, [ebp - 0x488]
push ecx
mov ecx, dword [ebp + 0x10]
sub ecx, ebx
push ecx
push eax
push edi
call dword [sym.imp.WININET.dll_InternetReadFile]
test eax, eax
je 0x40d542
add ebx, dword [ebp - 0x488]
mov dword [ebp - 0x490], ebx
cmp dword [ebp - 0x488], esi
ja 0x40d50c
cmp ebx, esi
jbe 0x40d682
mov dword [ebp - 0x120], esi
jmp 0x40d682
cmp edx, 0x190
jb 0x40d664
cmp edx, 0x258
jae 0x40d664
mov eax, 0x193
cmp edx, eax
je 0x40d62e
add eax, 0x61
cmp edx, eax
jne 0x40d5b1
cmp dword [ebp + 0x14], esi
je 0x40d642
push ebx
push esi
push eax
push esi
call fcn.0040d037
add esp, 0x10
test eax, eax
je 0x40d642
mov dword [ebp - 0x370], ebx
jmp 0x40d642
mov ecx, 0x1f7
cmp edx, ecx
jne 0x40d626
cmp dword [ebp - 0x130], 5
jge 0x40d5f9
mov eax, dword [ebp - 0x474]
mov dword [ebp - 0x494], eax
cmp dword [ebp - 0x494], esi
jl 0x40d5ea
push 0x3e8
call dword [sym.imp.KERNEL32.dll_Sleep]
dec dword [ebp - 0x494]
jmp 0x40d5cf
inc dword [ebp - 0x130]
add dword [ebp - 0x474], 0x1e
jmp 0x40d61e
cmp dword [ebp + 0x14], esi
je 0x40d642
push ebx
push esi
push ecx
push esi
call fcn.0040d037
add esp, 0x10
test eax, eax
je 0x40d642
mov dword [ebp - 0x130], esi
mov dword [ebp - 0x474], 0x3c
mov dword [ebp - 0x370], ebx
jmp 0x40d682
cmp edx, 0x194
je 0x40d642
push esi
xor ecx, ecx
cmp dword [ebp + 0x14], esi
sete cl
push ecx
push eax
push esi
call fcn.0040d037
add esp, 0x10
xor eax, eax
cmp dword [ebp - 0x47c], 0x194
setne al
dec eax
and eax, 0x6c1fd
add eax, 0x80004005
mov dword [ebp - 0x120], eax
jmp 0x40d682
push esi
xor eax, eax
cmp dword [ebp + 0x14], esi
sete al
push eax
push edx
push esi
call fcn.0040d037
add esp, 0x10
mov dword [ebp - 0x120], 0x80004005
cmp dword [ebp - 0x370], esi
jne 0x40d36d
or dword [ebp - 4], 0xffffffff
call fcn.0040d6a1
mov eax, dword [ebp - 0x120]
jmp 0x40d6e0
xor eax, eax
mov ecx, dword [ebp - 0x10]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
leave
ret