]> _ Git - cubist_net.git/commitdiff
wait #7008
authorsoufiane <soufiane@cubedesigners.com>
Tue, 30 Jul 2024 13:32:45 +0000 (15:32 +0200)
committersoufiane <soufiane@cubedesigners.com>
Tue, 30 Jul 2024 13:32:45 +0000 (15:32 +0200)
src/Transfer/Local.php

index ea8896091a43a3282421dd7d98b8d0f9710f97a8..0169b95738afbdadf68c7d45139411af61a2f757 100644 (file)
@@ -76,29 +76,6 @@ class Local extends Driver
     }
 
     public function checkConnexion($data = []) {
-        if(isset($data['protocol']) && isset($data['subdomains'])) {
-            $hosting = $data['protocol'] === 'hosting' ? 'hosting.fluidbook.com' : 'hosting2.fluidbook.com';
-            $ipHosting = dns_get_record($hosting, DNS_A)[0]['ip'];
-
-            $subdomains = explode("\r\n", $data['subdomains']);
-            $subdomainsIntruder = [];
-
-            if ($subdomains) {
-                foreach ($subdomains as $subdomain) {
-                    $ipSubdomain = dns_get_record($subdomain, DNS_A)[0]['ip'];
-                    $ipSubdomain = trim(str_replace('\n', '', shell_exec('dig +short @1.1.1.1 ' . $subdomain . ' | tail -1')));
-                    if ($ipSubdomain !== $ipHosting) {
-                        $subdomainsIntruder[] = $subdomain;
-                    }
-                }
-            }
-
-            if ($subdomainsIntruder) {
-                $subdomainsList = implode(", ", $subdomainsIntruder);
-                return ['subdomains' => $subdomainsList, 'host' => $hosting];
-            }
-        }
-
         if(file_exists($this->getRootPath().'status')) {
             return true;
         } else {