[Web] Fix transport validation for hostnames

master
andryyy 2020-01-22 11:04:10 +01:00
parent 92407d9439
commit fc37442d21
No known key found for this signature in database
GPG Key ID: 8EC34FF2794E25EF
1 changed files with 2 additions and 2 deletions

View File

@ -50,8 +50,8 @@ if (isset($_SESSION['mailcow_cc_role']) && $_SESSION['mailcow_cc_role'] == "admi
$port = null; $port = null;
} }
else { else {
echo "Invalid transport"; $port = substr($hostname_w_port, strrpos($hostname_w_port, ':') + 1);
die(); $hostname = rtrim($hostname_w_port, ':' . $port);
} }
} }
// Try to get MX if host is not [host] // Try to get MX if host is not [host]