Function at 0x409850
Capabilities:
Resolve dns

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x47961b
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x440
push ebx
push esi
mov esi, ecx
xor ebx, ebx
push edi
mov dword [ebp - 0x10], esp
mov dword [ebp - 0x38], esi
mov dword [esi + 4], ebx
mov dword [esi + 8], ebx
mov byte [esi + 0xc], bl
mov byte [esi + 0xd], 1
mov byte [esi + 0xe], bl
mov edi, dword [ebp + 8]
push 0xffffffffffffffff
push edi
mov dword [ebp - 4], ebx
mov dword [esi], 0x483ef0
call fcn.0044b020
add esp, 8
mov dword [esi + 0x10], eax
mov byte [ebp - 4], 1
mov dword [esi + 0x14], ebx
mov dword [esi + 0x18], ebx
call fcn.00408c00
mov dword [ebp - 0x14], 0xffffffff
call fcn.0040ba30
test al, al
je 0x4099c9
mov eax, dword [ebp + 0x10]
mov dword [ebp - 0x34], ebx
mov dword [ebp - 0x30], eax
mov dword [ebp - 0x2c], 1
mov dword [ebp - 0x28], ebx
mov dword [ebp - 0x24], ebx
mov dword [ebp - 0x20], ebx
mov dword [ebp - 0x1c], ebx
mov dword [ebp - 0x18], ebx
mov dword [ebp + 8], ebx
mov ecx, dword [ebp + 0xc]
push ecx
lea edx, [ebp + 8]
push 0x48268c
push edx
mov byte [ebp - 4], 2
call fcn.0044b320
mov edx, dword [ebp + 8]
lea eax, [ebp + 0x10]
push eax
lea ecx, [ebp - 0x34]
push ecx
push edx
push edi
call fcn.0040ba60
add esp, 0x1c
cmp eax, ebx
je 0x40994e
push eax
push str.getaddrinfo
lea ecx, [ebp - 0x140]
call fcn.0044ba90
push 0x499810
lea eax, [ebp - 0x348]
mov ecx, 0x41
lea esi, [ebp - 0x140]
lea edi, [ebp - 0x348]
push eax
rep movsd dword es:[edi], dword [esi]
call fcn.00459658
mov eax, dword [ebp + 0x10]
cmp eax, ebx
mov dword [ebp + 0xc], eax
je 0x4099ab
mov ecx, dword [eax + 0x10]
mov edx, dword [eax + 0xc]
push ecx
mov ecx, dword [eax + 8]
mov eax, dword [eax + 0x18]
push edx
push ecx
mov byte [ebp - 4], 3
call fcn.00408fc0
add esp, 0xc
mov edi, eax
mov byte [ebp - 4], 2
jmp 0x4099ae
mov edi, dword [ebp - 0x14]
mov ecx, dword [ebp + 0x10]
push ecx
call fcn.0040bab0
mov edx, dword [ebp + 8]
push edx
mov byte [ebp - 4], 1
call fcn.00459039
add esp, 8
jmp 0x409a29
xor eax, eax
mov dword [ebp - 0x24], eax
mov dword [ebp - 0x20], eax
mov dword [ebp - 0x1c], eax
push edi
mov dword [ebp - 0x18], eax
mov word [ebp - 0x24], 2
call dword [sym.imp.WS2_32.dll_inet_addr]
mov ecx, dword [ebp + 0xc]
push ecx
mov dword [ebp - 0x20], eax
call dword [sym.imp.WS2_32.dll_htons]
mov word [ebp - 0x22], ax
cmp dword [ebp - 0x20], 0xffffffff
jne 0x409a14
push edi
call dword [sym.imp.WS2_32.dll_gethostbyname]
cmp eax, ebx
je 0x409a68
mov edx, dword [eax + 0xc]
mov eax, dword [edx]
cmp eax, ebx
je 0x409a68
mov eax, dword [eax]
mov dword [ebp - 0x20], eax
push 0x10
push ebx
push 1
lea eax, [ebp - 0x24]
call fcn.00408fc0
add esp, 0xc
mov dword [ebp - 0x14], eax
mov edi, eax
cmp edi, ebx
jge 0x409aa3
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push 0x483fe4
lea ecx, [ebp - 0x140]
call fcn.0044ba90
push 0x499810
lea edx, [ebp - 0x44c]
mov ecx, 0x41
lea esi, [ebp - 0x140]
lea edi, [ebp - 0x44c]
push edx
rep movsd dword es:[edi], dword [esi]
call fcn.00459658
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push 0x483fc4
lea ecx, [ebp - 0x140]
call fcn.0044ba90
mov ecx, 0x41
lea esi, [ebp - 0x140]
lea edi, [ebp - 0x244]
rep movsd dword es:[edi], dword [esi]
push 0x499810
lea ecx, [ebp - 0x244]
push ecx
call fcn.00459658
mov eax, dword [ebp + 0x18]
mov ecx, dword [ebp + 0x14]
push eax
push ecx
push 1
push edi
mov ecx, esi
call fcn.00409630
mov ecx, esi
call fcn.00409760
mov edx, dword [eax]
push ebx
mov ecx, eax
call dword [edx + 0x10]
push eax
push 0x483fb4
push 0x4a6d0c
call fcn.00402eb0
mov ecx, dword [ebp - 0xc]
add esp, 0xc
pop edi
mov eax, esi
pop esi
mov dword fs:[0], ecx
pop ebx
mov esp, ebp
pop ebp
ret 0x14