Function at 0x475830
Capabilities:
Get hostname
Resolve dns

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff0
sub esp, 0x288
mov eax, dword [0x5b0008]
xor eax, esp
mov dword [esp + 0x284], eax
cmp byte [0x5b31ae], 0
push esi
push edi
mov edi, dword [ebp + 8]
je 0x47588e
mov eax, dword [0x5b35e8]
cmp eax, 0xc
jge 0x47588e
push 0x5bb6f8
inc eax
push 0x64
push edi
mov dword [0x5b35e8], eax
call fcn.0051f3ce
add esp, 0xc
pop edi
pop esi
mov ecx, dword [esp + 0x284]
xor ecx, esp
call fcn.00519459
mov esp, ebp
pop ebp
ret 8
push 0x100
lea eax, [esp + 0x18c]
mov dword [0x5b35e8], 0
push eax
call dword [sym.imp.WS2_32.dll_gethostname]
test eax, eax
je 0x4758d7
push 0x64
push str.Host_name_unavailable
push 0x64
push edi
call fcn.0052c878
add esp, 0x10
pop edi
pop esi
mov ecx, dword [esp + 0x284]
xor ecx, esp
call fcn.00519459
mov esp, ebp
pop ebp
ret 8
lea eax, [esp + 0x14]
mov byte [edi], 0
push eax
lea eax, [esp + 0x24]
mov dword [esp + 0x18], 0
push eax
xorps xmm0, xmm0
mov dword [esp + 0x28], 0
push 0
lea eax, [esp + 0x194]
movlpd qword [esp + 0x3c], xmm0
push eax
movlpd qword [esp + 0x48], xmm0
mov dword [esp + 0x34], 0
mov dword [esp + 0x38], 1
mov dword [esp + 0x3c], 6
call dword [sym.imp.WS2_32.dll_getaddrinfo]
test eax, eax
jne 0x475ad1
mov eax, dword [0x5be08c]
cmp dword [eax + 0xe64], 0
jne 0x4759e9
mov esi, dword [esp + 0x14]
test esi, esi
je 0x4759dc
mov eax, dword [esi + 4]
sub eax, 2
jne 0x4759cc
mov eax, dword [esi + 0x18]
movups xmm0, xmmword [eax]
movups xmmword [esp + 0x40], xmm0
push dword [esp + 0x44]
call dword [sym.imp.WS2_32.dll_inet_ntoa]
push eax
lea eax, [esp + 0x8c]
push 0x59d2f0
push eax
call fcn.004232c0
mov eax, edi
add esp, 0xc
lea edx, [eax + 1]
nop dword [eax]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x475990
sub eax, edx
lea edx, [esp + 0x88]
lea ecx, [edx + 1]
mov dword [esp + 0x18], ecx
mov cl, byte [edx]
inc edx
test cl, cl
jne 0x4759a7
sub edx, dword [esp + 0x18]
add eax, edx
cmp eax, 0x64
jge 0x4759cc
lea eax, [esp + 0x88]
push eax
push 0x64
push edi
call fcn.0051f428
add esp, 0xc
mov esi, dword [esi + 0x1c]
test esi, esi
jne 0x475951
mov eax, dword [0x5be08c]
cmp dword [eax + 0xe64], 0
je 0x475ad1
mov esi, dword [esp + 0x14]
test esi, esi
je 0x475ad1
cmp dword [esi + 4], 0x17
jne 0x475ac6
push 0x2e
lea eax, [esp + 0x5c]
mov dword [esp + 0x1c], 0x2e
push 0
push eax
call fcn.0051b450
add esp, 0xc
lea eax, [esp + 0x18]
push eax
lea eax, [esp + 0x5c]
push eax
push 0
push dword [esi + 0x10]
push dword [esi + 0x18]
call dword [sym.imp.WS2_32.dll_WSAAddressToStringA]
push 0x100
lea eax, [esp + 0x8c]
push 0
push eax
call fcn.0051b450
mov eax, dword [esp + 0x24]
add esp, 0xc
add eax, 0xfffffffc
push eax
lea eax, [esp + 0x5c]
push eax
lea eax, [esp + 0x90]
push 0x100
push eax
call fcn.0052c878
push 0x59d2f4
lea eax, [esp + 0x9c]
push 0x100
push eax
call fcn.0051f428
mov edx, edi
add esp, 0x1c
lea ecx, [edx + 1]
mov al, byte [edx]
inc edx
test al, al
jne 0x475a85
sub edx, ecx
lea ecx, [esp + 0x88]
lea eax, [ecx + 1]
mov dword [esp + 0x1c], eax
nop dword [eax]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x475aa0
sub ecx, dword [esp + 0x1c]
lea eax, [ecx + edx]
cmp eax, 0x64
jge 0x475ac6
lea eax, [esp + 0x88]
push eax
push 0x64
push edi
call fcn.0051f428
add esp, 0xc
mov esi, dword [esi + 0x1c]
test esi, esi
jne 0x4759f5
push dword [esp + 0x14]
call dword [sym.imp.WS2_32.dll_freeaddrinfo]
mov ecx, dword [esp + 0x28c]
pop edi
pop esi
xor ecx, esp
call fcn.00519459
mov esp, ebp
pop ebp
ret 8