Function at 0x49d578
Capabilities:
Get hostname
Resolve dns

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
sub esp, 0xb0
mov edi, dword [ebp + 8]
cmp edi, 0x5048c1
je 0x49d82d
mov eax, edi
and eax, 3
dec eax
je 0x49d5f0
mov eax, edi
and eax, 0x3f
cmp eax, 7
je 0x49d760
mov eax, edi
and eax, 3
dec eax
je 0x49d723
mov eax, edi
and eax, 3
dec eax
je 0x49d7b0
mov eax, edi
and eax, 0x37
cmp eax, 7
je 0x49d7e0
mov eax, edi
and eax, 3
dec eax
jne 0x49d5e2
mov edx, dword [edi + 3]
cmp dl, 0x1a
je 0x49d87b
mov dword [esp], edi
call fcn.0043aa90
lea esi, [esi]
movzx edx, byte [edi + 3]
mov al, dl
sub al, 0x11
cmp al, 7
setbe cl
cmp dl, 0x20
sete al
or eax, ecx
test al, 1
je 0x49d59a
lea eax, [ebp - 0x6c]
mov edx, edi
mov dword [esp + 8], eax
lea eax, [ebp - 0x70]
mov dword [esp + 4], eax
movzx eax, byte [edi + 3]
sub al, 0x11
cmp al, 7
jbe 0x49d626
mov edx, dword [edi + 0x17]
mov dword [esp], edx
call fcn.0044c2b8
cmp eax, 0x4fa001
mov esi, eax
je 0x49d99c
movsx eax, byte [eax + 3]
lea edx, [eax - 0x11]
sar edx, 1
cmp edx, 2
je 0x49d987
mov ecx, dword [ebp - 0x70]
lea eax, [ecx*4 + 0x1e]
and eax, 0xfffffff0
call fcn.004ea990
lea edi, [esp + 0x27]
and edi, 0xfffffff0
test ecx, ecx
jne 0x49d8b2
mov dword [ebp - 0x8c], edi
mov dword [ebp - 0x90], esp
mov esi, dword [ebp - 0x8c]
mov edx, dword [0x4f99dc]
mov dword [esp + 4], esi
lea eax, [esi + ecx*4]
mov dword [esp + 8], eax
mov eax, dword [0x4f99dc]
mov dword [esp], eax
call dword [edx + 0x1f]
lea edx, [eax + 0x1f]
mov ecx, eax
and edx, 0xfffffff0
mov eax, edx
call fcn.004ea990
mov dword [ebp - 0x78], esi
mov eax, dword [ebp - 0x8c]
lea edi, [esp + 0x27]
mov esi, dword [ebp - 0x70]
and edi, 0xfffffff0
lea ecx, [edi + ecx]
mov dword [ebp - 0x94], ecx
mov edx, dword [0x4f99dc]
lea esi, [eax + esi*4]
mov dword [ebp - 0x74], edi
lea eax, [ebp - 0x74]
mov dword [esp + 0x14], ecx
xor ecx, ecx
mov dword [esp + 0x10], eax
lea eax, [ebp - 0x78]
mov dword [esp + 0xc], esi
mov dword [esp + 8], eax
mov dword [esp + 4], ecx
mov eax, dword [0x4f99dc]
mov dword [esp], eax
call dword [edx + 0x23]
cmp dword [ebp - 0x78], esi
jne 0x49d70e
mov eax, dword [ebp - 0x74]
cmp eax, dword [ebp - 0x94]
je 0x49d9fd
mov dword [esp], str.c:_usr_work_edrive_w32texsrc_clisp249_clisp_2.49_src_socket.d
mov edx, 0x193
mov dword [esp + 4], edx
call fcn.00420a64
mov edx, dword [edi + 3]
cmp dl, 0x1a
jne 0x49d5b4
mov eax, edx
shr eax, 8
test al, al
js 0x49d5b4
mov eax, edx
shr eax, 0x10
cmp eax, 2
ja 0x49d5b4
cmp eax, 1
jbe 0x49d760
mov eax, dword [edi + 7]
test eax, eax
jne 0x49d5b4
lea esi, [esi]
mov dword [esp], edi
mov eax, 0x20
lea esi, [ebp - 0x80]
mov dword [esp + 8], esi
mov dword [esp + 4], eax
call fcn.004595d0
mov dword [0x698fa0], ebx
mov eax, 2
mov dword [esp + 8], eax
mov eax, 4
mov dword [esp + 4], eax
mov dword [esp], esi
call sub.WS2_32.DLL_gethostbyaddr
sub esp, 0xc
mov dword [ebp - 0x7c], eax
xor esi, esi
mov dword [0x698fa0], esi
lea esp, [ebp - 8]
pop esi
pop edi
pop ebp
ret
movzx eax, byte [edi + 3]
dec al
cmp al, 0x17
ja 0x49d5c0
mov dword [esp], edi
call fcn.0042a170
mov dword [esp], edi
mov esi, eax
call fcn.0042ae30
cmp eax, 5
ja case.default.0x49d7d9
jmp dword [eax*4 + 0x56917c]
test edi, 2
je 0x49d86c
test edi, 8
jne 0x49d5ce
mov dword [esp], edi
mov eax, pe_nt_image_headers32
lea esi, [ebp - 0x68]
mov dword [esp + 8], esi
mov edi, 0x10
mov dword [esp + 4], eax
call fcn.004595d0
mov dword [0x698fa0], ebx
mov eax, 0x17
mov dword [esp + 8], eax
mov dword [esp + 4], edi
jmp 0x49d790
mov dword [0x698fa0], ebx
mov eax, 0x40
lea esi, [ebp - 0x58]
mov dword [esp + 4], eax
mov dword [esp], esi
call sub.WS2_32.DLL_gethostname
sub esp, 8
test eax, eax
js 0x49da8d
mov byte [ebp - 0x18], 0
mov dword [0x698fa0], ebx
mov dword [esp], esi
call sub.WS2_32.DLL_gethostbyname
sub esp, 4
jmp 0x49d79b
mov eax, dword [edi + 3]
shr eax, 8
test al, al
jns 0x49d7f8
jmp 0x49d5ce
test edi, 2
jne 0x49d8a4
mov eax, edx
shr eax, 8
test al, al
js 0x49d5e2
shr edx, 0x10
shl edx, 5
cmp edx, 0x10
ja 0x49d5e2
jmp 0x49d7f8
test edi, 8
jne 0x49d5e2
jmp 0x49d890
cmp edx, 1
je 0x49da2d
test edx, edx
jne 0x49d70e
mov dword [esp + 8], ecx
mov dword [esp + 4], edi
mov eax, dword [ebp - 0x6c]
add esi, eax
lea eax, [esi + 7]
mov dword [esp], eax
call fcn.0044c124
mov ecx, dword [ebp - 0x70]
jmp 0x49d66e
mov eax, esi
shr eax, 1
test esi, 1
jne case.default.0x49d7d9
cmp eax, 4
je 0x49d9b4
cmp eax, 0x10
je 0x49da4c
mov dword [ebx], edi
lea eax, [ebx + 4]
mov edx, dword [0x4f9d28]
mov dword [eax + 4], 0x807
lea ebx, [eax + 4]
lea ebx, [eax + 8]
mov dword [eax], edx
mov edx, dword [0x6971f4]
lea ebx, [eax + 0xc]
mov dword [eax + 8], 0x207
lea ebx, [eax + 0x10]
lea ebx, [eax + 0x14]
mov dword [eax + 0xc], edi
mov edx, dword [edx + 4]
mov edx, dword [edx + 6]
mov dword [eax + 0x10], edx
mov eax, str.S:_IP_address_S_must_have_length_S_or_S
mov dword [esp + 4], eax
mov dword [esp], 0xe
call fcn.004357dc
mov eax, esi
shr eax, 3
test esi, 7
jmp 0x49d8ed
mov eax, esi
shr eax, 2
test esi, 3
jmp 0x49d8ed
lea eax, [esi*4]
jmp 0x49d8ef
lea eax, [esi + esi]
jmp 0x49d8ef
mov eax, esi
jmp 0x49d8ef
mov eax, dword [ebp - 0x6c]
mov ecx, dword [ebp - 0x70]
lea eax, [esi + eax*4 + 7]
mov dword [ebp - 0x8c], eax
jmp 0x49d674
mov ecx, dword [ebp - 0x70]
xor eax, eax
mov dword [ebp - 0x8c], eax
test ecx, ecx
je 0x49d674
call fcn.0042a998
xor eax, eax
mov dword [ebp - 0x84], eax
lea eax, [ebp - 0x84]
mov dword [esp + 4], esi
mov esi, 2
mov dword [esp + 8], eax
mov dword [esp], edi
call fcn.0042a554
mov dword [0x698fa0], ebx
mov ecx, 4
mov dword [esp + 8], esi
mov dword [esp + 4], ecx
mov edx, dword [ebp - 0x84]
add eax, edx
add eax, 7
mov dword [esp], eax
jmp 0x49d793
mov byte [eax], 0
lea eax, [ebp - 0x7c]
mov edx, 0x49d530
mov dword [0x698fa0], ebx
mov dword [esp], eax
mov eax, edi
call fcn.0049d44c
xor eax, eax
mov dword [0x698fa0], eax
mov esp, dword [ebp - 0x90]
mov eax, dword [ebp - 0x7c]
jmp 0x49d7a6
mov dword [esp + 8], ecx
mov dword [esp + 4], edi
mov eax, dword [ebp - 0x6c]
lea eax, [esi + eax*2 + 7]
mov dword [esp], eax
call fcn.0044c194
mov ecx, dword [ebp - 0x70]
jmp 0x49d66e
xor eax, eax
mov dword [ebp - 0x88], eax
lea eax, [ebp - 0x88]
mov dword [esp + 4], esi
mov esi, 0x17
mov dword [esp + 8], eax
mov dword [esp], edi
call fcn.0042a554
mov dword [0x698fa0], ebx
mov ecx, 0x10
mov dword [esp + 8], esi
mov dword [esp + 4], ecx
mov edx, dword [ebp - 0x88]
jmp 0x49d9f0
call fcn.00439708
nop