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

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x280
push ebx
push esi
push edi
mov eax, dword [ebp + 8]
mov ecx, dword [eax]
mov dword [ebp - 4], ecx
lea edx, [ebp - 0x84]
mov dword [ebp - 0x88], edx
mov dword [ebp - 0x8c], 0
lea eax, [ebp - 0x84]
mov dword [ebp - 0x90], eax
mov dword [ebp - 0x94], 0
mov ecx, dword [ebp - 4]
mov dx, word [ecx + 0x178]
mov word [ebp - 0x98], dx
mov eax, dword [ebp - 4]
mov ecx, dword [eax + 0x17c]
mov dword [ebp - 0x9c], ecx
mov edx, dword [ebp - 4]
mov eax, dword [edx + 0x42c]
mov dword [ebp - 0xa0], eax
cmp dword [ebp - 0xa0], 0
jne 0x42a3df
mov ecx, dword [ebp - 0x98]
and ecx, 0xffff
test ecx, ecx
jne 0x42a3df
xor eax, eax
jmp 0x42a921
push 0x80
push 0
lea edx, [ebp - 0x84]
push edx
call sub.MSVCRT.dll_memset
add esp, 0xc
cmp dword [ebp - 0xa0], 0
je 0x42a74b
mov eax, dword [ebp - 0xa0]
push eax
call sub.MSVCRT.dll_strlen
add esp, 4
cmp eax, 0xff
jae 0x42a74b
mov cl, byte [0x4795b0]
mov byte [ebp - 0x1a4], cl
mov ecx, 0x3f
xor eax, eax
lea edi, [ebp - 0x1a3]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
mov dword [ebp - 0x1a8], 0
mov dword [ebp - 0x1ac], 0
mov dword [ebp - 0x1b0], 0
mov edx, dword [0x478fe8]
push edx
call sub.MSVCRT.dll_strlen
add esp, 4
push eax
mov eax, dword [ebp - 0xa0]
push eax
mov ecx, dword [0x478fe8]
push ecx
call dword [sym.imp.MSVCRT.dll_strncmp]
add esp, 0xc
test eax, eax
jne 0x42a4ac
mov edx, dword [0x478fe8]
push edx
call sub.MSVCRT.dll_strlen
add esp, 4
mov ecx, dword [ebp - 0xa0]
add ecx, eax
mov dword [ebp - 0xa0], ecx
mov dword [ebp - 0x1ac], 1
jmp 0x42a4fe
mov edx, dword [str.host_]
push edx
call sub.MSVCRT.dll_strlen
add esp, 4
push eax
mov eax, dword [ebp - 0xa0]
push eax
mov ecx, dword [str.host_]
push ecx
call dword [sym.imp.MSVCRT.dll_strncmp]
add esp, 0xc
test eax, eax
jne 0x42a4fe
mov edx, dword [str.host_]
push edx
call sub.MSVCRT.dll_strlen
add esp, 4
mov ecx, dword [ebp - 0xa0]
add ecx, eax
mov dword [ebp - 0xa0], ecx
mov dword [ebp - 0x1b0], 1
cmp dword [ebp - 0x1b0], 0
jne 0x42a5c9
push pe_nt_image_headers32
lea edx, [ebp - 0x1a4]
push edx
mov eax, dword [ebp - 0xa0]
push eax
mov ecx, dword [ebp + 8]
mov edx, dword [ecx + 0x88]
push edx
mov eax, dword [ebp + 0x14]
push eax
mov ecx, dword [ebp + 0x10]
push ecx
call fcn.00413ba0
add esp, 0x18
mov dword [ebp - 0x240], eax
cmp dword [ebp - 0x240], 0
je 0x42a55b
cmp dword [ebp - 0x240], 1
je 0x42a588
cmp dword [ebp - 0x240], 2
je 0x42a592
jmp 0x42a5c9
cmp dword [ebp - 0x1ac], 0
je 0x42a586
mov edx, dword [ebp - 0xa0]
push edx
push str.Couldnt_bind_to_interface__s
mov eax, dword [ebp - 4]
push eax
call fcn.00424ef0
add esp, 0xc
mov eax, 0x2d
jmp 0x42a921
jmp 0x42a5c9
mov eax, 1
jmp 0x42a921
mov dword [ebp - 0x1ac], 1
mov ecx, dword [ebp + 0x10]
push ecx
lea edx, [ebp - 0x1a4]
push edx
mov eax, dword [ebp - 0xa0]
push eax
push str.Local_Interface__s_is_ip__s_using_address_family__i_n
mov ecx, dword [ebp - 4]
push ecx
call fcn.00424e70
add esp, 0x14
mov dword [ebp - 0x1a8], 1
cmp dword [ebp - 0x1ac], 0
jne 0x42a6c3
mov edx, dword [ebp + 8]
mov eax, dword [edx + 0x440]
mov dword [ebp - 0x1b4], eax
cmp dword [ebp + 0x10], 2
jne 0x42a5f8
mov ecx, dword [ebp + 8]
mov dword [ecx + 0x440], 1
lea edx, [ebp - 0x94]
push edx
push 0
mov eax, dword [ebp - 0xa0]
push eax
mov ecx, dword [ebp + 8]
push ecx
call fcn.00415f90
add esp, 0x10
mov dword [ebp - 0x1b8], eax
cmp dword [ebp - 0x1b8], 1
jne 0x42a636
lea edx, [ebp - 0x94]
push edx
mov eax, dword [ebp + 8]
push eax
call fcn.00413d30
add esp, 8
mov ecx, dword [ebp + 8]
mov edx, dword [ebp - 0x1b4]
mov dword [ecx + 0x440], edx
cmp dword [ebp - 0x94], 0
je 0x42a6b9
push pe_nt_image_headers32
lea eax, [ebp - 0x1a4]
push eax
mov ecx, dword [ebp - 0x94]
mov edx, dword [ecx]
push edx
call fcn.00415b10
add esp, 0xc
mov eax, dword [ebp - 0x94]
mov ecx, dword [eax]
mov edx, dword [ecx + 4]
push edx
lea eax, [ebp - 0x1a4]
push eax
mov ecx, dword [ebp + 0x10]
push ecx
mov edx, dword [ebp - 0xa0]
push edx
push str.Name__s_family__i_resolved_to__s_family__i_n
mov eax, dword [ebp - 4]
push eax
call fcn.00424e70
add esp, 0x18
mov ecx, dword [ebp - 0x94]
push ecx
mov edx, dword [ebp - 4]
push edx
call fcn.00416180
add esp, 8
mov dword [ebp - 0x1a8], 1
jmp 0x42a6c3
mov dword [ebp - 0x1a8], 0xffffffff
cmp dword [ebp - 0x1a8], 0
jle 0x42a71e
cmp dword [ebp + 0x10], 2
jne 0x42a71e
mov eax, dword [ebp - 0x90]
add eax, 4
push eax
lea ecx, [ebp - 0x1a4]
push ecx
push 2
call fcn.0042fa90
add esp, 0xc
test eax, eax
jle 0x42a71e
mov edx, dword [ebp - 0x90]
mov word [edx], 2
mov ax, word [ebp - 0x98]
push eax
call dword [sym.imp.WS2_32.dll_htons]
mov ecx, dword [ebp - 0x90]
mov word [ecx + 2], ax
mov dword [ebp - 0x8c], 0x10
cmp dword [ebp - 0x1a8], 1
jge 0x42a749
mov edx, dword [ebp - 0xa0]
push edx
push str.Couldnt_bind_to__s
mov eax, dword [ebp - 4]
push eax
call fcn.00424ef0
add esp, 0xc
mov eax, 0x2d
jmp 0x42a921
jmp 0x42a77e
cmp dword [ebp + 0x10], 2
jne 0x42a77e
mov ecx, dword [ebp - 0x90]
mov word [ecx], 2
mov dx, word [ebp - 0x98]
push edx
call dword [sym.imp.WS2_32.dll_htons]
mov ecx, dword [ebp - 0x90]
mov word [ecx + 2], ax
mov dword [ebp - 0x8c], 0x10
mov edx, dword [ebp - 0x8c]
push edx
mov eax, dword [ebp - 0x88]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
call dword [sym.imp.WS2_32.dll_bind]
test eax, eax
jl 0x42a85c
mov dword [ebp - 0x23c], 0x80
push 0x80
push 0
lea edx, [ebp - 0x238]
push edx
call sub.MSVCRT.dll_memset
add esp, 0xc
lea eax, [ebp - 0x23c]
push eax
lea ecx, [ebp - 0x238]
push ecx
mov edx, dword [ebp + 0xc]
push edx
call dword [sym.imp.WS2_32.dll_getsockname]
test eax, eax
jge 0x42a82b
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov dword [ebp - 0xa4], eax
mov eax, dword [ebp - 4]
mov ecx, dword [ebp - 0xa4]
mov dword [eax + 0x472c], ecx
mov edx, dword [ebp - 0xa4]
push edx
mov eax, dword [ebp + 8]
push eax
call fcn.0042c9d0
add esp, 8
push eax
mov ecx, dword [ebp - 0xa4]
push ecx
push str.getsockname___failed_with_errno__d:__s
mov edx, dword [ebp - 4]
push edx
call fcn.00424ef0
add esp, 0x10
mov eax, 0x2d
jmp 0x42a921
mov eax, dword [ebp - 0x98]
and eax, 0xffff
push eax
push str.Local_port:__hu_n
mov ecx, dword [ebp - 4]
push ecx
call fcn.00424e70
add esp, 0xc
mov edx, dword [ebp + 8]
mov dword [edx + 0x404], 1
xor eax, eax
jmp 0x42a921
mov eax, dword [ebp - 0x9c]
sub eax, 1
mov dword [ebp - 0x9c], eax
cmp dword [ebp - 0x9c], 0
jle 0x42a8ce
mov ecx, dword [ebp - 0x98]
and ecx, 0xffff
push ecx
push str.Bind_to_local_port__hu_failed__trying_next_n
mov edx, dword [ebp - 4]
push edx
call fcn.00424e70
add esp, 0xc
mov ax, word [ebp - 0x98]
add ax, 1
mov word [ebp - 0x98], ax
mov ecx, dword [ebp - 0x88]
xor edx, edx
mov dx, word [ecx]
cmp edx, 2
jne 0x42a8cc
mov ax, word [ebp - 0x98]
push eax
call dword [sym.imp.WS2_32.dll_ntohs]
mov ecx, dword [ebp - 0x90]
mov word [ecx + 2], ax
jmp 0x42a8d0
jmp 0x42a8d5
jmp 0x42a77e
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov dword [ebp - 0xa4], eax
mov edx, dword [ebp - 4]
mov eax, dword [ebp - 0xa4]
mov dword [edx + 0x472c], eax
mov ecx, dword [ebp - 0xa4]
push ecx
mov edx, dword [ebp + 8]
push edx
call fcn.0042c9d0
add esp, 8
push eax
mov eax, dword [ebp - 0xa4]
push eax
push str.bind_failed_with_errno__d:__s
mov ecx, dword [ebp - 4]
push ecx
call fcn.00424ef0
add esp, 0x10
mov eax, 0x2d
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret