Function at 0x40d0b1
Capabilities:
Check for time delay via gettickcount
Receive data
Receive data on socket

Disassembly:
sub esp, 0x44
or dword [esp + 0xc], 0xffffffff
xor eax, eax
push ebx
push ebp
mov bl, al
mov dword [esp + 0x24], eax
mov dword [esp + 0x30], eax
mov ebp, eax
mov dword [esp + 0x3c], eax
mov dword [esp + 0xc], eax
mov dword [esp + 0x2c], eax
mov eax, dword [esp + 0x5c]
mov byte [esp + 0xb], bl
push esi
push edi
test eax, eax
je 0x40d0ea
mov ebp, dword [eax]
dec ebp
mov dword [esp + 0x44], ebp
push 0x1cc
push 0x1618
mov esi, 0x1f4
call fcn.00401286
mov dword [esp + 0x28], eax
test eax, eax
je 0x40d4f1
add eax, 0x1000
mov dword [esp + 0x3c], eax
add eax, 0x208
cmp dword [esp + 0x68], 0
mov dword [esp + 0x18], eax
lea ecx, [eax + 0x104]
lea esi, [ecx + 0x104]
mov dword [esp + 0x4c], ecx
mov dword [esp + 0x30], esi
je 0x40d149
push dword [esp + 0x68]
call dword [sym.imp.KERNEL32.dll_lstrlenA]
mov dword [esp + 0x2c], eax
mov eax, dword [esp + 0x18]
and dword [esp + 0x48], 0
mov edi, dword [esp + 0x60]
mov byte [esi], bl
cmp byte [esi], 0
lea ecx, [esp + 0x20]
push 0x50
push ecx
push eax
mov eax, dword [esp + 0x68]
cmovne eax, esi
push eax
call fcn.0040cdcb
push 0x429724
push dword [esp + 0x60]
mov esi, eax
call fcn.00406e98
test eax, eax
jns 0x40d193
test esi, esi
jne 0x40d193
test edi, edi
je 0x40d193
cmp byte [edi], 0
je 0x40d193
inc bl
mov byte [esp + 0x13], bl
test bl, bl
jne 0x40d19f
test esi, esi
je 0x40d3dc
cmp dword [esp + 0x58], 0
je 0x40d235
test bl, bl
mov ebx, dword [esp + 0x18]
jne 0x40d1e2
push dword [esp + 0x6c]
mov eax, dword [esp + 0x30]
xor ecx, ecx
push ecx
push ecx
push ecx
push ecx
cdq
push edx
push eax
push ecx
push ecx
push esi
push dword [esp + 0x48]
push ebx
push 0xffffffffffffffff
call fcn.0040cc01
mov esi, eax
test esi, esi
jne 0x40d1e4
mov esi, 0x1f4
jmp 0x40d4f5
mov esi, edi
lea eax, [esp + 0x24]
mov dword [esp + 0x24], 0xfff
push eax
push dword [esp + 0x2c]
push dword [esp + 0x70]
push esi
call dword [sym.imp.KERNEL32.dll_lstrlenA]
push eax
push esi
push dword [esp + 0x34]
push ebx
push dword [esp + 0x74]
call fcn.0040cf8a
cmp byte [esp + 0x13], 0
mov ebx, eax
mov dword [esp + 0x1c], ebx
jne 0x40d223
push esi
call fcn.00404070
cmp ebx, 0xffffffff
je 0x40d3e6
mov eax, dword [esp + 0x24]
jmp 0x40d2b9
push dword [esp + 0x20]
mov ebx, dword [esp + 0x1c]
push ebx
call fcn.0040cee2
mov ebx, eax
mov dword [esp + 0x1c], ebx
cmp ebx, 0xffffffff
je 0x40d3e6
push 1
push ebx
call fcn.0040ce9a
cmp byte [esp + 0x13], 0
jne 0x40d285
push dword [esp + 0x6c]
mov eax, dword [esp + 0x30]
xor ecx, ecx
push ecx
push ecx
push ecx
push ecx
cdq
push edx
push eax
push ecx
push ecx
push esi
push dword [esp + 0x48]
push dword [esp + 0x44]
push ebx
call fcn.0040cc01
jmp 0x40d28c
push edi
push ebx
call fcn.0040cd36
cmp dword [esp + 0x68], 0
je 0x40d29d
push dword [esp + 0x68]
push ebx
call fcn.0040cd36
push 0x2710
push 0xfff
push dword [esp + 0x30]
push ebx
call fcn.0040cb5c
test eax, eax
jle 0x40d3e6
mov ecx, dword [esp + 0x28]
push 0x104
lea esi, [ecx + 0x1000]
lea ebx, [eax + ecx]
push esi
push ecx
mov dword [esp + 0x5c], ebx
mov byte [ebx], 0
call fcn.00402167
push 0
push 1
push esi
mov dword [esp + 0x30], eax
call fcn.00406666
push eax
call fcn.00401734
push 5
push str.HTTP_
push dword [esp + 0x44]
mov esi, eax
call sub.ntdll.dll_memcmp
add esp, 0xc
test eax, eax
jne 0x40d4ea
mov eax, dword [esp + 0x24]
cmp byte [eax], 0
je 0x40d3a3
mov edi, dword [esp + 0x3c]
mov ebp, dword [esp + 0x30]
mov ebx, dword [esp + 0x4c]
push 0x104
push edi
push eax
call fcn.00402167
cmp byte [edi], 0
mov dword [esp + 0x24], eax
je 0x40d397
push ebx
push 0x4294f8
push edi
call fcn.004058bf
add esp, 0xc
push 1
push edi
call fcn.00406666
push str.Content_Length:
push ebx
mov dword [esp + 0x48], eax
call dword [sym.imp.KERNEL32.dll_lstrcmpA]
test eax, eax
jne 0x40d373
push eax
push dword [esp + 0x44]
call fcn.00401734
mov dword [esp + 0x34], eax
jmp 0x40d38e
push str.Location:
push ebx
call dword [sym.imp.KERNEL32.dll_lstrcmpA]
test eax, eax
jne 0x40d38e
push dword [esp + 0x40]
push ebp
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
mov eax, dword [esp + 0x24]
cmp byte [eax], 0
jne 0x40d323
mov edi, dword [esp + 0x60]
mov ebx, dword [esp + 0x50]
mov ebp, dword [esp + 0x44]
cmp esi, 0x12e
jne 0x40d3fa
mov eax, dword [esp + 0x48]
inc eax
mov dword [esp + 0x48], eax
cmp eax, 0xa
jg 0x40d3f0
mov eax, dword [esp + 0x30]
cmp byte [eax], 0
je 0x40d3fa
push dword [esp + 0x1c]
call fcn.0040cff8
mov bl, byte [esp + 0x13]
mov eax, dword [esp + 0x18]
mov esi, dword [esp + 0x30]
jmp 0x40d154
mov esi, 0x190
jmp 0x40d4f5
mov esi, 0x1e4
jmp 0x40d4f5
mov esi, 0x1ec
jmp 0x40d4f5
test edi, edi
je 0x40d502
call dword [sym.imp.WS2_32.dll_WSACreateEvent]
push 1
push eax
push dword [esp + 0x24]
mov dword [esp + 0x44], eax
call dword [sym.imp.WS2_32.dll_WSAEventSelect]
call dword [sym.imp.KERNEL32.dll_GetTickCount]
mov dword [esp + 0x68], eax
mov eax, dword [esp + 0x24]
sub ebx, eax
test ebx, ebx
jle 0x40d455
cmp ebx, ebp
jle 0x40d448
push ebp
push eax
push edi
call sub.ntdll.dll_memcpy
add esp, 0xc
mov esi, 0x1e5
add edi, ebp
jmp 0x40d4f9
push ebx
push eax
push edi
call sub.ntdll.dll_memcpy
add esp, 0xc
jmp 0x40d469
push 0
push ebp
push edi
push dword [esp + 0x28]
call dword [sym.imp.WS2_32.dll_recv]
mov ebx, eax
test ebx, ebx
jle 0x40d49a
call dword [sym.imp.KERNEL32.dll_GetTickCount]
mov ecx, dword [esp + 0x34]
add edi, ebx
mov dword [esp + 0x68], eax
sub ebp, ebx
mov eax, dword [esp + 0x14]
add eax, ebx
mov dword [esp + 0x14], eax
test ecx, ecx
je 0x40d48f
cmp ecx, eax
je 0x40d4f5
jb 0x40d4ce
test ebp, ebp
jne 0x40d455
mov esi, 0x1e5
jmp 0x40d4f5
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x2733
jne 0x40d4dc
call dword [sym.imp.KERNEL32.dll_GetTickCount]
sub eax, dword [esp + 0x68]
cmp eax, 0x7530
ja 0x40d4d5
mov ebx, dword [esp + 0x38]
push 0x64
push ebx
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
push ebx
call dword [sym.imp.KERNEL32.dll_ResetEvent]
jmp 0x40d455
mov esi, 0xd2
jmp 0x40d4f5
mov esi, 0x198
jmp 0x40d4f5
cmp dword [esp + 0x34], 0
je 0x40d4f5
mov esi, 0x1e6
jmp 0x40d4f5
mov esi, 0x19c
jmp 0x40d4f5
mov edi, dword [esp + 0x60]
mov ebp, dword [esp + 0x14]
test edi, edi
je 0x40d506
mov byte [edi], 0
jmp 0x40d506
mov ebp, dword [esp + 0x14]
mov eax, dword [esp + 0x64]
test eax, eax
je 0x40d510
mov dword [eax], ebp
push dword [esp + 0x1c]
call fcn.0040cff8
mov eax, dword [esp + 0x38]
test eax, eax
je 0x40d528
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push dword [esp + 0x28]
call fcn.00404070
pop edi
mov eax, esi
pop esi
pop ebp
pop ebx
add esp, 0x44
ret 0x18