Function at 0x4af59c
Capabilities:
Create tcp socket
Create udp socket
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
add esp, 0xffffffec
push ebx
push esi
push edi
mov ebx, dword [ebp + 8]
mov esi, 0x4e546c
xor eax, eax
mov dword [ebp - 4], eax
push 0
push 1
push 2
call sub.WSOCK32.DLL_socket
mov edi, eax
push 0x10
push 0
lea eax, [ebp - 0x14]
push eax
call fcn.004798f8
add esp, 0xc
cmp edi, 0xffffffff
je 0x4af5ea
push 0
push 2
push 2
call sub.WSOCK32.DLL_socket
mov dword [ebx + 0x160], eax
cmp eax, 0xffffffff
jne 0x4af608
push str.tee_socket
push 0x4e6447
push 0x4e6440
push 3
call fcn.0048c898
add esp, 0x10
jmp 0x4af802
push 0x10
push 0
lea edx, [ebp - 0x14]
push edx
call fcn.004798f8
add esp, 0xc
mov word [ebp - 0x14], 2
push 0
call sub.WSOCK32.DLL_htons
movzx ecx, ax
mov dword [ebp - 0x10], ecx
mov word [esi], 0x10e5
jmp 0x4af685
mov ax, word [esi]
push eax
push 2
push ebx
call fcn.004afb40
add esp, 0xc
mov dx, word [esi]
push edx
push 1
push ebx
call fcn.004afb40
add esp, 0xc
mov cx, word [esi]
push ecx
call sub.WSOCK32.DLL_htons
mov word [ebp - 0x12], ax
push 0x10
lea eax, [ebp - 0x14]
push eax
push dword [ebx + 0x160]
call sub.WSOCK32.DLL_bind
test eax, eax
jne 0x4af682
push 0x10
lea edx, [ebp - 0x14]
push edx
push edi
call sub.WSOCK32.DLL_bind
test eax, eax
je 0x4af68c
inc word [esi]
cmp word [esi], 0x10e9
jbe 0x4af632
push edi
call sub.WSOCK32.DLL_closesocket
cmp word [esi], 0x10e9
jbe 0x4af6b7
push str.bind
push 0x4e646f
push 0x4e6468
push 3
call fcn.0048c898
add esp, 0x10
jmp 0x4af802
movzx ecx, word [esi]
push ecx
push str.PORT_hu.
push 0x4e648a
push 5
call fcn.0048c898
add esp, 0x10
push esi
push edi
lea esi, [ebp - 0x14]
lea edi, [ebx + 0x10c]
mov ecx, 4
rep movsd dword es:[edi], dword [esi]
pop edi
pop esi
mov dword [ebp - 4], 1
push 4
lea eax, [ebp - 4]
push eax
push 0x20
push 0xffff
push dword [ebx + 0x160]
call sub.WSOCK32.DLL_setsockopt
test eax, eax
jge 0x4af724
push str.setsockopt_SO_BROADCAST
push str.falied_to_invoke:_s._n
push 0x4e649b
push 3
call fcn.0048c898
add esp, 0x10
jmp 0x4af802
push 0xa
lea edx, [ebx + 0x164]
push edx
push ebx
call fcn.004afc20
add esp, 0xc
test al, al
jne 0x4af74e
push str.Assert_0____Failed_to_find_subnets._n
push 0x4e64d0
push 3
call fcn.0048c898
add esp, 0xc
push 0
push ebx
call fcn.004af84c
add esp, 8
push 0x1000
call fcn.004ac09c
pop ecx
mov dword [ebx + 0x220], eax
push 0
call fcn.004ad474
pop ecx
mov dword [ebx + 0x224], eax
push ebx
push 0x4af838
push 0x20000
call fcn.004ae484
add esp, 0xc
mov dword [ebx + 0x108], eax
cmp dword [ebx + 0x220], 0
je 0x4af7ac
cmp dword [ebx + 0x224], 0
je 0x4af7ac
cmp dword [ebx + 0x108], 0
jne 0x4af7c2
push str.Failed_to_create_thread._n
push 0x4e64fc
push 3
call fcn.0048c898
add esp, 0xc
jmp 0x4af802
mov cx, word [esi]
push ecx
lea eax, [ebx + 0x228]
push eax
call fcn.004b5fa0
add esp, 8
inc eax
je 0x4af7e8
add ebx, 0x228
push ebx
call fcn.004b5fd8
pop ecx
inc eax
jne 0x4af7fe
push str.Failed_to_init_download_module..._n
push 0x4e651d
push 3
call fcn.0048c898
add esp, 0xc
jmp 0x4af802
mov al, 1
jmp 0x4af80f
cmp edi, 0xffffffff
jne 0x4af80d
push edi
call sub.WSOCK32.DLL_closesocket
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret