Function at 0x404e10
Capabilities:
Receive data
Receive data on socket

Disassembly:
mov eax, 0xa440
call fcn.00406860
mov eax, dword [esp + 0xa444]
push ebx
push ebp
push esi
xor esi, esi
push edi
cmp eax, esi
jg 0x404e36
mov dword [esp + 0xa454], 1
mov eax, dword [esp + 0xa454]
push esi
push 2
push 2
mov dword [0x409c80], eax
call dword [sym.imp.WS2_32.dll_socket]
mov ebx, eax
cmp ebx, 0xffffffff
je 0x405036
mov al, byte [esp + 0xa458]
mov dword [esp + 0x1c], esi
test al, al
je 0x404e82
lea ecx, [esp + 0x1c]
push ecx
call fcn.00404d80
add esp, 4
test al, al
je 0x404e82
mov edi, dword [esp + 0x1c]
mov dword [esp + 0x18], edi
jmp 0x404e8e
mov dword [esp + 0x18], 0xfaffffef
mov edi, dword [esp + 0x18]
mov dword [esp + 0x10], esi
call dword [sym.imp.WS2_32.dll_WSACreateEvent]
push 1
push eax
push ebx
mov dword [esp + 0x20], eax
call dword [sym.imp.WS2_32.dll_WSAEventSelect]
mov ebp, dword [sym.imp.MSVCRT.dll_sprintf]
mov dword [esp + 0x20], esi
mov esi, 0x409c6c
mov edx, dword [0x409c80]
mov eax, dword [esi - 4]
mov ecx, dword [esi]
push edx
mov edx, dword [str.urn:schemas_upnp_org:]
push eax
push ecx
push edx
push str._s_s:_s:_d
push 0x737744
call ebp
push 0x737744
push 6
lea eax, [esp + 0x5470]
push str.M_SEARCH__HTTP_1.1_r_nHOST:_239.255.255.250:1900_r_nMAN:__ssdp:discover__r_nMX:__d_r_nST:__s_r_n_r_n
push eax
call ebp
lea ecx, [esp + 0x5478]
push ecx
push 0x76c
push edi
push ebx
call fcn.004042f0
add esp, 0x38
push 0
call dword [sym.imp.KERNEL32.dll_Sleep]
add esi, 8
cmp esi, 0x409c84
jl 0x404eb5
call dword [sym.imp.KERNEL32.dll_GetTickCount]
push 0
push 0x3e8
lea edx, [esp + 0x1c]
push 0
push edx
push 1
call dword [sym.imp.WS2_32.dll_WSAWaitForMultipleEvents]
cmp eax, 0x102
je 0x404f8a
test eax, eax
jne 0x404f8a
mov ecx, 0xb
lea edi, [esp + 0x24]
rep stosd dword es:[edi], eax
mov ecx, dword [esp + 0x14]
lea eax, [esp + 0x24]
push eax
push ecx
push ebx
call dword [sym.imp.WS2_32.dll_WSAEnumNetworkEvents]
test byte [esp + 0x24], 1
je 0x404f86
mov eax, dword [esp + 0x28]
test eax, eax
jne 0x404f86
push 0
lea edx, [esp + 0x7c54]
push 0x2800
push edx
push ebx
call dword [sym.imp.WS2_32.dll_recv]
test eax, eax
mov dword [esp + 0x10], eax
jg 0x404f9c
mov edi, dword [esp + 0x18]
mov eax, dword [esp + 0x20]
inc eax
cmp eax, 5
mov dword [esp + 0x20], eax
jl 0x404eb0
mov eax, dword [esp + 0x14]
push 0
push eax
push ebx
call dword [sym.imp.WS2_32.dll_WSAEventSelect]
mov ecx, dword [esp + 0x14]
push ecx
call dword [sym.imp.WS2_32.dll_WSACloseEvent]
push ebx
call dword [sym.imp.WS2_32.dll_closesocket]
mov eax, dword [esp + 0x10]
test eax, eax
jle 0x405036
mov byte [esp + eax + 0x7c50], 0
lea edx, [esp + 0x2c50]
lea eax, [esp + 0x7c50]
push edx
push eax
call fcn.00404200
add esp, 8
test al, al
je 0x405036
mov edi, dword [sym.imp.MSVCRT.dll_strstr]
mov esi, 0x409c6c
mov ecx, dword [esp + 0xa454]
mov edx, dword [esi - 4]
mov eax, dword [esi]
push ecx
mov ecx, dword [str.urn:schemas_upnp_org:]
push edx
push eax
push ecx
push str._s_s:_s:_d
push 0x737744
call ebp
lea edx, [esp + 0x2c68]
push 0x737744
push edx
call edi
add esp, 0x20
test eax, eax
jne 0x405043
add esi, 8
cmp esi, 0x409c84
jl 0x404ff3
pop edi
pop esi
pop ebp
xor al, al
pop ebx
add esp, 0xa440
ret
lea eax, [esp + 0x450]
lea ecx, [esp + 0x10]
push eax
push ecx
lea edx, [esp + 0x2c58]
push 0x409cf0
push edx
mov dword [esp + 0x20], 0
call fcn.00404030
lea edi, [esp + 0x460]
or ecx, 0xffffffff
xor eax, eax
add esp, 0x10
repne scasb al, byte es:[edi]
not ecx
dec ecx
je 0x405036
mov ebp, dword [sym.imp.MSVCRT.dll__strupr]
mov eax, dword [esp + 0x450]
mov ecx, dword [esp + 0x454]
mov dl, byte [esp + 0x458]
mov dword [esp + 0x50], eax
lea eax, [esp + 0x50]
mov dword [esp + 0x54], ecx
push eax
mov byte [esp + 0x5c], dl
mov byte [esp + 0x5d], 0
call ebp
add esp, 4
mov esi, str.LOCATION:
lea eax, [esp + 0x50]
mov dl, byte [eax]
mov bl, byte [esi]
mov cl, dl
cmp dl, bl
jne 0x4050e7
test cl, cl
je 0x4050e3
mov dl, byte [eax + 1]
mov bl, byte [esi + 1]
mov cl, dl
cmp dl, bl
jne 0x4050e7
add eax, 2
add esi, 2
test cl, cl
jne 0x4050bf
xor eax, eax
jmp 0x4050ec
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
je 0x405136
lea eax, [esp + 0x450]
lea ecx, [esp + 0x10]
push eax
push ecx
lea edx, [esp + 0x2c58]
push 0x409cf0
push edx
call fcn.00404030
lea edi, [esp + 0x460]
or ecx, 0xffffffff
xor eax, eax
add esp, 0x10
repne scasb al, byte es:[edi]
not ecx
dec ecx
jne 0x405086
pop edi
pop esi
pop ebp
xor al, al
pop ebx
add esp, 0xa440
ret
lea edi, [esp + 0x450]
or ecx, 0xffffffff
xor eax, eax
lea esi, [esp + 0x459]
repne scasb al, byte es:[edi]
not ecx
add ecx, 0xfffffff7
lea edi, [esp + 0x450]
mov eax, ecx
lea edx, [esp + 0x5450]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
xor eax, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea edi, [esp + 0x450]
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea ecx, [esp + 0x5450]
push ecx
call fcn.00404150
lea edx, [esp + 0x5454]
push edx
call fcn.004041b0
lea eax, [esp + 0x5458]
push eax
call fcn.00404a30
add esp, 0xc
pop edi
pop esi
pop ebp
pop ebx
add esp, 0xa440
ret