Parcourir la source

[Web] Remove MTA-STS version STSv2

FreddleSpl0it il y a 2 mois
Parent
commit
9343f2121c

+ 2 - 3
data/web/inc/functions.mailbox.inc.php

@@ -1417,7 +1417,7 @@ function mailbox($_action, $_type, $_data = null, $_extra = null) {
             );
             return false;
           }
-          if (empty($version) || !in_array($version, array('stsv1', 'stsv2'))) {
+          if (empty($version) || !in_array($version, array('stsv1'))) {
             $_SESSION['return'][] = array(
               'type' => 'danger',
               'log' => array(__FUNCTION__, $_action, $_type, $_data, $_attr),
@@ -3826,7 +3826,6 @@ function mailbox($_action, $_type, $_data = null, $_extra = null) {
 
           foreach ($domains as $domain) {
             $domain       = idn_to_ascii(strtolower(trim($domain)), 0, INTL_IDNA_VARIANT_UTS46);
-            $id           = time();
 
             if (!hasDomainAccess($_SESSION['mailcow_cc_username'], $_SESSION['mailcow_cc_role'], $domain)) {
               $_SESSION['return'][] = array(
@@ -3865,7 +3864,7 @@ function mailbox($_action, $_type, $_data = null, $_extra = null) {
               continue;
             }
 
-            if (empty($version) || !in_array($version, array('stsv1', 'stsv2'))) {
+            if (empty($version) || !in_array($version, array('stsv1'))) {
               $_SESSION['return'][] = array(
                 'type' => 'danger',
                 'log' => array(__FUNCTION__, $_action, $_type, $_data, $_attr),

+ 0 - 1
data/web/templates/edit/domain.twig

@@ -295,7 +295,6 @@
                     <div class="col-sm-10">
                       <select data-style="btn btn-light" class="form-control" name="version" title="" required>
                         <option value="stsv1"{% if mta_sts.version == 'STSv1' %} selected{% endif %}>STSv1</option>
-                        <option value="stsv2"{% if mta_sts.version == 'STSv2' %} selected{% endif %}>STSv2</option>
                       </select>
                     </div>
                   </div>