allow adding domains with multiple dashes, that are NOT punycode (xn--)

Signed-off-by: Michael Kaufmann (d00p) <d00p@froxlor.org>
This commit is contained in:
Michael Kaufmann (d00p)
2017-06-04 09:17:31 +02:00
parent 9aa2cc269b
commit dae233dd05
2 changed files with 2 additions and 2 deletions

View File

@@ -306,7 +306,7 @@ if ($page == 'domains' || $page == 'overview') {
standard_error('admin_domain_emailsystemhostname'); standard_error('admin_domain_emailsystemhostname');
} }
if (strpos($_POST['domain'], '--') !== false) { if (substr($_POST['domain'], 0, 4) == 'xn--') {
standard_error('domain_nopunycode'); standard_error('domain_nopunycode');
} }

View File

@@ -260,7 +260,7 @@ if ($page == 'overview') {
if ($userinfo['subdomains_used'] < $userinfo['subdomains'] || $userinfo['subdomains'] == '-1') { if ($userinfo['subdomains_used'] < $userinfo['subdomains'] || $userinfo['subdomains'] == '-1') {
if (isset($_POST['send']) && $_POST['send'] == 'send') { if (isset($_POST['send']) && $_POST['send'] == 'send') {
if (strpos($_POST['subdomain'], '--') !== false) { if (substr($_POST['subdomain'], 0, 4) == 'xn--') {
standard_error('domain_nopunycode'); standard_error('domain_nopunycode');
} }