Function at 0x4052f0
Capabilities:
Create raw socket
Create tcp socket
Create udp socket
Receive data
Receive data on socket
Set socket configuration

Disassembly:
push 0xffffffffffffffff
push 0x4a59df
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
mov eax, 0x283c
call fcn.0047f340
mov eax, dword [0x4d1788]
push ebx
mov ebx, dword [esp + 0x2850]
test ebx, ebx
push ebp
push esi
push edi
mov edi, ecx
mov dword [esp + 0x2848], eax
mov dword [esp + 0x28], edi
jg 0x405342
mov dword [esp + 0x285c], 1
mov ebx, dword [esp + 0x285c]
push str.WANPPPConnection
lea ecx, [esp + 0x34]
mov dword [edi + 0x1c], ebx
call fcn.00404200
push str.service
lea ecx, [esp + 0x38]
mov dword [esp + 0x2858], 0
call fcn.00404200
push str.WANIPConnection
lea ecx, [esp + 0x3c]
mov byte [esp + 0x2858], 1
call fcn.00404200
push str.service
lea ecx, [esp + 0x40]
mov byte [esp + 0x2858], 2
call fcn.00404200
push str.InternetGatewayDevice
lea ecx, [esp + 0x44]
mov byte [esp + 0x2858], 3
call fcn.00404200
push str.device
lea ecx, [esp + 0x48]
mov byte [esp + 0x2858], 4
call fcn.00404200
push 0
push 2
push 2
mov dword [esp + 0x2860], 5
call dword [sym.imp.WS2_32.dll_socket]
mov ebp, eax
lea eax, [esp + 0x2c]
push eax
push 0x8004667e
push ebp
mov dword [esp + 0x2c], ebp
mov dword [esp + 0x38], 1
call dword [sym.imp.WS2_32.dll_ioctlsocket]
xor eax, eax
mov dword [esp + 0x18], eax
jmp 0x405411
mov eax, dword [esp + 0x18]
mov ebx, dword [esp + 0x285c]
mov edi, dword [esp + 0x28]
cmp eax, 0x18
jge 0x40567c
cdq
mov ecx, 0xa
idiv ecx
test edx, edx
jne 0x4054dc
add edi, 4
lea esi, [esp + 0x34]
mov dword [esp + 0x14], 2
lea esp, [esp]
mov edx, dword [esi - 4]
mov eax, dword [esi]
mov ecx, dword [0x4d2b00]
push ebx
push edx
push eax
push ecx
push str._s_s:_s:_d
push edi
call fcn.004022f0
add esp, 0x18
call fcn.004951e5
mov edx, dword [eax]
mov ecx, eax
call dword [edx + 0xc]
add eax, 0x10
mov dword [esp + 0x10], eax
mov eax, dword [edi]
push eax
push 2
lea ecx, [esp + 0x18]
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 ecx
mov byte [esp + 0x2864], 6
call fcn.004022f0
lea edx, [esp + 0x20]
push edx
push 0x76c
push 0xfaffffef
push ebp
call fcn.004036a0
mov eax, dword [esp + 0x30]
add eax, 0xfffffff0
add esp, 0x20
mov byte [esp + 0x2854], 5
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4054ca
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
mov eax, dword [esp + 0x14]
add esi, 8
dec eax
mov dword [esp + 0x14], eax
jne 0x405440
push 0x32
call dword [sym.imp.KERNEL32.dll_Sleep]
push 0
push 0x2800
lea eax, [esp + 0x50]
push eax
push ebp
call dword [sym.imp.WS2_32.dll_recv]
mov ebx, eax
test ebx, ebx
jle 0x40566b
push ebp
call dword [sym.imp.WS2_32.dll_closesocket]
call fcn.004951e5
mov edx, dword [eax]
push 1
push ebx
mov ecx, eax
call dword [edx]
test eax, eax
je 0x4056ca
lea ebp, [eax + 0x10]
cmp ebx, dword [ebp - 8]
mov dword [esp + 0x10], ebp
jg 0x4059ba
mov ecx, ebx
mov eax, ecx
shr ecx, 2
mov dword [ebp - 0xc], ebx
mov byte [ebx + ebp], 0
lea esi, [esp + 0x48]
mov edi, ebp
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
push ebp
lea ecx, [esp + 0x28]
mov byte [esp + 0x2858], 7
call fcn.00402790
lea eax, [ebp - 0x10]
mov byte [esp + 0x2854], 9
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40557f
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
call fcn.004951e5
mov edx, dword [eax]
mov ecx, eax
call dword [edx + 0xc]
add eax, 0x10
mov dword [esp + 0x14], eax
lea eax, [esp + 0x14]
push eax
lea ecx, [esp + 0x28]
push ecx
mov byte [esp + 0x285c], 0xa
call fcn.00402bf0
add esp, 8
test al, al
je 0x40581f
mov edi, dword [esp + 0x28]
xor ebp, ebp
add edi, 4
lea esi, [esp + 0x34]
mov edx, dword [esp + 0x285c]
mov eax, dword [esi - 4]
mov ecx, dword [esi]
push edx
mov edx, dword [0x4d2b00]
push eax
push ecx
push edx
push str._s_s:_s:_d
push edi
call fcn.004022f0
mov eax, dword [edi]
add esp, 0x18
test eax, eax
je 0x405612
mov ecx, dword [esp + 0x14]
mov edx, dword [ecx - 0xc]
test edx, edx
jl 0x405612
push eax
push ecx
call fcn.0047e729
add esp, 8
test eax, eax
je 0x405612
sub eax, dword [esp + 0x14]
sar eax, 1
test eax, eax
jge 0x4056cf
inc ebp
add esi, 8
cmp ebp, 2
jl 0x4055c1
mov eax, dword [esp + 0x14]
add eax, 0xfffffff0
mov byte [esp + 0x2854], 9
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x405641
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
mov eax, dword [esp + 0x24]
add eax, 0xfffffff0
mov byte [esp + 0x2854], 5
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x405667
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
mov ebp, dword [esp + 0x20]
mov ecx, dword [esp + 0x18]
inc ecx
test ebx, ebx
mov dword [esp + 0x18], ecx
jle 0x405402
push ebp
call dword [sym.imp.WS2_32.dll_closesocket]
push fcn.004017e0
push 6
push 4
lea ecx, [esp + 0x3c]
push ecx
mov dword [esp + 0x2864], 0xffffffff
call fcn.0047f274
xor al, al
mov ecx, dword [esp + 0x284c]
pop edi
pop esi
pop ebp
mov dword fs:[0], ecx
mov ecx, dword [esp + 0x283c]
pop ebx
call fcn.0047e6cd
add esp, 0x2848
ret 4
call fcn.004012c0
lea ecx, [esp + 0x20]
push ecx
push 0x4ae7c4
lea edx, [esp + 0x18]
push edx
lea ecx, [esp + 0x20]
mov dword [esp + 0x2c], 0
call fcn.004021f0
mov ebx, dword [esp + 0x10]
mov eax, dword [ebx - 0xc]
test eax, eax
mov byte [esp + 0x2854], 0xb
je 0x4057fd
cmp eax, 9
jle 0x4057ac
push 9
push 0
lea eax, [esp + 0x20]
push eax
lea ecx, [esp + 0x1c]
call fcn.00401bc0
mov esi, dword [esp + 0x18]
mov eax, dword [esi - 4]
mov edi, dword [esi - 0xc]
mov ecx, 1
sub ecx, eax
mov eax, dword [esi - 8]
sub eax, edi
or eax, ecx
mov byte [esp + 0x2854], 0xc
jge 0x405751
push edi
lea ecx, [esp + 0x1c]
call fcn.00401590
mov esi, dword [esp + 0x18]
push esi
call fcn.0047e832
add esp, 4
test edi, edi
jl 0x4059ba
cmp edi, dword [esi - 8]
jg 0x4059ba
push str.LOCATION:
mov dword [esi - 0xc], edi
push esi
mov word [esi + edi*2], 0
call fcn.0047e6f7
add esp, 8
test eax, eax
je 0x40587e
add esi, 0xfffffff0
mov byte [esp + 0x2854], 0xb
lea ecx, [esi + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4057ac
mov ecx, dword [esi]
mov eax, dword [ecx]
push esi
call dword [eax + 4]
lea eax, [ebx - 0x10]
mov byte [esp + 0x2854], 0xa
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4057ce
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
lea eax, [esp + 0x20]
push eax
push 0x4ae7c4
lea ecx, [esp + 0x18]
push ecx
lea ecx, [esp + 0x20]
call fcn.004021f0
mov ebx, dword [esp + 0x10]
mov eax, dword [ebx - 0xc]
test eax, eax
mov byte [esp + 0x2854], 0xb
jne 0x405706
add ebx, 0xfffffff0
mov byte [esp + 0x2854], 0xa
lea edx, [ebx + 0xc]
or eax, 0xffffffff
lock xadd dword [edx], eax
dec eax
test eax, eax
jg 0x40581f
mov ecx, dword [ebx]
mov edx, dword [ecx]
push ebx
call dword [edx + 4]
mov eax, dword [esp + 0x14]
add eax, 0xfffffff0
mov byte [esp + 0x2854], 9
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x405845
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
mov eax, dword [esp + 0x24]
add eax, 0xfffffff0
mov byte [esp + 0x2854], 5
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40586b
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
push fcn.004017e0
push 6
push 4
lea eax, [esp + 0x3c]
push eax
jmp 0x405691
mov edi, dword [ebx - 0xc]
mov ebp, 9
cmp edi, ebp
jge 0x405890
test edi, edi
mov ebp, edi
jle 0x4058d7
mov eax, dword [ebx - 4]
sub edi, ebp
cmp eax, 1
jle 0x4058ab
mov ecx, dword [ebx - 0xc]
push ecx
lea ecx, [esp + 0x14]
call fcn.004012d0
mov ebx, dword [esp + 0x10]
lea edx, [edi + edi + 2]
push edx
lea eax, [ebx + ebp*2]
push eax
push ebx
call fcn.0047ea10
add esp, 0xc
test edi, edi
jl 0x4059ba
cmp edi, dword [ebx - 8]
jg 0x4059ba
mov dword [ebx - 0xc], edi
mov word [ebx + edi*2], 0
mov ebp, dword [esp + 0x28]
lea ecx, [esp + 0x10]
lea edi, [ebp + 8]
push ecx
mov ecx, edi
call fcn.00402060
mov ecx, edi
call fcn.004026e0
mov ecx, eax
call fcn.00401c40
mov ecx, ebp
call fcn.004042a0
add esi, 0xfffffff0
mov byte [esp + 0x1f], al
mov byte [esp + 0x2854], 0xb
lea edx, [esi + 0xc]
or eax, 0xffffffff
lock xadd dword [edx], eax
dec eax
test eax, eax
jg 0x405925
mov ecx, dword [esi]
mov edx, dword [ecx]
push esi
call dword [edx + 4]
add ebx, 0xfffffff0
mov byte [esp + 0x2854], 0xa
lea eax, [ebx + 0xc]
or ecx, 0xffffffff
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x405947
mov ecx, dword [ebx]
mov edx, dword [ecx]
push ebx
call dword [edx + 4]
mov eax, dword [esp + 0x14]
add eax, 0xfffffff0
mov byte [esp + 0x2854], 9
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40596d
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
mov eax, dword [esp + 0x24]
add eax, 0xfffffff0
mov byte [esp + 0x2854], 5
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x405993
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
push fcn.004017e0
push 6
push 4
lea eax, [esp + 0x3c]
push eax
mov dword [esp + 0x2864], 0xffffffff
call fcn.0047f274
mov al, byte [esp + 0x1f]
jmp 0x4056a3
push 0x80070057
call fcn.00401100
int3