Function at 0x506200
Capabilities:
Resolve dns

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x516920
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x188
push ebx
push esi
push edi
mov dword [ebp - 0x10], esp
mov dword [ebp - 0x24], 7
xor edi, edi
mov dword [ebp - 0x28], edi
xor eax, eax
mov word [ebp - 0x38], ax
push edi
mov eax, 0x528928
lea esi, [ebp - 0x38]
call fcn.00412b10
mov dword [ebp - 4], edi
mov dword [ebp - 0x14], edi
mov ecx, dword [ebp + 0xc]
push ecx
lea edx, [ebp - 0x58]
push edx
call fcn.004ee810
add esp, 8
mov byte [ebp - 4], 1
cmp dword [ebp - 0x44], 0x10
mov ecx, dword [ebp - 0x58]
jae 0x50626a
lea ecx, [ebp - 0x58]
mov byte [ebp - 4], 2
xor eax, eax
mov dword [ebp - 0x78], eax
mov dword [ebp - 0x74], eax
mov dword [ebp - 0x70], eax
mov dword [ebp - 0x6c], eax
mov dword [ebp - 0x68], eax
mov dword [ebp - 0x64], eax
mov dword [ebp - 0x60], eax
mov dword [ebp - 0x5c], eax
mov dword [ebp - 0x74], edi
mov dword [ebp - 0x70], 1
mov dword [ebp - 0x78], 5
lea eax, [ebp - 0x1c]
push eax
lea edx, [ebp - 0x78]
push edx
push ecx
push edi
call dword [sym.imp.WS2_32.dll_getaddrinfo]
mov esi, eax
cmp esi, edi
je 0x50631d
push edi
push 0x400
push 0x1579cf0
push 0x400
push esi
push edi
push 0x12ff
call dword [sym.imp.KERNEL32.dll_FormatMessageW]
push 0x1579cf0
push esi
push str.getaddrinfo_failed_with_error__d:__s_n
call dword [sym.imp.MSVCR100.dll___iob_func]
add eax, 0x40
push eax
call dword [sym.imp.MSVCR100.dll_fprintf]
add esp, 0x10
mov byte [ebp - 4], 0
lea esi, [ebp - 0x58]
call fcn.004150e0
mov dword [ebp - 4], 0xffffffff
lea esi, [ebp - 0x38]
call fcn.004150b0
mov eax, 0x65
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8
xor ebx, ebx
mov dword [ebp - 0x3c], ebx
mov esi, dword [ebp - 0x1c]
mov dword [ebp - 0x18], esi
cmp esi, edi
je 0x5064d7
cmp ebx, 0x40
je 0x5064d7
mov eax, dword [esi + 4]
cmp eax, 2
je 0x50634a
cmp eax, 0x17
jne 0x5064c8
mov ecx, dword [esi + 0xc]
push ecx
mov edx, dword [esi + 8]
push edx
push eax
call dword [sym.imp.WS2_32.dll_socket]
mov edi, dword [ebp + 8]
mov dword [edi + ebx*4 + 0x58], eax
cmp eax, 0xffffffff
je 0x5064c8
cmp dword [esi + 4], 0x17
jne 0x50639b
mov eax, dword [esi + 0x18]
cmp word [eax], 0x17
lea edi, [eax + 8]
je 0x50637e
lea edi, [eax + 4]
cmp byte [edi], 0xfe
jne 0x506398
mov cl, byte [edi + 1]
and cl, 0xc0
cmp cl, 0x80
jne 0x506398
cmp dword [eax + 0x18], 0
je 0x5064c8
mov edi, dword [ebp + 8]
mov edx, dword [esi + 0x10]
push edx
mov eax, dword [esi + 0x18]
push eax
mov ecx, dword [edi + ebx*4 + 0x58]
push ecx
call dword [sym.imp.WS2_32.dll_bind]
cmp eax, 0xffffffff
jne 0x50642f
mov dword [ebp - 0x14], 0x65
mov edx, dword [ebp + 0xc]
push edx
lea eax, [ebp - 0xb4]
push eax
call fcn.004ef520
mov byte [ebp - 4], 3
push eax
lea ecx, [ebp - 0x98]
push ecx
mov edx, str.Server_bind_failed__port_:
call fcn.00413910
add esp, 0x10
mov byte [ebp - 4], 4
mov edi, eax
lea esi, [ebp - 0x38]
call fcn.00411aa0
mov byte [ebp - 4], 3
lea esi, [ebp - 0x98]
call fcn.004150b0
mov byte [ebp - 4], 2
lea esi, [ebp - 0xb4]
call fcn.004150b0
mov edx, dword [ebp + 8]
mov eax, dword [edx + ebx*4 + 0x58]
push eax
call dword [sym.imp.WS2_32.dll_closesocket]
mov esi, dword [ebp - 0x18]
mov edx, dword [esi + 0x1c]
mov dword [ebp - 0x18], edx
mov esi, edx
xor edi, edi
jmp 0x506328
mov eax, 0xa
push eax
mov ecx, dword [edi + ebx*4 + 0x58]
push ecx
call dword [sym.imp.WS2_32.dll_listen]
cmp eax, 0xffffffff
jne 0x5064a1
mov dword [ebp - 0x14], 0x65
mov edx, dword [ebp + 0xc]
push edx
lea eax, [ebp - 0xd0]
push eax
call fcn.004ef520
mov byte [ebp - 4], 5
push eax
lea ecx, [ebp - 0xec]
push ecx
mov edx, str.Server_bind_failed__port_:
call fcn.00413910
add esp, 0x10
mov byte [ebp - 4], 6
mov edi, eax
lea esi, [ebp - 0x38]
call fcn.00411aa0
mov byte [ebp - 4], 5
lea esi, [ebp - 0xec]
call fcn.004150b0
mov byte [ebp - 4], 2
lea esi, [ebp - 0xd0]
jmp 0x50640a
cmp dword [ebp - 0x14], 0
je 0x5064c4
push 0
push 0x20000000
lea ecx, [ebp - 0x38]
push ecx
push 0x81
push str.ubserver::init
call fcn.0044d970
add esp, 0x14
inc ebx
mov dword [ebp - 0x3c], ebx
mov edx, dword [esi + 0x1c]
mov dword [ebp - 0x18], edx
mov esi, edx
xor edi, edi
jmp 0x506328
mov eax, dword [ebp + 8]
mov dword [eax + 0x158], ebx
mov ecx, dword [ebp - 0x1c]
push ecx
call dword [sym.imp.WS2_32.dll_freeaddrinfo]
cmp ebx, edi
jne 0x506565
mov edx, dword [ebp + 0xc]
push edx
lea eax, [ebp - 0xb4]
push eax
call fcn.004ef520
mov byte [ebp - 4], 7
push eax
lea ecx, [ebp - 0x98]
push ecx
mov edx, str.Fatal_error:_unable_to_serve_on_any_address__port_:
call fcn.00413910
add esp, 0x10
mov byte [ebp - 4], 8
mov edi, eax
lea esi, [ebp - 0x38]
call fcn.00411aa0
mov byte [ebp - 4], 7
lea esi, [ebp - 0x98]
call fcn.004150b0
mov byte [ebp - 4], 2
lea esi, [ebp - 0xb4]
call fcn.004150b0
push 0
push 0x20000000
lea edx, [ebp - 0x38]
push edx
push 0x8c
push str.ubserver::init
call fcn.0044d970
add esp, 0x14
jmp 0x5062ea
mov dword [ebp - 4], 1
mov byte [ebp - 4], 0
cmp dword [ebp - 0x44], 0x10
jb 0x506583
mov eax, dword [ebp - 0x58]
push eax
call dword [sym.imp.MSVCR100.dll_void___cdecl_operator_delete_void__]
add esp, 4
mov dword [ebp - 0x44], 0xf
xor esi, esi
mov dword [ebp - 0x48], esi
mov byte [ebp - 0x58], 0
mov dword [ebp - 4], 0xffffffff
cmp dword [ebp - 0x24], 8
jb 0x5065ad
mov ecx, dword [ebp - 0x38]
push ecx
call dword [sym.imp.MSVCR100.dll_void___cdecl_operator_delete_void__]
add esp, 4
mov dword [ebp - 0x24], 7
mov dword [ebp - 0x28], esi
xor edx, edx
mov word [ebp - 0x38], dx
mov eax, dword [ebp - 0x14]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8