corrected ip validation