Function at 0x5df0809b
Capabilities:
Get local ipv4 addresses
Get socket information
Set socket configuration

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x3c
mov eax, dword [0x5df0b004]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0xc]
mov ecx, dword [ebp + 0x1c]
or dword [eax], 0xffffffff
push ebx
push esi
mov esi, dword [ebp + 8]
mov dword [ebp - 0x34], ecx
xor edx, edx
xor ecx, ecx
mov dword [ebp - 0x3c], eax
mov eax, dword [esi + 0x38]
inc ecx
push edi
mov dword [ebp - 0x18], edx
mov dword [ebp - 0x38], ecx
mov dword [ebp - 0x30], edx
mov dword [ebp - 0x20], ecx
mov dword [ebp - 0x2c], edx
cmp eax, 6
jne 0x5df080f5
mov ecx, dword [ebp + 0x10]
dec ecx
neg ecx
sbb ecx, ecx
and ecx, 0xfffffeff
add ecx, 0x4e9
mov dword [ebp - 0x30], ecx
push dword [ebp - 0x30]
push dword [ebp + 0x10]
push eax
call sub.WS2_32.dll_socket
mov ebx, eax
mov dword [ebp - 0x1c], ebx
cmp ebx, 0xffffffff
je 0x5df083ad
jmp 0x5df08114
mov ebx, dword [ebp - 0x1c]
xor eax, eax
lea edi, [ebp - 0x14]
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
mov eax, dword [esi + 0x38]
dec eax
dec eax
je 0x5df0814a
sub eax, 4
jne 0x5df082cf
mov ax, word [esi + 0x38]
mov word [ebp - 0x14], ax
mov ax, word [ebp + 0x14]
mov word [ebp - 8], ax
xor eax, eax
lea edi, [ebp - 0xe]
stosd dword es:[edi], eax
stosw word es:[edi], ax
jmp 0x5df082cf
cmp dword [ebp + 0x10], 1
jne 0x5df081ab
push 4
lea eax, [ebp - 0x38]
push eax
push 8
push 0xffff
push ebx
call sub.WS2_32.dll_setsockopt
cmp eax, 0xffffffff
jne 0x5df0816d
call sub.WS2_32.dll_WSAGetLastError
test dword [esi + 0xec], 0x8000
je 0x5df08193
push 4
lea eax, [ebp - 0x38]
push eax
push 1
push 6
push ebx
call sub.WS2_32.dll_setsockopt
cmp eax, 0xffffffff
jne 0x5df08193
call sub.WS2_32.dll_WSAGetLastError
cmp word [ebp - 0x18], 0
jne 0x5df081a5
push dword [ebp - 0x20]
push ebx
call fcn.5df04bc1
jmp 0x5df081ab
push ebx
call fcn.5df04c2e
push 2
pop eax
mov word [ebp - 0x14], ax
mov eax, dword [ebp + 0x18]
xor edi, edi
mov dword [ebp - 0x10], eax
cmp word [ebp - 0x18], di
jne 0x5df081c5
push dword [ebp + 0x14]
jmp 0x5df081c8
push dword [ebp - 0x18]
call sub.WS2_32.dll_htons
mov word [ebp - 0x12], ax
cmp dword [ebp + 0x20], edi
je 0x5df082cf
cmp word [ebp + 0x14], di
jne 0x5df082cf
cmp word [ebp - 0x18], di
jne 0x5df082cf
cmp dword [ebp + 0x10], 1
mov dword [ebp - 0x24], 0x8fc
je 0x5df08202
mov dword [ebp - 0x24], 0x92e
push esi
call fcn.5df03950
test eax, eax
je 0x5df08210
add dword [ebp - 0x24], 0x19
movzx edi, word [ebp - 0x24]
jmp 0x5df08219
mov ebx, dword [ebp - 0x1c]
xor eax, eax
cmp dword [esi + 0x168], eax
je 0x5df08264
xor ecx, ecx
inc ecx
cmp dword [ebp + 0x10], ecx
jne 0x5df08238
cmp dword [esi + 0x184], eax
jne 0x5df08264
mov dword [ebp - 0x28], ecx
jmp 0x5df08243
cmp dword [esi + 0x180], eax
jne 0x5df08264
mov dword [ebp - 0x28], eax
push edi
push dword [ebp - 0x28]
push esi
call fcn.5df13f9e
cmp eax, 0x8015f090
jne 0x5df08259
or ebx, 0xffffffff
jmp 0x5df0828a
test eax, eax
jne 0x5df08264
mov dword [ebp - 0x2c], 1
push edi
call sub.WS2_32.dll_htons
mov word [ebp - 0x12], ax
push 0x10
lea eax, [ebp - 0x14]
push eax
push ebx
call sub.WS2_32.dll_bind
cmp eax, 0xffffffff
jne 0x5df0833e
call sub.WS2_32.dll_WSAGetLastError
mov ebx, eax
cmp dword [ebp - 0x2c], 0
je 0x5df0829d
push dword [ebp - 0x28]
push esi
call fcn.5df038e6
and dword [ebp - 0x2c], 0
inc edi
mov eax, 0x960
cmp di, ax
jbe 0x5df082ab
lea edi, [eax - 0x64]
cmp di, word [ebp - 0x24]
jne 0x5df08216
cmp ebx, 0x271d
jne 0x5df082cc
cmp dword [ebp - 0x20], 0
je 0x5df082cc
and dword [ebp - 0x20], 0
jmp 0x5df08393
mov ebx, dword [ebp - 0x1c]
push 0x10
lea eax, [ebp - 0x14]
push eax
push ebx
call sub.WS2_32.dll_bind
cmp eax, 0xffffffff
jne 0x5df08333
call sub.WS2_32.dll_WSAGetLastError
cmp eax, 0x271d
jne 0x5df082fa
cmp dword [ebp - 0x20], 0
je 0x5df082fa
push ebx
call sub.WS2_32.dll_closesocket
jmp 0x5df082c3
cmp word [ebp - 0x18], 0
je 0x5df083be
push 0x32
pop edi
add edi, edi
cmp edi, 0x3e8
jae 0x5df083be
call sub.WS2_32.dll_WSAGetLastError
push edi
call dword [sym.imp.KERNEL32.dll_Sleep]
push 0x10
lea eax, [ebp - 0x14]
push eax
push ebx
call sub.WS2_32.dll_bind
cmp eax, 0xffffffff
je 0x5df08308
cmp word [ebp - 0x18], 0
jne 0x5df083df
cmp dword [esi + 0x38], 2
jne 0x5df083df
cmp dword [ebp + 0x10], 1
jne 0x5df083df
push dword [ebp - 0x12]
call sub.WS2_32.dll_ntohs
movzx eax, ax
mov dword [ebp - 0x18], eax
test ax, ax
jne 0x5df0838d
lea eax, [ebp - 0x1c]
push eax
lea eax, [ebp - 0x14]
push eax
push ebx
mov dword [ebp - 0x1c], 0x10
call sub.WS2_32.dll_getsockname
cmp eax, 0xffffffff
je 0x5df083be
push dword [ebp - 0x12]
call sub.WS2_32.dll_ntohs
movzx eax, ax
mov dword [ebp - 0x18], eax
push ebx
call sub.WS2_32.dll_closesocket
push dword [ebp - 0x30]
push dword [ebp + 0x10]
push dword [esi + 0x38]
call sub.WS2_32.dll_socket
mov dword [ebp - 0x1c], eax
cmp eax, 0xffffffff
jne 0x5df08111
call sub.WS2_32.dll_WSAGetLastError
mov ecx, dword [ebp - 0x34]
mov dword [ecx], eax
mov eax, 0x80004005
jmp 0x5df083e6
call sub.WS2_32.dll_WSAGetLastError
mov ecx, dword [ebp - 0x34]
push ebx
mov dword [ecx], eax
call sub.WS2_32.dll_closesocket
cmp dword [ebp - 0x2c], 0
je 0x5df083b7
push dword [ebp - 0x28]
push esi
call fcn.5df038e6
jmp 0x5df083b7
mov eax, dword [ebp - 0x3c]
mov dword [eax], ebx
xor eax, eax
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.5df099e0
leave
ret 0x1c