[Web, Dovecot] Allow empty/unlimited quota

This commit is contained in:
andryyy
2019-03-28 22:05:12 +01:00
parent e7d17ad1ac
commit 49492dff61
5 changed files with 22 additions and 25 deletions

View File

@@ -1,4 +1,12 @@
<?php
function isset_has_content($var) {
if (isset($var) && $var != "") {
return true;
}
else {
return false;
}
}
function hash_password($password) {
$salt_str = bin2hex(openssl_random_pseudo_bytes(8));
return "{SSHA256}".base64_encode(hash('sha256', $password . $salt_str, true) . $salt_str);