Skip to content

Instantly share code, notes, and snippets.

@BlackMac
Created October 23, 2009 08:07
Show Gist options
  • Save BlackMac/216729 to your computer and use it in GitHub Desktop.
Save BlackMac/216729 to your computer and use it in GitHub Desktop.
check for your provider in the double-character .de domains...
<?php
for ($a=0;$a<26;$a++) {
for ($b=0;$b<27;$b++) {
$fc=chr($a+97);
if ($b==0) {
$sc="";
} else {
$sc=chr($b+96);
}
$dom=$fc.$sc.".de";
$repeat=true;
while ($repeat) {
echo $dom;
$res=shell_exec("whois $dom ");
$repeat=false;
if (preg_match("/Error:/",$res)==1) {
echo " : [FAIL]";
sleep(10);
$repeat=true;
} else {
preg_match("/Name: +(.+)/", $res, $name);
$name=$name[1];
preg_match("/Organisation: +(.+)/", $res, $org);
$org=$org[1];
echo " : $name ($org) ";
if (preg_match("/[Nn]etzquadrat/", $res)==1) {
echo "[MATCH!]\n";
}
}
echo "\n";
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment