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

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x9b4
mov eax, dword [0x1013a420]
xor eax, esp
mov dword [esp + 0x9b0], eax
push ebx
push esi
push edi
mov esi, ecx
mov dword [esp + 0x28], edx
push 0xff
lea eax, [esp + 0xb5]
mov byte [esp + 0xb4], 0
push 0
mov ebx, dword [esi]
push eax
mov dword [esp + 0x18], ebx
call fcn.1003e9c0
mov ebx, dword [ebx + 0x364]
xor eax, eax
add esp, 0xc
mov dword [esp + 0x10], eax
mov dword [esp + 0x24], eax
mov edi, eax
mov dword [esp + 0x1c], eax
mov dword [esp + 0x2c], 1
test ebx, ebx
je 0x1002a458
mov ecx, ebx
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x1002a34d
sub ecx, edx
cmp ecx, 1
jbe 0x1002a458
mov edx, ebx
lea ecx, [edx + 1]
mov al, byte [edx]
inc edx
test al, al
jne 0x1002a364
sub edx, ecx
push 0x16
pop ecx
cmp edx, ecx
jb 0x1002a382
mov ecx, ebx
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x1002a379
sub ecx, edx
lea eax, [ecx + 1]
push 1
push eax
call dword [0x1014537c]
mov edi, eax
pop ecx
pop ecx
test edi, edi
jne 0x1002a39d
push 0x1b
jmp 0x1002a8f3
cmp byte [ebx], 0x3a
jne 0x1002a3a6
mov ecx, ebx
jmp 0x1002a3db
push 0x3a
push ebx
call fcn.1003b670
pop ecx
pop ecx
mov ecx, eax
mov dword [esp + 0x20], ecx
test ecx, ecx
je 0x1002a3cd
sub ecx, ebx
push ecx
push ebx
push edi
call fcn.1003ba20
mov ecx, dword [esp + 0x2c]
add esp, 0xc
jmp 0x1002a3db
mov edx, edi
sub edx, ebx
mov al, byte [ebx]
mov byte [edx + ebx], al
inc ebx
test al, al
jne 0x1002a3d1
test ecx, ecx
je 0x1002a445
push 0x3a
push ecx
call fcn.1003b670
mov ebx, eax
pop ecx
pop ecx
test ebx, ebx
je 0x1002a445
push 0xa
lea ecx, [ebx + 1]
push 0
push ecx
call fcn.1003b9eb
add esp, 0xc
movzx eax, ax
mov dword [esp + 0x24], eax
push 0x2d
push ebx
call fcn.1003b670
pop ecx
pop ecx
test eax, eax
je 0x1002a42b
push 0xa
inc eax
push 0
push eax
call fcn.1003b9eb
movzx ecx, ax
add esp, 0xc
mov eax, dword [esp + 0x24]
jmp 0x1002a432
mov eax, dword [esp + 0x24]
movzx ecx, ax
mov dword [esp + 0x1c], ecx
cmp ax, cx
jbe 0x1002a445
and dword [esp + 0x1c], 0
and dword [esp + 0x24], 0
xor eax, eax
cmp byte [edi], al
cmovne eax, edi
mov dword [esp + 0x14], eax
test eax, eax
jne 0x1002a4dd
lea eax, [esp + 0x18]
mov dword [esp + 0x18], 0x80
push eax
lea eax, [esp + 0x34]
push eax
push dword [esi + 0x130]
call dword [sym.imp.WS2_32.dll_getsockname]
test eax, eax
je 0x1002a4b0
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov edx, eax
mov ecx, esi
call fcn.10030e33
push eax
push str.getsockname___failed:__s
push dword [esp + 0x14]
call fcn.10018208
add esp, 0xc
test edi, edi
je 0x1002a8f1
push edi
call dword [0x10145380]
pop ecx
jmp 0x1002a8f1
movzx ecx, word [esp + 0x30]
lea eax, [esp + 0x5b0]
push 0x401
push eax
lea edx, [esp + 0x3c]
call fcn.10030751
and dword [esp + 0x34], 0
lea eax, [esp + 0x5b8]
pop ecx
pop ecx
mov dword [esp + 0x14], eax
lea ecx, [esp + 0x10]
mov edx, eax
push ecx
push 0
mov ecx, esi
call fcn.1001789a
pop ecx
pop ecx
cmp eax, 1
jne 0x1002a4ff
lea edx, [esp + 0x10]
mov ecx, esi
call fcn.10017f1b
mov edx, dword [esp + 0x10]
test edx, edx
je 0x1002a514
mov ecx, dword [esp + 0xc]
mov ebx, dword [edx]
call fcn.100179f9
jmp 0x1002a516
xor ebx, ebx
test ebx, ebx
jne 0x1002a528
push dword [esp + 0x14]
push str.failed_to_resolve_the_address_provided_to_PORT:__s
jmp 0x1002a48f
test edi, edi
je 0x1002a534
push edi
call dword [0x10145380]
pop ecx
or dword [esp + 0x14], 0xffffffff
xor edi, edi
lea eax, [esp + 0x14]
mov edx, ebx
push eax
push 0
mov ecx, esi
call fcn.10017572
mov dword [esp + 0x28], eax
pop ecx
pop ecx
test eax, eax
je 0x1002a564
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov ebx, dword [ebx + 0x1c]
mov edi, eax
test ebx, ebx
jne 0x1002a53b
test ebx, ebx
jne 0x1002a588
mov edx, edi
mov ecx, esi
call fcn.10030e33
push eax
push str.socket_failure:__s
push dword [esp + 0x14]
call fcn.10018208
add esp, 0xc
jmp 0x1002a8f1
push dword [ebx + 0x10]
lea eax, [esp + 0x34]
push dword [ebx + 0x18]
push eax
call fcn.1003da60
mov eax, dword [ebx + 0x10]
add esp, 0xc
mov edx, dword [esp + 0x24]
mov ecx, dword [esp + 0x1c]
cmp dx, cx
mov edi, dword [esp + 0x14]
mov dword [esp + 0x18], eax
movzx eax, dx
mov dword [esp + 0x10], eax
ja 0x1002a8d8
push 2
pop ecx
cmp word [esp + 0x30], cx
jne 0x1002a5d4
push eax
call dword [sym.imp.WS2_32.dll_htons]
mov word [esp + 0x32], ax
push dword [esp + 0x18]
lea eax, [esp + 0x34]
push eax
push edi
call dword [sym.imp.WS2_32.dll_bind]
test eax, eax
je 0x1002a6c0
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp dword [esp + 0x2c], 0
je 0x1002a655
mov ecx, 0x2741
cmp eax, ecx
jne 0x1002a655
mov edx, ecx
mov ecx, esi
call fcn.10030e33
push eax
mov eax, dword [esp + 0x14]
movzx eax, ax
push eax
push str.bind_port_hu__on_non_local_address_failed:__s_n
push dword [esp + 0x18]
call fcn.10018194
add esp, 0x10
mov dword [esp + 0x18], 0x80
lea eax, [esp + 0x18]
push eax
lea eax, [esp + 0x34]
push eax
push dword [esi + 0x130]
call dword [sym.imp.WS2_32.dll_getsockname]
test eax, eax
jne 0x1002a672
mov eax, dword [esp + 0x24]
and dword [esp + 0x2c], 0
movzx eax, ax
jmp 0x1002a666
cmp eax, 0x2740
je 0x1002a661
cmp eax, 0xd
jne 0x1002a698
mov eax, dword [esp + 0x10]
inc eax
mov ecx, dword [esp + 0x1c]
cmp ax, cx
jmp 0x1002a5b4
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov edx, eax
mov ecx, esi
call fcn.10030e33
push eax
push str.getsockname___failed:__s
push dword [esp + 0x14]
call fcn.10018208
add esp, 0xc
jmp 0x1002a8e8
mov edx, eax
mov ecx, esi
call fcn.10030e33
push eax
mov eax, dword [esp + 0x14]
movzx eax, ax
push eax
push str.bind_port_hu__failed:__s
push dword [esp + 0x18]
call fcn.10018208
add esp, 0x10
jmp 0x1002a8e8
mov eax, dword [esp + 0x10]
mov ecx, dword [esp + 0x1c]
cmp ax, cx
ja 0x1002a8d8
lea eax, [esp + 0x18]
mov dword [esp + 0x18], 0x80
push eax
lea eax, [esp + 0x34]
push eax
push edi
call dword [sym.imp.WS2_32.dll_getsockname]
test eax, eax
jne 0x1002a672
push 1
push edi
call dword [sym.imp.WS2_32.dll_listen]
test eax, eax
je 0x1002a715
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov edx, eax
mov ecx, esi
call fcn.10030e33
push eax
push str.socket_failure:__s
jmp 0x1002a687
push 0x100
lea edx, [esp + 0xb4]
mov ecx, ebx
call fcn.10017659
mov ebx, dword [esp + 0x2c]
pop ecx
push 2
pop edx
cmp ebx, edx
je 0x1002a786
mov cx, word [esp + 0x30]
cmp dword [esi + 0x208], 0
jne 0x1002a746
test ebx, ebx
je 0x1002a77d
cmp ebx, 1
jne 0x1002a750
cmp cx, dx
jne 0x1002a77d
movzx eax, cx
sub eax, edx
jne 0x1002a77d
push dword [esp + 0x32]
call dword [sym.imp.WS2_32.dll_ntohs]
movzx eax, ax
mov dword [esp + 0x14], eax
test ebx, ebx
je 0x1002a863
cmp ebx, 1
je 0x1002a7c5
mov cx, word [esp + 0x30]
push 2
pop edx
inc ebx
mov dword [esp + 0x28], ebx
cmp ebx, edx
jne 0x1002a739
mov ebx, dword [esp + 0x20]
mov edx, dword [esp + 0x28]
mov dword [esi + 0x460], edx
mov edx, dword [esi + 0x134]
cmp edx, 0xffffffff
je 0x1002a7a6
mov ecx, esi
call fcn.1001753e
mov dword [esi + 0x134], edi
mov dword [esi + 0x1ec], 1
mov dword [esi + 0x46c], 0x1c
jmp 0x1002a8d4
lea edx, [esp + 0x1b0]
lea ebx, [esp + 0xb0]
mov cl, byte [ebx]
test cl, cl
je 0x1002a7f2
cmp cl, 0x2e
movzx eax, cl
mov dword [esp + 0x20], 0x2c
cmove eax, dword [esp + 0x20]
mov byte [edx], al
inc edx
inc ebx
jne 0x1002a7d3
mov eax, dword [esp + 0x14]
movzx ecx, ax
movzx eax, cl
push eax
shr ecx, 8
push ecx
push str.__d__d
push 0x14
push edx
mov byte [edx], 0
call fcn.1001ea20
add esp, 0x14
lea eax, [esp + 0x1b0]
push eax
push str.PORT
lea eax, [esi + 0x3f8]
push str._s__s
push eax
call fcn.100358d5
mov ebx, eax
add esp, 0x10
test ebx, ebx
je 0x1002a78a
mov ecx, ebx
call fcn.10030779
push eax
push str.Failure_sending_PORT_command:__s
push dword [esp + 0x14]
call fcn.10018208
add esp, 0xc
mov edx, edi
mov ecx, esi
call fcn.1001753e
jmp 0x1002a8cd
movzx eax, ax
push eax
lea eax, [esp + 0xb4]
push eax
push 2
pop ecx
xor eax, eax
cmp word [esp + 0x38], cx
setne al
inc eax
push eax
push str.EPRT
lea eax, [esi + 0x3f8]
push str._s__d_s_hu
push eax
call fcn.100358d5
mov ebx, eax
add esp, 0x18
test ebx, ebx
je 0x1002a78a
mov ecx, ebx
call fcn.10030779
push eax
push str.Failure_sending_EPRT_command:__s
push dword [esp + 0x14]
call fcn.10018208
add esp, 0xc
mov edx, edi
mov ecx, esi
call fcn.1001753e
mov dword [esi + 0x460], 1
and dword [esi + 0x46c], 0
mov eax, ebx
jmp 0x1002a8f4
push str.bind___failed__we_ran_out_of_ports_
push dword [esp + 0x10]
call fcn.10018208
pop ecx
pop ecx
mov edx, edi
mov ecx, esi
call fcn.1001753e
push 0x1e
pop eax
mov ecx, dword [esp + 0x9bc]
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.1003890f
mov esp, ebp
pop ebp
ret