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

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x4c
mov eax, dword [0x100120b4]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
mov esi, dword [ebp + 8]
mov eax, dword [esi]
movzx ecx, word [eax]
push edi
push 2
pop ebx
mov dword [ebp - 0x34], ecx
cmp ecx, ebx
jne 0x1000ba76
cmp dword [eax + 4], 0
je 0x1000bad5
push dword [ebp + 0xc]
push 0x10
push eax
push dword [esi + 4]
call fcn.10002e31
or ebx, 0xffffffff
cmp eax, ebx
jne 0x1000ba65
mov dword [esi + 8], ebx
mov dword [esi + 4], ebx
mov eax, ebx
jmp 0x1000bd61
push dword [esi + 8]
call dword [sym.imp.ws2_32.dll_closesocket]
mov dword [esi + 8], ebx
jmp 0x1000bd5f
cmp ecx, 0x17
jne 0x1000bad5
xor edi, edi
cmp word [eax + 8], di
jne 0x1000baad
cmp word [eax + 0xa], di
jne 0x1000baad
cmp word [eax + 0xc], di
jne 0x1000baad
cmp word [eax + 0xe], di
jne 0x1000baad
cmp word [eax + 0x10], di
jne 0x1000baad
cmp word [eax + 0x12], di
jne 0x1000baad
cmp word [eax + 0x14], di
jne 0x1000baad
cmp word [eax + 0x16], di
je 0x1000bad5
push dword [ebp + 0xc]
push 0x1c
push eax
push dword [esi + 8]
call fcn.10002e31
or ebx, 0xffffffff
cmp eax, ebx
je 0x1000ba58
push dword [esi + 4]
call dword [sym.imp.ws2_32.dll_closesocket]
xor eax, eax
mov dword [esi + 4], ebx
jmp 0x1000bd61
push 0x1c
lea eax, [ebp - 0x20]
push 0
push eax
call sub.msvcr100.dll_memset
add esp, 0xc
cmp dword [ebp - 0x34], ebx
jne 0x1000bb15
mov eax, dword [esi + 8]
mov edi, dword [esi + 4]
mov dword [ebp - 0x24], eax
mov eax, dword [esi]
cmp word [eax], bx
movzx eax, word [eax + 2]
mov dword [ebp - 0x28], eax
lea eax, [ebp - 0x20]
push eax
mov dword [ebp - 0x3c], 0x17
mov dword [ebp - 0x2c], edi
call fcn.1000ae63
pop ecx
jmp 0x1000bb3b
mov eax, dword [esi + 4]
mov dword [ebp - 0x24], eax
mov eax, dword [esi + 8]
mov dword [ebp - 0x2c], eax
mov eax, dword [esi]
cmp word [eax], bx
movzx eax, word [eax + 2]
and dword [ebp - 0x1c], 0
mov edi, dword [ebp - 0x2c]
mov dword [ebp - 0x3c], ebx
mov dword [ebp - 0x28], eax
mov word [ebp - 0x20], bx
mov ax, word [ebp - 0x28]
push dword [ebp + 0xc]
xor ecx, ecx
mov word [ebp - 0x1e], ax
mov eax, dword [esi]
cmp word [eax], 0x17
setne cl
dec ecx
and ecx, 0xc
add ecx, 0x10
push ecx
push eax
push edi
call fcn.10002e31
or ebx, 0xffffffff
cmp eax, ebx
jne 0x1000bb8a
cmp edi, ebx
je 0x1000bb72
push edi
call dword [sym.imp.ws2_32.dll_closesocket]
cmp dword [ebp - 0x24], ebx
je 0x1000bb80
push dword [ebp - 0x24]
call dword [sym.imp.ws2_32.dll_closesocket]
mov dword [esi + 8], ebx
mov eax, ebx
jmp 0x1000bacd
mov eax, dword [esi]
xor ecx, ecx
cmp word [eax], 0x17
setne cl
dec ecx
and ecx, 0xc
add ecx, 0x10
mov dword [ebp - 0x44], ecx
lea ecx, [ebp - 0x44]
push ecx
push eax
push edi
call dword [sym.imp.ws2_32.dll_getsockname]
cmp eax, ebx
je 0x1000bb67
mov eax, dword [esi]
cmp word [eax], 2
movzx eax, word [eax + 2]
push dword [ebp + 0xc]
mov word [ebp - 0x1e], ax
xor eax, eax
cmp word [ebp - 0x20], 0x17
setne al
dec eax
and eax, 0xc
add eax, 0x10
push eax
lea eax, [ebp - 0x20]
push eax
push dword [ebp - 0x24]
call fcn.10002e31
cmp eax, ebx
jne 0x1000bd5f
cmp word [ebp - 0x28], 0
mov dword [ebp - 0x4c], 4
jne 0x1000bb67
lea eax, [ebp - 0x4c]
push eax
lea eax, [ebp - 0x40]
push eax
push 0x1008
push 0xffff
push edi
call dword [sym.imp.ws2_32.dll_getsockopt]
and dword [ebp - 0x38], 0
mov edi, dword [sym.imp.ws2_32.dll_closesocket]
mov eax, dword [ebp - 0x2c]
push 0
push dword [ebp - 0x40]
mov dword [ebp - 0x28], eax
mov eax, dword [ebp - 0x24]
push dword [ebp - 0x34]
mov dword [ebp - 0x30], eax
mov dword [esi + 4], ebx
mov dword [esi + 8], ebx
call dword [sym.imp.ws2_32.dll_socket]
mov dword [ebp - 0x2c], eax
cmp eax, ebx
je 0x1000bcfe
push 0
push dword [ebp - 0x40]
push dword [ebp - 0x3c]
call dword [sym.imp.ws2_32.dll_socket]
mov dword [ebp - 0x24], eax
cmp eax, ebx
je 0x1000bd1b
push dword [ebp + 0xc]
xor ecx, ecx
cmp word [ebp - 0x20], 0x17
mov word [ebp - 0x1e], cx
setne cl
dec ecx
and ecx, 0xc
add ecx, 0x10
push ecx
lea ecx, [ebp - 0x20]
push ecx
push eax
call fcn.10002e31
cmp eax, ebx
je 0x1000bd38
push dword [ebp - 0x28]
call edi
push dword [ebp - 0x30]
call edi
xor eax, eax
cmp word [ebp - 0x20], 0x17
setne al
dec eax
and eax, 0xc
add eax, 0x10
mov dword [ebp - 0x48], eax
lea eax, [ebp - 0x48]
push eax
lea eax, [ebp - 0x20]
push eax
push dword [ebp - 0x24]
call dword [sym.imp.ws2_32.dll_getsockname]
cmp eax, ebx
je 0x1000bcf7
movzx ecx, word [ebp - 0x1e]
mov eax, dword [esi]
push dword [ebp + 0xc]
mov word [eax + 2], cx
mov eax, dword [esi]
xor ecx, ecx
cmp word [eax], 0x17
setne cl
dec ecx
and ecx, 0xc
add ecx, 0x10
push ecx
push eax
push dword [ebp - 0x2c]
call fcn.10002e31
cmp eax, ebx
jne 0x1000bd42
inc dword [ebp - 0x38]
cmp dword [ebp - 0x38], 0x32
jl 0x1000bc1b
push dword [ebp - 0x2c]
call edi
jmp 0x1000bd11
cmp dword [ebp - 0x28], ebx
je 0x1000bd08
push dword [ebp - 0x28]
call edi
cmp dword [ebp - 0x24], ebx
je 0x1000bb80
push dword [ebp - 0x24]
call edi
jmp 0x1000bb80
push dword [ebp - 0x2c]
call edi
cmp dword [ebp - 0x28], ebx
je 0x1000bd2a
push dword [ebp - 0x28]
call edi
cmp dword [ebp - 0x30], ebx
je 0x1000bb80
push dword [ebp - 0x30]
jmp 0x1000bd14
push dword [ebp - 0x2c]
call edi
push dword [ebp - 0x24]
jmp 0x1000bd1e
cmp dword [ebp - 0x34], 2
jne 0x1000bd53
mov eax, dword [ebp - 0x2c]
mov dword [esi + 4], eax
mov eax, dword [ebp - 0x24]
jmp 0x1000bd5c
mov eax, dword [ebp - 0x24]
mov dword [esi + 4], eax
mov eax, dword [ebp - 0x2c]
mov dword [esi + 8], eax
xor eax, eax
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.1000c212
leave
ret 8