sentora / sentora-core

Sentora is a web hosting control panel written in PHP for *NIX
GNU General Public License v3.0
653 stars 444 forks source link

[Mailserver] Invalid Domain (BUG) #331

Closed Bizarrus closed 5 years ago

Bizarrus commented 5 years ago

Version: 1.0.3 (latest) OS: Debian 8 (Linux $DOMAIN 3.16.0-4-amd64 #1 SMP Debian 3.16.51-3 (2017-12-13) x86_64 GNU/Linux)

When i try to add a Mailbox with an .tk TLD, i've got following error:

The selected domain was not valid.

Debug-Testing: /etc/sentora/panel/modules/mailboxes/code/controller.ext.php on Line 309 with var_dump on IsValidDomain:

ListDomains: array(2) { [0]=> array(1) { ["domain"]=> string(11) "example.tk" } [1]=> array(1) { ["domain"]=> string(17) "subexample.example.tk" } }

if($checkDomain == $domain): array(1) { ["domain"]=> string(11) "example.tk" } string(11) "example.tk"

On IsValidEmail:

string(16) "info@example.tk" int(1)

The module seems be okay, i don't know, where the problem is. The validate-methods are correct

Bizarrus commented 5 years ago

I've found the problem. IsValidDomain is broken, on the 1.0.3 release. On repo's version, it was fixed.