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

Disassembly:
push ebp
mov ebp, esp
mov eax, 0xa440
call fcn.00420250
push esi
xor esi, esi
cmp dword [ebp + 8], esi
jg 0x4150a9
mov dword [ebp + 8], 1
mov eax, dword [ebp + 8]
push esi
push 2
push 2
mov dword [0x4459c4], eax
call dword [sym.imp.WS2_32.dll_socket]
cmp eax, 0xffffffff
mov dword [ebp - 8], eax
jne 0x4150cb
xor al, al
jmp 0x415276
cmp byte [ebp + 0xc], 0
mov dword [ebp - 4], esi
je 0x4150ea
lea eax, [ebp - 4]
push eax
call fcn.00415011
test al, al
pop ecx
je 0x4150ea
mov eax, dword [ebp - 4]
mov dword [ebp - 0x10], eax
jmp 0x4150f1
mov dword [ebp - 0x10], 0xfaffffef
push ebx
mov dword [ebp - 0x14], esi
call dword [sym.imp.WS2_32.dll_WSACreateEvent]
push 1
push eax
push dword [ebp - 8]
mov dword [ebp - 0xc], eax
call dword [sym.imp.WS2_32.dll_WSAEventSelect]
mov ebx, dword [sym.imp.USER32.dll_wsprintfA]
mov dword [ebp - 4], esi
mov esi, 0x456ae0
push edi
mov edi, 0x4459b0
push dword [0x4459c4]
push dword [edi - 4]
push dword [edi]
push dword [0x4459a8]
push str._s_s:_s:_d
push esi
call ebx
push esi
push 6
lea eax, [ebp - 0x5440]
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 ebx
lea eax, [ebp - 0x5440]
push eax
push 0x76c
push dword [ebp - 0x10]
push dword [ebp - 8]
call fcn.00414898
add esp, 0x38
push 0
call dword [sym.imp.KERNEL32.dll_Sleep]
add edi, 8
cmp edi, 0x4459c8
jl 0x41511e
call dword [sym.imp.KERNEL32.dll_GetTickCount]
xor edi, edi
push edi
push 0x3e8
push edi
lea eax, [ebp - 0xc]
push eax
push 1
call dword [sym.imp.WS2_32.dll_WSAWaitForMultipleEvents]
cmp eax, 0x102
je 0x4151e2
cmp eax, edi
jne 0x4151e2
push 0x2c
lea eax, [ebp - 0x40]
push edi
push eax
call fcn.004200c0
add esp, 0xc
lea eax, [ebp - 0x40]
push eax
push dword [ebp - 0xc]
push dword [ebp - 8]
call dword [sym.imp.WS2_32.dll_WSAEnumNetworkEvents]
test byte [ebp - 0x40], 1
je 0x4151e2
cmp dword [ebp - 0x3c], edi
jne 0x4151e2
push edi
push 0x27d8
lea eax, [ebp - 0xa440]
push eax
push dword [ebp - 8]
call dword [sym.imp.WS2_32.dll_recv]
cmp eax, edi
mov dword [ebp - 0x14], eax
jg 0x4151f1
inc dword [ebp - 4]
cmp dword [ebp - 4], 5
jl 0x415119
xor edi, edi
push edi
push dword [ebp - 0xc]
push dword [ebp - 8]
call dword [sym.imp.WS2_32.dll_WSAEventSelect]
push dword [ebp - 0xc]
call dword [sym.imp.WS2_32.dll_WSACloseEvent]
push dword [ebp - 8]
call dword [sym.imp.WS2_32.dll_closesocket]
mov eax, dword [ebp - 0x14]
cmp eax, edi
jle 0x415272
mov byte [ebp + eax - 0xa440], 0
lea eax, [ebp - 0x2c40]
push eax
lea eax, [ebp - 0xa440]
push eax
call fcn.004147c9
test al, al
pop ecx
pop ecx
je 0x415272
mov edi, 0x4459b0
push dword [ebp + 8]
push dword [edi - 4]
push dword [edi]
push dword [0x4459a8]
push str._s_s:_s:_d
push esi
call ebx
lea eax, [ebp - 0x2c40]
push esi
push eax
call fcn.004203c0
add esp, 0x20
test eax, eax
jne 0x415279
add edi, 8
cmp edi, 0x4459c8
jl 0x41523d
xor al, al
pop edi
pop ebx
pop esi
leave
ret
and dword [ebp + 8], 0
lea eax, [ebp - 0x7c40]
push eax
lea eax, [ebp + 8]
push eax
mov edi, 0x4284c8
lea eax, [ebp - 0x2c40]
push edi
push eax
call fcn.004146a2
mov esi, dword [sym.imp.KERNEL32.dll_lstrlenA]
jmp 0x4152fb
push 9
lea eax, [ebp - 0x7c40]
push eax
lea eax, [ebp - 0x440]
push eax
call fcn.0041fd80
lea eax, [ebp - 0x440]
push eax
mov byte [ebp - 0x437], 0
call fcn.00420e1b
add esp, 0x10
push str.LOCATION:
lea eax, [ebp - 0x440]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpA]
test eax, eax
lea eax, [ebp - 0x7c40]
push eax
je 0x415310
lea eax, [ebp + 8]
push eax
lea eax, [ebp - 0x2c40]
push edi
push eax
call fcn.004146a2
lea eax, [ebp - 0x7c40]
add esp, 0x10
push eax
call esi
test eax, eax
jne 0x4152a2
jmp 0x415272
call esi
sub eax, 8
push eax
lea eax, [ebp - 0x7c37]
push eax
lea eax, [ebp - 0x7c40]
push eax
call fcn.0041fd80
add esp, 0xc
lea eax, [ebp - 0x7c40]
push eax
lea eax, [ebp - 0x5440]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
lea eax, [ebp - 0x5440]
push eax
call fcn.00414752
lea eax, [ebp - 0x5440]
push eax
call fcn.00414794
lea eax, [ebp - 0x5440]
push eax
call fcn.00414da6
add esp, 0xc
jmp 0x415274