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

Disassembly:
sub esp, 0x9a8
mov eax, dword [0x13147f14]
xor eax, esp
mov dword [esp + 0x9a4], eax
push ebx
push ebp
mov ebp, dword [edi]
push esi
xor ebx, ebx
push 0xff
lea eax, [esp + 0xb1]
push ebx
push eax
mov dword [esp + 0x1c], ebp
mov dword [esp + 0x18], 0xffffffff
mov byte [esp + 0xb8], bl
call fcn.1301f940
mov esi, dword [ebp + 0x364]
mov dword [esp + 0x30], ebx
mov eax, dword [ebp + 0x364]
add esp, 0xc
cmp eax, ebx
mov dword [esp + 0x1c], ebx
mov dword [esp + 0x14], ebx
mov dword [esp + 0x28], 1
je 0x13058cc0
lea edx, [eax + 1]
nop
mov cl, byte [eax]
add eax, 1
test cl, cl
jne 0x13058b60
sub eax, edx
cmp eax, 1
jbe 0x13058cc0
mov eax, esi
lea edx, [eax + 1]
lea esp, [esp]
mov cl, byte [eax]
add eax, 1
test cl, cl
jne 0x13058b80
sub eax, edx
cmp eax, 0x41
jae 0x13058b97
mov eax, 0x41
jmp 0x13058bab
mov eax, esi
lea edx, [eax + 1]
lea esp, [esp]
mov cl, byte [eax]
add eax, 1
test cl, cl
jne 0x13058ba0
sub eax, edx
add eax, 1
push 1
push eax
call dword [0x13149120]
mov ebx, eax
add esp, 8
test ebx, ebx
jne 0x13058bdd
pop esi
pop ebp
mov eax, 0x1b
pop ebx
mov ecx, dword [esp + 0x9a4]
xor ecx, esp
call fcn.130222cb
add esp, 0x9a8
ret
mov al, byte [esi]
cmp al, 0x5b
jne 0x13058d32
lea ecx, [esi + 1]
push 0x5d
push esi
mov dword [esp + 0x28], ecx
call fcn.130364f0
mov ebp, eax
add esp, 8
test ebp, ebp
je 0x13058c83
mov eax, dword [esp + 0x20]
mov edx, ebp
sub edx, eax
push edx
push eax
push ebx
call fcn.1306bf20
add esp, 0xc
test ebp, ebp
je 0x13058c83
push 0x3a
push ebp
call fcn.130364f0
mov esi, eax
add esp, 8
test esi, esi
je 0x13058c83
push 0xa
lea edx, [esi + 1]
push 0
push edx
call fcn.130357b6
push eax
call fcn.13061820
movzx ebp, ax
push 0x2d
push esi
mov dword [esp + 0x34], ebp
call fcn.130364f0
xor esi, esi
add esp, 0x18
cmp eax, esi
je 0x13058da6
push 0xa
add eax, 1
push esi
push eax
call fcn.130357b6
push eax
call fcn.13061820
movzx eax, ax
add esp, 0x10
cmp bp, ax
mov dword [esp + 0x14], eax
jbe 0x13058c83
mov dword [esp + 0x14], esi
mov dword [esp + 0x1c], esi
cmp byte [ebx], 0
je 0x13058cc0
mov edx, dword [edi + 0x70]
mov eax, dword [edi + 0x3c]
push 0x401
lea ecx, [esp + 0x1b0]
push ecx
mov ecx, dword [eax + 4]
push ebx
push edx
push ecx
call fcn.130031d0
add esp, 0x14
sub eax, 0
je 0x13058db2
sub eax, 1
je 0x13058d15
sub eax, 1
je 0x13058df4
mov ecx, dword [edi + 0x130]
lea edx, [esp + 0x18]
push edx
lea eax, [esp + 0x30]
push eax
push ecx
mov dword [esp + 0x24], 0x80
call dword [sym.imp.WS2_32.dll_getsockname]
test eax, eax
je 0x13058db6
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push edi
call fcn.130385f0
mov edx, dword [esp + 0x18]
push eax
push str.getsockname___failed:__s
push edx
call fcn.13042ce0
add esp, 0x14
test ebx, ebx
je 0x13058d15
push ebx
call dword [0x13149114]
add esp, 4
pop esi
pop ebp
mov eax, 0x1e
pop ebx
mov ecx, dword [esp + 0x9a4]
xor ecx, esp
call fcn.130222cb
add esp, 0x9a8
ret
cmp al, 0x3a
jne 0x13058d3d
mov ebp, esi
jmp 0x13058c16
push 0x3a
push esi
call fcn.130364f0
mov ebp, eax
add esp, 8
test ebp, ebp
je 0x13058d8f
lea eax, [esp + 0x2c]
push eax
push esi
push 0x17
call fcn.130486b0
add esp, 0xc
cmp eax, 1
jne 0x13058d84
xor eax, eax
mov edx, ebx
mov dword [esp + 0x14], eax
mov dword [esp + 0x1c], eax
mov eax, esi
sub edx, esi
mov cl, byte [eax]
mov byte [edx + eax], cl
add eax, 1
test cl, cl
jne 0x13058d73
jmp 0x13058c83
mov ecx, ebp
sub ecx, esi
push ecx
push esi
jmp 0x13058c0d
mov edx, ebx
mov eax, esi
sub edx, esi
mov cl, byte [eax]
mov byte [edx + eax], cl
add eax, 1
test cl, cl
jne 0x13058d95
jmp 0x13058c83
movzx eax, bp
mov dword [esp + 0x14], eax
jmp 0x13058c83
mov esi, ebx
jmp 0x13058dfb
movzx eax, word [esp + 0x2c]
cmp eax, 0x17
push 0x401
je 0x13058dd5
lea ecx, [esp + 0x1b0]
push ecx
lea edx, [esp + 0x38]
push edx
push eax
jmp 0x13058de4
lea eax, [esp + 0x1b0]
push eax
lea ecx, [esp + 0x3c]
push ecx
push 0x17
call fcn.1304d2d0
add esp, 0x10
mov dword [esp + 0x28], 0
lea esi, [esp + 0x1ac]
lea edx, [esp + 0x24]
push edx
push 0
push esi
push edi
call fcn.13039fb0
add esp, 0x10
cmp eax, 1
jne 0x13058e1f
lea eax, [esp + 0x24]
push eax
push edi
call fcn.13039130
add esp, 8
mov eax, dword [esp + 0x24]
test eax, eax
je 0x13058e3b
mov ecx, dword [esp + 0x10]
mov ebp, dword [eax]
push eax
push ecx
call fcn.1303a1a0
add esp, 8
test ebp, ebp
jne 0x13058e53
mov edx, dword [esp + 0x10]
push esi
push str.failed_to_resolve_the_address_provided_to_PORT:__s
push edx
call fcn.13042ce0
add esp, 0xc
jmp 0x13058d07
test ebx, ebx
je 0x13058e61
push ebx
call dword [0x13149114]
add esp, 4
mov ebx, dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov dword [esp + 0xc], 0xffffffff
xor esi, esi
lea eax, [esp + 0xc]
push eax
push 0
push ebp
push edi
call fcn.130454f0
add esp, 0x10
test eax, eax
mov dword [esp + 0x20], eax
je 0x13058e97
call ebx
mov ebp, dword [ebp + 0x1c]
test ebp, ebp
mov esi, eax
jne 0x13058e71
jmp 0x13058e9b
test ebp, ebp
jne 0x13058eba
push esi
push edi
call fcn.130385f0
mov ecx, dword [esp + 0x18]
push eax
push str.socket_failure:__s
push ecx
call fcn.13042ce0
add esp, 0x14
jmp 0x13058d15
mov edx, dword [ebp + 0x10]
mov eax, dword [ebp + 0x18]
push edx
push eax
lea ecx, [esp + 0x34]
push ecx
call fcn.1301f5d0
mov eax, dword [esp + 0x28]
mov edx, dword [ebp + 0x10]
add esp, 0xc
cmp ax, word [esp + 0x14]
mov dword [esp + 0x18], edx
movzx esi, ax
ja 0x13058ff1
mov ebx, dword [esp + 0x28]
lea esp, [esp]
push esi
call dword [sym.imp.WS2_32.dll_htons]
mov edx, dword [esp + 0xc]
mov word [esp + 0x2e], ax
mov eax, dword [esp + 0x18]
push eax
lea ecx, [esp + 0x30]
push ecx
push edx
call dword [sym.imp.WS2_32.dll_bind]
test eax, eax
je 0x13058fea
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
test ebx, ebx
je 0x13058f74
cmp eax, 0x2741
jne 0x13058f74
push eax
push edi
call fcn.130385f0
push eax
movzx eax, si
mov esi, dword [esp + 0x1c]
push eax
push str.bind_port_hu__on_non_local_address_failed:__s_n
push esi
call fcn.13042c50
mov eax, dword [edi + 0x130]
add esp, 0x18
lea ecx, [esp + 0x18]
push ecx
lea edx, [esp + 0x30]
push edx
push eax
mov dword [esp + 0x24], 0x80
call dword [sym.imp.WS2_32.dll_getsockname]
test eax, eax
jne 0x13058f90
movzx esi, word [esp + 0x1c]
xor ebx, ebx
jmp 0x13058f83
cmp eax, 0x2740
je 0x13058f80
cmp eax, 0xd
jne 0x13058fbc
add esi, 1
cmp si, word [esp + 0x14]
jbe 0x13058ef0
jmp 0x13058ff1
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push edi
call fcn.130385f0
push eax
push str.getsockname___failed:__s
push esi
call fcn.13042ce0
mov ecx, dword [esp + 0x20]
push ecx
push edi
call fcn.130454a0
add esp, 0x1c
jmp 0x13058d15
push eax
push edi
call fcn.130385f0
push eax
mov eax, dword [esp + 0x1c]
movzx edx, si
push edx
push str.bind_port_hu__failed:__s
push eax
call fcn.13042ce0
mov ecx, dword [esp + 0x24]
push ecx
push edi
call fcn.130454a0
add esp, 0x20
jmp 0x13058d15
cmp si, word [esp + 0x14]
jbe 0x13059013
mov edx, dword [esp + 0x10]
push str.bind___failed__we_ran_out_of_ports_
push edx
call fcn.13042ce0
mov eax, dword [esp + 0x14]
push eax
push edi
call fcn.130454a0
add esp, 0x10
jmp 0x13058d15
mov eax, dword [esp + 0xc]
lea ecx, [esp + 0x18]
push ecx
lea edx, [esp + 0x30]
push edx
push eax
mov dword [esp + 0x24], 0x80
call dword [sym.imp.WS2_32.dll_getsockname]
test eax, eax
je 0x13059064
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push edi
call fcn.130385f0
push eax
push str.getsockname___failed:__s
mov ecx, dword [esp + 0x20]
push ecx
call fcn.13042ce0
mov edx, dword [esp + 0x20]
push edx
push edi
call fcn.130454a0
add esp, 0x1c
jmp 0x13058d15
mov eax, dword [esp + 0xc]
push 1
push eax
call dword [sym.imp.WS2_32.dll_listen]
test eax, eax
je 0x1305908a
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push edi
call fcn.130385f0
push eax
push str.socket_failure:__s
jmp 0x13059047
push pe_nt_image_headers32
lea eax, [esp + 0xb0]
push eax
push ebp
call fcn.13039d10
add esp, 0xc
cmp dword [edi + 0x204], 0
jne 0x130590bc
cmp dword [edi + 0x1dc], 0
je 0x130590bc
mov dword [edi + 0x204], 1
mov ebp, dword [esp + 0x9b8]
cmp ebp, 2
je 0x13059123
mov ebx, dword [sym.imp.WS2_32.dll_ntohs]
mov cx, word [esp + 0x2c]
cmp dword [edi + 0x204], 0
jne 0x130590e0
test ebp, ebp
je 0x1305911b
cmp ebp, 1
jne 0x130590eb
cmp cx, 2
jne 0x1305911b
movzx eax, cx
sub eax, 2
je 0x130590ff
sub eax, 0x15
jne 0x1305911b
mov ecx, dword [esp + 0x2e]
push ecx
jmp 0x13059104
mov edx, dword [esp + 0x2e]
push edx
call ebx
test ebp, ebp
movzx esi, ax
je 0x1305917c
cmp ebp, 1
je 0x130591ec
mov cx, word [esp + 0x2c]
add ebp, 1
cmp ebp, 2
jne 0x130590d3
mov ebx, dword [esp + 0x20]
mov dword [edi + 0x450], ebp
mov eax, dword [edi + 0x134]
cmp eax, 0xffffffff
je 0x13059142
push eax
push edi
call fcn.130454a0
add esp, 8
mov eax, dword [esp + 0xc]
mov dword [edi + 0x134], eax
mov dword [edi + 0x1e8], 1
mov eax, 0x1c
mov ecx, edi
call fcn.130589e0
mov ecx, dword [esp + 0x9b0]
pop esi
pop ebp
mov eax, ebx
pop ebx
xor ecx, esp
call fcn.130222cb
add esp, 0x9a8
ret
xor edx, edx
cmp word [esp + 0x2c], 2
movzx eax, si
setne dl
push eax
lea ecx, [esp + 0xb0]
push ecx
lea esi, [edi + 0x3e8]
add edx, 1
push edx
push str.EPRT
push str._s__d_s_hu
push esi
call fcn.13066d20
mov ebx, eax
add esp, 0x18
test ebx, ebx
je 0x13059127
push ebx
call sym.CliExt.dll_curl_easy_strerror
push eax
mov eax, dword [esp + 0x18]
push str.Failure_sending_EPRT_command:__s
push eax
call fcn.13042ce0
mov ecx, dword [esp + 0x1c]
push ecx
push edi
call fcn.130454a0
add esp, 0x18
mov dword [esi + 0x68], 1
xor eax, eax
jmp 0x1305915b
lea ecx, [esp + 0x5b0]
lea edx, [esp + 0xac]
lea ebx, [ebx]
mov al, byte [edx]
test al, al
je 0x13059219
cmp al, 0x2e
jne 0x1305920f
mov byte [ecx], 0x2c
jmp 0x13059211
mov byte [ecx], al
add ecx, 1
add edx, 1
jne 0x13059200
movzx eax, si
mov edx, eax
and edx, 0xff
push edx
shr eax, 8
push eax
push str.__d__d
push 0x14
push ecx
mov byte [ecx], 0
call sym.CliExt.dll_curl_msnprintf
lea eax, [esp + 0x5c4]
push eax
push str.PORT
lea eax, [edi + 0x3e8]
push 0x13104e50
push eax
call fcn.13066d20
mov ebx, eax
add esp, 0x24
test ebx, ebx
je 0x13059127
push ebx
call sym.CliExt.dll_curl_easy_strerror
mov ecx, dword [esp + 0x14]
push eax
push str.Failure_sending_PORT_command:__s
push ecx
call fcn.13042ce0
mov edx, dword [esp + 0x1c]
push edx
push edi
call fcn.130454a0
add esp, 0x18
xor eax, eax
jmp 0x1305915b