Function at 0x4074a0
Capabilities:
Get hostname
Resolve dns

Disassembly:
sub esp, 0x230
mov eax, dword [ecx + 0x8058]
test eax, eax
push esi
push edi
mov dword [esp + 8], ecx
jne 0x4074da
mov edi, dword [esp + 0x244]
mov ecx, 6
mov esi, str.501_GSSAPI_not_initialized
rep movsd dword es:[edi], dword [esi]
movsw word es:[edi], word [esi]
movsb byte es:[edi], byte [esi]
pop edi
or eax, 0xffffffff
pop esi
add esp, 0x230
ret 0xc
mov edx, dword [esp + 0x240]
push ebx
push ebp
lea ebp, [ecx + 0x40]
mov eax, edx
mov dword [esp + 0x18], ebp
mov ebx, ebp
lea esi, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x4074f1
sub eax, esi
add eax, 0x3e8
cmp eax, 0x8000
jb 0x407530
mov eax, edx
lea edx, [eax + 1]
jmp 0x407510
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x407510
sub eax, edx
add eax, 0x3e8
push eax
call fcn.00449a29
mov edx, dword [esp + 0x24c]
add esp, 4
mov ebx, eax
mov esi, dword [esp + 0x244]
mov edi, 0x4626a0
mov ecx, 5
xor eax, eax
repe cmpsb byte [esi], byte es:[edi]
jne 0x4076e3
mov ecx, dword [esp + 0x10]
mov edx, dword [ecx]
lea eax, [esp + 0x14]
push eax
lea eax, [esp + 0x30]
mov esi, 0x10
push eax
mov dword [esp + 0x1c], esi
call dword [edx + 0x2c]
test eax, eax
jne 0x40759d
cmp ebx, ebp
je 0x407578
push ebx
call fcn.0044c004
add esp, 4
mov ecx, dword [esp + 0x24c]
push str.501_unable_to_getpeername
push ecx
call fcn.0044c02b
add esp, 8
pop ebp
pop ebx
pop edi
or eax, 0xffffffff
pop esi
add esp, 0x230
ret 0xc
lea eax, [esp + 0x14]
mov dword [esp + 0x14], esi
mov esi, dword [esp + 0x10]
mov edx, dword [esi]
push eax
lea ecx, [esp + 0x20]
push ecx
mov ecx, esi
call dword [edx + 0x30]
test eax, eax
jne 0x4075ec
cmp ebx, ebp
je 0x4075c7
push ebx
call fcn.0044c004
add esp, 4
mov edx, dword [esp + 0x24c]
push str.501_unable_to_getsockname
push edx
call fcn.0044c02b
add esp, 8
pop ebp
pop ebx
pop edi
or eax, 0xffffffff
pop esi
add esp, 0x230
ret 0xc
push 0x200
lea eax, [esp + 0x40]
push eax
call sub.WS2_32.dll_gethostname
test eax, eax
je 0x407639
cmp ebx, ebp
je 0x40760c
push ebx
call fcn.0044c004
add esp, 4
call fcn.0044c2c4
mov ecx, dword [eax]
mov edx, dword [esp + 0x24c]
push ecx
push str.501_couldnt_get_local_hostname___d_
push edx
call fcn.0044c02b
add esp, 0xc
pop ebp
pop ebx
pop edi
or eax, 0xffffffff
pop esi
add esp, 0x230
ret 0xc
lea eax, [esp + 0x3c]
push eax
call sub.WS2_32.dll_gethostbyname
test eax, eax
jne 0x407679
cmp ebx, ebp
je 0x407654
push ebx
call fcn.0044c004
add esp, 4
mov ecx, dword [esp + 0x24c]
push str.501_couldnt_canonicalize_local_hostname
push ecx
call fcn.0044c02b
add esp, 8
pop ebp
pop ebx
pop edi
or eax, 0xffffffff
pop esi
add esp, 0x230
ret 0xc
mov edx, dword [eax]
push 0x200
push edx
lea eax, [esp + 0x44]
push eax
call fcn.0044c1a0
mov ecx, dword [esp + 0x3c]
mov edx, dword [esp + 0x2c]
mov dword [ebx + 4], edx
lea eax, [esp + 0x48]
mov dword [ebx], ecx
lea edx, [ebx + 8]
mov ecx, eax
add esp, 0xc
mov byte [esp + 0x23c], 0
sub edx, ecx
mov edi, edi
mov cl, byte [eax]
mov byte [edx + eax], cl
inc eax
test cl, cl
jne 0x4076b0
lea eax, [esp + 0x3c]
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x4076c1
mov ecx, dword [esp + 0x248]
sub eax, edx
lea edx, [eax + ebx + 9]
sub edx, ecx
mov al, byte [ecx]
mov byte [edx + ecx], al
inc ecx
test al, al
jne 0x4076d7
jmp 0x4076fe
mov ecx, dword [esp + 0x248]
mov eax, edx
mov edx, ebx
sub edx, ecx
mov cl, byte [eax]
mov byte [edx + eax], cl
inc eax
test cl, cl
jne 0x4076f0
mov esi, dword [esp + 0x10]
mov edx, dword [esp + 0x24c]
mov eax, dword [esp + 0x244]
mov ecx, dword [esi + 0x8054]
push edx
push ebx
push eax
push ecx
call dword [esi + 0x8060]
mov esi, dword [esp + 0x254]
add esp, 0x10
mov edi, 0x4626a0
mov ecx, 5
xor edx, edx
repe cmpsb byte [esi], byte es:[edi]
mov ebp, eax
jne 0x407755
cmp ebp, 0xffffffff
je 0x407755
mov eax, dword [esp + 0x10]
mov dword [eax + 0x8044], 3
mov dword [eax + 0x805c], 1
cmp ebx, dword [esp + 0x18]
je 0x407764
push ebx
call fcn.0044c004
add esp, 4
mov eax, ebp
pop ebp
pop ebx
pop edi
pop esi
add esp, 0x230
ret 0xc