Function at 0x462020
Capabilities:
Convert ip address from string
Resolve dns

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x138
mov eax, dword [0x62aabc]
xor eax, ebp
mov dword [ebp - 4], eax
mov ecx, dword [ebp + 0x10]
push ebx
mov ebx, dword [ebp + 8]
push esi
push edi
push 0x88
xor edi, edi
mov dword [ebp - 0x118], ebx
push edi
push ecx
mov dword [ebp - 0x108], ecx
call sub.VCRUNTIME140.dll_memset
push 0x100
lea eax, [ebp - 0x104]
push edi
push eax
call sub.VCRUNTIME140.dll_memset
push 0xff
lea eax, [ebp - 0x104]
push ebx
push eax
call dword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_strncpy]
mov al, byte [ebp - 0x104]
lea esi, [ebp - 0x104]
add esp, 0x24
cmp al, 0x5b
jne 0x4620ea
lea ecx, [ebp - 0x103]
mov eax, ecx
mov dword [ebp - 0x10c], eax
mov al, byte [ebp - 0x103]
test al, al
je 0x4620b2
cmp al, 0x5d
je 0x4620c8
mov al, byte [ecx + 1]
inc ecx
test al, al
jne 0x4620a6
pop edi
pop esi
mov eax, 0xffffff94
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0054f742
mov esp, ebp
pop ebp
ret
xor edx, edx
mov byte [ecx], 0
cmp byte [ecx + 1], 0x3a
mov edi, 0x17
sete dl
xor ebx, ebx
cmp byte [ecx + 1], 0x3a
sete bl
inc ebx
add ebx, ecx
jmp 0x462204
lea ecx, [ebp - 0x104]
mov dword [ebp - 0x10c], ecx
cmp al, 0x3a
je 0x462133
mov ebx, dword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_isalnum]
mov cl, al
mov al, cl
cmp cl, 0x2f
je 0x462133
movsx eax, cl
push eax
call ebx
add esp, 4
test eax, eax
jne 0x462122
mov al, byte [esi]
cmp al, 0x2e
je 0x462127
cmp al, 0x2d
jne 0x462133
jmp 0x462129
cmp byte [esi], 0x2e
jne 0x462129
mov edi, esi
mov al, byte [esi + 1]
inc esi
mov cl, al
cmp al, 0x3a
jne 0x462102
xor ecx, ecx
mov byte [esi], 0
cmp al, 0x3a
lea ebx, [esi + 1]
sete cl
cmovne ebx, esi
mov dword [ebp - 0x110], ecx
test edi, edi
je 0x462169
movsx eax, byte [edi + 1]
push eax
call dword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_isdigit]
add esp, 4
test eax, eax
je 0x462169
mov edi, 2
jmp 0x4621fe
lea eax, [ebp - 0x114]
xorps xmm0, xmm0
push eax
lea eax, [ebp - 0x138]
push eax
push 0
lea eax, [ebp - 0x104]
movups xmmword [ebp - 0x138], xmm0
push eax
movups xmmword [ebp - 0x128], xmm0
mov dword [ebp - 0x130], 1
call dword [sym.imp.WS2_32.dll_getaddrinfo]
test eax, eax
jne 0x4620b2
mov edi, dword [ebp - 0x114]
mov esi, edi
test esi, esi
je 0x4621ed
mov eax, dword [esi + 4]
sub eax, 2
je 0x4621d5
sub eax, 0x15
je 0x4621d5
mov esi, dword [esi + 0x1c]
test esi, esi
jne 0x4621b5
push edi
call dword [sym.imp.WS2_32.dll_freeaddrinfo]
jmp 0x4620b2
push dword [esi + 0x10]
mov eax, dword [ebp - 0x108]
push dword [esi + 0x18]
add eax, 8
push eax
call sub.VCRUNTIME140.dll_memcpy
add esp, 0xc
push edi
call dword [sym.imp.WS2_32.dll_freeaddrinfo]
test esi, esi
je 0x4620b2
xor edi, edi
mov edx, dword [ebp - 0x110]
cmp edx, 1
jne 0x462242
mov al, byte [ebx]
mov esi, ebx
test al, al
je 0x46222a
movsx eax, al
push eax
call dword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_isdigit]
add esp, 4
test eax, eax
je 0x46222a
mov al, byte [ebx + 1]
inc ebx
test al, al
jne 0x462211
push esi
call dword [sym.imp.api_ms_win_crt_convert_l1_1_0.dll_atoi]
movzx eax, ax
add esp, 4
test ax, ax
je 0x4620b2
jmp 0x462246
movzx eax, word [ebp + 0xc]
mov esi, dword [ebp - 0x108]
lea ecx, [ebp - 0x104]
sub ebx, ecx
mov ecx, edi
push eax
sub ecx, 2
je 0x4622b6
sub ecx, 0x15
je 0x462292
call dword [sym.imp.WS2_32.dll_htons]
mov ecx, dword [ebp - 0x118]
movzx eax, ax
mov word [esi + 0xa], ax
mov eax, dword [ebp - 0x108]
pop edi
pop esi
mov dword [eax + 4], ebx
mov dword [eax], ecx
mov eax, ebx
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0054f742
mov esp, ebp
pop ebp
ret
mov word [esi + 8], di
call dword [sym.imp.WS2_32.dll_htons]
mov word [esi + 0xa], ax
mov eax, dword [0x627664]
mov dword [esi + 0x20], eax
lea eax, [esi + 0x10]
push eax
push dword [ebp - 0x10c]
push 0x17
jmp 0x4622d0
mov word [esi + 8], di
call dword [sym.imp.WS2_32.dll_htons]
mov word [esi + 0xa], ax
lea eax, [esi + 0xc]
push eax
push dword [ebp - 0x10c]
push 2
call dword [sym.imp.WS2_32.dll_inet_pton]
test eax, eax
jle 0x4620b2
mov eax, dword [ebp - 0x108]
mov ecx, dword [ebp - 0x118]
pop edi
pop esi
mov dword [eax], ecx
mov ecx, dword [ebp - 4]
mov dword [eax + 4], ebx
xor ecx, ebp
mov eax, ebx
pop ebx
call fcn.0054f742
mov esp, ebp
pop ebp
ret