Function at 0x406630
Capabilities:
Resolve dns

Disassembly:
sub esp, 0x820
push ebx
push ebp
push esi
push edi
xor edi, edi
mov dword [esp + 0x20], edx
push 0x401
lea eax, [esp + 0x2c]
mov dword [esp + 0x14], edi
mov ebx, ecx
push edi
push eax
mov dword [esp + 0x30], ebx
call fcn.004c22a0
push 0x401
lea eax, [esp + 0x43c]
push edi
push eax
call fcn.004c22a0
push 0x400
push ebx
lea eax, [esp + 0x48]
push 0x401
lea ebp, [esp + 0x450]
mov dword [esp + 0x40], eax
push eax
mov dword [esp + 0x40], ebp
call fcn.004ca903
add esp, 0x28
mov ecx, dword [esp + 0x840]
push ebx
mov dword [esp + 0x18], ecx
mov byte [ebp], 0
mov dword [ecx], 0
call dword [sym.imp.WSOCK32.dll_gethostbyname]
mov ebx, eax
test ebx, ebx
je 0x40687f
cmp word [ebx + 8], 2
jne 0x406763
cmp word [ebx + 0xa], 4
jne 0x406763
mov edi, dword [ebx + 0xc]
mov eax, dword [edi]
test eax, eax
je 0x40675f
nop dword [eax]
mov ebp, dword [eax]
push 0x20
push 1
call fcn.004ca7e7
mov esi, eax
add esp, 8
test esi, esi
je 0x406800
push 0x10
push 1
call fcn.004ca7e7
add esp, 8
test eax, eax
je 0x4067f7
mov dword [eax + 4], ebp
mov ecx, 2
mov word [eax], cx
add edi, 4
mov cx, word [esp + 0x838]
mov word [eax + 2], cx
mov ecx, dword [esp + 0x20]
mov dword [esi + 0x18], eax
mov eax, dword [esp + 0x14]
mov dword [esi + 8], ecx
mov ecx, dword [esp + 0x834]
mov dword [esi + 4], 2
mov dword [esi + 0xc], ecx
mov dword [esi + 0x10], 0x10
mov dword [eax], esi
lea eax, [esi + 0x1c]
mov dword [esp + 0x14], eax
mov eax, dword [edi]
test eax, eax
jne 0x4066e0
mov ebp, dword [esp + 0x18]
mov edi, dword [esp + 0x10]
push 0x400
push dword [ebx]
push 0x401
push ebp
call fcn.004ca903
mov eax, dword [esp + 0x850]
xor esi, esi
add esp, 0x10
cmp dword [eax], esi
jne 0x40681e
mov ecx, ebp
lea edx, [ecx + 1]
nop
mov al, byte [ecx]
inc ecx
test al, al
jne 0x406790
sub ecx, edx
je case.0x40688f.11003
mov ebx, dword [esp + 0x1c]
mov eax, ebp
mov ecx, ebx
mov dl, byte [ecx]
cmp dl, byte [eax]
jne 0x4067c7
test dl, dl
je 0x4067c3
mov dl, byte [ecx + 1]
cmp dl, byte [eax + 1]
jne 0x4067c7
add ecx, 2
add eax, 2
test dl, dl
jne 0x4067a7
xor eax, eax
jmp 0x4067cc
sbb eax, eax
or eax, 1
test eax, eax
je case.0x40688f.11003
inc edi
mov dword [esp + 0x10], edi
cmp edi, 0x10
je case.0x40688f.11003
mov eax, ebx
mov dword [esp + 0x1c], ebp
mov ebx, dword [esp + 0x24]
mov ebp, eax
mov dword [esp + 0x18], ebp
jmp 0x406694
push esi
call fcn.004c4247
add esp, 4
mov eax, dword [esp + 0x14]
mov esi, 8
pop edi
mov dword [eax], 0
mov eax, esi
pop esi
pop ebp
pop ebx
add esp, 0x820
ret 0x10
cmp dword [esp + 0x83c], esi
je 0x4068c3
mov ecx, ebp
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x406830
sub ecx, edx
lea ebx, [ecx + 1]
push ebx
push 1
call fcn.004ca7e7
mov edi, eax
add esp, 8
test edi, edi
je 0x406858
push ebp
push ebx
push edi
call fcn.004ca7f2
add esp, 0xc
mov ecx, dword [esp + 0x840]
mov eax, dword [ecx]
mov dword [eax + 0x14], edi
mov eax, dword [ecx]
cmp dword [eax + 0x14], esi
jne 0x4068c3
mov esi, 8
pop edi
mov eax, esi
pop esi
pop ebp
pop ebx
add esp, 0x820
ret 0x10
call dword [sym.imp.WSOCK32.dll_WSAGetLastError]
add eax, 0xffffd507
cmp eax, 3
ja case.0x40688f.11001
jmp dword [eax*4 + 0x4068d4]
mov esi, 0x2afa
pop edi
mov eax, esi
pop esi
pop ebp
pop ebx
add esp, 0x820
ret 0x10
mov esi, 0x2afb
pop edi
mov eax, esi
pop esi
pop ebp
pop ebx
add esp, 0x820
ret 0x10
mov esi, 0x2af9
pop edi
mov eax, esi
pop esi
pop ebp
pop ebx
add esp, 0x820
ret 0x10