Ultimate Domain & IP Lookup Tool
This tool allows you to perform a comprehensive lookup of domain names or IP addresses, providing detailed WHOIS information.
',$output, '
';
} else {
echo "Invalid domain.";
}
}
if(isset($_POST['ip']) && $_POST['ip']){
function validatePublicIp($ip) {
if (filter_var($ip, FILTER_VALIDATE_IP)) {
if (filter_var($ip, FILTER_VALIDATE_IP, FILTER_FLAG_NO_PRIV_RANGE | FILTER_FLAG_NO_RES_RANGE)) {
return true;
}
}
return false;
}
$ip = isset($_POST['ip']) ? $_POST['ip'] : '';
if ($ip && validatePublicIp($ip)) {
$command = 'whois '.$_POST['ip'];
$escaped_command = escapeshellcmd($command);
$output = shell_exec($escaped_command);
echo '';
} else {
echo "Invalid IP address.";
}
}
?>
Usage:
- Enter a domain name or an IP address into the respective input field.
- Click the "Check" button to retrieve WHOIS information.
Features:
- Supports lookup for both domain names and IP addresses.
- Displays WHOIS data including registration details and administrative contacts.
- Secure input validation to ensure accurate results.
Example Use Cases:
- Investigate ownership and registration details of a domain.
- Check the WHOIS information of an IP address for network troubleshooting.
- Verify domain availability and registration status.