Function at 0x52a070
Capabilities:
Get local ipv4 addresses
Get socket information

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
and esp, 0xfffffff0
sub esp, 0x230
mov dword [esp + 0x14], edx
mov eax, dword [0x7c3824]
xor eax, ebp
mov dword [esp + 0x228], eax
mov eax, dword [ecx + 0xc]
mov dword [esp + 0x1c], 0
movzx edi, word [ecx + 0x190]
mov ebx, dword [ecx + 0x194]
mov dword [esp + 8], ecx
mov edx, dword [ecx + 0x554]
xor esi, esi
test di, di
jne 0x52a0c2
test edx, edx
je 0x52a521
mov dword [esp + 0xc], eax
mov ecx, dword [ebp + 8]
xorps xmm0, xmm0
movaps xmmword [esp + 0x210], xmm0
movaps xmmword [esp + 0x200], xmm0
movaps xmmword [esp + 0x1f0], xmm0
movaps xmmword [esp + 0x1e0], xmm0
movaps xmmword [esp + 0x1d0], xmm0
movaps xmmword [esp + 0x1c0], xmm0
movaps xmmword [esp + 0x1b0], xmm0
movaps xmmword [esp + 0x1a0], xmm0
test edx, edx
je 0x52a1f5
push edx
mov esi, edx
call fcn.005fef10
mov ecx, dword [ebp + 8]
add esp, 4
cmp eax, 0xfe
ja 0x52a1f5
xorps xmm0, xmm0
movaps xmmword [esp + 0x190], xmm0
movaps xmmword [esp + 0x180], xmm0
movaps xmmword [esp + 0x170], xmm0
movaps xmmword [esp + 0x160], xmm0
movaps xmmword [esp + 0x150], xmm0
movaps xmmword [esp + 0x140], xmm0
movaps xmmword [esp + 0x130], xmm0
movaps xmmword [esp + 0x120], xmm0
movaps xmmword [esp + 0x110], xmm0
movaps xmmword [esp + 0x100], xmm0
movaps xmmword [esp + 0xf0], xmm0
movaps xmmword [esp + 0xe0], xmm0
movaps xmmword [esp + 0xd0], xmm0
movaps xmmword [esp + 0xc0], xmm0
movaps xmmword [esp + 0xb0], xmm0
movaps xmmword [esp + 0xa0], xmm0
push 3
push esi
push 0x66f4e6
call fcn.005fefa0
add esp, 0xc
test eax, eax
mov dword [esp + 0x10], eax
je 0x52a375
push 5
push esi
push str.host_
call fcn.005fefa0
add esp, 0xc
test eax, eax
jne 0x52a378
add esi, 5
mov eax, dword [esp + 0xc]
mov ecx, dword [ebp + 8]
mov edx, esi
jmp 0x52a40b
xor esi, esi
cmp ecx, 2
jne 0x52a21d
mov word [esp + 0x1a0], 2
movzx eax, di
push eax
call dword [sym.imp.WSOCK32.dll_htons]
mov word [esp + 0x1a2], ax
mov esi, 0x10
lea eax, [esp + 0x1a0]
push esi
jmp 0x52a23b
add ebx, 0xffffffff
push esi
lea eax, [esp + 0x1a4]
push eax
push dword [esp + 0x1c]
call dword [sym.imp.WSOCK32.dll_bind]
test eax, eax
jns 0x52a28a
cmp ebx, 2
jl 0x52a333
movzx eax, di
push eax
push str.Bind_to_local_port__hu_failed__trying_next
push dword [esp + 0x10]
call fcn.0051ec50
add esp, 0xc
add edi, 1
cmp word [esp + 0x1a0], 2
jne 0x52a230
movzx eax, di
push eax
call dword [sym.imp.WSOCK32.dll_ntohs]
mov word [esp + 0x1a2], ax
jmp 0x52a230
mov dword [esp + 0x18], 0x80
xorps xmm0, xmm0
movaps xmmword [esp + 0x20], xmm0
movaps xmmword [esp + 0x30], xmm0
movaps xmmword [esp + 0x40], xmm0
movaps xmmword [esp + 0x50], xmm0
movaps xmmword [esp + 0x60], xmm0
movaps xmmword [esp + 0x70], xmm0
movaps xmmword [esp + 0x80], xmm0
movaps xmmword [esp + 0x90], xmm0
lea eax, [esp + 0x18]
lea ecx, [esp + 0x20]
push eax
push ecx
push dword [esp + 0x1c]
call dword [sym.imp.WSOCK32.dll_getsockname]
test eax, eax
js 0x52a302
movzx eax, di
push eax
push str.Local_port:__hu
push dword [esp + 0x10]
call fcn.0051ec50
add esp, 0xc
mov eax, dword [esp + 0xc]
mov byte [eax + 0x270], 1
xor esi, esi
jmp 0x52a521
call dword [sym.imp.WSOCK32.dll_WSAGetLastError]
mov edi, eax
mov esi, dword [esp + 8]
mov dword [esi + 0x974], eax
lea eax, [esp + 0xa0]
push 0x100
push eax
push edi
call fcn.00589dd0
add esp, 0xc
push eax
push edi
push str.getsockname___failed_with_errno__d:__s
jmp 0x52a362
call dword [sym.imp.WSOCK32.dll_WSAGetLastError]
mov edi, eax
mov esi, dword [esp + 8]
mov dword [esi + 0x974], eax
lea eax, [esp + 0xa0]
push 0x100
push eax
push edi
call fcn.00589dd0
add esp, 0xc
push eax
push edi
push str.bind_failed_with_errno__d:__s
push esi
call fcn.0051ed60
add esp, 0x10
mov esi, 0x2d
jmp 0x52a521
add esi, 3
mov eax, dword [esp + 0xc]
mov ecx, dword [ebp + 8]
mov edx, esi
lea esi, [esp + 0xa0]
push 0x100
push esi
mov esi, edx
push edx
push dword [eax + 0x54]
push dword [ebp + 0xc]
push ecx
call fcn.00401a00
add esp, 0x18
cmp eax, 2
je 0x52a3d1
cmp eax, 1
je 0x52a51f
test eax, eax
jne 0x52a3f7
cmp dword [esp + 0x10], 0
mov eax, dword [esp + 0xc]
mov ecx, dword [ebp + 8]
mov edx, esi
jne 0x52a40b
push edx
push str.Couldnt_bind_to_interface__s
push dword [esp + 0x10]
jmp 0x52a512
mov eax, dword [ebp + 8]
push eax
lea eax, [esp + 0xa4]
push eax
push esi
push str.Local_Interface__s_is_ip__s_using_address_family__i
push dword [esp + 0x18]
call fcn.0051ec50
mov ecx, dword [ebp + 8]
add esp, 0x14
jmp 0x52a4cc
cmp dword [esp + 0x10], 0
mov eax, dword [esp + 0xc]
mov ecx, dword [ebp + 8]
mov edx, esi
je 0x52a500
mov esi, ecx
mov cl, byte [eax + 0x100]
mov byte [esp + 0x10], cl
cmp esi, 2
jne 0x52a423
mov byte [eax + 0x100], 1
lea eax, [esp + 0x1c]
push eax
push 0
push 0
mov esi, edx
push edx
push dword [esp + 0x18]
call fcn.0057e950
add esp, 0x14
cmp eax, 1
jne 0x52a451
lea eax, [esp + 0x1c]
push eax
push dword [esp + 0xc]
call fcn.00519a30
add esp, 8
mov eax, dword [esp + 0xc]
mov cl, byte [esp + 0x10]
mov byte [eax + 0x100], cl
mov eax, dword [esp + 0x1c]
test eax, eax
je 0x52a4fe
lea ecx, [esp + 0xa0]
push 0x100
push ecx
push dword [eax]
call fcn.0057e310
add esp, 0xc
mov eax, dword [esp + 0x1c]
mov eax, dword [eax]
push dword [eax + 4]
lea eax, [esp + 0xa4]
push eax
mov eax, dword [ebp + 8]
push eax
push esi
push str.Name__s_family__i_resolved_to__s_family__i
mov esi, dword [esp + 0x1c]
push esi
call fcn.0051ec50
add esp, 0x18
push dword [esp + 0x1c]
push esi
call fcn.0057ec90
add esp, 8
mov eax, dword [esp + 0x1c]
mov ecx, dword [eax]
mov eax, 1
mov edx, dword [ebp + 8]
cmp dword [ecx + 4], edx
mov ecx, edx
jne 0x52a51f
xor esi, esi
cmp ecx, 2
jne 0x52a21d
lea eax, [esp + 0x1a4]
lea ecx, [esp + 0xa0]
push eax
push ecx
push 2
call fcn.005a13a0
add esp, 0xc
test eax, eax
jg 0x52a1fc
jmp 0x52a21d
mov edx, esi
mov eax, dword [esp + 8]
mov byte [eax + 0xd07], 0
push edx
push str.Couldnt_bind_to__s
push eax
call fcn.0051ed60
add esp, 0xc
mov eax, 0x2d
mov esi, eax
mov ecx, dword [esp + 0x228]
xor ecx, ebp
call fcn.005db451
mov eax, esi
lea esp, [ebp - 0xc]
pop esi
pop edi
pop ebx
pop ebp
ret