Function at 0x402488
Capabilities:
Convert ip address from string

Disassembly:
mov eax, dword [ebp - 0x28]
mov edx, 0x27
dec eax
cmp eax, 3
ja case.default.0x4022a9
jmp dword [eax*4 + 0x402714]
mov al, byte [edi]
cmp al, 0x78
jne 0x4022c2
mov dword [ebp - 0x3c], 0x10
jmp 0x4024b9
movsx eax, al
push eax
call dword [sym.imp.MSVCR120.dll_isxdigit]
add esp, 4
test eax, eax
je 0x402558
push dword [ebp - 0x3c]
lea eax, [ebp - 0x30]
push eax
push edi
call dword [sym.imp.MSVCR120.dll_strtol]
add esp, 0xc
cmp eax, 0xff
ja 0x40252f
mov edi, dword [ebp - 0x30]
mov byte [esi], al
inc esi
dec edi
mov dword [ebp - 0x28], 0
jmp 0x4024b9
cmp esi, dword [ebp - 0x2c]
je 0x4025aa
push 0xa
lea eax, [ebp - 0x30]
push eax
push edi
call dword [sym.imp.MSVCR120.dll_strtol]
mov ecx, eax
add esp, 0xc
cmp ecx, 2
jl 0x402581
mov edi, dword [ebp - 0x30]
mov eax, 1
mov dl, byte [esi - 1]
dec edi
cmp ecx, eax
jle 0x402351
lea ebx, [ebx]
mov byte [esi], dl
inc esi
cmp esi, dword [ebp - 0x40]
je 0x4026fe
inc eax
cmp eax, ecx
jl 0x402340
mov dword [ebp - 0x28], 0
jmp 0x4024b9
mov al, byte [edi]
cmp al, 0x20
je 0x4024b9
cmp al, 0x2c
je 0x4024b9
lea edx, [ebp - 0x24]
mov dword [ebp - 0x30], edx
mov cl, byte [edi]
cmp cl, 0x2e
je 0x402386
cmp cl, 0x30
jl 0x40239b
cmp cl, 0x39
jg 0x40239b
mov eax, edx
lea ebx, [ebp - 0x24]
sub eax, ebx
cmp eax, 0x1f
jg 0x40239b
mov byte [edx], cl
mov edx, dword [ebp - 0x30]
inc edx
inc edi
jmp 0x402372
mov ebx, dword [ebp - 0x4c]
lea eax, [esi + 4]
dec edi
mov byte [edx], 0
mov dword [ebp - 0x44], eax
cmp eax, dword [ebp - 0x40]
jae 0x402600
push esi
lea eax, [ebp - 0x24]
push eax
push 2
call dword [sym.imp.WS2_32.dll_inet_pton]
cmp eax, 1
jl 0x4025d3
cmp dword [ebp - 0x38], 0
je 0x4023da
mov eax, dword [ebp - 0x50]
cmp dword [eax], 0
jne 0x4023da
sub esi, dword [ebp - 0x2c]
mov dword [eax], esi
mov ecx, dword [ebp - 0x34]
mov esi, dword [ebp - 0x44]
mov al, byte [ecx]
cmp al, 0x25
jae 0x4024b9
add al, 4
mov byte [ecx], al
jmp 0x4024b9
movsx eax, byte [edi]
add eax, 0xffffffd6
cmp eax, 0x32
ja case.0x402409.43
movzx eax, byte [eax + 0x402738]
jmp dword [eax*4 + 0x402724]
mov dword [ebp - 0x28], 1
mov dword [ebp - 0x3c], 0xa
jmp 0x4024b9
mov dword [ebp - 0x28], 2
jmp 0x4024b9
cmp esi, dword [ebp - 0x2c]
jne 0x40265a
mov byte [esi], 1
inc esi
movsx eax, byte [edi]
sub eax, 0x4c
je 0x402456
sub eax, 6
je 0x402451
invalid
dec eax
jne 0x402461
mov byte [esi], 0x89
jmp 0x402459
mov byte [esi], 7
jmp 0x402460
mov byte [esi], 0x83
mov dword [ebp - 0x38], 1
inc esi
cmp byte [edi], 0x52
mov eax, 3
add byte [ebx - 0x27ba3832], cl
add eax, dword [eax]
add byte [eax], al
add byte [ebx - 0x27ba3832], cl
add eax, dword [eax]
add byte [eax], al
cmove eax, edx
mov byte [esi], al
mov byte [esi + 1], 4
add esi, 2
jmp 0x4024b6
cmp esi, dword [ebp - 0x2c]
jne 0x40265a
invalid
mov byte [esi], 0x44
lea ecx, [esi + 1]
cmp byte [edi], 0x55
mov dword [ebp - 0x28], 4
setne al
lea eax, [eax*4 + 0x24]
mov byte [esi + 1], al
mov byte [esi + 2], 5
cmp byte [edi], 0x55
sete al
mov byte [esi + 3], al
add esi, 4
mov dword [ebp - 0x34], ecx
mov eax, dword [ebp - 0x40]
cmp esi, eax
je 0x4024e4
jb 0x4024da
push 0x18a
push str.netutil.cc
push str.d_dataend
call dword [sym.imp.MSVCR120.dll__wassert]
add esp, 0xc
inc edi
cmp byte [edi], 0
jne 0x402297
cmp dword [ebp - 0x38], 0
mov ecx, dword [ebp - 0x34]
je 0x40250e
mov al, byte [ecx]
cmp al, 0x25
jae 0x402687
mov edx, dword [ebp - 0x48]
add al, 4
mov byte [ecx], al
mov eax, esi
sub eax, dword [ebp - 0x2c]
mov dword [edx], eax
mov dword [esi], 0
add esi, 4
mov eax, dword [ebp - 0x28]
cmp eax, 3
jne 0x4026b4
movzx eax, byte [ecx]
pop edi
pop esi
inc eax
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004bb11e
mov esp, ebp
pop ebp
ret
test ebx, ebx
je 0x402544
push str.invalid_ipv4_address_format
push dword [ebp + 0x20]
push ebx
call fcn.004b54a0
add esp, 0xc
pop edi
pop esi
or eax, 0xffffffff
pop ebx
mov ecx, dword [ebp - 4]
cld
test ebx, ebx
je 0x402544
push str.not_a_digit_after_
push dword [ebp + 0x20]
push ebx
call fcn.004b54a0
add esp, 0xc
or eax, 0xffffffff
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004bb11e
mov esp, ebp
pop ebp
ret
test ebx, ebx
je 0x402544
push str.bad_number_after_
push dword [ebp + 0x20]
push ebx
call fcn.004b54a0
add esp, 0xc
invalid
invalid