Function at 0x408920
Capabilities:
Check for time delay via gettickcount
Create tcp socket
Create udp socket
Receive data
Receive data on socket

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4352ac
mov eax, dword fs:[0]
push eax
sub esp, 0x95c
mov eax, dword [0x440320]
xor eax, ebp
mov dword [ebp - 0x30], eax
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x884], 0
lea ecx, [ebp - 0x870]
call fcn.00401000
mov dword [ebp - 4], 0
mov byte [ebp - 0x834], 0
push 0x7ff
push 0
lea eax, [ebp - 0x833]
push eax
call fcn.00423ab0
add esp, 0xc
lea ecx, [ebp - 0x90c]
call fcn.004058f0
mov byte [ebp - 4], 1
mov dword [ebp - 0x85c], 0
mov dword [ebp - 0x854], 0
mov dword [ebp - 0x874], 0
cmp dword [ebp + 8], 1
jne 0x4089cd
mov dword [ebp - 0x854], 0x14
mov dword [ebp - 0x874], 0x7d0
jmp 0x4089e7
cmp dword [ebp + 8], 0
jne 0x4089e7
mov dword [ebp - 0x854], 5
mov dword [ebp - 0x874], 0
mov ecx, dword [ebp + 0x1c]
mov dword [ecx], 0
mov dword [ebp - 0x918], 0
mov dword [ebp - 0x83c], 0
mov edx, dword [ebp + 0x28]
mov dword [edx], 0
mov dword [ebp - 0x850], 0
mov dword [ebp - 0x14], 0
mov dword [ebp - 0x1c], 0
mov dword [ebp - 0x24], 0
mov eax, dword [ebp - 0x24]
mov dword [ebp - 0x91c], eax
mov dword [ebp - 0x10], 0
mov ecx, dword [ebp + 0xc]
call fcn.00403d00
push eax
call fcn.00408830
add esp, 4
mov dword [ebp - 0x914], eax
cmp dword [ebp - 0x914], 0xffffffff
jne 0x408aad
cmp dword [ebp - 0x10], 5
jae 0x408a77
push 0x64
call dword [sym.imp.KERNEL32.dll_Sleep]
mov ecx, dword [ebp - 0x10]
add ecx, 1
mov dword [ebp - 0x10], ecx
jmp 0x408a3c
mov dword [ebp - 0x964], 0
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x90c]
call fcn.004059d0
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x870]
call fcn.00407e20
mov eax, dword [ebp - 0x964]
jmp 0x4092c5
push 0
push 1
push 2
call sub.WSOCK32.dll_socket
mov dword [ebp - 0x838], eax
cmp dword [ebp - 0x838], 0xffffffff
jne 0x408ad6
mov dword [ebp - 0x884], 0
jmp 0x409292
call dword [sym.imp.KERNEL32.dll_GetTickCount]
mov dword [ebp - 0x18], eax
mov edx, 2
mov word [ebp - 0x84c], dx
mov eax, dword [ebp - 0x914]
mov dword [ebp - 0x848], eax
movzx ecx, word [ebp + 0x10]
push ecx
call sub.WSOCK32.dll_htons
mov word [ebp - 0x84a], ax
cmp dword [ebp + 8], 1
jne 0x408b34
push 0xf
push 0xa
push 0x3c
push 0x10
lea edx, [ebp - 0x84c]
push edx
mov eax, dword [ebp - 0x838]
push eax
call fcn.004080a0
add esp, 0x18
mov dword [ebp - 0x87c], eax
jmp 0x408b5e
cmp dword [ebp + 8], 0
jne 0x408b5e
push 0xf
push 0xa
push 2
push 0x10
lea ecx, [ebp - 0x84c]
push ecx
mov edx, dword [ebp - 0x838]
push edx
call fcn.004080a0
add esp, 0x18
mov dword [ebp - 0x87c], eax
cmp dword [ebp - 0x87c], 0xffffffff
jne 0x408c1b
mov eax, dword [ebp + 0x1c]
cmp dword [eax], 0
je 0x408bcc
cmp dword [ebp - 0x14], 5
jae 0x408ba3
push 0x7d0
call dword [sym.imp.KERNEL32.dll_Sleep]
mov ecx, dword [ebp - 0x14]
add ecx, 1
mov dword [ebp - 0x14], ecx
mov edx, dword [ebp - 0x838]
push edx
call fcn.00407fc0
add esp, 4
jmp 0x408aad
mov eax, dword [ebp + 0x28]
mov dword [eax], 0xa
mov ecx, dword [ebp - 0x838]
push ecx
call fcn.00407fc0
add esp, 4
mov dword [ebp - 0x884], 0
jmp 0x409292
mov edx, dword [ebp + 0x28]
mov dword [edx], 0
mov eax, dword [ebp - 0x838]
push eax
call fcn.00407fc0
add esp, 4
mov ecx, dword [ebp - 0x1c]
cmp ecx, dword [ebp - 0x854]
jae 0x408c0c
mov edx, dword [ebp - 0x874]
push edx
call dword [sym.imp.KERNEL32.dll_Sleep]
mov eax, dword [ebp - 0x1c]
add eax, 1
mov dword [ebp - 0x1c], eax
jmp 0x408aad
mov dword [ebp - 0x884], 0
jmp 0x409292
mov dword [ebp - 0x14], 0
mov dword [ebp - 0x1c], 0
mov dword [ebp - 0x860], 0
push 0x4397bc
push str.Accept:__r_nAccept_Encoding:_deflate_r_nAccept_Language:zh_cn_r_nContent_Type_r_nAccept_Encoding_r_nReferer_r_nUser_Agent:Mozilla_4.0__compatible__MSIE_6.0__Windows_NT_5.1__SV1__r_nHost_r_nRange:_r_nContent_Length_r_nConnection:Close_r_nCache_Control:no_cache_r_nCookie
lea ecx, [ebp - 0x90c]
call fcn.00405b10
push 0x4398b8
lea ecx, [ebp - 0x90c]
call fcn.00405ee0
mov ecx, dword [ebp + 0x24]
neg ecx
sbb ecx, ecx
and ecx, 2
mov dword [ebp - 0x908], ecx
mov edx, dword [ebp + 0x14]
push edx
lea ecx, [ebp - 0x8f8]
call fcn.00407770
push str.Mozilla_4.0__compatible__MSIE_6.0__Windows_NT_5.1__SV1__.NET_CLR_2.0.50727__
push str.User_Agent
lea ecx, [ebp - 0x90c]
call fcn.00406100
mov ecx, dword [ebp + 0xc]
call fcn.00403d00
push eax
push str.Host
lea ecx, [ebp - 0x90c]
call fcn.00406100
push str.no_cache
push str.Cache_Control
lea ecx, [ebp - 0x90c]
call fcn.00406100
mov eax, dword [ebp + 0x1c]
cmp dword [eax], 0
je 0x408cd5
push 0
mov ecx, dword [ebp + 0x1c]
mov edx, dword [ecx]
push edx
lea ecx, [ebp - 0x90c]
call fcn.00406160
push 0
lea ecx, [ebp - 0x90c]
call fcn.00406230
call dword [sym.imp.KERNEL32.dll_GetTickCount]
mov dword [ebp - 0x18], eax
lea ecx, [ebp - 0x8c0]
call fcn.00403de0
mov dword [ebp - 0x28], eax
push 0
mov eax, dword [ebp - 0x28]
push eax
push 0
lea ecx, [ebp - 0x90c]
call fcn.00406230
push eax
mov ecx, dword [ebp - 0x838]
push ecx
call fcn.00407ef0
add esp, 0x10
movzx edx, al
test edx, edx
jne 0x408d32
mov dword [ebp - 0x860], 0xb
jmp 0x409095
cmp dword [ebp + 0x24], 0
je 0x408d6d
cmp dword [ebp + 0x20], 0
je 0x408d6d
push 0
mov eax, dword [ebp + 0x24]
push eax
mov ecx, dword [ebp + 0x20]
push ecx
mov edx, dword [ebp - 0x838]
push edx
call fcn.00407ef0
add esp, 0x10
movzx eax, al
test eax, eax
jne 0x408d6d
mov dword [ebp - 0x860], 0xc
jmp 0x409095
mov dword [ebp - 0x880], 0
mov dword [ebp - 0x2c], 0
mov dword [ebp - 0x20], 0
call dword [sym.imp.KERNEL32.dll_GetTickCount]
mov dword [ebp - 0x18], eax
lea ecx, [ebp - 0x870]
call fcn.00407e20
mov ecx, 1
test ecx, ecx
je 0x409095
push 0
push 0x800
lea edx, [ebp - 0x834]
push edx
mov eax, dword [ebp - 0x838]
push eax
call sub.WSOCK32.dll_recv
mov dword [ebp - 0x87c], eax
cmp dword [ebp - 0x87c], 0xffffffff
jne 0x408de9
cmp dword [ebp - 0x860], 0
jne 0x408de2
mov dword [ebp - 0x860], 0xd
jmp 0x409095
cmp dword [ebp - 0x87c], 0
jne 0x408e0a
cmp dword [ebp - 0x860], 0
jne 0x408e05
mov dword [ebp - 0x860], 0xe
jmp 0x409095
cmp dword [ebp - 0x880], 0
jne 0x409011
mov ecx, dword [ebp - 0x87c]
push ecx
lea edx, [ebp - 0x834]
push edx
lea ecx, [ebp - 0x870]
call fcn.00407e40
lea ecx, [ebp - 0x870]
call fcn.00401020
mov dword [ebp - 0x858], eax
push str._r_n_r_n
mov eax, dword [ebp - 0x858]
push eax
call fcn.00403c60
add esp, 8
mov dword [ebp - 0x910], eax
cmp dword [ebp - 0x910], 0
je 0x40900c
mov ecx, dword [ebp - 0x910]
add ecx, 2
mov dword [ebp - 0x910], ecx
mov edx, dword [ebp - 0x910]
mov byte [edx], 0
mov eax, dword [ebp - 0x910]
mov byte [eax + 1], 0
mov ecx, dword [ebp - 0x910]
add ecx, 2
mov dword [ebp - 0x910], ecx
mov edx, dword [ebp - 0x910]
sub edx, dword [ebp - 0x858]
mov dword [ebp - 0x28], edx
push 0x439944
mov eax, dword [ebp - 0x858]
push eax
lea ecx, [ebp - 0x90c]
call fcn.00405b10
mov ecx, dword [ebp - 0x8a4]
mov dword [ebp - 0x860], ecx
cmp dword [ebp - 0x850], 0
jne 0x408f0e
push str.Accept_Ranges
lea ecx, [ebp - 0x90c]
call fcn.004061e0
neg eax
sbb eax, eax
neg eax
mov dword [ebp - 0x850], eax
jne 0x408f0e
push 0x439958
lea ecx, [ebp - 0x90c]
call fcn.004061e0
neg eax
sbb eax, eax
neg eax
mov dword [ebp - 0x850], eax
push str.Content_Length
lea ecx, [ebp - 0x90c]
call fcn.004061e0
mov dword [ebp - 0x878], eax
cmp dword [ebp - 0x878], 0
je 0x408f83
push 0xa
push 0
mov edx, dword [ebp - 0x878]
push edx
call fcn.0041f291
add esp, 0xc
mov dword [ebp - 0x20], eax
cmp dword [ebp - 0x860], 0xc8
jne 0x408f83
cmp dword [ebp - 0x20], 0
je 0x408f83
cmp dword [ebp - 0x83c], 0
jne 0x408f69
mov eax, dword [ebp - 0x20]
mov dword [ebp - 0x83c], eax
jmp 0x408f83
mov ecx, dword [ebp - 0x83c]
cmp ecx, dword [ebp - 0x20]
je 0x408f83
mov dword [ebp - 0x860], 0x136
jmp 0x409095
mov edx, dword [ebp + 0x1c]
cmp dword [edx], 0
je 0x408fc3
push str.Content_Range
lea ecx, [ebp - 0x90c]
call fcn.004061e0
mov dword [ebp - 0x878], eax
cmp dword [ebp - 0x878], 0
je 0x408fc3
lea eax, [ebp - 0x83c]
push eax
mov ecx, dword [ebp - 0x878]
push ecx
call fcn.00408600
add esp, 8
mov dword [ebp - 0x20], eax
mov edx, dword [ebp - 0x864]
sub edx, dword [ebp - 0x28]
mov dword [ebp - 0x87c], edx
je 0x408ff5
mov eax, dword [ebp - 0x87c]
push eax
mov ecx, dword [ebp - 0x28]
lea edx, [ebp + ecx - 0x834]
push edx
lea eax, [ebp - 0x834]
push eax
call fcn.0041f2c0
add esp, 0xc
mov dword [ebp - 0x880], 1
lea ecx, [ebp - 0x870]
call fcn.00407e20
jmp 0x409011
jmp 0x408d99
cmp dword [ebp - 0x87c], 0
je 0x40906a
cmp dword [ebp - 0x860], 0xc8
je 0x409032
cmp dword [ebp - 0x860], 0xce
jne 0x40905e
cmp dword [ebp + 0x18], 0
je 0x40904e
mov ecx, dword [ebp - 0x87c]
push ecx
lea edx, [ebp - 0x834]
push edx
mov ecx, dword [ebp + 0x18]
call fcn.00407e40
mov eax, dword [ebp + 0x1c]
mov ecx, dword [eax]
add ecx, dword [ebp - 0x87c]
mov edx, dword [ebp + 0x1c]
mov dword [edx], ecx
mov eax, dword [ebp - 0x2c]
add eax, dword [ebp - 0x87c]
mov dword [ebp - 0x2c], eax
cmp dword [ebp - 0x20], 0
je 0x409078
mov ecx, dword [ebp - 0x2c]
cmp ecx, dword [ebp - 0x20]
jae 0x40908e
cmp dword [ebp - 0x83c], 0
je 0x409090
mov edx, dword [ebp + 0x1c]
mov eax, dword [edx]
cmp eax, dword [ebp - 0x83c]
jb 0x409090
jmp 0x409095
jmp 0x408d99
mov ecx, dword [ebp - 0x838]
push ecx
call fcn.00407fc0
add esp, 4
cmp dword [ebp - 0x860], 0x12d
je 0x4090c0
cmp dword [ebp - 0x860], 0x12e
jne 0x4091a0
push str.Location
lea ecx, [ebp - 0x90c]
call fcn.004061e0
mov dword [ebp - 0x920], eax
cmp dword [ebp - 0x920], 0
je 0x40919e
lea ecx, [ebp - 0x960]
call fcn.00404710
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x940]
call fcn.00404710
mov byte [ebp - 4], 3
lea edx, [ebp - 0x944]
push edx
lea eax, [ebp - 0x940]
push eax
lea ecx, [ebp - 0x960]
push ecx
lea edx, [ebp - 0x924]
push edx
mov eax, dword [ebp - 0x920]
push eax
call fcn.00408500
add esp, 0x14
cmp dword [ebp - 0x924], 3
jne 0x409180
lea ecx, [ebp - 0x960]
push ecx
mov ecx, dword [ebp + 0xc]
call fcn.00407770
lea edx, [ebp - 0x940]
push edx
mov ecx, dword [ebp + 0x14]
call fcn.00407770
movzx eax, word [ebp - 0x944]
mov dword [ebp + 0x10], eax
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x940]
call fcn.00404560
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x960]
call fcn.00404560
jmp 0x4089e7
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x940]
call fcn.00404560
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x960]
call fcn.00404560
jmp 0x4091c9
cmp dword [ebp - 0x860], 0x136
jne 0x4091c9
cmp dword [ebp - 0x91c], 2
jae 0x4091c9
mov ecx, dword [ebp - 0x91c]
add ecx, 1
mov dword [ebp - 0x91c], ecx
jmp 0x4089e7
cmp dword [ebp - 0x83c], 0
je 0x409276
mov edx, dword [ebp + 0x1c]
mov eax, dword [edx]
cmp eax, dword [ebp - 0x83c]
jae 0x40923c
cmp dword [ebp - 0x850], 0
je 0x40923c
cmp dword [ebp - 0x24], 0xa
jae 0x40923c
mov ecx, dword [ebp + 0x1c]
mov edx, dword [ebp - 0x918]
cmp edx, dword [ecx]
ja 0x40920a
mov eax, dword [ebp - 0x24]
add eax, 1
mov dword [ebp - 0x24], eax
jmp 0x40921c
mov dword [ebp - 0x24], 0
mov ecx, dword [ebp + 0x1c]
mov edx, dword [ecx]
mov dword [ebp - 0x918], edx
call dword [sym.imp.KERNEL32.dll_GetTickCount]
sub eax, dword [ebp - 0x18]
cmp eax, 0x3e8
jae 0x409237
push 0x3e8
call dword [sym.imp.KERNEL32.dll_Sleep]
jmp 0x408aad
mov eax, dword [ebp + 0x1c]
mov ecx, dword [eax]
xor edx, edx
cmp ecx, dword [ebp - 0x83c]
sete dl
mov dword [ebp - 0x884], edx
cmp dword [ebp - 0x860], 0xce
jne 0x409269
mov eax, dword [ebp + 0x28]
mov dword [eax], 0xc8
jmp 0x409274
mov ecx, dword [ebp + 0x28]
mov edx, dword [ebp - 0x860]
mov dword [ecx], edx
jmp 0x409292
mov eax, dword [ebp + 0x28]
mov ecx, dword [ebp - 0x860]
mov dword [eax], ecx
mov edx, dword [ebp + 0x1c]
xor eax, eax
cmp eax, dword [edx]
sbb ecx, ecx
neg ecx
mov dword [ebp - 0x884], ecx
mov edx, dword [ebp - 0x884]
mov dword [ebp - 0x968], edx
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x90c]
call fcn.004059d0
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x870]
call fcn.00407e20
mov eax, dword [ebp - 0x968]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
mov ecx, dword [ebp - 0x30]
xor ecx, ebp
call fcn.0041e0c4
mov esp, ebp
pop ebp
ret