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

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x9c8
mov eax, dword [0x4d8c20]
xor eax, ebp
mov dword [ebp - 8], eax
mov eax, dword [ebp + 8]
push ebx
push esi
mov esi, dword [eax]
push edi
lea edx, [eax + 0x3e0]
xor ebx, ebx
push 0xff
mov dword [ebp - 0x9a0], eax
lea eax, [ebp - 0x10b]
push ebx
push eax
mov dword [ebp - 0x9c4], ecx
mov dword [ebp - 0x9b0], edx
mov dword [ebp - 0x99c], esi
mov byte [ebp - 0x10c], bl
call fcn.0047f860
mov esi, dword [esi + 0x3a4]
add esp, 0xc
mov dword [ebp - 0x9a4], ebx
mov dword [ebp - 0x9b4], ebx
mov dword [ebp - 0x9ac], ebx
mov dword [ebp - 0x9b8], 1
mov dword [ebp - 0x998], ebx
cmp esi, ebx
je 0x4611ab
mov eax, esi
lea edx, [eax + 1]
jmp 0x4610a0
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x4610a0
sub eax, edx
cmp eax, 1
jbe 0x4611ab
mov eax, esi
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x4610b7
sub eax, edx
cmp eax, 0x16
jae 0x4610cc
mov eax, 0x16
jmp 0x4610da
mov eax, esi
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x4610d1
sub eax, edx
inc eax
push 1
push eax
call dword [0x4dc058]
mov ebx, eax
add esp, 8
mov dword [ebp - 0x998], ebx
test ebx, ebx
jne 0x461107
lea eax, [ebx + 0x1b]
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.004751dc
mov esp, ebp
pop ebp
ret
cmp byte [esi], 0x3a
jne 0x461228
mov edi, esi
test edi, edi
je 0x46118e
push 0x3a
push edi
call fcn.00476060
mov esi, eax
add esp, 8
test esi, esi
je 0x46118e
push 0xa
lea edx, [esi + 1]
push 0
push edx
call fcn.0048dbf2
add esp, 0xc
push eax
call fcn.004554e0
add esp, 4
movzx edi, ax
push 0x2d
push esi
mov dword [ebp - 0x9b4], edi
call fcn.00476060
add esp, 8
test eax, eax
je 0x461262
push 0xa
xor esi, esi
inc eax
push esi
push eax
call fcn.0048dbf2
add esp, 0xc
push eax
call fcn.004554e0
movzx eax, ax
add esp, 4
mov dword [ebp - 0x9ac], eax
cmp di, ax
jbe 0x46118e
mov dword [ebp - 0x9ac], esi
mov dword [ebp - 0x9b4], esi
cmp byte [ebx], 0
je 0x4611ab
call fcn.0044a410
sub eax, 0
je 0x461270
dec eax
je 0x461212
dec eax
je 0x4612a3
mov esi, dword [ebp - 0x9a0]
mov eax, dword [esi + 0x140]
lea ecx, [ebp - 0x9a8]
push ecx
lea edx, [ebp - 0x994]
push edx
push eax
mov dword [ebp - 0x9a8], 0x80
call dword [sym.imp.WS2_32.dll_getsockname]
test eax, eax
je 0x461278
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push esi
mov edi, eax
call fcn.0046a2a0
mov ecx, dword [ebp - 0x99c]
add esp, 4
push eax
push str.getsockname___failed:__s
push ecx
call fcn.0044b120
add esp, 0xc
test ebx, ebx
je 0x461212
push ebx
call dword [0x4dc04c]
add esp, 4
mov eax, 0x1e
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.004751dc
mov esp, ebp
pop ebp
ret
push 0x3a
push esi
call fcn.00476060
mov edi, eax
add esp, 8
test edi, edi
je 0x46124d
mov ecx, edi
sub ecx, esi
push ecx
push esi
push ebx
call fcn.004a3a00
add esp, 0xc
jmp 0x461112
mov edx, ebx
mov eax, esi
sub edx, esi
mov cl, byte [eax]
mov byte [edx + eax], cl
inc eax
test cl, cl
jne 0x461253
jmp 0x46118e
movzx eax, di
mov dword [ebp - 0x9ac], eax
jmp 0x46118e
mov ebx, dword [ebp - 0x998]
jmp 0x4612a9
movzx eax, word [ebp - 0x994]
lea edx, [ebp - 0x990]
push 0x401
push edx
lea esi, [ebp - 0x514]
call fcn.00469aa0
add esp, 8
mov dword [ebp - 0x9b8], 0
lea ebx, [ebp - 0x514]
mov esi, dword [ebp - 0x9a0]
lea eax, [ebp - 0x9a4]
push eax
push 0
push ebx
push esi
call fcn.00449f70
add esp, 0x10
cmp eax, 1
jne 0x4612d2
lea eax, [ebp - 0x9a4]
call fcn.0044a720
mov edi, dword [ebp - 0x9a4]
test edi, edi
je 0x4612ed
mov eax, dword [ebp - 0x99c]
mov esi, dword [edi]
call fcn.0044a140
test esi, esi
jne 0x461330
mov ecx, dword [ebp - 0x99c]
push ebx
push str.failed_to_resolve_the_address_provided_to_PORT:__s
push ecx
call fcn.0044b120
mov eax, dword [ebp - 0x998]
add esp, 0xc
test eax, eax
je 0x461212
push eax
call dword [0x4dc04c]
add esp, 4
mov eax, 0x1e
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.004751dc
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp - 0x998]
test eax, eax
je 0x461344
push eax
call dword [0x4dc04c]
add esp, 4
mov edi, esi
mov dword [ebp - 0x998], 0xffffffff
mov dword [ebp - 0x9bc], 0
mov dword [ebp - 0x9a4], edi
jmp 0x461368
mov edi, dword [ebp - 0x9a4]
mov edx, dword [ebp - 0x9a0]
push edx
lea ebx, [ebp - 0x998]
xor edx, edx
mov ecx, edi
call fcn.00449b80
add esp, 4
mov dword [ebp - 0x9c0], eax
test eax, eax
je 0x4613a6
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov edi, dword [edi + 0x1c]
mov dword [ebp - 0x9bc], eax
mov dword [ebp - 0x9a4], edi
test edi, edi
jne 0x461362
jmp 0x4613aa
test edi, edi
jne 0x4613ea
mov eax, dword [ebp - 0x9a0]
mov edi, dword [ebp - 0x9bc]
push eax
call fcn.0046a2a0
mov ecx, dword [ebp - 0x99c]
add esp, 4
push eax
push str.socket_failure:__s
push ecx
call fcn.0044b120
add esp, 0xc
mov eax, 0x1e
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.004751dc
mov esp, ebp
pop ebp
ret
mov edx, dword [edi + 0x10]
mov eax, dword [edi + 0x18]
push edx
push eax
lea ecx, [ebp - 0x994]
push ecx
call fcn.00478c70
mov eax, dword [ebp - 0x9b4]
mov edx, dword [edi + 0x10]
add esp, 0xc
mov dword [ebp - 0x9a8], edx
movzx esi, ax
cmp ax, word [ebp - 0x9ac]
ja 0x46158f
cmp word [ebp - 0x994], 2
jne 0x461438
push esi
call dword [sym.imp.WS2_32.dll_htons]
mov word [ebp - 0x992], ax
mov eax, dword [ebp - 0x9a8]
mov edx, dword [ebp - 0x998]
push eax
lea ecx, [ebp - 0x994]
push ecx
push edx
call dword [sym.imp.WS2_32.dll_bind]
test eax, eax
je 0x461586
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp dword [ebp - 0x9b8], 0
je 0x4614d7
cmp eax, 0x2741
jne 0x4614d7
mov ebx, dword [ebp - 0x9a0]
push ebx
mov edi, eax
call fcn.0046a2a0
add esp, 4
push eax
movzx eax, si
mov esi, dword [ebp - 0x99c]
push eax
push str.bind_port_hu__on_non_local_address_failed:__s_n
push esi
call fcn.0044b0a0
mov eax, dword [ebx + 0x140]
add esp, 0x10
lea ecx, [ebp - 0x9a8]
push ecx
lea edx, [ebp - 0x994]
push edx
push eax
mov dword [ebp - 0x9a8], 0x80
call dword [sym.imp.WS2_32.dll_getsockname]
test eax, eax
jne 0x4614f6
movzx esi, word [ebp - 0x9b4]
mov dword [ebp - 0x9b8], eax
jmp 0x4614e4
cmp eax, 0x2740
je 0x4614e3
cmp eax, 0xd
jne 0x461539
inc esi
cmp si, word [ebp - 0x9ac]
jbe 0x461420
jmp 0x46158f
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push ebx
mov edi, eax
call fcn.0046a2a0
add esp, 4
push eax
push str.getsockname___failed:__s
push esi
call fcn.0044b120
mov esi, dword [ebp - 0x998]
add esp, 0xc
mov eax, ebx
call fcn.00449b30
mov eax, 0x1e
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.004751dc
mov esp, ebp
pop ebp
ret
mov ebx, dword [ebp - 0x9a0]
push ebx
mov edi, eax
call fcn.0046a2a0
mov edx, dword [ebp - 0x99c]
add esp, 4
push eax
movzx ecx, si
push ecx
push str.bind_port_hu__failed:__s
push edx
call fcn.0044b120
mov esi, dword [ebp - 0x998]
add esp, 0x10
mov eax, ebx
call fcn.00449b30
mov eax, 0x1e
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.004751dc
mov esp, ebp
pop ebp
ret
cmp si, word [ebp - 0x9ac]
jbe 0x4615ca
mov eax, dword [ebp - 0x99c]
push str.bind___failed__we_ran_out_of_ports_
push eax
call fcn.0044b120
mov esi, dword [ebp - 0x998]
mov eax, dword [ebp - 0x9a0]
add esp, 8
call fcn.00449b30
mov eax, 0x1e
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.004751dc
mov esp, ebp
pop ebp
ret
mov esi, dword [ebp - 0x998]
lea ecx, [ebp - 0x9a8]
push ecx
lea edx, [ebp - 0x994]
push edx
push esi
mov dword [ebp - 0x9a8], 0x80
call dword [sym.imp.WS2_32.dll_getsockname]
test eax, eax
je 0x46163c
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov ebx, dword [ebp - 0x9a0]
push ebx
mov edi, eax
call fcn.0046a2a0
add esp, 4
push eax
mov eax, dword [ebp - 0x99c]
push str.getsockname___failed:__s
push eax
call fcn.0044b120
add esp, 0xc
mov eax, ebx
call fcn.00449b30
mov eax, 0x1e
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.004751dc
mov esp, ebp
pop ebp
ret
push 1
push esi
call dword [sym.imp.WS2_32.dll_listen]
test eax, eax
je 0x461672
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov ebx, dword [ebp - 0x9a0]
push ebx
mov edi, eax
call fcn.0046a2a0
mov ecx, dword [ebp - 0x99c]
add esp, 4
push eax
push str.socket_failure:__s
push ecx
jmp 0x46150e
mov ecx, dword [ebp - 0x9a4]
push 0x100
lea esi, [ebp - 0x10c]
call fcn.00449cd0
mov esi, dword [ebp - 0x9c4]
add esp, 4
cmp esi, 2
je 0x46180c
mov cx, word [ebp - 0x994]
mov ebx, dword [ebp - 0x9a0]
cmp dword [ebx + 0x1fc], 0
jne 0x4616b4
test esi, esi
je 0x4616eb
cmp esi, 1
jne 0x4616bf
cmp cx, 2
jne 0x4616eb
movzx eax, cx
sub eax, 2
jne 0x4616eb
mov edx, dword [ebp - 0x992]
push edx
call dword [sym.imp.WS2_32.dll_ntohs]
movzx edi, ax
test esi, esi
je 0x4616f6
cmp esi, 1
je 0x46176f
mov cx, word [ebp - 0x994]
inc esi
cmp esi, 2
jne 0x4616a1
jmp 0x461812
mov eax, dword [ebp - 0x9b0]
xor edx, edx
cmp word [ebp - 0x994], 2
push edi
setne dl
lea ecx, [ebp - 0x10c]
push ecx
inc edx
push edx
push str.EPRT
push str._s__d_s_hu
push eax
call fcn.0046c6b0
mov edi, eax
add esp, 0x18
test edi, edi
je 0x461818
push edi
call sym.kometabrowsercmd.exe_curl_easy_strerror
mov ecx, dword [ebp - 0x99c]
add esp, 4
push eax
push str.Failure_sending_EPRT_command:__s
push ecx
call fcn.0044b120
mov esi, dword [ebp - 0x998]
add esp, 0xc
mov eax, ebx
call fcn.00449b30
mov edx, dword [ebp - 0x9b0]
mov dword [edx + 0x68], 1
xor eax, eax
jmp 0x46184e
lea ecx, [ebp - 0x914]
lea edx, [ebp - 0x10c]
jmp 0x461780
mov al, byte [edx]
test al, al
je 0x461795
cmp al, 0x2e
jne 0x46178f
mov byte [ecx], 0x2c
jmp 0x461791
mov byte [ecx], al
inc ecx
inc edx
jne 0x461780
mov eax, edi
mov edx, edi
and edx, 0xff
push edx
shr eax, 8
push eax
push str.__d__d
push 0x14
push ecx
mov byte [ecx], 0
call sym.kometabrowsercmd.exe_curl_msnprintf
mov ecx, dword [ebp - 0x9b0]
add esp, 0x14
lea eax, [ebp - 0x914]
push eax
push str.PORT
push 0x4c3cd0
push ecx
call fcn.0046c6b0
mov edi, eax
add esp, 0x10
test edi, edi
je 0x461818
push edi
call sym.kometabrowsercmd.exe_curl_easy_strerror
mov edx, dword [ebp - 0x99c]
add esp, 4
push eax
push str.Failure_sending_PORT_command:__s
push edx
call fcn.0044b120
mov esi, dword [ebp - 0x998]
add esp, 0xc
mov eax, ebx
call fcn.00449b30
xor eax, eax
jmp 0x46184e
mov ebx, dword [ebp - 0x9a0]
mov edi, dword [ebp - 0x9c0]
mov eax, dword [ebp - 0x9b0]
mov dword [eax + 0x68], esi
mov esi, dword [ebx + 0x144]
cmp esi, 0xffffffff
je 0x461833
mov eax, ebx
call fcn.00449b30
mov ecx, dword [ebp - 0x998]
mov dword [ebx + 0x144], ecx
mov dword [ebx + 0x1e0], 1
mov eax, 0x1c
mov ecx, ebx
call fcn.00460ea0
mov ecx, dword [ebp - 8]
mov eax, edi
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.004751dc
mov esp, ebp
pop ebp
ret