0 ) {$eventuredomain="yes"; } $froms=0; $froms = substr_count($thiscase, "from="); if ($froms > 1) { $tempstr = after_last("from=",$thiscase); $tempstr = before_last("|",$tempstr); $domainrecord=array(); $sldtld=$tempstr; $route="found"; $domainrecord[0]["sldtld"]=GETSLDTLD($thiscase); $domainrecord[0]["rawtext"]=$a.$b.$c.$referer; $domainrecord[0]["ip"]=$c; HitRecord($domainrecord[0]); } $subdomainrecord=array() ; if ($froms==1) { $tempstr=remove_http($thiscase); //HERE $tempstr = after_last("from=",$thiscase); $tempstr = before_last("|",$tempstr); // ip removed if $dots=CountDots($tempstr); if ($dots > 1 ) { $subdomain="yes" ;} if ($subdomain=="yes") { $subdomains=ExtractSubdomain($tempstr) ; $sldtld = after($subdomains, $thiscase); $sldtld = before("|",$sldtld); $sldtld=before("/",$sldtld); $subdomainrecord[0]["subdomain"]=$subdomains; $subdomainrecord[0]["sldtld"]=$sldtld; $subdomainrecord[0]["rawtext"]=$a.$b.$c.$referer; $subdomainrecord[0]["ip"]=$c; $thisjson = json_encode($subdomainrecord[0],JSON_PRETTY_PRINT); file_put_contents("hits/subdomain.hit.".time(), $thisjson ) ; } if ($subdomain=="no") { $tempstr = before_last('/',$tempstr); $domainrecord=array() ; $tempstr=remove_http($tempstr); $sldtld=$tempstr; $route="found"; $domainrecord[0]["sldtld"]=GETSLDTLD($thiscase); $domainrecord[0]["rawtext"]=$a.$b.$c.$referer; $domainrecord[0]["ip"]=$c; HitRecord($domainrecord[0]); } // froms==1 } if ($route!="found") { $extractSLDTLD = GETSLDTLD($thiscase); if ($extractSLDTLD=="notfound") { $route="default"; } if ($route!="default") { // echo PHP_EOL.$thiscase."|resolved:".$extractSLDTLD; // file_put_contents("dev.report",$thiscase."|resolved:".$extractSLDTLD.PHP_EOL,FILE_APPEND); $sldtld=$extractSLDTLD;$route="found"; } } // route != found //if ($route=="default") // default handling // if ($sldtld=="global.router.e.e.ventures") { $route="globalrouter"; } if ($route=="tbd") { $sldtld="e.ventures"; } //$idn="tbd"; //$idncount = TestSpecificString($thiscase, "xn--"); $checkventures = TestSpecificString($sldtld,"ventures"); $checkdotboss = TestSpecificString($sldtld,"dotboss"); if ($checkdotboss>0) { $exceptiontrue="yes"; } if ($exceptiontrue=="yes") { $checkventures=1; } $alternatelink="no"; if ($checkventures>0) { $sldtld="e.ventures"; $alternatelink="yes"; } $protocol='https://'; $sldtld=trim($sldtld); if($sldtld=="tbd"){ $sldtld="e.ventures"; } $marketlink = 'https://uniregistry.com/market/domain/'.$sldtld; $link = idn_to_utf8($protocol.$sldtld); $html = "".idn_to_utf8($sldtld).""; if ($alternatelink=="yes") { $sldtld="e.ventures"; $marketlink = 'https://e.ventures/express3.php'; $link = ""; $html = "".idn_to_utf8($sldtld).""; } // $sldtld = $portfolio[$y]["trimmedsldtld"]; function ReverseDNS($ip) { $ip = str_replace("\n","",$ip); $domain = gethostbyaddr($ip); // echo $ip."|".$domain.PHP_EOL; return $domain ; } function HitRecord($array) { file_put_contents("hits/hit.record.".time(), json_encode($array,JSON_PRETTY_PRINT)); } function after ($this2, $inthat) { //after ('@', 'name@domain.com); //returns 'domain.com' //from the first occurrence of '@' if (!is_bool(strpos($inthat, $this2))) return substr($inthat, strpos($inthat,$this2)+strlen($this2)); }; function after_last ($this2, $inthat) { //after_last ('[', 'sin[90]*cos[180]'); //returns '180]' //from the last occurrence of '[' if (!is_bool(strrevpos($inthat, $this2))) return substr($inthat, strrevpos($inthat, $this2)+strlen($this2)); }; function before ($this2, $inthat) { //before ('@', 'tld@sld'); //returns 'tld' //from the first occurrence of '@' return substr($inthat, 0, strpos($inthat, $this2)); }; function before_last ($this2, $inthat) { //before_last ('[', 'sin[90]*cos[180]'); //returns 'sin[90]*cos[' //from the last occurrence of '[' return substr($inthat, 0, strrevpos($inthat, $this2)); }; function between ($this2, $that, $inthat) { // between ('@', '.', 'sld@tld.ca'); //returns 'tld' //from the first occurrence of '@' return before ($that, after($this2, $inthat)); }; function between_last ($this2, $that, $inthat) { //after_last ('[', 'sin[90]*cos[180]'); //returns '180]' //from the last occurrence of '[' return after_last($this2, before_last($that, $inthat)); }; // use strrevpos function in case your php version does not include it function strrevpos($instr, $needle) { $rev_pos = strpos (strrev($instr), strrev($needle)); if ($rev_pos===false) return false; else return strlen($instr) - $rev_pos - strlen($needle); } function GetTLDsPresent ($thiscase,$tldlist) { $extractedtld=""; $comparetld=""; $thiscase = strtolower($thiscase); $thiscase = after('/games/',$thiscase); $hint="none"; $thiscleancase = before('|',CleanCase($thiscase)); $hint = after("|",CleanCase($thiscase)); $presentarray = Array() ; $tldlistsize =count($tldlist); $x=0; $presentindex = 0 ; for($x=0;$x<$tldlistsize; $x++) { $thistld = $tldlist[$x]; $thistld = trim($thistld); $dots = CountDots($thiscleancase); $present = TestTLD ($thiscleancase, $thiscase, $tldlist,$thistld,$hint,$dots); if ($present > 0 ) { $presentarray["case"]=$thiscase; $presentarray["cleancase"]=$thiscleancase; $presentarray["thistld"]=$thistld; $presentarray["hint"]=$hint; $presentarray["extractedtld"]=$thistld; $presentarray["compare"]="true"; return $presentarray; } $presentarray["hint"]=$hint; $presentarray["case"]=$thiscase; $presentarray["cleancase"]=$thiscleancase; $presentarray["thistld"]=$thistld; $presentarray["extractedtld"]="none" ; $presentarray["compare"]="false"; // if ($hint=="onedot") { extractfromONEDOT($hint, $thistld, $thiscleancase); // $presentarray[$x]["case"]=$thiscase; // $presentarray[$x]["cleancase"]=$thiscleancase; // $presentarray[$x]["thistld"]=$thistld; // $comparetld = after(".",$thiscleancase); // if ($comparetld==$thistld) { // $presentarray[$x]["extractedtld"]=$comparetld ; // $presentarray[$x]["compare"]="true"; // return $presentarray;} // hint = onedot && thistld is present in thiscleancase // } // $comparetld==$thistld // } // // $IsThisTLDpresent = CountThis($thistld, $thiscase); // if ($IsThisTLDpresent > 1) { // $presentarray[$presentarrayindex] = $thistld; $presentarray=$presentarray+1; // echo $thistld." is present in the case:".$thiscase.PHP_EOL ; } } //for return $presentarray; } //function function extractfromONEDOT($hint, $thistld, $thiscleancase) { $tld=after(".",$thiscleancase) ; return $tld; } function CountThis($thistld, $thiscase) { //substr_count($text, 'is') $thispresent = substr_count($thiscase, $thistld); return $thispresent; } function CountDots ($string) { $dots = substr_count($string,"."); return $dots; } function CleanCase($thiscase) { $hint="none"; $www = substr_count($thiscase,'www.') ; if ($www==1) { $thiscase=str_replace('www.','',$thiscase); } if ($www>1) { $thiscase=str_replace('www.','',$thiscase); $thiscase=str_replace('www.','',$thiscase); } $from = substr_count($thiscase,'from=') ; if ($from==1) { $thiscase=str_replace('from=','',$thiscase); } if ($from>1) { $thiscase=str_replace('from=','',$thiscase); $thiscase=str_replace('?from=','',$thiscase); } $eventures = substr_count($thiscase,'e.ventures'); if ($eventures==1) { $thiscase=str_replace('e.ventures','',$thiscase); } if ($eventures==2) { $thiscase=str_replace('e.ventures','',$thiscase); $thiscase=str_replace('e.ventures','',$thiscase); } $questionmark = substr_count($thiscase,'?'); if ($questionmark==1) { $thiscase=str_replace('?','',$thiscase); } if ($questionmark==2) { $thiscase=str_replace('?','',$thiscase); $thiscase=str_replace('?','',$thiscase); } $ampercent = substr_count($thiscase,"%"); if ($ampercent==1) { $thiscase=str_replace('%','',$thiscase); } if ($ampercent==2) { $thiscase=str_replace('%','',$thiscase); $thiscase=str_replace('%','',$thiscase); $hint="onedot"; } //extract tld // pass tldlist array here //echo $thiscase."|hint:".$hint.PHP_EOL; return $thiscase."|hint:".$hint; } function TestSpecificString ($case,$string) { return $counter = substr_count($case,$string); } function TestTLD ($thiscleancase, $thiscase, $tldlist,$thistld,$hint,$dots) { $counter = substr_count($thiscleancase, $thistld) ; //same .tld twice is not handled ------------------------- // wrapper does it or should .. if ($counter==1) { return 1; } if ($counter>1) { return 2; } if ($counter<1) { return 0; } return $counter; } function Bypasser ($thiscase,$thiscleancase,$thistld,$tldlist) { $dots=-1; $dots = CountDots($thiscleancase); if ($dots=="1") { //shortest shortcut $a=TestTLD ($thiscleancase, $thiscase, $tldlist,$thistld,"none"); return $a; } return "no"; } function LightSpeedRoute ($thiscase) { // get clean case <-- dont get the clean case, no need //$thiscase = urldec($thiscase); // create array // FROM portfolio // field: trimmed = SLD + TLD ( no dots ) // second field: original name // compare this array to the case directly $thiscase = strtolower($thiscase); $hint="none"; $thiscleancase = before('|',CleanCase($thiscase)); $hint = after("|",CleanCase($thiscase)); $fileportfolio=file("portfolio.all"); $size = count($fileportfolio); $portfolio=Array() ; $x=0; for($x=0;$x<$size;$x++) { $sldtld=trim($fileportfolio[$x]); $portfolio[$x]["sldtld"]=$sldtld; $trimmedsldtld = str_replace(".","",$portfolio[$x]["sldtld"]); $portfolio[$x]["trimmedsldtld"] = $trimmedsldtld ; $portfolio[$x]["launcher"]=$sldtld.".php"; //$portfolio[$x]["utf8"] = punycode_to_unicode($input) ; $portfolio[$x]["ascii"]=idn_to_utf8($sldtld); $portfolio[$x]["tld"]= after(".",$sldtld); $portfolio[$x]["sld"]= idn_to_utf8(before(".",$sldtld)); } // if case matches a name ( trimmed ) from portfolio, then you // have found sld.tld $portfolio=array_values($portfolio); $newsize = count($portfolio); $y=0; for($y=0;$y<$newsize;$y++) { //compare trimmedsldtld to case $sldtld = $portfolio[$y]["trimmedsldtld"]; if (($sldtld=="")) { continue; } $compareboth = substr_count($thiscase, $sldtld) ; if ($compareboth>0) { $portfolio[$y]["reversed"]= $portfolio[$y]["sldtld"]."|".$thiscase; } if ($compareboth<1) { $portfolio[$y]["reversed"]="not a hit for case:".$thiscase; } } // for // if not .. // do default .. //echo "ok" ; file_put_contents("test.result",print_r($portfolio,true)); return $portfolio; } function GETSLDTLD ($thiscase) { //$thiscase = urldecode($thiscase); $thiscase=str_replace("eventures","",$thiscase); $thiscase=str_replace("e.ventures","",$thiscase); // get clean case <-- dont get the clean case, no need // create array // FROM portfolio // field: trimmed = SLD + TLD ( no dots ) // second field: original name // compare this array to the case directly $hint="none"; $thiscleancase = before('|',CleanCase($thiscase)); $hint = after("|",CleanCase($thiscase)); $fileportfolio=file("portfolio.all"); $size = count($fileportfolio); $portfolio=Array() ; $x=0; for($x=0;$x<$size;$x++) { $sldtld=trim($fileportfolio[$x]); $portfolio[$x]["sldtld"]=$sldtld; $trimmedsldtld = str_replace(".","",$portfolio[$x]["sldtld"]); $portfolio[$x]["trimmedsldtld"] = $trimmedsldtld ; $xsldtld = str_replace(".","",$sldtld); $portfolio[$x]["launcher"]=$xsldtld.".php"; //$portfol/io[$x]["utf8"] = punycode_to_unicode($input) ; $portfolio[$x]["ascii"]=idn_to_utf8($sldtld); $portfolio[$x]["tld"]= after(".",$sldtld); $portfolio[$x]["sld"]= idn_to_utf8(before(".",$sldtld)); } // if case matches a name ( trimmed ) from portfolio, then you // have found sld.tld $portfolio=array_values($portfolio); $newsize = count($portfolio); $y=0; // PrintLaunchers($portfolio); for($y=0;$y<$newsize;$y++) { // echo $y.PHP_EOL; //compare trimmedsldtld to case $sldtld = $portfolio[$y]["trimmedsldtld"]; if (($sldtld=="")) { continue; } $compareboth = substr_count($thiscase, $sldtld) ; //$compareboth2 = // assign to another IF // //$thiscaseagain=after('from=eventures/?from=',$thiscase); if ($compareboth>0) { $portfolio[$y]["reversed"]= $portfolio[$y]["sldtld"]."|".$thiscase; return $portfolio[$y]["sldtld"]; } if ($compareboth<1) { //before declaring default // check for eventuresdomains.php folio[$y]["reversed"]= $portfolio[$y]["sldtld"]."|".$thisc $thiscaseagain=after('from=',$thiscase);se; // $thiscaseagain=GETSLDTLD($thiscaseagain); // if ($thiscaseagain!="notfound") { return $portfolio[$y]["sldtld"]; } // $comparebothagain = substr_count($thiscaseagain, $sldtld) ; // if ($comparebothagain > 0 ) { $portfolio[$y]["reversed"]= $portfolio[$y]["sldtld"]."|".$thiscaseagain;return $portfolio[$y]["sldtld"];} // check for % // % can be converted back using $portfolio[$y]["reversed"]="not a hit for case:".$thiscase; } } // for // if not .. // do default .. // file_put_contents("test.result",print_r($portfolio,true)); return "notfound"; } function PrintLaunchers($array) { $size = count($array); $x=0; shell_exec("sudo rm -f launches.list"); for($x=0;$x<$size;$x++) { $launcher = $array[$x]["launcher"]; $string = "sudo cp -fr index.php ".$launcher; file_put_contents("launches.list",$string.PHP_EOL,FILE_APPEND); } } function StatsNotFound($array) { $size=count($array); $y=0; $counter=0; for($y=0;$y<$size;$y++) { $resolved = trim($array[$y]["resolved"]); if ($resolved=="notfound") { $counter=$counter+1; } } return $counter; } function PerCent($string) { shell_exec("sudo rm -f percent.converted"); //convert % to normal $string = urldecode($string); $string=idn_to_ascii($string); // file_put_contents("percent.converted",$string,FILE_APPEND); return $string; } function remove_http($url) { $disallowed = array('http://', 'https://'); foreach($disallowed as $d) { if(strpos($url, $d) === 0) { return str_replace($d, '', $url); } } return $url; } function ExtractSubDomain($string) { $sldtld=$string; $sldtld=trim($sldtld); $dots=CountDots($sldtld); $subdomain=""; while($dots>1) { $subdomain = $subdomain. before('.',$sldtld)."." ; $sldtld = after(".",$sldtld); $dots=CountDots($sldtld); } return $subdomain; } ?> <?php echo idn_to_utf8($sldtld); ?>


e.ventures/domains

Created with Dotboss.digital by e.ventures