diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/ajax/dns_diagnostics.php b/mailcow/src/mailcow-dockerized/data/web/inc/ajax/dns_diagnostics.php
index a315680..4cfee16 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/ajax/dns_diagnostics.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/ajax/dns_diagnostics.php
@@ -151,7 +151,7 @@
   }
 
   if (!in_array($domain, $alias_domains)) {
-    $current_records = dns_get_record('_pop3._tcp.' . $domain, DNS_SRV);
+    $current_records = (array)dns_get_record('_pop3._tcp.' . $domain, DNS_SRV);
     if (count($current_records) == 0 || $current_records[0]['target'] != '') {
       if ($autodiscover_config['pop3']['tlsport'] != '110') {
         $records[] = array(
@@ -169,7 +169,7 @@
       );
     }
 
-    $current_records = dns_get_record('_pop3s._tcp.' . $domain, DNS_SRV);
+    $current_records = (array)dns_get_record('_pop3s._tcp.' . $domain, DNS_SRV);
 
     if (count($current_records) == 0 || $current_records[0]['target'] != '') {
       if ($autodiscover_config['pop3']['port'] != '995') {
@@ -265,7 +265,7 @@
         $state = state_optional;
 
         if ($record[1] == 'TLSA') {
-          $currents = dns_get_record($record[0], 52, $_, $_, TRUE);
+          $currents = (array)dns_get_record($record[0], 52, $_, $_, TRUE);
           foreach ($currents as &$current) {
             $current['type'] = 'TLSA';
             $current['cert_usage'] = hexdec(bin2hex($current['data'][0]));
@@ -277,9 +277,9 @@
           unset($current);
         }
         else {
-          $currents = dns_get_record($record[0], $record_types[$record[1]]);
+          $currents = (array)dns_get_record($record[0], $record_types[$record[1]]);
           if ($record[0] == $mailcow_hostname && ($record[1] == "A" || $record[1] == "AAAA")) {
-            if (!empty(dns_get_record($record[0], DNS_CNAME))) {
+            if (!empty((array)dns_get_record($record[0], DNS_CNAME))) {
               $currents[0]['ip'] = state_missing . ' <b>(CNAME)</b>';
               $currents[0]['ipv6'] = state_missing . ' <b>(CNAME)</b>';
             }
@@ -309,8 +309,8 @@
 
         if ($record[1] == 'CNAME' && count($currents) == 0) {
           // A and AAAA are also valid instead of CNAME
-          $a = dns_get_record($record[0], DNS_A);
-          $cname = dns_get_record($record[2], DNS_A);
+          $a = (array)dns_get_record($record[0], DNS_A);
+          $cname = (array)dns_get_record($record[2], DNS_A);
           if (count($a) > 0 && count($cname) > 0) {
             if ($a[0]['ip'] == $cname[0]['ip']) {
               $currents = array(
@@ -321,8 +321,8 @@
                   'target' => $record[2]
                 )
               );
-              $aaaa = dns_get_record($record[0], DNS_AAAA);
-              $cname = dns_get_record($record[2], DNS_AAAA);
+              $aaaa = (array)dns_get_record($record[0], DNS_AAAA);
+              $cname = (array)dns_get_record($record[2], DNS_AAAA);
               if (count($aaaa) == 0 || count($cname) == 0 || expand_ipv6($aaaa[0]['ipv6']) != expand_ipv6($cname[0]['ipv6'])) {
                 $currents[0]['target'] = expand_ipv6($aaaa[0]['ipv6']) . ' <sup>1</sup>';
               }
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/footer.inc.php b/mailcow/src/mailcow-dockerized/data/web/inc/footer.inc.php
index f99c86d..9c08c66 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/footer.inc.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/footer.inc.php
@@ -1,5 +1,4 @@
 <?php
-require_once $_SERVER['DOCUMENT_ROOT'] . '/modals/footer.php';
 logger();
 
 $hash = $js_minifier->getDataHash();
@@ -8,303 +7,46 @@
   $js_minifier->minify($JSPath);
   cleanupJS($hash);
 }
-?>
-<script src="/cache/<?=basename($JSPath)?>"></script>
-<script>
-<?php
-$lang_footer = json_encode($lang['footer']);
-$lang_acl = json_encode($lang['acl']);
-$lang_tfa = json_encode($lang['tfa']);
-$lang_fido2 = json_encode($lang['fido2']);
-echo "var lang_footer = ". $lang_footer . ";\n";
-echo "var lang_acl = ". $lang_acl . ";\n";
-echo "var lang_tfa = ". $lang_tfa . ";\n";
-echo "var lang_fido2 = ". $lang_fido2 . ";\n";
-echo "var docker_timeout = ". $DOCKER_TIMEOUT * 1000 . ";\n";
-?>
-$(window).scroll(function() {
-  sessionStorage.scrollTop = $(this).scrollTop();
-});
-// Select language and reopen active URL without POST
-function setLang(sel) {
-  $.post( "<?= $_SERVER['REQUEST_URI']; ?>", {lang: sel} );
-  window.location.href = window.location.pathname + window.location.search;
-}
-// FIDO2 functions
-function arrayBufferToBase64(buffer) {
-  let binary = '';
-  let bytes = new Uint8Array(buffer);
-  let len = bytes.byteLength;
-  for (let i = 0; i < len; i++) {
-    binary += String.fromCharCode( bytes[ i ] );
+
+$alertbox_log_parser = alertbox_log_parser($_SESSION);
+$alerts = [];
+if (is_array($alertbox_log_parser)) {
+  foreach ($alertbox_log_parser as $log) {
+    $message = strtr($log['msg'], ["\n" => '', "\r" => '', "\t" => '<br>']);
+    $alerts[trim($log['type'], '"')][] = trim($message, '"');
   }
-  return window.btoa(binary);
-}
-function recursiveBase64StrToArrayBuffer(obj) {
-  let prefix = '=?BINARY?B?';
-  let suffix = '?=';
-  if (typeof obj === 'object') {
-    for (let key in obj) {
-      if (typeof obj[key] === 'string') {
-        let str = obj[key];
-        if (str.substring(0, prefix.length) === prefix && str.substring(str.length - suffix.length) === suffix) {
-          str = str.substring(prefix.length, str.length - suffix.length);
-          let binary_string = window.atob(str);
-          let len = binary_string.length;
-          let bytes = new Uint8Array(len);
-          for (let i = 0; i < len; i++) {
-            bytes[i] = binary_string.charCodeAt(i);
-          }
-          obj[key] = bytes.buffer;
-        }
-      } else {
-        recursiveBase64StrToArrayBuffer(obj[key]);
-      }
-    }
+  $alert = array_filter(array_unique($alerts));
+  foreach($alert as $alert_type => $alert_msg) {
+    $alerts[$alert_type] = implode('<hr class="alert-hr">', $alert_msg);
   }
-}
-$(window).load(function() {
-  $(".overlay").hide();
-});
-$(document).ready(function() {
-  $(document).on('shown.bs.modal', function(e) {
-    modal_id = $(e.relatedTarget).data('target');
-    $(modal_id).attr("aria-hidden","false");
-  });
-  // TFA, CSRF, Alerts in footer.inc.php
-  // Other general functions in mailcow.js
-  <?php
-  $alertbox_log_parser = alertbox_log_parser($_SESSION);
-  if (is_array($alertbox_log_parser)) {
-    foreach($alertbox_log_parser as $log) {
-      $alerts[$log['type']][] = $log['msg'];
-    }
-    $alerts = array_filter(array_unique($alerts));
-    foreach($alerts as $alert_type => $alert_msg) {
-  ?>
-  mailcow_alert_box(<?=json_encode(implode('<hr class="alert-hr">', $alert_msg));?>, <?=$alert_type;?>);
-  <?php
-    }
   unset($_SESSION['return']);
-  }
-  ?>
-  // Confirm TFA modal
-  <?php if (isset($_SESSION['pending_tfa_method'])):?>
-  $('#ConfirmTFAModal').modal({
-    backdrop: 'static',
-    keyboard: false
-  });
-  $('#u2f_status_auth').html('<p><i class="bi bi-arrow-repeat icon-spin"></i> ' + lang_tfa.init_u2f + '</p>');
-  $('#ConfirmTFAModal').on('shown.bs.modal', function(){
-      $(this).find('input[name=token]').focus();
-      // If U2F
-      if(document.getElementById("u2f_auth_data") !== null) {
-        $.ajax({
-          type: "GET",
-          cache: false,
-          dataType: 'script',
-          url: "/api/v1/get/u2f-authentication/<?= (isset($_SESSION['pending_mailcow_cc_username'])) ? rawurlencode($_SESSION['pending_mailcow_cc_username']) : null; ?>",
-          complete: function(data){
-            $('#u2f_status_auth').html(lang_tfa.waiting_usb_auth);
-            data;
-            setTimeout(function() {
-              console.log("Ready to authenticate");
-              u2f.sign(appId, challenge, registeredKeys, function(data) {
-                var form = document.getElementById('u2f_auth_form');
-                var auth = document.getElementById('u2f_auth_data');
-                console.log("Authenticate callback", data);
-                auth.value = JSON.stringify(data);
-                form.submit();
-              });
-            }, 1000);
-          }
-        });
-      }
-  });
-  $('#ConfirmTFAModal').on('hidden.bs.modal', function(){
-      $.ajax({
-        type: "GET",
-        cache: false,
-        dataType: 'script',
-        url: '/inc/ajax/destroy_tfa_auth.php',
-        complete: function(data){
-          window.location = window.location.href.split("#")[0];
-        }
-      });
-  });
-  <?php endif; ?>
-  // Validate FIDO2
-  $("#fido2-login").click(function(){
-    $('#fido2-alerts').html();
-    if (!window.fetch || !navigator.credentials || !navigator.credentials.create) {
-      window.alert('Browser not supported.');
-      return;
-    }
-    window.fetch("/api/v1/get/fido2-get-args", {method:'GET',cache:'no-cache'}).then(function(response) {
-      return response.json();
-    }).then(function(json) {
-    if (json.success === false) {
-      throw new Error();
-    }
-    recursiveBase64StrToArrayBuffer(json);
-    return json;
-    }).then(function(getCredentialArgs) {
-      return navigator.credentials.get(getCredentialArgs);
-    }).then(function(cred) {
-      return {
-        id: cred.rawId ? arrayBufferToBase64(cred.rawId) : null,
-        clientDataJSON: cred.response.clientDataJSON  ? arrayBufferToBase64(cred.response.clientDataJSON) : null,
-        authenticatorData: cred.response.authenticatorData ? arrayBufferToBase64(cred.response.authenticatorData) : null,
-        signature : cred.response.signature ? arrayBufferToBase64(cred.response.signature) : null
-      };
-    }).then(JSON.stringify).then(function(AuthenticatorAttestationResponse) {
-      return window.fetch("/api/v1/process/fido2-args", {method:'POST', body: AuthenticatorAttestationResponse, cache:'no-cache'});
-    }).then(function(response) {
-      return response.json();
-    }).then(function(json) {
-      if (json.success) {
-        window.location = window.location.href.split("#")[0];
-      } else {
-        throw new Error();
-      }
-    }).catch(function(err) {
-      if (typeof err.message === 'undefined') {
-        mailcow_alert_box(lang_fido2.fido2_validation_failed, "danger");
-      } else {
-        mailcow_alert_box(lang_fido2.fido2_validation_failed + ":<br><i>" + err.message + "</i>", "danger");
-      }
-    });
-  });
-  // Set TFA/FIDO2
-  $("#register-fido2").click(function(){
-    $("option:selected").prop("selected", false);
-    if (!window.fetch || !navigator.credentials || !navigator.credentials.create) {
-        window.alert('Browser not supported.');
-        return;
-    }
-    window.fetch("/api/v1/get/fido2-registration/<?= (isset($_SESSION['mailcow_cc_username'])) ? rawurlencode($_SESSION['mailcow_cc_username']) : null; ?>", {method:'GET',cache:'no-cache'}).then(function(response) {
-      return response.json();
-    }).then(function(json) {
-      if (json.success === false) {
-        throw new Error(json.msg);
-      }
-      recursiveBase64StrToArrayBuffer(json);
-      return json;
-    }).then(function(createCredentialArgs) {
-      console.log(createCredentialArgs);
-      return navigator.credentials.create(createCredentialArgs);
-    }).then(function(cred) {
-      return {
-        clientDataJSON: cred.response.clientDataJSON  ? arrayBufferToBase64(cred.response.clientDataJSON) : null,
-        attestationObject: cred.response.attestationObject ? arrayBufferToBase64(cred.response.attestationObject) : null
-      };
-    }).then(JSON.stringify).then(function(AuthenticatorAttestationResponse) {
-      return window.fetch("/api/v1/add/fido2-registration", {method:'POST', body: AuthenticatorAttestationResponse, cache:'no-cache'});
-    }).then(function(response) {
-      return response.json();
-    }).then(function(json) {
-      if (json.success) {
-        window.location = window.location.href.split("#")[0];
-      } else {
-        throw new Error(json.msg);
-      }
-    }).catch(function(err) {
-      $('#fido2-alerts').html('<span class="text-danger"><b>' + err.message + '</b></span>');
-    });
-  });
-  $('#selectTFA').change(function () {
-    if ($(this).val() == "yubi_otp") {
-      $('#YubiOTPModal').modal('show');
-      $("option:selected").prop("selected", false);
-    }
-    if ($(this).val() == "totp") {
-      $('#TOTPModal').modal('show');
-      request_token = $('#tfa-qr-img').data('totp-secret');
-      $.ajax({
-        url: '/inc/ajax/qr_gen.php',
-        data: {
-          token: request_token,
-        },
-      }).done(function (result) {
-        $("#tfa-qr-img").attr("src", result);
-      });
-      $("option:selected").prop("selected", false);
-    }
-    if ($(this).val() == "u2f") {
-      $('#U2FModal').modal('show');
-      $("option:selected").prop("selected", false);
-      $("#start_u2f_register").click(function(){
-        $('#u2f_return_code').html('');
-        $('#u2f_return_code').hide();
-        $('#u2f_status_reg').html('<p><i class="bi bi-arrow-repeat icon-spin"></i> ' + lang_tfa.init_u2f + '</p>');
-        $.ajax({
-          type: "GET",
-          cache: false,
-          dataType: 'script',
-          url: "/api/v1/get/u2f-registration/<?= (isset($_SESSION['mailcow_cc_username'])) ? rawurlencode($_SESSION['mailcow_cc_username']) : null; ?>",
-          complete: function(data){
-            data;
-            setTimeout(function() {
-              console.log("Ready to register");
-              $('#u2f_status_reg').html(lang_tfa.waiting_usb_register);
-              u2f.register(appId, registerRequests, registeredKeys, function(deviceResponse) {
-                var form  = document.getElementById('u2f_reg_form');
-                var reg   = document.getElementById('u2f_register_data');
-                console.log("Register callback: ", data);
-                if (deviceResponse.errorCode && deviceResponse.errorCode != 0) {
-                  var u2f_return_code = document.getElementById('u2f_return_code');
-                  u2f_return_code.style.display = u2f_return_code.style.display === 'none' ? '' : null;
-                  if (deviceResponse.errorCode == "4") {
-                    deviceResponse.errorCode = "4 - The presented device is not eligible for this request. For a registration request this may mean that the token is already registered, and for a sign request it may mean that the token does not know the presented key handle";
-                  }
-                  else if (deviceResponse.errorCode == "5") {
-                    deviceResponse.errorCode = "5 - Timeout reached before request could be satisfied.";
-                  }
-                  u2f_return_code.innerHTML = lang_tfa.error_code + ': ' + deviceResponse.errorCode + ' ' + lang_tfa.reload_retry;
-                  return;
-                }
-                reg.value = JSON.stringify(deviceResponse);
-                form.submit();
-              });
-            }, 1000);
-          }
-        });
-      });
-    }
-    if ($(this).val() == "none") {
-      $('#DisableTFAModal').modal('show');
-      $("option:selected").prop("selected", false);
-    }
-  });
+}
 
-  // Reload after session timeout
-  var session_lifetime = <?=((int)$SESSION_LIFETIME * 1000) + 15000;?>;
-  <?php
-  if (isset($_SESSION['mailcow_cc_username'])):
-  ?>
-  setTimeout(function() {
-    location.reload();
-  }, session_lifetime);
-  <?php
-  endif;
-  ?>
+$globalVariables = [
+  'js_path' => '/cache/'.basename($JSPath),
+  'pending_tfa_method' => @$_SESSION['pending_tfa_method'],
+  'pending_mailcow_cc_username' => @$_SESSION['pending_mailcow_cc_username'],
+  'lang_footer' => json_encode($lang['footer']),
+  'lang_acl' => json_encode($lang['acl']),
+  'lang_tfa' => json_encode($lang['tfa']),
+  'lang_fido2' => json_encode($lang['fido2']),
+  'docker_timeout' => $DOCKER_TIMEOUT,
+  'session_lifetime' => (int)$SESSION_LIFETIME,
+  'csrf_token' => $_SESSION['CSRF']['TOKEN'],
+  'pagination_size' => $PAGINATION_SIZE,
+  'log_pagination_size' => $LOG_PAGINATION_SIZE,
+  'alerts' => $alerts,
+  'totp_secret' => $tfa->createSecret(),
+];
 
-  // CSRF
-  $('<input type="hidden" value="<?= $_SESSION['CSRF']['TOKEN']; ?>">').attr('name', 'csrf_token').appendTo('form');
-  if (sessionStorage.scrollTop != "undefined") {
-    $(window).scrollTop(sessionStorage.scrollTop);
-  }
-});
-</script>
+foreach ($globalVariables as $globalVariableName => $globalVariableValue) {
+  $twig->addGlobal($globalVariableName, $globalVariableValue);
+}
 
-  <div class="container footer">
-  <?php if (!empty($UI_TEXTS['ui_footer'])) { ?>
-   <hr><span class="rot-enc"><?=str_rot13($UI_TEXTS['ui_footer']);?></span>
-  <?php } ?>
-  </div>
-</body>
-</html>
-<?php
+if (is_array($template_data)) {
+  echo $twig->render($template, $template_data);
+}
+
 if (isset($_SESSION['mailcow_cc_api'])) {
   session_regenerate_id(true);
   session_unset();
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/functions.admin.inc.php b/mailcow/src/mailcow-dockerized/data/web/inc/functions.admin.inc.php
index af1474c..9f42fd7 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/functions.admin.inc.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/functions.admin.inc.php
@@ -15,8 +15,8 @@
   !isset($_data_log['password2']) ?: $_data_log['password2'] = '*';
   switch ($_action) {
     case 'add':
-      $username		= strtolower(trim($_data['username']));
-      $password		= $_data['password'];
+      $username   = strtolower(trim($_data['username']));
+      $password   = $_data['password'];
       $password2  = $_data['password2'];
       $active     = intval($_data['active']);
       if (!ctype_alnum(str_replace(array('_', '.', '-'), '', $username)) || empty ($username) || $username == 'API') {
@@ -51,7 +51,7 @@
       if (password_check($password, $password2) !== true) {
         return false;
       }
-      $password_hashed = hash_password($password_new);
+      $password_hashed = hash_password($password);
       $stmt = $pdo->prepare("INSERT INTO `admin` (`username`, `password`, `superadmin`, `active`)
         VALUES (:username, :password_hashed, '1', :active)");
       $stmt->execute(array(
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/functions.app_passwd.inc.php b/mailcow/src/mailcow-dockerized/data/web/inc/functions.app_passwd.inc.php
index 8c8ad18..b493fc9 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/functions.app_passwd.inc.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/functions.app_passwd.inc.php
@@ -27,6 +27,13 @@
       $password = $_data['app_passwd'];
       $password2 = $_data['app_passwd2'];
       $active = intval($_data['active']);
+      $protocols = (array)$_data['protocols'];
+      $imap_access = (in_array('imap_access', $protocols)) ? 1 : 0;
+      $dav_access = (in_array('dav_access', $protocols)) ? 1 : 0;
+      $smtp_access = (in_array('smtp_access', $protocols)) ? 1 : 0;
+      $eas_access = (in_array('eas_access', $protocols)) ? 1 : 0;
+      $pop3_access = (in_array('pop3_access', $protocols)) ? 1 : 0;
+      $sieve_access = (in_array('sieve_access', $protocols)) ? 1 : 0;
       $domain = mailbox('get', 'mailbox_details', $username)['domain'];
       if (empty($domain)) {
         $_SESSION['return'][] = array(
@@ -61,13 +68,19 @@
         );
         return false;
       }
-      $stmt = $pdo->prepare("INSERT INTO `app_passwd` (`name`, `mailbox`, `domain`, `password`, `active`)
-        VALUES (:app_name, :mailbox, :domain, :password, :active)");
+      $stmt = $pdo->prepare("INSERT INTO `app_passwd` (`name`, `mailbox`, `domain`, `password`, `imap_access`, `smtp_access`, `eas_access`, `dav_access`, `pop3_access`, `sieve_access`, `active`)
+        VALUES (:app_name, :mailbox, :domain, :password, :imap_access, :smtp_access, :eas_access, :dav_access, :pop3_access, :sieve_access, :active)");
       $stmt->execute(array(
         ':app_name' => $app_name,
         ':mailbox' => $username,
         ':domain' => $domain,
         ':password' => $password_hashed,
+        ':imap_access' => $imap_access,
+        ':smtp_access' => $smtp_access,
+        ':eas_access' => $eas_access,
+        ':dav_access' => $dav_access,
+        ':pop3_access' => $pop3_access,
+        ':sieve_access' => $sieve_access,
         ':active' => $active
       ));
       $_SESSION['return'][] = array(
@@ -84,6 +97,23 @@
           $app_name = (!empty($_data['app_name'])) ? $_data['app_name'] : $is_now['name'];
           $password = (!empty($_data['password'])) ? $_data['password'] : null;
           $password2 = (!empty($_data['password2'])) ? $_data['password2'] : null;
+          if (isset($_data['protocols'])) {
+            $protocols = (array)$_data['protocols'];
+            $imap_access = (in_array('imap_access', $protocols)) ? 1 : 0;
+            $dav_access = (in_array('dav_access', $protocols)) ? 1 : 0;
+            $smtp_access = (in_array('smtp_access', $protocols)) ? 1 : 0;
+            $eas_access = (in_array('eas_access', $protocols)) ? 1 : 0;
+            $pop3_access = (in_array('pop3_access', $protocols)) ? 1 : 0;
+            $sieve_access = (in_array('sieve_access', $protocols)) ? 1 : 0;
+          }
+          else {
+            $imap_access = $is_now['imap_access'];
+            $smtp_access = $is_now['smtp_access'];
+            $dav_access = $is_now['dav_access'];
+            $eas_access = $is_now['eas_access'];
+            $pop3_access = $is_now['pop3_access'];
+            $sieve_access = $is_now['sieve_access'];
+          }
           $active = (isset($_data['active'])) ? intval($_data['active']) : $is_now['active'];
         }
         else {
@@ -122,21 +152,34 @@
             ':id' => $id
           ));
         }
+
         $stmt = $pdo->prepare("UPDATE `app_passwd` SET
           `name` = :app_name,
           `mailbox` = :username,
+          `imap_access` = :imap_access,
+          `smtp_access` = :smtp_access,
+          `eas_access` = :eas_access,
+          `dav_access` = :dav_access,
+          `pop3_access` = :pop3_access,
+          `sieve_access` = :sieve_access,
           `active` = :active
             WHERE `id` = :id");
         $stmt->execute(array(
           ':app_name' => $app_name,
           ':username' => $username,
+          ':imap_access' => $imap_access,
+          ':smtp_access' => $smtp_access,
+          ':eas_access' => $eas_access,
+          ':dav_access' => $dav_access,
+          ':pop3_access' => $pop3_access,
+          ':sieve_access' => $sieve_access,
           ':active' => $active,
           ':id' => $id
         ));
         $_SESSION['return'][] = array(
           'type' => 'success',
           'log' => array(__FUNCTION__, $_action, $_data_log),
-          'msg' => array('object_modified', htmlspecialchars($ids))
+          'msg' => array('object_modified', htmlspecialchars(implode(', ', $ids)))
         );
       }
     break;
@@ -180,16 +223,10 @@
     break;
     case 'details':
       $app_passwd_data = array();
-      $stmt = $pdo->prepare("SELECT `id`,
-        `name`,
-        `mailbox`,
-        `domain`,
-        `created`,
-        `modified`,
-        `active`
+      $stmt = $pdo->prepare("SELECT *
           FROM `app_passwd`
             WHERE `id` = :id");
-      $stmt->execute(array(':id' => $_data['id']));
+      $stmt->execute(array(':id' => $_data));
       $app_passwd_data = $stmt->fetch(PDO::FETCH_ASSOC);
       if (empty($app_passwd_data)) {
         return false;
@@ -202,4 +239,4 @@
       return $app_passwd_data;
     break;
   }
-}
\ No newline at end of file
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/functions.customize.inc.php b/mailcow/src/mailcow-dockerized/data/web/inc/functions.customize.inc.php
index d594822..de1b22c 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/functions.customize.inc.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/functions.customize.inc.php
@@ -234,8 +234,9 @@
             $img_data = explode('base64,', customize('get', 'main_logo'));
             if ($img_data[1]) {
               $image->readImageBlob(base64_decode($img_data[1]));
+              return $image->identifyImage();
             }
-            return $image->identifyImage();
+            return false;
           }
           catch (ImagickException $e) {
             $_SESSION['return'][] = array(
@@ -249,4 +250,4 @@
       }
     break;
   }
-}
\ No newline at end of file
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/functions.dkim.inc.php b/mailcow/src/mailcow-dockerized/data/web/inc/functions.dkim.inc.php
index 33ee49f..85d3c6c 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/functions.dkim.inc.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/functions.dkim.inc.php
@@ -5,14 +5,6 @@
   global $lang;
   switch ($_action) {
     case 'add':
-      if ($_SESSION['mailcow_cc_role'] != "admin") {
-        $_SESSION['return'][] = array(
-          'type' => 'danger',
-          'log' => array(__FUNCTION__, $_action, $_data, ),
-          'msg' => 'access_denied'
-        );
-        return false;
-      }
       $key_length = intval($_data['key_size']);
       $dkim_selector = (isset($_data['dkim_selector'])) ? $_data['dkim_selector'] : 'dkim';
       $domains = array_map('trim', preg_split( "/( |,|;|\n)/", $_data['domains']));
@@ -42,6 +34,14 @@
           );
           continue;
         }
+        if (!hasDomainAccess($_SESSION['mailcow_cc_username'], $_SESSION['mailcow_cc_role'], $domain)) {
+          $_SESSION['return'][] = array(
+            'type' => 'danger',
+            'log' => array(__FUNCTION__, $_action, $_data),
+            'msg' => array('access_denied', $domain)
+          );
+          continue;
+        }
         $config = array(
           "digest_alg" => "sha256",
           "private_key_bits" => $key_length,
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/functions.inc.php b/mailcow/src/mailcow-dockerized/data/web/inc/functions.inc.php
index 142a9fe..7ac0af5 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/functions.inc.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/functions.inc.php
@@ -258,7 +258,7 @@
   switch ($action) {
     case 'get':
       if (filter_var($username, FILTER_VALIDATE_EMAIL) && hasMailboxObjectAccess($_SESSION['mailcow_cc_username'], $_SESSION['mailcow_cc_role'], $username)) {
-        $stmt = $pdo->prepare('SELECT `real_rip`, MAX(`datetime`) as `datetime`, `service`, `app_password` FROM `sasl_log`
+        $stmt = $pdo->prepare('SELECT `real_rip`, MAX(`datetime`) as `datetime`, `service`, `app_password`, MAX(`app_passwd`.`name`) as `app_password_name` FROM `sasl_log`
           LEFT OUTER JOIN `app_passwd` on `sasl_log`.`app_password` = `app_passwd`.`id`
           WHERE `username` = :username
             AND HOUR(TIMEDIFF(NOW(), `datetime`)) < :sasl_limit_days
@@ -807,10 +807,11 @@
   }
   return false;
 }
-function check_login($user, $pass) {
+function check_login($user, $pass, $app_passwd_data = false) {
   global $pdo;
   global $redis;
   global $imap_server;
+
   if (!filter_var($user, FILTER_VALIDATE_EMAIL) && !ctype_alnum(str_replace(array('_', '.', '-'), '', $user))) {
     $_SESSION['return'][] =  array(
       'type' => 'danger',
@@ -819,6 +820,8 @@
     );
     return false;
   }
+
+  // Validate admin
   $user = strtolower(trim($user));
   $stmt = $pdo->prepare("SELECT `password` FROM `admin`
       WHERE `superadmin` = '1'
@@ -854,6 +857,8 @@
       }
     }
   }
+
+  // Validate domain admin
   $stmt = $pdo->prepare("SELECT `password` FROM `admin`
       WHERE `superadmin` = '0'
       AND `active`='1'
@@ -888,6 +893,8 @@
       }
     }
   }
+
+  // Validate mailbox user
   $stmt = $pdo->prepare("SELECT `password` FROM `mailbox`
       INNER JOIN domain on mailbox.domain = domain.domain
       WHERE `kind` NOT REGEXP 'location|thing|group'
@@ -896,6 +903,32 @@
         AND `username` = :user");
   $stmt->execute(array(':user' => $user));
   $rows = $stmt->fetchAll(PDO::FETCH_ASSOC);
+  if ($app_passwd_data['eas'] === true) {
+    $stmt = $pdo->prepare("SELECT `app_passwd`.`password` as `password`, `app_passwd`.`id` as `app_passwd_id` FROM `app_passwd`
+        INNER JOIN `mailbox` ON `mailbox`.`username` = `app_passwd`.`mailbox`
+        INNER JOIN `domain` ON `mailbox`.`domain` = `domain`.`domain`
+        WHERE `mailbox`.`kind` NOT REGEXP 'location|thing|group'
+          AND `mailbox`.`active` = '1'
+          AND `domain`.`active` = '1'
+          AND `app_passwd`.`active` = '1'
+          AND `app_passwd`.`eas_access` = '1'
+          AND `app_passwd`.`mailbox` = :user");
+    $stmt->execute(array(':user' => $user));
+    $rows = array_merge($rows, $stmt->fetchAll(PDO::FETCH_ASSOC));
+  }
+  elseif ($app_passwd_data['dav'] === true) {
+    $stmt = $pdo->prepare("SELECT `app_passwd`.`password` as `password`, `app_passwd`.`id` as `app_passwd_id` FROM `app_passwd`
+        INNER JOIN `mailbox` ON `mailbox`.`username` = `app_passwd`.`mailbox`
+        INNER JOIN `domain` ON `mailbox`.`domain` = `domain`.`domain`
+        WHERE `mailbox`.`kind` NOT REGEXP 'location|thing|group'
+          AND `mailbox`.`active` = '1'
+          AND `domain`.`active` = '1'
+          AND `app_passwd`.`active` = '1'
+          AND `app_passwd`.`dav_access` = '1'
+          AND `app_passwd`.`mailbox` = :user");
+    $stmt->execute(array(':user' => $user));
+    $rows = array_merge($rows, $stmt->fetchAll(PDO::FETCH_ASSOC));
+  }
   foreach ($rows as $row) {
     if (verify_hash($row['password'], $pass) !== false) {
       unset($_SESSION['ldelay']);
@@ -904,9 +937,20 @@
         'log' => array(__FUNCTION__, $user, '*'),
         'msg' => array('logged_in_as', $user)
       );
+      if ($app_passwd_data['eas'] === true || $app_passwd_data['dav'] === true) {
+        $service = ($app_passwd_data['eas'] === true) ? 'EAS' : 'DAV';
+        $stmt = $pdo->prepare("REPLACE INTO sasl_log (`service`, `app_password`, `username`, `real_rip`) VALUES (:service, :app_id, :username, :remote_addr)");
+        $stmt->execute(array(
+          ':service' => $service,
+          ':app_id' => $row['app_passwd_id'],
+          ':username' => $user,
+          ':remote_addr' => ($_SERVER['HTTP_X_REAL_IP'] ?? $_SERVER['REMOTE_ADDR'])
+        ));
+      }
       return "user";
     }
   }
+
   if (!isset($_SESSION['ldelay'])) {
     $_SESSION['ldelay'] = "0";
     $redis->publish("F2B_CHANNEL", "mailcow UI: Invalid password for " . $user . " by " . $_SERVER['REMOTE_ADDR']);
@@ -917,11 +961,13 @@
     $redis->publish("F2B_CHANNEL", "mailcow UI: Invalid password for " . $user . " by " . $_SERVER['REMOTE_ADDR']);
     error_log("mailcow UI: Invalid password for " . $user . " by " . $_SERVER['REMOTE_ADDR']);
   }
+
   $_SESSION['return'][] =  array(
     'type' => 'danger',
     'log' => array(__FUNCTION__, $user, '*'),
     'msg' => 'login_failed'
   );
+
   sleep($_SESSION['ldelay']);
   return false;
 }
@@ -1222,8 +1268,8 @@
     case "totp":
       $key_id = (!isset($_data["key_id"])) ? 'unidentified' : $_data["key_id"];
       if ($tfa->verifyCode($_POST['totp_secret'], $_POST['totp_confirm_token']) === true) {
-        $stmt = $pdo->prepare("DELETE FROM `tfa` WHERE `username` = :username");
-        $stmt->execute(array(':username' => $username));
+        //$stmt = $pdo->prepare("DELETE FROM `tfa` WHERE `username` = :username");
+        //$stmt->execute(array(':username' => $username));
         $stmt = $pdo->prepare("INSERT INTO `tfa` (`username`, `key_id`, `authmech`, `secret`, `active`) VALUES (?, ?, 'totp', ?, '1')");
         $stmt->execute(array($username, $key_id, $_POST['totp_secret']));
         $_SESSION['return'][] =  array(
@@ -1610,15 +1656,17 @@
           AND `authmech` = 'totp'
           AND `active`='1'");
       $stmt->execute(array(':username' => $username));
-      $row = $stmt->fetch(PDO::FETCH_ASSOC);
-      if ($tfa->verifyCode($row['secret'], $_POST['token']) === true) {
-        $_SESSION['tfa_id'] = $row['id'];
-        $_SESSION['return'][] =  array(
-          'type' => 'success',
-          'log' => array(__FUNCTION__, $username, '*'),
-          'msg' => 'verified_totp_login'
-        );
-        return true;
+      $rows = $stmt->fetchAll(PDO::FETCH_ASSOC);
+      foreach ($rows as $row) {
+        if ($tfa->verifyCode($row['secret'], $_POST['token']) === true) {
+          $_SESSION['tfa_id'] = $row['id'];
+          $_SESSION['return'][] =  array(
+            'type' => 'success',
+            'log' => array(__FUNCTION__, $username, '*'),
+            'msg' => 'verified_totp_login'
+          );
+          return true;
+        }
       }
       $_SESSION['return'][] =  array(
         'type' => 'danger',
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/functions.mailbox.inc.php b/mailcow/src/mailcow-dockerized/data/web/inc/functions.mailbox.inc.php
index 24e5dab..21b6b13 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/functions.mailbox.inc.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/functions.mailbox.inc.php
@@ -579,6 +579,9 @@
           if (!empty(intval($_data['rl_value']))) {
             ratelimit('edit', 'domain', array('rl_value' => $_data['rl_value'], 'rl_frame' => $_data['rl_frame'], 'object' => $domain));
           }
+          if (!empty($_data['key_size']) && !empty($_data['dkim_selector'])) {
+            dkim('add', array('key_size' => $_data['key_size'], 'dkim_selector' => $_data['dkim_selector'], 'domains' => $domain));
+          }
           if (!empty($restart_sogo)) {
             $restart_response = json_decode(docker('post', 'sogo-mailcow', 'restart'), true);
             if ($restart_response['type'] == "success") {
@@ -906,6 +909,9 @@
             if (!empty(intval($_data['rl_value']))) {
               ratelimit('edit', 'domain', array('rl_value' => $_data['rl_value'], 'rl_frame' => $_data['rl_frame'], 'object' => $alias_domain));
             }
+            if (!empty($_data['key_size']) && !empty($_data['dkim_selector'])) {
+              dkim('add', array('key_size' => $_data['key_size'], 'dkim_selector' => $_data['dkim_selector'], 'domains' => $alias_domain));
+            }
             $_SESSION['return'][] = array(
               'type' => 'success',
               'log' => array(__FUNCTION__, $_action, $_type, $_data_log, $_attr),
@@ -956,6 +962,7 @@
           $imap_access = (isset($_data['imap_access'])) ? intval($_data['imap_access']) : intval($MAILBOX_DEFAULT_ATTRIBUTES['imap_access']);
           $pop3_access = (isset($_data['pop3_access'])) ? intval($_data['pop3_access']) : intval($MAILBOX_DEFAULT_ATTRIBUTES['pop3_access']);
           $smtp_access = (isset($_data['smtp_access'])) ? intval($_data['smtp_access']) : intval($MAILBOX_DEFAULT_ATTRIBUTES['smtp_access']);
+          $sieve_access = (isset($_data['sieve_access'])) ? intval($_data['sieve_access']) : intval($MAILBOX_DEFAULT_ATTRIBUTES['sieve_access']);
           $relayhost = (isset($_data['relayhost'])) ? intval($_data['relayhost']) : 0;
           $quarantine_notification = (isset($_data['quarantine_notification'])) ? strval($_data['quarantine_notification']) : strval($MAILBOX_DEFAULT_ATTRIBUTES['quarantine_notification']);
           $quarantine_category = (isset($_data['quarantine_category'])) ? strval($_data['quarantine_category']) : strval($MAILBOX_DEFAULT_ATTRIBUTES['quarantine_category']);
@@ -969,6 +976,7 @@
               'imap_access' => strval($imap_access),
               'pop3_access' => strval($pop3_access),
               'smtp_access' => strval($smtp_access),
+              'sieve_access' => strval($sieve_access),
               'relayhost' => strval($relayhost),
               'passwd_update' => time(),
               'mailbox_format' => strval($MAILBOX_DEFAULT_ATTRIBUTES['mailbox_format']),
@@ -1673,6 +1681,7 @@
               $user1 = (!empty($_data['user1'])) ? $_data['user1'] : $is_now['user1'];
               $active = (isset($_data['active'])) ? intval($_data['active']) : $is_now['active'];
               $last_run = (isset($_data['last_run'])) ? NULL : $is_now['last_run'];
+              $success = (isset($_data['success'])) ? NULL : $is_now['success'];
               $delete2duplicates = (isset($_data['delete2duplicates'])) ? intval($_data['delete2duplicates']) : $is_now['delete2duplicates'];
               $subscribeall = (isset($_data['subscribeall'])) ? intval($_data['subscribeall']) : $is_now['subscribeall'];
               $delete1 = (isset($_data['delete1'])) ? intval($_data['delete1']) : $is_now['delete1'];
@@ -1768,6 +1777,7 @@
               `exclude` = :exclude,
               `host1` = :host1,
               `last_run` = :last_run,
+              `success` = :success,
               `user1` = :user1,
               `password1` = :password1,
               `mins_interval` = :mins_interval,
@@ -1794,6 +1804,7 @@
               ':user1' => $user1,
               ':password1' => $password1,
               ':last_run' => $last_run,
+              ':success' => $success,
               ':mins_interval' => $mins_interval,
               ':port1' => $port1,
               ':enc1' => $enc1,
@@ -2328,17 +2339,20 @@
             }
             $is_now = mailbox('get', 'mailbox_details', $username);
             if (isset($_data['protocol_access'])) {
+              $_data['protocol_access'] = (array)$_data['protocol_access'];
               $_data['imap_access'] = (in_array('imap', $_data['protocol_access'])) ? 1 : 0;
               $_data['pop3_access'] = (in_array('pop3', $_data['protocol_access'])) ? 1 : 0;
               $_data['smtp_access'] = (in_array('smtp', $_data['protocol_access'])) ? 1 : 0;
+              $_data['sieve_access'] = (in_array('sieve', $_data['protocol_access'])) ? 1 : 0;
             }
             if (!empty($is_now)) {
               $active     = (isset($_data['active'])) ? intval($_data['active']) : $is_now['active'];
               (int)$force_pw_update = (isset($_data['force_pw_update'])) ? intval($_data['force_pw_update']) : intval($is_now['attributes']['force_pw_update']);
-              (int)$sogo_access = (isset($_data['sogo_access']) && isset($_SESSION['acl']['protocol_access']) && $_SESSION['acl']['protocol_access'] == "1") ? intval($_data['sogo_access']) : intval($is_now['attributes']['sogo_access']);
+              (int)$sogo_access = (isset($_data['sogo_access']) && isset($_SESSION['acl']['sogo_access']) && $_SESSION['acl']['sogo_access'] == "1") ? intval($_data['sogo_access']) : intval($is_now['attributes']['sogo_access']);
               (int)$imap_access = (isset($_data['imap_access']) && isset($_SESSION['acl']['protocol_access']) && $_SESSION['acl']['protocol_access'] == "1") ? intval($_data['imap_access']) : intval($is_now['attributes']['imap_access']);
               (int)$pop3_access = (isset($_data['pop3_access']) && isset($_SESSION['acl']['protocol_access']) && $_SESSION['acl']['protocol_access'] == "1") ? intval($_data['pop3_access']) : intval($is_now['attributes']['pop3_access']);
               (int)$smtp_access = (isset($_data['smtp_access']) && isset($_SESSION['acl']['protocol_access']) && $_SESSION['acl']['protocol_access'] == "1") ? intval($_data['smtp_access']) : intval($is_now['attributes']['smtp_access']);
+              (int)$sieve_access = (isset($_data['sieve_access']) && isset($_SESSION['acl']['protocol_access']) && $_SESSION['acl']['protocol_access'] == "1") ? intval($_data['sieve_access']) : intval($is_now['attributes']['sieve_access']);
               (int)$relayhost = (isset($_data['relayhost']) && isset($_SESSION['acl']['mailbox_relayhost']) && $_SESSION['acl']['mailbox_relayhost'] == "1") ? intval($_data['relayhost']) : intval($is_now['attributes']['relayhost']);
               (int)$quota_m = (isset_has_content($_data['quota'])) ? intval($_data['quota']) : ($is_now['quota'] / 1048576);
               $name       = (!empty($_data['name'])) ? ltrim(rtrim($_data['name'], '>'), '<') : $is_now['name'];
@@ -2604,6 +2618,7 @@
                 `attributes` = JSON_SET(`attributes`, '$.force_pw_update', :force_pw_update),
                 `attributes` = JSON_SET(`attributes`, '$.sogo_access', :sogo_access),
                 `attributes` = JSON_SET(`attributes`, '$.imap_access', :imap_access),
+                `attributes` = JSON_SET(`attributes`, '$.sieve_access', :sieve_access),
                 `attributes` = JSON_SET(`attributes`, '$.pop3_access', :pop3_access),
                 `attributes` = JSON_SET(`attributes`, '$.relayhost', :relayhost),
                 `attributes` = JSON_SET(`attributes`, '$.smtp_access', :smtp_access)
@@ -2616,6 +2631,7 @@
               ':sogo_access' => $sogo_access,
               ':imap_access' => $imap_access,
               ':pop3_access' => $pop3_access,
+              ':sieve_access' => $sieve_access,
               ':smtp_access' => $smtp_access,
               ':relayhost' => $relayhost,
               ':username' => $username
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/functions.rspamd.inc.php b/mailcow/src/mailcow-dockerized/data/web/inc/functions.rspamd.inc.php
index bdc23b0..fd1c5bd 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/functions.rspamd.inc.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/functions.rspamd.inc.php
@@ -77,7 +77,7 @@
         $_SESSION['return'][] = array(
           'type' => 'success',
           'log' => array(__FUNCTION__, $_action, $_data_log),
-          'msg' => array('object_modified', htmlspecialchars($ids))
+          'msg' => array('object_modified', htmlspecialchars(implode(',', $ids)))
         );
       }
     break;
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/functions.transports.inc.php b/mailcow/src/mailcow-dockerized/data/web/inc/functions.transports.inc.php
index 7b22917..05ad25d 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/functions.transports.inc.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/functions.transports.inc.php
@@ -262,7 +262,7 @@
       $destinations = array_filter(array_values(array_unique($destinations)));
       if (empty($destinations)) { return false; }
       if (isset($next_hop_matches[1])) {
-        if (in_array($next_hop_clean, $existing_nh)) {
+        if ($existing_nh !== null && in_array($next_hop_clean, $existing_nh)) {
           $_SESSION['return'][] = array(
             'type' => 'danger',
             'log' => array(__FUNCTION__, $_action, $_data_log),
@@ -379,7 +379,7 @@
           return false;
         }
         if (isset($next_hop_matches[1])) {
-          if (in_array($next_hop_clean, $existing_nh)) {
+          if ($existing_nh !== null && in_array($next_hop_clean, $existing_nh)) {
             $_SESSION['return'][] = array(
               'type' => 'danger',
               'log' => array(__FUNCTION__, $_action, $_data_log),
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/header.inc.php b/mailcow/src/mailcow-dockerized/data/web/inc/header.inc.php
index d97a388..6c783a0 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/header.inc.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/header.inc.php
@@ -1,148 +1,56 @@
-<!DOCTYPE html>
-<html lang="<?= $_SESSION['mailcow_locale'] ?>">
-<head>
-  <meta charset="utf-8">
-  <meta http-equiv="X-UA-Compatible" content="IE=edge">
-  <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=0">
-  <meta name="theme-color" content="#F5D76E"/>
-  <meta http-equiv="Referrer-Policy" content="same-origin">
-  <title><?=$UI_TEXTS['title_name'];?></title>
-  <?php
-    if (preg_match("/mailbox/i", $_SERVER['REQUEST_URI'])) {
-      $css_minifier->add('/web/css/site/mailbox.css');
-    }
-    if (preg_match("/admin/i", $_SERVER['REQUEST_URI'])) {
-      $css_minifier->add('/web/css/site/admin.css');
-    }
-    if (preg_match("/user/i", $_SERVER['REQUEST_URI'])) {
-      $css_minifier->add('/web/css/site/user.css');
-    }
-    if (preg_match("/edit/i", $_SERVER['REQUEST_URI'])) {
-      $css_minifier->add('/web/css/site/edit.css');
-    }
-    if (preg_match("/(quarantine|qhandler)/i", $_SERVER['REQUEST_URI'])) {
-      $css_minifier->add('/web/css/site/quarantine.css');
-    }
-    if (preg_match("/debug/i", $_SERVER['REQUEST_URI'])) {
-      $css_minifier->add('/web/css/site/debug.css');
-    }
-    if ($_SERVER['REQUEST_URI'] == '/') {
-      $css_minifier->add('/web/css/site/index.css');
-    }
+<?php
 
-  $hash = $css_minifier->getDataHash();
-  $CSSPath = '/tmp/' . $hash . '.css';
-  if(!file_exists($CSSPath)) {
-    $css_minifier->minify($CSSPath);
-    cleanupCSS($hash);
-  }
-  ?>
-  <link rel="stylesheet" href="/cache/<?=basename($CSSPath)?>">
-  <?php if (strtolower(trim($DEFAULT_THEME)) != "lumen") { ?>
-  <link rel="stylesheet" href="//cdnjs.cloudflare.com/ajax/libs/bootswatch/3.3.7/<?= strtolower(trim($DEFAULT_THEME)); ?>/bootstrap.min.css">
-  <?php } ?>
-  <link rel="shortcut icon" href="/favicon.png" type="image/png">
-  <link rel="icon" href="/favicon.png" type="image/png">
-</head>
-<body id="top">
-  <div class="overlay"></div>
-  <nav class="navbar navbar-default navbar-fixed-top" role="navigation">
-    <div class="container-fluid">
-      <div class="navbar-header">
-        <button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#navbar" aria-expanded="false" aria-controls="navbar">
-          <span class="icon-bar"></span>
-          <span class="icon-bar"></span>
-          <span class="icon-bar"></span>
-        </button>
-        <a class="navbar-brand" href="/"><img alt="mailcow-logo" src="<?=($main_logo = customize('get', 'main_logo')) ? $main_logo : '/img/cow_mailcow.svg';?>"></a>
-      </div>
-      <div id="navbar" class="navbar-collapse collapse">
-        <ul class="nav navbar-nav navbar-right">
-          <?php
-          if (isset($_SESSION['mailcow_locale'])) {
-          ?>
-          <li class="dropdown<?=(isset($_SESSION['mailcow_locale']) && count($AVAILABLE_LANGUAGES) === 1) ? ' lang-link-disabled"' : '' ?>">
-            <a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-expanded="false"><span class="flag-icon flag-icon-<?= $_SESSION['mailcow_locale']; ?>"></span><span class="caret"></span></a>
-            <ul class="dropdown-menu" role="menu">
-              <?php
-              foreach ($AVAILABLE_LANGUAGES as $c => $v) {
-              ?>
-              <li<?= ($_SESSION['mailcow_locale'] == $c) ? ' class="active"' : ''; ?>><a href="?<?= http_build_query(array_merge($_GET, array('lang' => $c))); ?>"><span class="flag-icon flag-icon-<?=$c;?>"></span> <?=$v;?></a></li>
-              <?php
-              }
-              ?>
-            </ul>
-          </li>
-          <?php
-          }
-          if (isset($_SESSION['mailcow_cc_role'])) {
-          ?>
-          <li class="dropdown">
-            <a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-expanded="false"><?= $lang['header']['mailcow_settings']; ?> <span class="caret"></span></a>
-            <ul class="dropdown-menu" role="menu">
-              <?php
-              if (isset($_SESSION['mailcow_cc_role'])) {
-                if ($_SESSION['mailcow_cc_role'] == 'admin') {
-                ?>
-                  <li<?= (preg_match("/admin/i", $_SERVER['REQUEST_URI'])) ? ' class="active"' : ''; ?>><a href="/admin"><?= $lang['header']['administration']; ?></a></li>
-                  <li<?= (preg_match("/debug/i", $_SERVER['REQUEST_URI'])) ? ' class="active"' : ''; ?>><a href="/debug"><?= $lang['header']['debug']; ?></a></li>
-                <?php
-                }
-                if ($_SESSION['mailcow_cc_role'] == 'admin' || $_SESSION['mailcow_cc_role'] == 'domainadmin') {
-                ?>
-                  <li<?= (preg_match("/mailbox/i", $_SERVER['REQUEST_URI'])) ? ' class="active"' : ''; ?>><a href="/mailbox"><?= $lang['header']['mailboxes']; ?></a></li>
-                <?php } if ($_SESSION['mailcow_cc_role'] != 'admin') { ?>
-                  <li<?= (preg_match("/user/i", $_SERVER['REQUEST_URI'])) ? ' class="active"' : ''; ?>><a href="/user"><?= $lang['header']['user_settings']; ?></a></li>
-                <?php
-                }
-              }
-              ?>
-            </ul>
-          </li>
-          <?php if (isset($_SESSION['mailcow_cc_role'])) { ?>
-          <li<?= (preg_match("/quarantine/i", $_SERVER['REQUEST_URI'])) ? ' class="active"' : ''; ?>><a href="/quarantine"><i class="bi bi-inbox-fill"></i> <?= $lang['header']['quarantine']; ?></a></li>
-          <?php } if ($_SESSION['mailcow_cc_role'] == 'admin' && getenv('SKIP_SOGO') != "y") { ?>
-          <li><a href data-toggle="modal" data-container="sogo-mailcow" data-target="#RestartContainer"><i class="bi bi-arrow-repeat"></i> <?= $lang['header']['restart_sogo']; ?></a></li>
-          <?php } ?>
-          <li class="dropdown">
-            <a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-expanded="false"><i class="bi bi-link-45deg"></i> <?=$UI_TEXTS['apps_name'];?> <span class="caret"></span></a>
-            <ul class="dropdown-menu" role="menu">
-            <?php foreach ($MAILCOW_APPS as $app) {
-              if (getenv('SKIP_SOGO') == "y" && preg_match('/^\/SOGo/i', $app['link'])) { continue; }
-            ?>
-              <li title="<?=(isset($app['description'])) ? htmlspecialchars($app['description']) : '';?>"><a href="<?=(isset($app['link'])) ? htmlspecialchars($app['link']) : '';?>"><?=(isset($app['name'])) ? htmlspecialchars($app['name']) : '';?></a></li>
-            <?php
-            }
-            $app_links = customize('get', 'app_links');
-            if ($app_links) {
-              foreach ($app_links as $row) {
-                foreach ($row as $key => $val) {
-              ?>
-              <li><a href="<?= htmlspecialchars($val); ?>"><?= htmlspecialchars($key); ?></a></li>
-              <?php
-                }
-              }
-            }
-            ?>
-            </ul>
-          </li>
-          <?php } if (!isset($_SESSION['dual-login']) && isset($_SESSION['mailcow_cc_username'])) { ?>
-            <li class="logged-in-as"><a href="#" onclick="logout.submit()"><b class="username-lia"><?= htmlspecialchars($_SESSION['mailcow_cc_username']); ?></b> <i class="bi bi-power"></i></a></li>
-          <?php } elseif (isset($_SESSION['dual-login'])) { ?>
-            <li class="logged-in-as"><a href="#" onclick="logout.submit()"><b class="username-lia"><?= htmlspecialchars($_SESSION['mailcow_cc_username']); ?> <span class="text-info">(<?= htmlspecialchars($_SESSION['dual-login']['username']); ?>)</span> </b><i class="bi bi-power"></i></a></li>
-          <?php } if (!preg_match('/y|yes/i', getenv('MASTER'))) { ?>
-            <li class="text-warning slave-info">[ slave ]</li>
-          <?php } ?>
-        </ul>
-      </div><!--/.nav-collapse -->
-    </div><!--/.container-fluid -->
-  </nav>
-  <form action="/" method="post" id="logout"><input type="hidden" name="logout"></form>
-  <?php if (!empty($UI_TEXTS['ui_announcement_text']) &&
-    in_array($UI_TEXTS['ui_announcement_type'], array('info', 'warning', 'danger')) &&
-    $UI_TEXTS['ui_announcement_active'] == 1 &&
-    parse_url($_SERVER['REQUEST_URI'], PHP_URL_PATH) != '/') { ?>
-  <div class="container">
-    <div class="alert alert-<?=$UI_TEXTS['ui_announcement_type'];?>"><?=$UI_TEXTS['ui_announcement_text'];?></div>
-  </div>
-  <?php } ?>
+// CSS
+if (preg_match("/mailbox/i", $_SERVER['REQUEST_URI'])) {
+  $css_minifier->add('/web/css/site/mailbox.css');
+}
+if (preg_match("/admin/i", $_SERVER['REQUEST_URI'])) {
+  $css_minifier->add('/web/css/site/admin.css');
+}
+if (preg_match("/user/i", $_SERVER['REQUEST_URI'])) {
+  $css_minifier->add('/web/css/site/user.css');
+}
+if (preg_match("/edit/i", $_SERVER['REQUEST_URI'])) {
+  $css_minifier->add('/web/css/site/edit.css');
+}
+if (preg_match("/(quarantine|qhandler)/i", $_SERVER['REQUEST_URI'])) {
+  $css_minifier->add('/web/css/site/quarantine.css');
+}
+if (preg_match("/debug/i", $_SERVER['REQUEST_URI'])) {
+  $css_minifier->add('/web/css/site/debug.css');
+}
+if ($_SERVER['REQUEST_URI'] == '/') {
+  $css_minifier->add('/web/css/site/index.css');
+}
+
+$hash = $css_minifier->getDataHash();
+$CSSPath = '/tmp/' . $hash . '.css';
+if(!file_exists($CSSPath)) {
+  $css_minifier->minify($CSSPath);
+  cleanupCSS($hash);
+}
+
+$globalVariables = [
+  'mailcow_hostname' => getenv('MAILCOW_HOSTNAME'),
+  'mailcow_locale' => @$_SESSION['mailcow_locale'],
+  'mailcow_cc_role' => @$_SESSION['mailcow_cc_role'],
+  'mailcow_cc_username' => @$_SESSION['mailcow_cc_username'],
+  'is_master' => preg_match('/y|yes/i', getenv('MASTER')),
+  'dual_login' => @$_SESSION['dual-login'],
+  'ui_texts' => $UI_TEXTS,
+  'css_path' => '/cache/'.basename($CSSPath),
+  'theme' => strtolower(trim($DEFAULT_THEME)),
+  'logo' => customize('get', 'main_logo'),
+  'available_languages' => $AVAILABLE_LANGUAGES,
+  'lang' => $lang,
+  'skip_sogo' => (getenv('SKIP_SOGO') == 'y'),
+  'allow_admin_email_login' => (getenv('ALLOW_ADMIN_EMAIL_LOGIN') == 'n'),
+  'mailcow_apps' => $MAILCOW_APPS,
+  'app_links' => customize('get', 'app_links'),
+  'is_root_uri' => (parse_url($_SERVER['REQUEST_URI'], PHP_URL_PATH) == '/'),
+  'uri' => $_SERVER['REQUEST_URI'],
+];
+
+foreach ($globalVariables as $globalVariableName => $globalVariableValue) {
+  $twig->addGlobal($globalVariableName, $globalVariableValue);
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/init_db.inc.php b/mailcow/src/mailcow-dockerized/data/web/inc/init_db.inc.php
index c43afbf..60a8ead 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/init_db.inc.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/init_db.inc.php
@@ -3,7 +3,7 @@
   try {
     global $pdo;
 
-    $db_version = "01072021_0630";
+    $db_version = "31102021_0620";
 
     $stmt = $pdo->query("SHOW TABLES LIKE 'versions'");
     $num_results = count($stmt->fetchAll(PDO::FETCH_ASSOC));
@@ -364,6 +364,12 @@
           "password" => "VARCHAR(255) NOT NULL",
           "created" => "DATETIME(0) NOT NULL DEFAULT NOW(0)",
           "modified" => "DATETIME ON UPDATE CURRENT_TIMESTAMP",
+          "imap_access" => "TINYINT(1) NOT NULL DEFAULT '1'",
+          "smtp_access" => "TINYINT(1) NOT NULL DEFAULT '1'",
+          "dav_access" => "TINYINT(1) NOT NULL DEFAULT '1'",
+          "eas_access" => "TINYINT(1) NOT NULL DEFAULT '1'",
+          "pop3_access" => "TINYINT(1) NOT NULL DEFAULT '1'",
+          "sieve_access" => "TINYINT(1) NOT NULL DEFAULT '1'",
           "active" => "TINYINT(1) NOT NULL DEFAULT '1'"
         ),
         "keys" => array(
@@ -632,6 +638,8 @@
           "is_running" => "TINYINT(1) NOT NULL DEFAULT '0'",
           "returned_text" => "LONGTEXT",
           "last_run" => "TIMESTAMP NULL DEFAULT NULL",
+          "success" => "TINYINT(1) UNSIGNED DEFAULT NULL",
+          "exit_status" => "VARCHAR(50) DEFAULT NULL",
           "created" => "DATETIME(0) NOT NULL DEFAULT NOW(0)",
           "modified" => "DATETIME ON UPDATE CURRENT_TIMESTAMP",
           "active" => "TINYINT(1) NOT NULL DEFAULT '0'"
@@ -1210,6 +1218,7 @@
     $pdo->query("UPDATE `mailbox` SET `attributes` =  JSON_SET(`attributes`, '$.passwd_update', \"0\") WHERE JSON_VALUE(`attributes`, '$.passwd_update') IS NULL;");
     $pdo->query("UPDATE `mailbox` SET `attributes` =  JSON_SET(`attributes`, '$.relayhost', \"0\") WHERE JSON_VALUE(`attributes`, '$.relayhost') IS NULL;");
     $pdo->query("UPDATE `mailbox` SET `attributes` =  JSON_SET(`attributes`, '$.force_pw_update', \"0\") WHERE JSON_VALUE(`attributes`, '$.force_pw_update') IS NULL;");
+    $pdo->query("UPDATE `mailbox` SET `attributes` =  JSON_SET(`attributes`, '$.sieve_access', \"1\") WHERE JSON_VALUE(`attributes`, '$.sieve_access') IS NULL;");
     $pdo->query("UPDATE `mailbox` SET `attributes` =  JSON_SET(`attributes`, '$.sogo_access', \"1\") WHERE JSON_VALUE(`attributes`, '$.sogo_access') IS NULL;");
     $pdo->query("UPDATE `mailbox` SET `attributes` =  JSON_SET(`attributes`, '$.imap_access', \"1\") WHERE JSON_VALUE(`attributes`, '$.imap_access') IS NULL;");
     $pdo->query("UPDATE `mailbox` SET `attributes` =  JSON_SET(`attributes`, '$.pop3_access', \"1\") WHERE JSON_VALUE(`attributes`, '$.pop3_access') IS NULL;");
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/composer.json b/mailcow/src/mailcow-dockerized/data/web/inc/lib/composer.json
index e7e6b68..78033ec 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/composer.json
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/composer.json
@@ -9,6 +9,7 @@
         "matthiasmullie/minify": "^1.3",
         "bshaffer/oauth2-server-php": "^1.11",
         "mustangostang/spyc": "^0.6.3",
-        "directorytree/ldaprecord": "^2.4"
+        "directorytree/ldaprecord": "^2.4",
+        "twig/twig": "^3.0"
     }
 }
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/composer.lock b/mailcow/src/mailcow-dockerized/data/web/inc/lib/composer.lock
index e2633cc..b150752 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/composer.lock
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/composer.lock
@@ -4,7 +4,7 @@
         "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
         "This file is @generated automatically"
     ],
-    "content-hash": "50acd623ff29bb513cd29819f4537aa0",
+    "content-hash": "139c1e5dec323144cd778ce80fd1847e",
     "packages": [
         {
             "name": "bshaffer/oauth2-server-php",
@@ -62,10 +62,6 @@
                 "oauth",
                 "oauth2"
             ],
-            "support": {
-                "issues": "https://github.com/bshaffer/oauth2-server-php/issues",
-                "source": "https://github.com/bshaffer/oauth2-server-php/tree/master"
-            },
             "time": "2018-12-04T00:29:32+00:00"
         },
         {
@@ -388,10 +384,6 @@
                 "paths",
                 "relative"
             ],
-            "support": {
-                "issues": "https://github.com/matthiasmullie/path-converter/issues",
-                "source": "https://github.com/matthiasmullie/path-converter/tree/1.1.3"
-            },
             "time": "2019-02-05T23:41:09+00:00"
         },
         {
@@ -1022,11 +1014,6 @@
                 "php",
                 "text"
             ],
-            "support": {
-                "email": "support@jevon.org",
-                "issues": "https://github.com/soundasleep/html2text/issues",
-                "source": "https://github.com/soundasleep/html2text/tree/master"
-            },
             "time": "2017-04-19T22:01:50+00:00"
         },
         {
@@ -1097,6 +1084,85 @@
             "time": "2021-03-23T23:28:01+00:00"
         },
         {
+            "name": "symfony/polyfill-ctype",
+            "version": "v1.23.0",
+            "source": {
+                "type": "git",
+                "url": "https://github.com/symfony/polyfill-ctype.git",
+                "reference": "46cd95797e9df938fdd2b03693b5fca5e64b01ce"
+            },
+            "dist": {
+                "type": "zip",
+                "url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/46cd95797e9df938fdd2b03693b5fca5e64b01ce",
+                "reference": "46cd95797e9df938fdd2b03693b5fca5e64b01ce",
+                "shasum": ""
+            },
+            "require": {
+                "php": ">=7.1"
+            },
+            "suggest": {
+                "ext-ctype": "For best performance"
+            },
+            "type": "library",
+            "extra": {
+                "branch-alias": {
+                    "dev-main": "1.23-dev"
+                },
+                "thanks": {
+                    "name": "symfony/polyfill",
+                    "url": "https://github.com/symfony/polyfill"
+                }
+            },
+            "autoload": {
+                "psr-4": {
+                    "Symfony\\Polyfill\\Ctype\\": ""
+                },
+                "files": [
+                    "bootstrap.php"
+                ]
+            },
+            "notification-url": "https://packagist.org/downloads/",
+            "license": [
+                "MIT"
+            ],
+            "authors": [
+                {
+                    "name": "Gert de Pagter",
+                    "email": "BackEndTea@gmail.com"
+                },
+                {
+                    "name": "Symfony Community",
+                    "homepage": "https://symfony.com/contributors"
+                }
+            ],
+            "description": "Symfony polyfill for ctype functions",
+            "homepage": "https://symfony.com",
+            "keywords": [
+                "compatibility",
+                "ctype",
+                "polyfill",
+                "portable"
+            ],
+            "support": {
+                "source": "https://github.com/symfony/polyfill-ctype/tree/v1.23.0"
+            },
+            "funding": [
+                {
+                    "url": "https://symfony.com/sponsor",
+                    "type": "custom"
+                },
+                {
+                    "url": "https://github.com/fabpot",
+                    "type": "github"
+                },
+                {
+                    "url": "https://tidelift.com/funding/github/packagist/symfony/symfony",
+                    "type": "tidelift"
+                }
+            ],
+            "time": "2021-02-19T12:13:01+00:00"
+        },
+        {
             "name": "symfony/polyfill-mbstring",
             "version": "v1.23.1",
             "source": {
@@ -1575,6 +1641,82 @@
             "time": "2021-03-29T21:29:00+00:00"
         },
         {
+            "name": "twig/twig",
+            "version": "v3.3.2",
+            "source": {
+                "type": "git",
+                "url": "https://github.com/twigphp/Twig.git",
+                "reference": "21578f00e83d4a82ecfa3d50752b609f13de6790"
+            },
+            "dist": {
+                "type": "zip",
+                "url": "https://api.github.com/repos/twigphp/Twig/zipball/21578f00e83d4a82ecfa3d50752b609f13de6790",
+                "reference": "21578f00e83d4a82ecfa3d50752b609f13de6790",
+                "shasum": ""
+            },
+            "require": {
+                "php": ">=7.2.5",
+                "symfony/polyfill-ctype": "^1.8",
+                "symfony/polyfill-mbstring": "^1.3"
+            },
+            "require-dev": {
+                "psr/container": "^1.0",
+                "symfony/phpunit-bridge": "^4.4.9|^5.0.9"
+            },
+            "type": "library",
+            "extra": {
+                "branch-alias": {
+                    "dev-master": "3.3-dev"
+                }
+            },
+            "autoload": {
+                "psr-4": {
+                    "Twig\\": "src/"
+                }
+            },
+            "notification-url": "https://packagist.org/downloads/",
+            "license": [
+                "BSD-3-Clause"
+            ],
+            "authors": [
+                {
+                    "name": "Fabien Potencier",
+                    "email": "fabien@symfony.com",
+                    "homepage": "http://fabien.potencier.org",
+                    "role": "Lead Developer"
+                },
+                {
+                    "name": "Twig Team",
+                    "role": "Contributors"
+                },
+                {
+                    "name": "Armin Ronacher",
+                    "email": "armin.ronacher@active-4.com",
+                    "role": "Project Founder"
+                }
+            ],
+            "description": "Twig, the flexible, fast, and secure template language for PHP",
+            "homepage": "https://twig.symfony.com",
+            "keywords": [
+                "templating"
+            ],
+            "support": {
+                "issues": "https://github.com/twigphp/Twig/issues",
+                "source": "https://github.com/twigphp/Twig/tree/v3.3.2"
+            },
+            "funding": [
+                {
+                    "url": "https://github.com/fabpot",
+                    "type": "github"
+                },
+                {
+                    "url": "https://tidelift.com/funding/github/packagist/twig/twig",
+                    "type": "tidelift"
+                }
+            ],
+            "time": "2021-05-16T12:14:13+00:00"
+        },
+        {
             "name": "yubico/u2flib-server",
             "version": "1.0.2",
             "source": {
@@ -1609,10 +1751,6 @@
             ],
             "description": "Library for U2F implementation",
             "homepage": "https://developers.yubico.com/php-u2flib-server",
-            "support": {
-                "issues": "https://github.com/Yubico/php-u2flib-server/issues",
-                "source": "https://github.com/Yubico/php-u2flib-server/tree/1.0.2"
-            },
             "time": "2018-09-07T08:16:44+00:00"
         }
     ],
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/composer/autoload_files.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/composer/autoload_files.php
index fac18c7..183b68d 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/composer/autoload_files.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/composer/autoload_files.php
@@ -6,10 +6,11 @@
 $baseDir = dirname($vendorDir);
 
 return array(
-    'a4a119a56e50fbb293281d9a48007e0e' => $vendorDir . '/symfony/polyfill-php80/bootstrap.php',
     '0e6d7bf4a5811bfa5cf40c5ccd6fae6a' => $vendorDir . '/symfony/polyfill-mbstring/bootstrap.php',
+    'a4a119a56e50fbb293281d9a48007e0e' => $vendorDir . '/symfony/polyfill-php80/bootstrap.php',
     '6e3fae29631ef280660b3cdad06f25a8' => $vendorDir . '/symfony/deprecation-contracts/function.php',
     'a1105708a18b76903365ca1c4aa61b02' => $vendorDir . '/symfony/translation/Resources/functions.php',
+    '320cde22f66dd4f5d3fd621d3e88b98f' => $vendorDir . '/symfony/polyfill-ctype/bootstrap.php',
     '667aeda72477189d0494fecd327c3641' => $vendorDir . '/symfony/var-dumper/Resources/functions/dump.php',
     'fe62ba7e10580d903cc46d808b5961a4' => $vendorDir . '/tightenco/collect/src/Collect/Support/helpers.php',
     'caf31cc6ec7cf2241cb6f12c226c3846' => $vendorDir . '/tightenco/collect/src/Collect/Support/alias.php',
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/composer/autoload_psr4.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/composer/autoload_psr4.php
index 7c9542e..6e9d44e 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/composer/autoload_psr4.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/composer/autoload_psr4.php
@@ -6,9 +6,11 @@
 $baseDir = dirname($vendorDir);
 
 return array(
+    'Twig\\' => array($vendorDir . '/twig/twig/src'),
     'Tightenco\\Collect\\' => array($vendorDir . '/tightenco/collect/src/Collect'),
     'Symfony\\Polyfill\\Php80\\' => array($vendorDir . '/symfony/polyfill-php80'),
     'Symfony\\Polyfill\\Mbstring\\' => array($vendorDir . '/symfony/polyfill-mbstring'),
+    'Symfony\\Polyfill\\Ctype\\' => array($vendorDir . '/symfony/polyfill-ctype'),
     'Symfony\\Contracts\\Translation\\' => array($vendorDir . '/symfony/translation-contracts'),
     'Symfony\\Component\\VarDumper\\' => array($vendorDir . '/symfony/var-dumper'),
     'Symfony\\Component\\Translation\\' => array($vendorDir . '/symfony/translation'),
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/composer/autoload_static.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/composer/autoload_static.php
index 4d3a5d4..19aadb6 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/composer/autoload_static.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/composer/autoload_static.php
@@ -7,10 +7,11 @@
 class ComposerStaticInit873464e4bd965a3168f133248b1b218b
 {
     public static $files = array (
-        'a4a119a56e50fbb293281d9a48007e0e' => __DIR__ . '/..' . '/symfony/polyfill-php80/bootstrap.php',
         '0e6d7bf4a5811bfa5cf40c5ccd6fae6a' => __DIR__ . '/..' . '/symfony/polyfill-mbstring/bootstrap.php',
+        'a4a119a56e50fbb293281d9a48007e0e' => __DIR__ . '/..' . '/symfony/polyfill-php80/bootstrap.php',
         '6e3fae29631ef280660b3cdad06f25a8' => __DIR__ . '/..' . '/symfony/deprecation-contracts/function.php',
         'a1105708a18b76903365ca1c4aa61b02' => __DIR__ . '/..' . '/symfony/translation/Resources/functions.php',
+        '320cde22f66dd4f5d3fd621d3e88b98f' => __DIR__ . '/..' . '/symfony/polyfill-ctype/bootstrap.php',
         '667aeda72477189d0494fecd327c3641' => __DIR__ . '/..' . '/symfony/var-dumper/Resources/functions/dump.php',
         'fe62ba7e10580d903cc46d808b5961a4' => __DIR__ . '/..' . '/tightenco/collect/src/Collect/Support/helpers.php',
         'caf31cc6ec7cf2241cb6f12c226c3846' => __DIR__ . '/..' . '/tightenco/collect/src/Collect/Support/alias.php',
@@ -20,12 +21,14 @@
     public static $prefixLengthsPsr4 = array (
         'T' => 
         array (
+            'Twig\\' => 5,
             'Tightenco\\Collect\\' => 18,
         ),
         'S' => 
         array (
             'Symfony\\Polyfill\\Php80\\' => 23,
             'Symfony\\Polyfill\\Mbstring\\' => 26,
+            'Symfony\\Polyfill\\Ctype\\' => 23,
             'Symfony\\Contracts\\Translation\\' => 30,
             'Symfony\\Component\\VarDumper\\' => 28,
             'Symfony\\Component\\Translation\\' => 30,
@@ -70,6 +73,10 @@
     );
 
     public static $prefixDirsPsr4 = array (
+        'Twig\\' => 
+        array (
+            0 => __DIR__ . '/..' . '/twig/twig/src',
+        ),
         'Tightenco\\Collect\\' => 
         array (
             0 => __DIR__ . '/..' . '/tightenco/collect/src/Collect',
@@ -82,6 +89,10 @@
         array (
             0 => __DIR__ . '/..' . '/symfony/polyfill-mbstring',
         ),
+        'Symfony\\Polyfill\\Ctype\\' => 
+        array (
+            0 => __DIR__ . '/..' . '/symfony/polyfill-ctype',
+        ),
         'Symfony\\Contracts\\Translation\\' => 
         array (
             0 => __DIR__ . '/..' . '/symfony/translation-contracts',
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/composer/installed.json b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/composer/installed.json
index 1ff198c..c524704 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/composer/installed.json
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/composer/installed.json
@@ -1129,6 +1129,88 @@
             "install-path": "../symfony/deprecation-contracts"
         },
         {
+            "name": "symfony/polyfill-ctype",
+            "version": "v1.23.0",
+            "version_normalized": "1.23.0.0",
+            "source": {
+                "type": "git",
+                "url": "https://github.com/symfony/polyfill-ctype.git",
+                "reference": "46cd95797e9df938fdd2b03693b5fca5e64b01ce"
+            },
+            "dist": {
+                "type": "zip",
+                "url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/46cd95797e9df938fdd2b03693b5fca5e64b01ce",
+                "reference": "46cd95797e9df938fdd2b03693b5fca5e64b01ce",
+                "shasum": ""
+            },
+            "require": {
+                "php": ">=7.1"
+            },
+            "suggest": {
+                "ext-ctype": "For best performance"
+            },
+            "time": "2021-02-19T12:13:01+00:00",
+            "type": "library",
+            "extra": {
+                "branch-alias": {
+                    "dev-main": "1.23-dev"
+                },
+                "thanks": {
+                    "name": "symfony/polyfill",
+                    "url": "https://github.com/symfony/polyfill"
+                }
+            },
+            "installation-source": "dist",
+            "autoload": {
+                "psr-4": {
+                    "Symfony\\Polyfill\\Ctype\\": ""
+                },
+                "files": [
+                    "bootstrap.php"
+                ]
+            },
+            "notification-url": "https://packagist.org/downloads/",
+            "license": [
+                "MIT"
+            ],
+            "authors": [
+                {
+                    "name": "Gert de Pagter",
+                    "email": "BackEndTea@gmail.com"
+                },
+                {
+                    "name": "Symfony Community",
+                    "homepage": "https://symfony.com/contributors"
+                }
+            ],
+            "description": "Symfony polyfill for ctype functions",
+            "homepage": "https://symfony.com",
+            "keywords": [
+                "compatibility",
+                "ctype",
+                "polyfill",
+                "portable"
+            ],
+            "support": {
+                "source": "https://github.com/symfony/polyfill-ctype/tree/v1.23.0"
+            },
+            "funding": [
+                {
+                    "url": "https://symfony.com/sponsor",
+                    "type": "custom"
+                },
+                {
+                    "url": "https://github.com/fabpot",
+                    "type": "github"
+                },
+                {
+                    "url": "https://tidelift.com/funding/github/packagist/symfony/symfony",
+                    "type": "tidelift"
+                }
+            ],
+            "install-path": "../symfony/polyfill-ctype"
+        },
+        {
             "name": "symfony/polyfill-mbstring",
             "version": "v1.23.1",
             "version_normalized": "1.23.1.0",
@@ -1625,6 +1707,85 @@
             "install-path": "../tightenco/collect"
         },
         {
+            "name": "twig/twig",
+            "version": "v3.3.2",
+            "version_normalized": "3.3.2.0",
+            "source": {
+                "type": "git",
+                "url": "https://github.com/twigphp/Twig.git",
+                "reference": "21578f00e83d4a82ecfa3d50752b609f13de6790"
+            },
+            "dist": {
+                "type": "zip",
+                "url": "https://api.github.com/repos/twigphp/Twig/zipball/21578f00e83d4a82ecfa3d50752b609f13de6790",
+                "reference": "21578f00e83d4a82ecfa3d50752b609f13de6790",
+                "shasum": ""
+            },
+            "require": {
+                "php": ">=7.2.5",
+                "symfony/polyfill-ctype": "^1.8",
+                "symfony/polyfill-mbstring": "^1.3"
+            },
+            "require-dev": {
+                "psr/container": "^1.0",
+                "symfony/phpunit-bridge": "^4.4.9|^5.0.9"
+            },
+            "time": "2021-05-16T12:14:13+00:00",
+            "type": "library",
+            "extra": {
+                "branch-alias": {
+                    "dev-master": "3.3-dev"
+                }
+            },
+            "installation-source": "dist",
+            "autoload": {
+                "psr-4": {
+                    "Twig\\": "src/"
+                }
+            },
+            "notification-url": "https://packagist.org/downloads/",
+            "license": [
+                "BSD-3-Clause"
+            ],
+            "authors": [
+                {
+                    "name": "Fabien Potencier",
+                    "email": "fabien@symfony.com",
+                    "homepage": "http://fabien.potencier.org",
+                    "role": "Lead Developer"
+                },
+                {
+                    "name": "Twig Team",
+                    "role": "Contributors"
+                },
+                {
+                    "name": "Armin Ronacher",
+                    "email": "armin.ronacher@active-4.com",
+                    "role": "Project Founder"
+                }
+            ],
+            "description": "Twig, the flexible, fast, and secure template language for PHP",
+            "homepage": "https://twig.symfony.com",
+            "keywords": [
+                "templating"
+            ],
+            "support": {
+                "issues": "https://github.com/twigphp/Twig/issues",
+                "source": "https://github.com/twigphp/Twig/tree/v3.3.2"
+            },
+            "funding": [
+                {
+                    "url": "https://github.com/fabpot",
+                    "type": "github"
+                },
+                {
+                    "url": "https://tidelift.com/funding/github/packagist/twig/twig",
+                    "type": "tidelift"
+                }
+            ],
+            "install-path": "../twig/twig"
+        },
+        {
             "name": "yubico/u2flib-server",
             "version": "1.0.2",
             "version_normalized": "1.0.2.0",
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/composer/installed.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/composer/installed.php
index 2e6adce..cc343e0 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/composer/installed.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/composer/installed.php
@@ -1,22 +1,22 @@
 <?php return array(
     'root' => array(
-        'pretty_version' => '1.0.0+no-version-set',
-        'version' => '1.0.0.0',
+        'pretty_version' => 'dev-master',
+        'version' => 'dev-master',
         'type' => 'library',
         'install_path' => __DIR__ . '/../../',
         'aliases' => array(),
-        'reference' => NULL,
+        'reference' => '1c2923a4ddd7f89b3cf38c9594db289b7dd756d3',
         'name' => '__root__',
         'dev' => true,
     ),
     'versions' => array(
         '__root__' => array(
-            'pretty_version' => '1.0.0+no-version-set',
-            'version' => '1.0.0.0',
+            'pretty_version' => 'dev-master',
+            'version' => 'dev-master',
             'type' => 'library',
             'install_path' => __DIR__ . '/../../',
             'aliases' => array(),
-            'reference' => NULL,
+            'reference' => '1c2923a4ddd7f89b3cf38c9594db289b7dd756d3',
             'dev_requirement' => false,
         ),
         'bshaffer/oauth2-server-php' => array(
@@ -184,6 +184,15 @@
             'reference' => '5f38c8804a9e97d23e0c8d63341088cd8a22d627',
             'dev_requirement' => false,
         ),
+        'symfony/polyfill-ctype' => array(
+            'pretty_version' => 'v1.23.0',
+            'version' => '1.23.0.0',
+            'type' => 'library',
+            'install_path' => __DIR__ . '/../symfony/polyfill-ctype',
+            'aliases' => array(),
+            'reference' => '46cd95797e9df938fdd2b03693b5fca5e64b01ce',
+            'dev_requirement' => false,
+        ),
         'symfony/polyfill-mbstring' => array(
             'pretty_version' => 'v1.23.1',
             'version' => '1.23.1.0',
@@ -244,6 +253,15 @@
             'reference' => 'b069783ab0c547bb894ebcf8e7f6024bb401f9d2',
             'dev_requirement' => false,
         ),
+        'twig/twig' => array(
+            'pretty_version' => 'v3.3.2',
+            'version' => '3.3.2.0',
+            'type' => 'library',
+            'install_path' => __DIR__ . '/../twig/twig',
+            'aliases' => array(),
+            'reference' => '21578f00e83d4a82ecfa3d50752b609f13de6790',
+            'dev_requirement' => false,
+        ),
         'yubico/u2flib-server' => array(
             'pretty_version' => '1.0.2',
             'version' => '1.0.2.0',
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-ctype/Ctype.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-ctype/Ctype.php
new file mode 100644
index 0000000..58414dc
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-ctype/Ctype.php
@@ -0,0 +1,227 @@
+<?php
+
+/*
+ * This file is part of the Symfony package.
+ *
+ * (c) Fabien Potencier <fabien@symfony.com>
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Symfony\Polyfill\Ctype;
+
+/**
+ * Ctype implementation through regex.
+ *
+ * @internal
+ *
+ * @author Gert de Pagter <BackEndTea@gmail.com>
+ */
+final class Ctype
+{
+    /**
+     * Returns TRUE if every character in text is either a letter or a digit, FALSE otherwise.
+     *
+     * @see https://php.net/ctype-alnum
+     *
+     * @param string|int $text
+     *
+     * @return bool
+     */
+    public static function ctype_alnum($text)
+    {
+        $text = self::convert_int_to_char_for_ctype($text);
+
+        return \is_string($text) && '' !== $text && !preg_match('/[^A-Za-z0-9]/', $text);
+    }
+
+    /**
+     * Returns TRUE if every character in text is a letter, FALSE otherwise.
+     *
+     * @see https://php.net/ctype-alpha
+     *
+     * @param string|int $text
+     *
+     * @return bool
+     */
+    public static function ctype_alpha($text)
+    {
+        $text = self::convert_int_to_char_for_ctype($text);
+
+        return \is_string($text) && '' !== $text && !preg_match('/[^A-Za-z]/', $text);
+    }
+
+    /**
+     * Returns TRUE if every character in text is a control character from the current locale, FALSE otherwise.
+     *
+     * @see https://php.net/ctype-cntrl
+     *
+     * @param string|int $text
+     *
+     * @return bool
+     */
+    public static function ctype_cntrl($text)
+    {
+        $text = self::convert_int_to_char_for_ctype($text);
+
+        return \is_string($text) && '' !== $text && !preg_match('/[^\x00-\x1f\x7f]/', $text);
+    }
+
+    /**
+     * Returns TRUE if every character in the string text is a decimal digit, FALSE otherwise.
+     *
+     * @see https://php.net/ctype-digit
+     *
+     * @param string|int $text
+     *
+     * @return bool
+     */
+    public static function ctype_digit($text)
+    {
+        $text = self::convert_int_to_char_for_ctype($text);
+
+        return \is_string($text) && '' !== $text && !preg_match('/[^0-9]/', $text);
+    }
+
+    /**
+     * Returns TRUE if every character in text is printable and actually creates visible output (no white space), FALSE otherwise.
+     *
+     * @see https://php.net/ctype-graph
+     *
+     * @param string|int $text
+     *
+     * @return bool
+     */
+    public static function ctype_graph($text)
+    {
+        $text = self::convert_int_to_char_for_ctype($text);
+
+        return \is_string($text) && '' !== $text && !preg_match('/[^!-~]/', $text);
+    }
+
+    /**
+     * Returns TRUE if every character in text is a lowercase letter.
+     *
+     * @see https://php.net/ctype-lower
+     *
+     * @param string|int $text
+     *
+     * @return bool
+     */
+    public static function ctype_lower($text)
+    {
+        $text = self::convert_int_to_char_for_ctype($text);
+
+        return \is_string($text) && '' !== $text && !preg_match('/[^a-z]/', $text);
+    }
+
+    /**
+     * Returns TRUE if every character in text will actually create output (including blanks). Returns FALSE if text contains control characters or characters that do not have any output or control function at all.
+     *
+     * @see https://php.net/ctype-print
+     *
+     * @param string|int $text
+     *
+     * @return bool
+     */
+    public static function ctype_print($text)
+    {
+        $text = self::convert_int_to_char_for_ctype($text);
+
+        return \is_string($text) && '' !== $text && !preg_match('/[^ -~]/', $text);
+    }
+
+    /**
+     * Returns TRUE if every character in text is printable, but neither letter, digit or blank, FALSE otherwise.
+     *
+     * @see https://php.net/ctype-punct
+     *
+     * @param string|int $text
+     *
+     * @return bool
+     */
+    public static function ctype_punct($text)
+    {
+        $text = self::convert_int_to_char_for_ctype($text);
+
+        return \is_string($text) && '' !== $text && !preg_match('/[^!-\/\:-@\[-`\{-~]/', $text);
+    }
+
+    /**
+     * Returns TRUE if every character in text creates some sort of white space, FALSE otherwise. Besides the blank character this also includes tab, vertical tab, line feed, carriage return and form feed characters.
+     *
+     * @see https://php.net/ctype-space
+     *
+     * @param string|int $text
+     *
+     * @return bool
+     */
+    public static function ctype_space($text)
+    {
+        $text = self::convert_int_to_char_for_ctype($text);
+
+        return \is_string($text) && '' !== $text && !preg_match('/[^\s]/', $text);
+    }
+
+    /**
+     * Returns TRUE if every character in text is an uppercase letter.
+     *
+     * @see https://php.net/ctype-upper
+     *
+     * @param string|int $text
+     *
+     * @return bool
+     */
+    public static function ctype_upper($text)
+    {
+        $text = self::convert_int_to_char_for_ctype($text);
+
+        return \is_string($text) && '' !== $text && !preg_match('/[^A-Z]/', $text);
+    }
+
+    /**
+     * Returns TRUE if every character in text is a hexadecimal 'digit', that is a decimal digit or a character from [A-Fa-f] , FALSE otherwise.
+     *
+     * @see https://php.net/ctype-xdigit
+     *
+     * @param string|int $text
+     *
+     * @return bool
+     */
+    public static function ctype_xdigit($text)
+    {
+        $text = self::convert_int_to_char_for_ctype($text);
+
+        return \is_string($text) && '' !== $text && !preg_match('/[^A-Fa-f0-9]/', $text);
+    }
+
+    /**
+     * Converts integers to their char versions according to normal ctype behaviour, if needed.
+     *
+     * If an integer between -128 and 255 inclusive is provided,
+     * it is interpreted as the ASCII value of a single character
+     * (negative values have 256 added in order to allow characters in the Extended ASCII range).
+     * Any other integer is interpreted as a string containing the decimal digits of the integer.
+     *
+     * @param string|int $int
+     *
+     * @return mixed
+     */
+    private static function convert_int_to_char_for_ctype($int)
+    {
+        if (!\is_int($int)) {
+            return $int;
+        }
+
+        if ($int < -128 || $int > 255) {
+            return (string) $int;
+        }
+
+        if ($int < 0) {
+            $int += 256;
+        }
+
+        return \chr($int);
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-ctype/LICENSE b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-ctype/LICENSE
new file mode 100644
index 0000000..3f853aa
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-ctype/LICENSE
@@ -0,0 +1,19 @@
+Copyright (c) 2018-2019 Fabien Potencier
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is furnished
+to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE.
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-ctype/README.md b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-ctype/README.md
new file mode 100644
index 0000000..8add1ab
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-ctype/README.md
@@ -0,0 +1,12 @@
+Symfony Polyfill / Ctype
+========================
+
+This component provides `ctype_*` functions to users who run php versions without the ctype extension.
+
+More information can be found in the
+[main Polyfill README](https://github.com/symfony/polyfill/blob/master/README.md).
+
+License
+=======
+
+This library is released under the [MIT license](LICENSE).
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-ctype/bootstrap.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-ctype/bootstrap.php
new file mode 100644
index 0000000..d54524b
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-ctype/bootstrap.php
@@ -0,0 +1,50 @@
+<?php
+
+/*
+ * This file is part of the Symfony package.
+ *
+ * (c) Fabien Potencier <fabien@symfony.com>
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+use Symfony\Polyfill\Ctype as p;
+
+if (\PHP_VERSION_ID >= 80000) {
+    return require __DIR__.'/bootstrap80.php';
+}
+
+if (!function_exists('ctype_alnum')) {
+    function ctype_alnum($text) { return p\Ctype::ctype_alnum($text); }
+}
+if (!function_exists('ctype_alpha')) {
+    function ctype_alpha($text) { return p\Ctype::ctype_alpha($text); }
+}
+if (!function_exists('ctype_cntrl')) {
+    function ctype_cntrl($text) { return p\Ctype::ctype_cntrl($text); }
+}
+if (!function_exists('ctype_digit')) {
+    function ctype_digit($text) { return p\Ctype::ctype_digit($text); }
+}
+if (!function_exists('ctype_graph')) {
+    function ctype_graph($text) { return p\Ctype::ctype_graph($text); }
+}
+if (!function_exists('ctype_lower')) {
+    function ctype_lower($text) { return p\Ctype::ctype_lower($text); }
+}
+if (!function_exists('ctype_print')) {
+    function ctype_print($text) { return p\Ctype::ctype_print($text); }
+}
+if (!function_exists('ctype_punct')) {
+    function ctype_punct($text) { return p\Ctype::ctype_punct($text); }
+}
+if (!function_exists('ctype_space')) {
+    function ctype_space($text) { return p\Ctype::ctype_space($text); }
+}
+if (!function_exists('ctype_upper')) {
+    function ctype_upper($text) { return p\Ctype::ctype_upper($text); }
+}
+if (!function_exists('ctype_xdigit')) {
+    function ctype_xdigit($text) { return p\Ctype::ctype_xdigit($text); }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-ctype/bootstrap80.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-ctype/bootstrap80.php
new file mode 100644
index 0000000..ab2f861
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-ctype/bootstrap80.php
@@ -0,0 +1,46 @@
+<?php
+
+/*
+ * This file is part of the Symfony package.
+ *
+ * (c) Fabien Potencier <fabien@symfony.com>
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+use Symfony\Polyfill\Ctype as p;
+
+if (!function_exists('ctype_alnum')) {
+    function ctype_alnum(mixed $text): bool { return p\Ctype::ctype_alnum($text); }
+}
+if (!function_exists('ctype_alpha')) {
+    function ctype_alpha(mixed $text): bool { return p\Ctype::ctype_alpha($text); }
+}
+if (!function_exists('ctype_cntrl')) {
+    function ctype_cntrl(mixed $text): bool { return p\Ctype::ctype_cntrl($text); }
+}
+if (!function_exists('ctype_digit')) {
+    function ctype_digit(mixed $text): bool { return p\Ctype::ctype_digit($text); }
+}
+if (!function_exists('ctype_graph')) {
+    function ctype_graph(mixed $text): bool { return p\Ctype::ctype_graph($text); }
+}
+if (!function_exists('ctype_lower')) {
+    function ctype_lower(mixed $text): bool { return p\Ctype::ctype_lower($text); }
+}
+if (!function_exists('ctype_print')) {
+    function ctype_print(mixed $text): bool { return p\Ctype::ctype_print($text); }
+}
+if (!function_exists('ctype_punct')) {
+    function ctype_punct(mixed $text): bool { return p\Ctype::ctype_punct($text); }
+}
+if (!function_exists('ctype_space')) {
+    function ctype_space(mixed $text): bool { return p\Ctype::ctype_space($text); }
+}
+if (!function_exists('ctype_upper')) {
+    function ctype_upper(mixed $text): bool { return p\Ctype::ctype_upper($text); }
+}
+if (!function_exists('ctype_xdigit')) {
+    function ctype_xdigit(mixed $text): bool { return p\Ctype::ctype_xdigit($text); }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-ctype/composer.json b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-ctype/composer.json
new file mode 100644
index 0000000..f0621a3
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-ctype/composer.json
@@ -0,0 +1,38 @@
+{
+    "name": "symfony/polyfill-ctype",
+    "type": "library",
+    "description": "Symfony polyfill for ctype functions",
+    "keywords": ["polyfill", "compatibility", "portable", "ctype"],
+    "homepage": "https://symfony.com",
+    "license": "MIT",
+    "authors": [
+        {
+            "name": "Gert de Pagter",
+            "email": "BackEndTea@gmail.com"
+        },
+        {
+            "name": "Symfony Community",
+            "homepage": "https://symfony.com/contributors"
+        }
+    ],
+    "require": {
+        "php": ">=7.1"
+    },
+    "autoload": {
+        "psr-4": { "Symfony\\Polyfill\\Ctype\\": "" },
+        "files": [ "bootstrap.php" ]
+    },
+    "suggest": {
+        "ext-ctype": "For best performance"
+    },
+    "minimum-stability": "dev",
+    "extra": {
+        "branch-alias": {
+            "dev-main": "1.23-dev"
+        },
+        "thanks": {
+            "name": "symfony/polyfill",
+            "url": "https://github.com/symfony/polyfill"
+        }
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/.editorconfig b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/.editorconfig
new file mode 100644
index 0000000..270f1d1
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/.editorconfig
@@ -0,0 +1,18 @@
+; top-most EditorConfig file
+root = true
+
+; Unix-style newlines
+[*]
+end_of_line = LF
+
+[*.php]
+indent_style = space
+indent_size = 4
+
+[*.test]
+indent_style = space
+indent_size = 4
+
+[*.rst]
+indent_style = space
+indent_size = 4
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/.gitattributes b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/.gitattributes
new file mode 100644
index 0000000..75e18f8
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/.gitattributes
@@ -0,0 +1,3 @@
+/extra/** export-ignore
+/tests export-ignore
+/phpunit.xml.dist export-ignore
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/.github/workflows/ci.yml b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/.github/workflows/ci.yml
new file mode 100644
index 0000000..dfc40c3
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/.github/workflows/ci.yml
@@ -0,0 +1,173 @@
+name: "CI"
+
+on:
+    pull_request:
+    push:
+        branches:
+            - '3.x'
+
+env:
+    SYMFONY_PHPUNIT_DISABLE_RESULT_CACHE: 1
+
+jobs:
+    tests:
+        name: "PHP ${{ matrix.php-version }}"
+
+        runs-on: 'ubuntu-latest'
+
+        continue-on-error: ${{ matrix.experimental }}
+
+        strategy:
+            matrix:
+                php-version:
+                    - '7.2.5'
+                    - '7.3'
+                    - '7.4'
+                    - '8.0'
+                composer-options: ['']
+                experimental: [false]
+                include:
+                  - { php-version: '8.1', experimental: true, composer-options: '--ignore-platform-req=php' }
+
+        steps:
+            - name: "Checkout code"
+              uses: actions/checkout@v2.3.3
+
+            - name: "Install PHP with extensions"
+              uses: shivammathur/setup-php@2.7.0
+              with:
+                  coverage: "none"
+                  php-version: ${{ matrix.php-version }}
+                  ini-values: memory_limit=-1
+                  tools: composer:v2
+
+            - name: "Add PHPUnit matcher"
+              run: echo "::add-matcher::${{ runner.tool_cache }}/phpunit.json"
+
+            - name: "Set composer cache directory"
+              id: composer-cache
+              run: echo "::set-output name=dir::$(composer config cache-files-dir)"
+
+            - name: "Cache composer"
+              uses: actions/cache@v2.1.2
+              with:
+                  path: ${{ steps.composer-cache.outputs.dir }}
+                  key: ${{ runner.os }}-${{ matrix.php-version }}-composer-${{ hashFiles('composer.json') }}
+                  restore-keys: ${{ runner.os }}-${{ matrix.php-version }}-composer-
+
+            - run: composer install ${{ matrix.composer-options }}
+
+            - name: "Install PHPUnit"
+              run: vendor/bin/simple-phpunit install
+
+            - name: "PHPUnit version"
+              run: vendor/bin/simple-phpunit --version
+
+            - name: "Run tests"
+              run: vendor/bin/simple-phpunit
+
+    extension-tests:
+        needs:
+            - 'tests'
+
+        name: "${{ matrix.extension }} with PHP ${{ matrix.php-version }}"
+
+        runs-on: 'ubuntu-latest'
+
+        continue-on-error: true
+
+        strategy:
+            matrix:
+                php-version:
+                    - '7.2.5'
+                    - '7.3'
+                    - '7.4'
+                    - '8.0'
+                extension:
+                    - 'extra/cache-extra'
+                    - 'extra/cssinliner-extra'
+                    - 'extra/html-extra'
+                    - 'extra/inky-extra'
+                    - 'extra/intl-extra'
+                    - 'extra/markdown-extra'
+                    - 'extra/string-extra'
+                    - 'extra/twig-extra-bundle'
+
+        steps:
+            - name: "Checkout code"
+              uses: actions/checkout@v2.3.3
+
+            - name: "Install PHP with extensions"
+              uses: shivammathur/setup-php@2.7.0
+              with:
+                  coverage: "none"
+                  php-version: ${{ matrix.php-version }}
+                  ini-values: memory_limit=-1
+                  tools: composer:v2
+
+            - name: "Add PHPUnit matcher"
+              run: echo "::add-matcher::${{ runner.tool_cache }}/phpunit.json"
+
+            - name: "Set composer cache directory"
+              id: composer-cache
+              run: echo "::set-output name=dir::$(composer config cache-files-dir)"
+
+            - name: "Cache composer"
+              uses: actions/cache@v2.1.2
+              with:
+                  path: ${{ steps.composer-cache.outputs.dir }}
+                  key: ${{ runner.os }}-${{ matrix.php-version }}-${{ matrix.extension }}-${{ hashFiles('composer.json') }}
+                  restore-keys: ${{ runner.os }}-${{ matrix.php-version }}-${{ matrix.extension }}-
+
+            - run: composer install
+
+            - name: "Install PHPUnit"
+              run: vendor/bin/simple-phpunit install
+
+            - name: "PHPUnit version"
+              run: vendor/bin/simple-phpunit --version
+
+            - if: matrix.extension == 'extra/markdown-extra' && matrix.php-version == '8.0'
+              working-directory: ${{ matrix.extension}}
+              run: composer config platform.php 7.4.99
+
+            - name: "Composer install"
+              working-directory: ${{ matrix.extension}}
+              run: composer install
+
+            - name: "Run tests"
+              working-directory: ${{ matrix.extension}}
+              run: ../../vendor/bin/simple-phpunit
+#
+#    Drupal does not support Twig 3 now!
+#
+#    integration-tests:
+#        needs:
+#            - 'tests'
+#
+#        name: "Integration tests with PHP ${{ matrix.php-version }}"
+#
+#        runs-on: 'ubuntu-20.04'
+#
+#        continue-on-error: true
+#
+#        strategy:
+#            matrix:
+#                php-version:
+#                    - '7.3'
+#
+#        steps:
+#            - name: "Checkout code"
+#              uses: actions/checkout@v2.3.3
+#
+#            - name: "Install PHP with extensions"
+#              uses: shivammathur/setup-php@2.7.0
+#              with:
+#                  coverage: "none"
+#                  extensions: "gd, pdo_sqlite"
+#                  php-version: ${{ matrix.php-version }}
+#                  ini-values: memory_limit=-1
+#                  tools: composer:v2
+#
+#            - run: ./drupal_test.sh
+#              shell: "bash"
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/.github/workflows/documentation.yml b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/.github/workflows/documentation.yml
new file mode 100644
index 0000000..0b3ca71
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/.github/workflows/documentation.yml
@@ -0,0 +1,60 @@
+name: "Documentation"
+
+on:
+    pull_request:
+    push:
+        branches:
+            - '3.x'
+
+jobs:
+    build:
+        name: "Build"
+
+        runs-on: ubuntu-latest
+
+        steps:
+            -   name: "Checkout code"
+                uses: actions/checkout@v2
+
+            -   name: "Set up Python 3.7"
+                uses: actions/setup-python@v1
+                with:
+                    python-version: '3.7' # Semantic version range syntax or exact version of a Python version
+
+            -   name: "Display Python version"
+                run: python -c "import sys; print(sys.version)"
+
+            -   name: "Install Sphinx dependencies"
+                run: sudo apt-get install python-dev build-essential
+
+            -   name: "Cache pip"
+                uses: actions/cache@v2
+                with:
+                    path: ~/.cache/pip
+                    key: ${{ runner.os }}-pip-${{ hashFiles('_build/.requirements.txt') }}
+                    restore-keys: |
+                        ${{ runner.os }}-pip-
+
+            -   name: "Install Sphinx + requirements via pip"
+                working-directory: "doc"
+                run: pip install -r _build/.requirements.txt
+
+            -   name: "Build documentation"
+                working-directory: "doc"
+                run: make -C _build SPHINXOPTS="-nqW -j auto" html
+
+    doctor-rst:
+        name: "DOCtor-RST"
+
+        runs-on: ubuntu-latest
+
+        steps:
+            - name: "Checkout code"
+              uses: actions/checkout@v2
+
+            - name: "Run DOCtor-RST"
+              uses: docker://oskarstark/doctor-rst
+              with:
+                  args: --short
+              env:
+                  DOCS_DIR: 'doc/'
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/.gitignore b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/.gitignore
new file mode 100644
index 0000000..cd52aea
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/.gitignore
@@ -0,0 +1,4 @@
+/composer.lock
+/phpunit.xml
+/vendor
+.phpunit.result.cache
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/.php-cs-fixer.dist.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/.php-cs-fixer.dist.php
new file mode 100644
index 0000000..b07ac7f
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/.php-cs-fixer.dist.php
@@ -0,0 +1,20 @@
+<?php
+
+return (new PhpCsFixer\Config())
+    ->setRules([
+        '@Symfony' => true,
+        '@Symfony:risky' => true,
+        '@PHPUnit75Migration:risky' => true,
+        'php_unit_dedicate_assert' => ['target' => '5.6'],
+        'array_syntax' => ['syntax' => 'short'],
+        'php_unit_fqcn_annotation' => true,
+        'no_unreachable_default_argument_value' => false,
+        'braces' => ['allow_single_line_closure' => true],
+        'heredoc_to_nowdoc' => false,
+        'ordered_imports' => true,
+        'phpdoc_types_order' => ['null_adjustment' => 'always_last', 'sort_algorithm' => 'none'],
+        'native_function_invocation' => ['include' => ['@compiler_optimized'], 'scope' => 'all'],
+    ])
+    ->setRiskyAllowed(true)
+    ->setFinder((new PhpCsFixer\Finder())->in(__DIR__))
+;
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/CHANGELOG b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/CHANGELOG
new file mode 100644
index 0000000..832e639
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/CHANGELOG
@@ -0,0 +1,1621 @@
+# 3.3.2 (2021-05-16)
+
+ * Revert "Throw a proper exception when a template name is an absolute path (as it has never been supported)"
+
+# 3.3.1 (2021-05-12)
+
+ * Fix PHP 8.1 compatibility
+ * Throw a proper exception when a template name is an absolute path (as it has never been supported)
+
+# 3.3.0 (2021-02-08)
+
+ * Fix macro calls in a "cache" tag
+ * Add the slug filter
+ * Allow extra bundle to be compatible with Twig 2
+
+# 3.2.1 (2021-01-05)
+
+ * Fix extra bundle compat with older versions of Symfony
+
+# 3.2.0 (2021-01-05)
+
+ * Add the Cache extension in the "extra" repositories: "cache" tag
+ * Add "registerUndefinedTokenParserCallback"
+ * Mark built-in node visitors as @internal
+ * Fix "odd" not working for negative numbers
+
+# 3.1.1 (2020-10-27)
+
+ * Fix "include(template_from_string())"
+
+# 3.1.0 (2020-10-21)
+
+ * Fix sandbox support when using "include(template_from_string())"
+ * Make round brackets optional for one argument tests like "same as" or "divisible by"
+ * Add support for ES2015 style object initialisation shortcut { a } is the same as { 'a': a }
+
+# 3.0.5 (2020-08-05)
+
+ * Fix twig_compare w.r.t. whitespace trimming
+ * Fix sandbox not disabled if syntax error occurs within {% sandbox %} tag
+ * Fix a regression when not using a space before an operator
+ * Restrict callables to closures in filters
+ * Allow trailing commas in argument lists (in calls as well as definitions)
+
+# 3.0.4 (2020-07-05)
+
+ * Fix comparison operators
+ * Fix options not taken into account when using "Michelf\MarkdownExtra"
+ * Fix "Twig\Extra\Intl\IntlExtension::getCountryName()" to accept "null" as a first argument
+ * Throw exception in case non-Traversable data is passed to "filter"
+ * Fix context optimization on PHP 7.4
+ * Fix PHP 8 compatibility
+ * Fix ambiguous syntax parsing
+
+# 3.0.3 (2020-02-11)
+
+ * Add a check to ensure that iconv() is defined
+
+# 3.0.2 (2020-02-11)
+
+ * Avoid exceptions when an intl resource is not found
+ * Fix implementation of case-insensitivity for method names
+
+# 3.0.1 (2019-12-28)
+
+ * fixed Symfony 5.0 support for the HTML extra extension
+
+# 3.0.0 (2019-11-15)
+
+ * fixed number formatter in Intl extra extension when using a formatter prototype
+
+# 3.0.0-BETA1 (2019-11-11)
+
+ * removed the "if" condition support on the "for" tag
+ * made the in, <, >, <=, >=, ==, and != operators more strict when comparing strings and integers/floats
+ * removed the "filter" tag
+ * added type hints everywhere
+ * changed Environment::resolveTemplate() to always return a TemplateWrapper instance
+ * removed Template::__toString()
+ * removed Parser::isReservedMacroName()
+ * removed SanboxedPrintNode
+ * removed Node::setTemplateName()
+ * made classes maked as "@final" final
+ * removed InitRuntimeInterface, ExistsLoaderInterface, and SourceContextLoaderInterface
+ * removed the "spaceless" tag
+ * removed Twig\Environment::getBaseTemplateClass() and Twig\Environment::setBaseTemplateClass()
+ * removed the "base_template_class" option on Twig\Environment
+ * bumped minimum PHP version to 7.2
+ * removed PSR-0 classes
+
+# 2.14.6 (2021-XX-XX)
+
+ * Revert "Throw a proper exception when a template name is an absolute path (as it has never been supported)"
+
+# 2.14.5 (2021-05-12)
+
+ * Fix PHP 8.1 compatibility
+ * Throw a proper exception when a template name is an absolute path (as it has never been supported)
+
+# 2.14.4 (2021-03-10)
+
+ * Add the slug filter
+
+# 2.14.3 (2021-01-05)
+
+ * Fix extra bundle compat with older versions of Symfony
+
+# 2.14.2 (2021-01-05)
+
+ * Fix "odd" not working for negative numbers
+
+# 2.14.1 (2020-10-27)
+
+* Fix "include(template_from_string())"
+
+# 2.14.0 (2020-10-21)
+
+ * Fix sandbox support when using "include(template_from_string())"
+ * Make round brackets optional for one argument tests like "same as" or "divisible by"
+ * Add support for ES2015 style object initialisation shortcut { a } is the same as { 'a': a }
+ * Drop PHP 7.1 support
+
+# 2.13.1 (2020-08-05)
+
+ * Fix sandbox not disabled if syntax error occurs within {% sandbox %} tag
+ * Fix a regression when not using a space before an operator
+ * Restrict callables to closures in filters
+ * Allow trailing commas in argument lists (in calls as well as definitions)
+
+# 2.13.0 (2020-07-05)
+
+ * Fix options not taken into account when using "Michelf\MarkdownExtra"
+ * Fix "Twig\Extra\Intl\IntlExtension::getCountryName()" to accept "null" as a first argument
+ * Drop support for PHP 7.0
+ * Throw exception in case non-Traversable data is passed to "filter"
+ * Fix context optimization on PHP 7.4
+ * Fix PHP 8 compatibility
+ * Fix ambiguous syntax parsing
+
+# 2.12.5 (2020-02-11)
+
+ * Add a check to ensure that iconv() is defined
+
+# 2.12.4 (2020-02-11)
+
+ * Avoid exceptions when an intl resource is not found
+ * Fix implementation of case-insensitivity for method names
+
+# 2.12.3 (2019-12-28)
+
+ * fixed Symfony 5.0 support for the HTML extra extension
+ * fixed number formatter in Intl extra extension when using a formatter prototype
+
+# 2.12.2 (2019-11-11)
+
+ * added supported for exponential numbers
+
+# 2.12.1 (2019-10-17)
+
+ * added the String extension in the "extra" repositories: "u" filter
+
+# 2.12.0 (2019-10-05)
+
+ * added the spaceship operator ("<=>"), useful when using an arrow function in the "sort" filter
+ * added support for an "arrow" function on the "sort" filter
+ * added the CssInliner extension in the "extra" repositories: "inline_css"
+   filter
+ * added the Inky extension in the "extra" repositories: "inky_to_html" filter
+ * added Intl extension in the "extra" repositories: "country_name",
+   "currency_name", "currency_symbol", "language_name", "locale_name",
+   "timezone_name", "format_currency", "format_number",
+   "format_*_number", "format_datetime", "format_date", and "format_time"
+   filters, and the "country_timezones" function
+ * added the Markdown extension in the "extra" repositories: "markdown_to_html",
+   and "html_to_markdown" filters
+ * added the HtmlExtension extension in the "extra" repositories: "date_uri"
+   filter, and "html_classes" function
+ * optimized "block('foo') ?? 'bar'"
+ * fixed the empty test on Traversable instances
+ * fixed array_key_exists() on objects
+ * fixed cache when opcache is installed but disabled
+ * fixed using macros in arrow functions
+ * fixed split filter on edge case
+
+# 2.11.3 (2019-06-18)
+
+ * display partial output (PHP buffer) when an error occurs in debug mode
+ * fixed the filter filter (allow the result to be used several times)
+ * fixed macro auto-import when a template contains only macros
+
+# 2.11.2 (2019-06-05)
+
+ * fixed macro auto-import
+
+# 2.11.1 (2019-06-04)
+
+ * added support for "Twig\Markup" instances in the "in" test (again)
+ * allowed string operators as variables names in assignments
+ * fixed support for macros defined in parent templates
+
+# 2.11.0 (2019-05-31)
+
+ * added the possibility to register classes/interfaces as being safe for the escaper ("EscaperExtension::addSafeClass()")
+ * deprecated CoreExtension::setEscaper() and CoreExtension::getEscapers() in favor of the same methods on EscaperExtension
+ * macros are now auto-imported in the template they are defined (under the ``_self`` variable)
+ * added support for macros on "is defined" tests
+ * fixed macros "import" when using the same name in the parent and child templates
+ * fixed recursive macros
+ * macros imported "globally" in a template are now available in macros without re-importing them
+ * fixed the "filter" filter when the argument is \Traversable but does not implement \Iterator (\SimpleXmlElement for instance)
+ * fixed a PHP fatal error when calling a macro imported in a block in a nested block
+ * fixed a PHP fatal error when calling a macro imported in the template in another macro
+ * fixed wrong error message on "import" and "from"
+
+# 2.10.0 (2019-05-14)
+
+ * deprecated "if" conditions on "for" tags
+ * added "filter", "map", and "reduce" filters (and support for arrow functions)
+ * fixed partial output leak when a PHP fatal error occurs
+ * optimized context access on PHP 7.4
+
+# 2.9.0 (2019-04-28)
+
+ * deprecated returning "false" to remove a Node from NodeVisitorInterface::leaveNode()
+ * allowed Twig\NodeVisitor\NodeVisitorInterface::leaveNode() to return "null" instead of "false" (same meaning)
+ * deprecated the "filter" tag (use the "apply" tag instead)
+ * added the "apply" tag as a replacement for the "filter" tag
+ * allowed Twig\Loader\FilesystemLoader::findTemplate() to return "null" instead of "false" (same meaning)
+ * added support for "Twig\Markup" instances in the "in" test
+ * fixed "import" when macros are stored in a template string
+ * fixed Lexer when using custom options containing the # char
+ * added template line number to twig_get_attribute()
+
+# 2.8.1 (2019-04-16)
+
+ * fixed EscaperNodeVisitor
+ * deprecated passing a 3rd, 4th, and 5th arguments to the Sandbox exception classes
+ * deprecated Node::setTemplateName() in favor of Node::setSourceContext()
+
+# 2.8.0 (2019-04-16)
+
+ * added Traversable support for the length filter
+ * fixed some wrong location in error messages
+ * made exception creation faster
+ * made escaping on ternary expressions (?: and ??) more fine-grained
+ * added the possibility to give a nice name to string templates (template_from_string function)
+ * fixed the "with" behavior to always include the globals (for consistency with the "include" and "embed" tags)
+ * fixed "include" with "ignore missing" when an error loading occurs in the included template
+ * added support for a new whitespace trimming option ({%~ ~%}, {{~ ~}}, {#~ ~#})
+ * added the "column" filter
+
+# 2.7.4 (2019-03-23)
+
+ * fixed variadic support
+ * fixed CheckToStringNode implementation (broken when a function/filter is variadic)
+
+# 2.7.3 (2019-03-21)
+
+ * fixed the spaceless filter so that it behaves like the spaceless tag
+ * fixed BC break on Environment::resolveTemplate()
+ * allowed Traversable objects to be used in the "with" tag
+ * allowed Traversable objects to be used in the "with" tag
+ * allowed Traversable objects to be used in the "with" argument of the "include" and "embed" tags
+
+# 2.7.2 (2019-03-12)
+
+ * added TemplateWrapper::getTemplateName()
+
+# 2.7.1 (2019-03-12)
+
+ * fixed class aliases
+
+# 2.7.0 (2019-03-12)
+
+ * fixed sandbox security issue (under some circumstances, calling the
+   __toString() method on an object was possible even if not allowed by the
+   security policy)
+ * fixed batch filter clobbers array keys when fill parameter is used
+ * added preserveKeys support for the batch filter
+ * fixed "embed" support when used from "template_from_string"
+ * deprecated passing a Twig\Template to Twig\Environment::load()/Twig\Environment::resolveTemplate()
+ * added the possibility to pass a TemplateWrapper to Twig\Environment::load()
+ * marked Twig\Environment::getTemplateClass() as internal (implementation detail)
+ * improved the performance of the sandbox
+ * deprecated the spaceless tag
+ * added a spaceless filter
+ * added max value to the "random" function
+ * deprecated Twig\Extension\InitRuntimeInterface
+ * deprecated Twig\Loader\ExistsLoaderInterface
+ * deprecated PSR-0 classes in favor of namespaced ones
+ * made namespace classes the default classes (PSR-0 ones are aliases now)
+ * added Twig\Loader\ChainLoader::getLoaders()
+ * removed duplicated directory separator in FilesystemLoader
+ * deprecated the "base_template_class" option on Twig\Environment
+ * deprecated the Twig\Environment::getBaseTemplateClass() and
+   Twig\Environment::setBaseTemplateClass() methods
+ * changed internal code to use the namespaced classes as much as possible
+ * deprecated Twig_Parser::isReservedMacroName()
+
+# 2.6.2 (2019-01-14)
+
+ * fixed regression (key exists check for non ArrayObject objects)
+
+# 2.6.1 (2019-01-14)
+
+ * fixed ArrayObject access with a null value
+ * fixed embedded templates starting with a BOM
+ * fixed using a Twig_TemplateWrapper instance as an argument to extends
+ * fixed error location when calling an undefined block
+ * deprecated passing a string as a source on Twig_Error
+ * switched generated code to use the PHP short array notation
+ * fixed float representation in compiled templates
+ * added a second argument to the join filter (last separator configuration)
+
+# 2.6.0 (2018-12-16)
+
+ * made sure twig_include returns a string
+ * fixed multi-byte UFT-8 in escape('html_attr')
+ * added the "deprecated" tag
+ * added support for dynamically named tests
+ * fixed GlobalsInterface extended class
+ * fixed filesystem loader throwing an exception instead of returning false
+
+# 2.5.0 (2018-07-13)
+
+ * deprecated using the spaceless tag at the root level of a child template (noop anyway)
+ * deprecated the possibility to define a block in a non-capturing block in a child template
+ * added the Symfony ctype polyfill as a dependency
+ * fixed reporting the proper location for errors compiled in templates
+ * fixed the error handling for the optimized extension-based function calls
+ * ensured that syntax errors are triggered with the right line
+ * "js" filter now produces valid JSON
+
+# 2.4.8 (2018-04-02)
+
+ * fixed a regression when using the "default" filter or the "defined" test on non-existing arrays
+
+# 2.4.7 (2018-03-20)
+
+ * optimized runtime performance
+ * optimized parser performance by inlining the constant values
+ * fixed block names unicity
+ * fixed counting children of SimpleXMLElement objects
+ * added missing else clause to avoid infinite loops
+ * fixed .. (range operator) in sandbox policy
+
+# 2.4.6 (2018-03-03)
+
+ * fixed a regression in the way the profiler is registered in templates
+
+# 2.4.5 (2018-03-02)
+
+ * optimized the performance of calling an extension method at runtime
+ * optimized the performance of the dot operator for array and method calls
+ * added an exception when using "===" instead of "same as"
+ * fixed possible array to string conversion concealing actual error
+ * made variable names deterministic in compiled templates
+ * fixed length filter when passing an instance of IteratorAggregate
+ * fixed Environment::resolveTemplate to accept instances of TemplateWrapper
+
+# 2.4.4 (2017-09-27)
+
+ * added Twig_Profiler_Profile::reset()
+ * fixed use TokenParser to return an empty Node
+ * added RuntimeExtensionInterface
+ * added circular reference detection when loading templates
+ * added support for runtime loaders in IntegrationTestCase
+ * fixed deprecation when using Twig_Profiler_Dumper_Html
+ * removed @final from Twig_Profiler_Dumper_Text
+
+# 2.4.3 (2017-06-07)
+
+ * fixed namespaces introduction
+
+# 2.4.2 (2017-06-05)
+
+ * fixed namespaces introduction
+
+# 2.4.1 (2017-06-05)
+
+ * fixed namespaces introduction
+
+# 2.4.0 (2017-06-05)
+
+ * added support for PHPUnit 6 when testing extensions
+ * fixed PHP 7.2 compatibility
+ * fixed template name generation in Twig_Environment::createTemplate()
+ * removed final tag on Twig_TokenParser_Include
+ * dropped HHVM support
+ * added namespaced aliases for all (non-deprecated) classes and interfaces
+ * marked Twig_Filter, Twig_Function, Twig_Test, Twig_Node_Module and Twig_Profiler_Profile as final via the @final annotation
+
+# 2.3.2 (2017-04-20)
+
+ * fixed edge case in the method cache for Twig attributes
+
+# 2.3.1 (2017-04-18)
+
+ * fixed the empty() test
+
+# 2.3.0 (2017-03-22)
+
+ * fixed a race condition handling when writing cache files
+ * "length" filter now returns string length when applied to an object that does
+   not implement \Countable but provides __toString()
+ * "empty" test will now consider the return value of the __toString() method for
+   objects implement __toString() but not \Countable
+ * fixed JS escaping for unicode characters with higher code points
+ * added error message when calling `parent()` in a block that doesn't exist in the parent template
+
+# 2.2.0 (2017-02-26)
+
+ * added a PSR-11 compatible runtime loader
+ * added `side` argument to `trim` to allow left or right trimming only.
+
+# 2.1.0 (2017-01-11)
+
+ * fixed twig_get_attribute()
+ * added Twig_NodeCaptureInterface for nodes that capture all output
+
+# 2.0.0 (2017-01-05)
+
+ * removed the C extension
+ * moved Twig_Environment::getAttribute() to twig_get_attribute()
+ * removed Twig_Environment::getLexer(), Twig_Environment::getParser(), Twig_Environment::getCompiler()
+ * removed Twig_Compiler::getFilename()
+ * added hasser support in Twig_Template::getAttribute()
+ * sped up the json_encode filter
+ * removed reserved macro names; all names can be used as macro
+ * removed Twig_Template::getEnvironment()
+ * changed _self variable to return the current template name
+ * made the loader a required argument of Twig_Environment constructor
+ * removed Twig_Environment::clearTemplateCache()
+ * removed Twig_Autoloader (use Composer instead)
+ * removed `true` as an equivalent to `html` for the auto-escaping strategy
+ * removed pre-1.8 autoescape tag syntax
+ * dropped support for PHP 5.x
+ * removed the ability to register a global variable after the runtime or the extensions have been initialized
+ * improved the performance of the filesystem loader
+ * removed features that were deprecated in 1.x
+
+# 1.44.4 (2021-XX-XX)
+
+ * Revert "Throw a proper exception when a template name is an absolute path (as it has never been supported)"
+
+# 1.44.3 (2021-05-12)
+
+ * Fix PHP 8.1 compatibility
+ * Throw a proper exception when a template name is an absolute path (as it has never been supported)
+
+# 1.44.2 (2021-01-05)
+
+ * Fix "odd" not working for negative numbers
+
+# 1.44.1 (2020-10-27)
+
+ * Fix "include(template_from_string())"
+
+# 1.44.0 (2020-10-21)
+
+ * Remove implicit dependency on ext/iconv in JS escaper
+ * Fix sandbox support when using "include(template_from_string())"
+ * Make round brackets optional for one argument tests like "same as" or "divisible by"
+ * Add support for ES2015 style object initialisation shortcut { a } is the same as { 'a': a }
+ * Fix filter(), map(), and reduce() to throw a RuntimeError instead of a PHP TypeError
+ * Drop PHP 7.1 support
+
+# 1.43.1 (2020-08-05)
+
+ * Fix sandbox not disabled if syntax error occurs within {% sandbox %} tag
+ * Fix a regression when not using a space before an operator
+ * Restrict callables to closures in filters
+ * Allow trailing commas in argument lists (in calls as well as definitions)
+
+# 1.43.0 (2020-07-05)
+
+ * Throw exception in case non-Traversable data is passed to "filter"
+ * Fix context optimization on PHP 7.4
+ * Fix PHP 8 compatibility
+ * Drop PHP 5.5 5.6, and 7.0 support
+ * Fix ambiguous syntax parsing
+ * In sandbox, the `filter`, `map` and `reduce` filters require Closures in `arrow` parameter
+
+# 1.42.5 (2020-02-11)
+
+ * Fix implementation of case-insensitivity for method names
+
+# 1.42.4 (2019-11-11)
+
+ * optimized "block('foo') ?? 'bar"
+ * added supported for exponential numbers
+
+# 1.42.3 (2019-08-24)
+
+ * fixed the "split" filter when the delimiter is "0"
+ * fixed the "empty" test on Traversable instances
+ * fixed cache when opcache is installed but disabled
+ * fixed PHP 7.4 compatibility
+ * bumped the minimal PHP version to 5.5
+
+# 1.42.2 (2019-06-18)
+
+ * Display partial output (PHP buffer) when an error occurs in debug mode
+
+# 1.42.1 (2019-06-04)
+
+ * added support for "Twig\Markup" instances in the "in" test (again)
+ * allowed string operators as variables names in assignments
+
+# 1.42.0 (2019-05-31)
+
+ * fixed the "filter" filter when the argument is \Traversable but does not implement \Iterator (\SimpleXmlElement for instance)
+ * fixed a PHP fatal error when calling a macro imported in a block in a nested block
+ * fixed a PHP fatal error when calling a macro imported in the template in another macro
+ * fixed wrong error message on "import" and "from"
+
+# 1.41.0 (2019-05-14)
+
+ * fixed support for PHP 7.4
+ * added "filter", "map", and "reduce" filters (and support for arrow functions)
+ * fixed partial output leak when a PHP fatal error occurs
+ * optimized context access on PHP 7.4
+
+# 1.40.1 (2019-04-29)
+
+# fixed regression in NodeTraverser
+
+# 1.40.0 (2019-04-28)
+
+ * allowed Twig\NodeVisitor\NodeVisitorInterface::leaveNode() to return "null" instead of "false" (same meaning)
+ * added the "apply" tag as a replacement for the "filter" tag
+ * allowed Twig\Loader\FilesystemLoader::findTemplate() to return "null" instead of "false" (same meaning)
+ * added support for "Twig\Markup" instances in the "in" test
+ * fixed Lexer when using custom options containing the # char
+ * fixed "import" when macros are stored in a template string
+
+# 1.39.1 (2019-04-16)
+
+ * fixed EscaperNodeVisitor
+
+# 1.39.0 (2019-04-16)
+
+ * added Traversable support for the length filter
+ * fixed some wrong location in error messages
+ * made exception creation faster
+ * made escaping on ternary expressions (?: and ??) more fine-grained
+ * added the possibility to give a nice name to string templates (template_from_string function)
+ * fixed the "with" behavior to always include the globals (for consistency with the "include" and "embed" tags)
+ * fixed "include" with "ignore missing" when an error loading occurs in the included template
+ * added support for a new whitespace trimming option ({%~ ~%}, {{~ ~}}, {#~ ~#})
+
+# 1.38.4 (2019-03-23)
+
+ * fixed CheckToStringNode implementation (broken when a function/filter is variadic)
+
+# 1.38.3 (2019-03-21)
+
+ * fixed the spaceless filter so that it behaves like the spaceless tag
+ * fixed BC break on Environment::resolveTemplate()
+ * fixed the bundled Autoloader to also load namespaced classes
+ * allowed Traversable objects to be used in the "with" tag
+ * allowed Traversable objects to be used in the "with" argument of the "include" and "embed" tags
+
+# 1.38.2 (2019-03-12)
+
+ * added TemplateWrapper::getTemplateName()
+
+# 1.38.1 (2019-03-12)
+
+ * fixed class aliases
+
+# 1.38.0 (2019-03-12)
+
+ * fixed sandbox security issue (under some circumstances, calling the
+   __toString() method on an object was possible even if not allowed by the
+   security policy)
+ * fixed batch filter clobbers array keys when fill parameter is used
+ * added preserveKeys support for the batch filter
+ * fixed "embed" support when used from "template_from_string"
+ * added the possibility to pass a TemplateWrapper to Twig\Environment::load()
+ * improved the performance of the sandbox
+ * added a spaceless filter
+ * added max value to the "random" function
+ * made namespace classes the default classes (PSR-0 ones are aliases now)
+ * removed duplicated directory separator in FilesystemLoader
+ * added Twig\Loader\ChainLoader::getLoaders()
+ * changed internal code to use the namespaced classes as much as possible
+
+# 1.37.1 (2019-01-14)
+
+ * fixed regression (key exists check for non ArrayObject objects)
+ * fixed logic in TemplateWrapper
+
+# 1.37.0 (2019-01-14)
+
+ * fixed ArrayObject access with a null value
+ * fixed embedded templates starting with a BOM
+ * fixed using a Twig_TemplateWrapper instance as an argument to extends
+ * switched generated code to use the PHP short array notation
+ * dropped PHP 5.3 support
+ * fixed float representation in compiled templates
+ * added a second argument to the join filter (last separator configuration)
+
+# 1.36.0 (2018-12-16)
+
+ * made sure twig_include returns a string
+ * fixed multi-byte UFT-8 in escape('html_attr')
+ * added the "deprecated" tag
+ * added support for dynamically named tests
+ * fixed GlobalsInterface extended class
+ * fixed filesystem loader throwing an exception instead of returning false
+
+# 1.35.4 (2018-07-13)
+
+ * ensured that syntax errors are triggered with the right line
+ * added the Symfony ctype polyfill as a dependency
+ * "js" filter now produces valid JSON
+
+# 1.35.3 (2018-03-20)
+
+ * fixed block names unicity
+ * fixed counting children of SimpleXMLElement objects
+ * added missing else clause to avoid infinite loops
+ * fixed .. (range operator) in sandbox policy
+
+# 1.35.2 (2018-03-03)
+
+ * fixed a regression in the way the profiler is registered in templates
+
+# 1.35.1 (2018-03-02)
+
+ * added an exception when using "===" instead of "same as"
+ * fixed possible array to string conversion concealing actual error
+ * made variable names deterministic in compiled templates
+ * fixed length filter when passing an instance of IteratorAggregate
+ * fixed Environment::resolveTemplate to accept instances of TemplateWrapper
+
+# 1.35.0 (2017-09-27)
+
+ * added Twig_Profiler_Profile::reset()
+ * fixed use TokenParser to return an empty Node
+ * added RuntimeExtensionInterface
+ * added circular reference detection when loading templates
+
+# 1.34.4 (2017-07-04)
+
+ * added support for runtime loaders in IntegrationTestCase
+ * fixed deprecation when using Twig_Profiler_Dumper_Html
+
+# 1.34.3 (2017-06-07)
+
+ * fixed namespaces introduction
+
+# 1.34.2 (2017-06-05)
+
+ * fixed namespaces introduction
+
+# 1.34.1 (2017-06-05)
+
+ * fixed namespaces introduction
+
+# 1.34.0 (2017-06-05)
+
+ * added support for PHPUnit 6 when testing extensions
+ * fixed PHP 7.2 compatibility
+ * fixed template name generation in Twig_Environment::createTemplate()
+ * removed final tag on Twig_TokenParser_Include
+ * added namespaced aliases for all (non-deprecated) classes and interfaces
+ * dropped HHVM support
+ * dropped PHP 5.2 support
+
+# 1.33.2 (2017-04-20)
+
+ * fixed edge case in the method cache for Twig attributes
+
+# 1.33.1 (2017-04-18)
+
+ * fixed the empty() test
+
+# 1.33.0 (2017-03-22)
+
+ * fixed a race condition handling when writing cache files
+ * "length" filter now returns string length when applied to an object that does
+   not implement \Countable but provides __toString()
+ * "empty" test will now consider the return value of the __toString() method for
+   objects implement __toString() but not \Countable
+ * fixed JS escaping for unicode characters with higher code points
+
+# 1.32.0 (2017-02-26)
+
+ * fixed deprecation notice in Twig_Util_DeprecationCollector
+ * added a PSR-11 compatible runtime loader
+ * added `side` argument to `trim` to allow left or right trimming only.
+
+# 1.31.0 (2017-01-11)
+
+ * added Twig_NodeCaptureInterface for nodes that capture all output
+ * fixed marking the environment as initialized too early
+ * fixed C89 compat for the C extension
+ * turned fatal error into exception when a previously generated cache is corrupted
+ * fixed offline cache warm-ups for embedded templates
+
+# 1.30.0 (2016-12-23)
+
+ * added Twig_FactoryRuntimeLoader
+ * deprecated function/test/filter/tag overriding
+ * deprecated the "disable_c_ext" attribute on Twig_Node_Expression_GetAttr
+
+# 1.29.0 (2016-12-13)
+
+ * fixed sandbox being left enabled if an exception is thrown while rendering
+ * marked some classes as being final (via @final)
+ * made Twig_Error report real source path when possible
+ * added support for {{ _self }} to provide an upgrade path from 1.x to 2.0 (replaces {{ _self.templateName }})
+ * deprecated silent display of undefined blocks
+ * deprecated support for mbstring.func_overload != 0
+
+# 1.28.2 (2016-11-23)
+
+ * fixed precedence between getFoo() and isFoo() in Twig_Template::getAttribute()
+ * improved a deprecation message
+
+# 1.28.1 (2016-11-18)
+
+ * fixed block() function when used with a template argument
+
+# 1.28.0 (2016-11-17)
+
+ * added support for the PHP 7 null coalescing operator for the ?? Twig implementation
+ * exposed a way to access template data and methods in a portable way
+ * changed context access to use the PHP 7 null coalescing operator when available
+ * added the "with" tag
+ * added support for a custom template on the block() function
+ * added "is defined" support for block() and constant()
+ * optimized the way attributes are fetched
+
+# 1.27.0 (2016-10-25)
+
+ * deprecated Twig_Parser::getEnvironment()
+ * deprecated Twig_Parser::addHandler() and Twig_Parser::addNodeVisitor()
+ * deprecated Twig_Compiler::addIndentation()
+ * fixed regression when registering two extensions having the same class name
+ * deprecated Twig_LoaderInterface::getSource() (implement Twig_SourceContextLoaderInterface instead)
+ * fixed the filesystem loader with relative paths
+ * deprecated Twig_Node::getLine() in favor of Twig_Node::getTemplateLine()
+ * deprecated Twig_Template::getSource() in favor of Twig_Template::getSourceContext()
+ * deprecated Twig_Node::getFilename() in favor of Twig_Node::getTemplateName()
+ * deprecated the "filename" escaping strategy (use "name" instead)
+ * added Twig_Source to hold information about the original template
+ * deprecated Twig_Error::getTemplateFile() and Twig_Error::setTemplateFile() in favor of Twig_Error::getTemplateName() and Twig_Error::setTemplateName()
+ * deprecated Parser::getFilename()
+ * fixed template paths when a template name contains a protocol like vfs://
+ * improved debugging with Twig_Sandbox_SecurityError exceptions for disallowed methods and properties
+
+# 1.26.1 (2016-10-05)
+
+ * removed template source code from generated template classes when debug is disabled
+ * fixed default implementation of Twig_Template::getDebugInfo() for better BC
+ * fixed regression on static calls for functions/filters/tests
+
+# 1.26.0 (2016-10-02)
+
+ * added template cache invalidation based on more environment options
+ * added a missing deprecation notice
+ * fixed template paths when a template is stored in a PHAR file
+ * allowed filters/functions/tests implementation to use a different class than the extension they belong to
+ * deprecated Twig_ExtensionInterface::getName()
+
+# 1.25.0 (2016-09-21)
+
+ * changed the way we store template source in template classes
+ * removed usage of realpath in cache keys
+ * fixed Twig cache sharing when used with different versions of PHP
+ * removed embed parent workaround for simple use cases
+ * deprecated the ability to store non Node instances in Node::$nodes
+ * deprecated Twig_Environment::getLexer(), Twig_Environment::getParser(), Twig_Environment::getCompiler()
+ * deprecated Twig_Compiler::getFilename()
+
+# 1.24.2 (2016-09-01)
+
+ * fixed static callables
+ * fixed a potential PHP warning when loading the cache
+ * fixed a case where the autoescaping does not work as expected
+
+# 1.24.1 (2016-05-30)
+
+ * fixed reserved keywords (forbids true, false, null and none keywords for variables names)
+ * fixed support for PHP7 (Throwable support)
+ * marked the following methods as being internals on Twig_Environment:
+   getFunctions(), getFilters(), getTests(), getFunction(), getFilter(), getTest(),
+   getTokenParsers(), getTags(), getNodeVisitors(), getUnaryOperators(), getBinaryOperators(),
+   getFunctions(), getFilters(), getGlobals(), initGlobals(), initExtensions(), and initExtension()
+
+# 1.24.0 (2016-01-25)
+
+ * adding support for the ?? operator
+ * fixed the defined test when used on a constant, a map, or a sequence
+ * undeprecated _self (should only be used to get the template name, not the template instance)
+ * fixed parsing on PHP7
+
+# 1.23.3 (2016-01-11)
+
+ * fixed typo
+
+# 1.23.2 (2015-01-11)
+
+ * added versions in deprecated messages
+ * made file cache tolerant for trailing (back)slashes on directory configuration
+ * deprecated unused Twig_Node_Expression_ExtensionReference class
+
+# 1.23.1 (2015-11-05)
+
+ * fixed some exception messages which triggered PHP warnings
+ * fixed BC on Twig_Test_NodeTestCase
+
+# 1.23.0 (2015-10-29)
+
+ * deprecated the possibility to override an extension by registering another one with the same name
+ * deprecated Twig_ExtensionInterface::getGlobals() (added Twig_Extension_GlobalsInterface for BC)
+ * deprecated Twig_ExtensionInterface::initRuntime() (added Twig_Extension_InitRuntimeInterface for BC)
+ * deprecated Twig_Environment::computeAlternatives()
+
+# 1.22.3 (2015-10-13)
+
+ * fixed regression when using null as a cache strategy
+ * improved performance when checking template freshness
+ * fixed warnings when loaded templates do not exist
+ * fixed template class name generation to prevent possible collisions
+ * fixed logic for custom escapers to call them even on integers and null values
+ * changed template cache names to take into account the Twig C extension
+
+# 1.22.2 (2015-09-22)
+
+ * fixed a race condition in template loading
+
+# 1.22.1 (2015-09-15)
+
+ * fixed regression in template_from_string
+
+# 1.22.0 (2015-09-13)
+
+ * made Twig_Test_IntegrationTestCase more flexible
+ * added an option to force PHP bytecode invalidation when writing a compiled template into the cache
+ * fixed the profiler duration for the root node
+ * changed template cache names to take into account enabled extensions
+ * deprecated Twig_Environment::clearCacheFiles(), Twig_Environment::getCacheFilename(),
+   Twig_Environment::writeCacheFile(), and Twig_Environment::getTemplateClassPrefix()
+ * added a way to override the filesystem template cache system
+ * added a way to get the original template source from Twig_Template
+
+# 1.21.2 (2015-09-09)
+
+ * fixed variable names for the deprecation triggering code
+ * fixed escaping strategy detection based on filename
+ * added Traversable support for replace, merge, and sort
+ * deprecated support for character by character replacement for the "replace" filter
+
+# 1.21.1 (2015-08-26)
+
+ * fixed regression when using the deprecated Twig_Test_* classes
+
+# 1.21.0 (2015-08-24)
+
+ * added deprecation notices for deprecated features
+ * added a deprecation "framework" for filters/functions/tests and test fixtures
+
+# 1.20.0 (2015-08-12)
+
+ * forbid access to the Twig environment from templates and internal parts of Twig_Template
+ * fixed limited RCEs when in sandbox mode
+ * deprecated Twig_Template::getEnvironment()
+ * deprecated the _self variable for usage outside of the from and import tags
+ * added Twig_BaseNodeVisitor to ease the compatibility of node visitors
+   between 1.x and 2.x
+
+# 1.19.0 (2015-07-31)
+
+ * fixed wrong error message when including an undefined template in a child template
+ * added support for variadic filters, functions, and tests
+ * added support for extra positional arguments in macros
+ * added ignore_missing flag to the source function
+ * fixed batch filter with zero items
+ * deprecated Twig_Environment::clearTemplateCache()
+ * fixed sandbox disabling when using the include function
+
+# 1.18.2 (2015-06-06)
+
+ * fixed template/line guessing in exceptions for nested templates
+ * optimized the number of inodes and the size of realpath cache when using the cache
+
+# 1.18.1 (2015-04-19)
+
+ * fixed memory leaks in the C extension
+ * deprecated Twig_Loader_String
+ * fixed the slice filter when used with a SimpleXMLElement object
+ * fixed filesystem loader when trying to load non-files (like directories)
+
+# 1.18.0 (2015-01-25)
+
+ * fixed some error messages where the line was wrong (unknown variables or argument names)
+ * added a new way to customize the main Module node (via empty nodes)
+ * added Twig_Environment::createTemplate() to create a template from a string
+ * added a profiler
+ * fixed filesystem loader cache when different file paths are used for the same template
+
+# 1.17.0 (2015-01-14)
+
+ * added a 'filename' autoescaping strategy, which dynamically chooses the
+   autoescaping strategy for a template based on template file extension.
+
+# 1.16.3 (2014-12-25)
+
+ * fixed regression for dynamic parent templates
+ * fixed cache management with statcache
+ * fixed a regression in the slice filter
+
+# 1.16.2 (2014-10-17)
+
+ * fixed timezone on dates as strings
+ * fixed 2-words test names when a custom node class is not used
+ * fixed macros when using an argument named like a PHP super global (like GET or POST)
+ * fixed date_modify when working with DateTimeImmutable
+ * optimized for loops
+ * fixed multi-byte characters handling in the split filter
+ * fixed a regression in the in operator
+ * fixed a regression in the slice filter
+
+# 1.16.1 (2014-10-10)
+
+ * improved error reporting in a sandboxed template
+ * fixed missing error file/line information under certain circumstances
+ * fixed wrong error line number in some error messages
+ * fixed the in operator to use strict comparisons
+ * sped up the slice filter
+ * fixed for mb function overload mb_substr acting different
+ * fixed the attribute() function when passing a variable for the arguments
+
+# 1.16.0 (2014-07-05)
+
+ * changed url_encode to always encode according to RFC 3986
+ * fixed inheritance in a 'use'-hierarchy
+ * removed the __toString policy check when the sandbox is disabled
+ * fixed recursively calling blocks in templates with inheritance
+
+# 1.15.1 (2014-02-13)
+
+ * fixed the conversion of the special '0000-00-00 00:00' date
+ * added an error message when trying to import an undefined block from a trait
+ * fixed a C extension crash when accessing defined but uninitialized property.
+
+# 1.15.0 (2013-12-06)
+
+ * made ignoreStrictCheck in Template::getAttribute() works with __call() methods throwing BadMethodCallException
+ * added min and max functions
+ * added the round filter
+ * fixed a bug that prevented the optimizers to be enabled/disabled selectively
+ * fixed first and last filters for UTF-8 strings
+ * added a source function to include the content of a template without rendering it
+ * fixed the C extension sandbox behavior when get or set is prepend to method name
+
+# 1.14.2 (2013-10-30)
+
+ * fixed error filename/line when an error occurs in an included file
+ * allowed operators that contain whitespaces to have more than one whitespace
+ * allowed tests to be made of 1 or 2 words (like "same as" or "divisible by")
+
+# 1.14.1 (2013-10-15)
+
+ * made it possible to use named operators as variables
+ * fixed the possibility to have a variable named 'matches'
+ * added support for PHP 5.5 DateTimeInterface
+
+# 1.14.0 (2013-10-03)
+
+ * fixed usage of the html_attr escaping strategy to avoid double-escaping with the html strategy
+ * added new operators: ends with, starts with, and matches
+ * fixed some compatibility issues with HHVM
+ * added a way to add custom escaping strategies
+ * fixed the C extension compilation on Windows
+ * fixed the batch filter when using a fill argument with an exact match of elements to batch
+ * fixed the filesystem loader cache when a template name exists in several namespaces
+ * fixed template_from_string when the template includes or extends other ones
+ * fixed a crash of the C extension on an edge case
+
+# 1.13.2 (2013-08-03)
+
+ * fixed the error line number for an error occurs in and embedded template
+ * fixed crashes of the C extension on some edge cases
+
+# 1.13.1 (2013-06-06)
+
+ * added the possibility to ignore the filesystem constructor argument in Twig_Loader_Filesystem
+ * fixed Twig_Loader_Chain::exists() for a loader which implements Twig_ExistsLoaderInterface
+ * adjusted backtrace call to reduce memory usage when an error occurs
+ * added support for object instances as the second argument of the constant test
+ * fixed the include function when used in an assignment
+
+# 1.13.0 (2013-05-10)
+
+ * fixed getting a numeric-like item on a variable ('09' for instance)
+ * fixed getting a boolean or float key on an array, so it is consistent with PHP's array access:
+   `{{ array[false] }}` behaves the same as `echo $array[false];` (equals `$array[0]`)
+ * made the escape filter 20% faster for happy path (escaping string for html with UTF-8)
+ * changed ☃ to § in tests
+ * enforced usage of named arguments after positional ones
+
+# 1.12.3 (2013-04-08)
+
+ * fixed a security issue in the filesystem loader where it was possible to include a template one
+   level above the configured path
+ * fixed fatal error that should be an exception when adding a filter/function/test too late
+ * added a batch filter
+ * added support for encoding an array as query string in the url_encode filter
+
+# 1.12.2 (2013-02-09)
+
+ * fixed the timezone used by the date filter and function when the given date contains a timezone (like 2010-01-28T15:00:00+02:00)
+ * fixed globals when getGlobals is called early on
+ * added the first and last filter
+
+# 1.12.1 (2013-01-15)
+
+ * added support for object instances as the second argument of the constant function
+ * relaxed globals management to avoid a BC break
+ * added support for {{ some_string[:2] }}
+
+# 1.12.0 (2013-01-08)
+
+ * added verbatim as an alias for the raw tag to avoid confusion with the raw filter
+ * fixed registration of tests and functions as anonymous functions
+ * fixed globals management
+
+# 1.12.0-RC1 (2012-12-29)
+
+ * added an include function (does the same as the include tag but in a more flexible way)
+ * added the ability to use any PHP callable to define filters, functions, and tests
+ * added a syntax error when using a loop variable that is not defined
+ * added the ability to set default values for macro arguments
+ * added support for named arguments for filters, tests, and functions
+ * moved filters/functions/tests syntax errors to the parser
+ * added support for extended ternary operator syntaxes
+
+# 1.11.1 (2012-11-11)
+
+ * fixed debug info line numbering (was off by 2)
+ * fixed escaping when calling a macro inside another one (regression introduced in 1.9.1)
+ * optimized variable access on PHP 5.4
+ * fixed a crash of the C extension when an exception was thrown from a macro called without being imported (using _self.XXX)
+
+# 1.11.0 (2012-11-07)
+
+ * fixed macro compilation when a variable name is a PHP reserved keyword
+ * changed the date filter behavior to always apply the default timezone, except if false is passed as the timezone
+ * fixed bitwise operator precedences
+ * added the template_from_string function
+ * fixed default timezone usage for the date function
+ * optimized the way Twig exceptions are managed (to make them faster)
+ * added Twig_ExistsLoaderInterface (implementing this interface in your loader make the chain loader much faster)
+
+# 1.10.3 (2012-10-19)
+
+ * fixed wrong template location in some error messages
+ * reverted a BC break introduced in 1.10.2
+ * added a split filter
+
+# 1.10.2 (2012-10-15)
+
+ * fixed macro calls on PHP 5.4
+
+# 1.10.1 (2012-10-15)
+
+ * made a speed optimization to macro calls when imported via the "import" tag
+ * fixed C extension compilation on Windows
+ * fixed a segfault in the C extension when using DateTime objects
+
+# 1.10.0 (2012-09-28)
+
+ * extracted functional tests framework to make it reusable for third-party extensions
+ * added namespaced templates support in Twig_Loader_Filesystem
+ * added Twig_Loader_Filesystem::prependPath()
+ * fixed an error when a token parser pass a closure as a test to the subparse() method
+
+# 1.9.2 (2012-08-25)
+
+ * fixed the in operator for objects that contain circular references
+ * fixed the C extension when accessing a public property of an object implementing the \ArrayAccess interface
+
+# 1.9.1 (2012-07-22)
+
+ * optimized macro calls when auto-escaping is on
+ * fixed wrong parent class for Twig_Function_Node
+ * made Twig_Loader_Chain more explicit about problems
+
+# 1.9.0 (2012-07-13)
+
+ * made the parsing independent of the template loaders
+ * fixed exception trace when an error occurs when rendering a child template
+ * added escaping strategies for CSS, URL, and HTML attributes
+ * fixed nested embed tag calls
+ * added the date_modify filter
+
+# 1.8.3 (2012-06-17)
+
+ * fixed paths in the filesystem loader when passing a path that ends with a slash or a backslash
+ * fixed escaping when a project defines a function named html or js
+ * fixed chmod mode to apply the umask correctly
+
+# 1.8.2 (2012-05-30)
+
+ * added the abs filter
+ * fixed a regression when using a number in template attributes
+ * fixed compiler when mbstring.func_overload is set to 2
+ * fixed DateTimeZone support in date filter
+
+# 1.8.1 (2012-05-17)
+
+ * fixed a regression when dealing with SimpleXMLElement instances in templates
+ * fixed "is_safe" value for the "dump" function when "html_errors" is not defined in php.ini
+ * switched to use mbstring whenever possible instead of iconv (you might need to update your encoding as mbstring and iconv encoding names sometimes differ)
+
+# 1.8.0 (2012-05-08)
+
+ * enforced interface when adding tests, filters, functions, and node visitors from extensions
+ * fixed a side-effect of the date filter where the timezone might be changed
+ * simplified usage of the autoescape tag; the only (optional) argument is now the escaping strategy or false (with a BC layer)
+ * added a way to dynamically change the auto-escaping strategy according to the template "filename"
+ * changed the autoescape option to also accept a supported escaping strategy (for BC, true is equivalent to html)
+ * added an embed tag
+
+# 1.7.0 (2012-04-24)
+
+ * fixed a PHP warning when using CIFS
+ * fixed template line number in some exceptions
+ * added an iterable test
+ * added an error when defining two blocks with the same name in a template
+ * added the preserves_safety option for filters
+ * fixed a PHP notice when trying to access a key on a non-object/array variable
+ * enhanced error reporting when the template file is an instance of SplFileInfo
+ * added Twig_Environment::mergeGlobals()
+ * added compilation checks to avoid misuses of the sandbox tag
+ * fixed filesystem loader freshness logic for high traffic websites
+ * fixed random function when charset is null
+
+# 1.6.5 (2012-04-11)
+
+ * fixed a regression when a template only extends another one without defining any blocks
+
+# 1.6.4 (2012-04-02)
+
+ * fixed PHP notice in Twig_Error::guessTemplateLine() introduced in 1.6.3
+ * fixed performance when compiling large files
+ * optimized parent template creation when the template does not use dynamic inheritance
+
+# 1.6.3 (2012-03-22)
+
+ * fixed usage of Z_ADDREF_P for PHP 5.2 in the C extension
+ * fixed compilation of numeric values used in templates when using a locale where the decimal separator is not a dot
+ * made the strategy used to guess the real template file name and line number in exception messages much faster and more accurate
+
+# 1.6.2 (2012-03-18)
+
+ * fixed sandbox mode when used with inheritance
+ * added preserveKeys support for the slice filter
+ * fixed the date filter when a DateTime instance is passed with a specific timezone
+ * added a trim filter
+
+# 1.6.1 (2012-02-29)
+
+ * fixed Twig C extension
+ * removed the creation of Twig_Markup instances when not needed
+ * added a way to set the default global timezone for dates
+ * fixed the slice filter on strings when the length is not specified
+ * fixed the creation of the cache directory in case of a race condition
+
+# 1.6.0 (2012-02-04)
+
+ * fixed raw blocks when used with the whitespace trim option
+ * made a speed optimization to macro calls when imported via the "from" tag
+ * fixed globals, parsers, visitors, filters, tests, and functions management in Twig_Environment when a new one or new extension is added
+ * fixed the attribute function when passing arguments
+ * added slice notation support for the [] operator (syntactic sugar for the slice operator)
+ * added a slice filter
+ * added string support for the reverse filter
+ * fixed the empty test and the length filter for Twig_Markup instances
+ * added a date function to ease date comparison
+ * fixed unary operators precedence
+ * added recursive parsing support in the parser
+ * added string and integer handling for the random function
+
+# 1.5.1 (2012-01-05)
+
+ * fixed a regression when parsing strings
+
+# 1.5.0 (2012-01-04)
+
+ * added Traversable objects support for the join filter
+
+# 1.5.0-RC2 (2011-12-30)
+
+ * added a way to set the default global date interval format
+ * fixed the date filter for DateInterval instances (setTimezone() does not exist for them)
+ * refactored Twig_Template::display() to ease its extension
+ * added a number_format filter
+
+# 1.5.0-RC1 (2011-12-26)
+
+ * removed the need to quote hash keys
+ * allowed hash keys to be any expression
+ * added a do tag
+ * added a flush tag
+ * added support for dynamically named filters and functions
+ * added a dump function to help debugging templates
+ * added a nl2br filter
+ * added a random function
+ * added a way to change the default format for the date filter
+ * fixed the lexer when an operator ending with a letter ends a line
+ * added string interpolation support
+ * enhanced exceptions for unknown filters, functions, tests, and tags
+
+# 1.4.0 (2011-12-07)
+
+ * fixed lexer when using big numbers (> PHP_INT_MAX)
+ * added missing preserveKeys argument to the reverse filter
+ * fixed macros containing filter tag calls
+
+# 1.4.0-RC2 (2011-11-27)
+
+ * removed usage of Reflection in Twig_Template::getAttribute()
+ * added a C extension that can optionally replace Twig_Template::getAttribute()
+ * added negative timestamp support to the date filter
+
+# 1.4.0-RC1 (2011-11-20)
+
+ * optimized variable access when using PHP 5.4
+ * changed the precedence of the .. operator to be more consistent with languages that implements such a feature like Ruby
+ * added an Exception to Twig_Loader_Array::isFresh() method when the template does not exist to be consistent with other loaders
+ * added Twig_Function_Node to allow more complex functions to have their own Node class
+ * added Twig_Filter_Node to allow more complex filters to have their own Node class
+ * added Twig_Test_Node to allow more complex tests to have their own Node class
+ * added a better error message when a template is empty but contain a BOM
+ * fixed "in" operator for empty strings
+ * fixed the "defined" test and the "default" filter (now works with more than one call (foo.bar.foo) and for both values of the strict_variables option)
+ * changed the way extensions are loaded (addFilter/addFunction/addGlobal/addTest/addNodeVisitor/addTokenParser/addExtension can now be called in any order)
+ * added Twig_Environment::display()
+ * made the escape filter smarter when the encoding is not supported by PHP
+ * added a convert_encoding filter
+ * moved all node manipulations outside the compile() Node method
+ * made several speed optimizations
+
+# 1.3.0 (2011-10-08)
+
+no changes
+
+# 1.3.0-RC1 (2011-10-04)
+
+ * added an optimization for the parent() function
+ * added cache reloading when auto_reload is true and an extension has been modified
+ * added the possibility to force the escaping of a string already marked as safe (instance of Twig_Markup)
+ * allowed empty templates to be used as traits
+ * added traits support for the "parent" function
+
+# 1.2.0 (2011-09-13)
+
+no changes
+
+# 1.2.0-RC1 (2011-09-10)
+
+ * enhanced the exception when a tag remains unclosed
+ * added support for empty Countable objects for the "empty" test
+ * fixed algorithm that determines if a template using inheritance is valid (no output between block definitions)
+ * added better support for encoding problems when escaping a string (available as of PHP 5.4)
+ * added a way to ignore a missing template when using the "include" tag ({% include "foo" ignore missing %})
+ * added support for an array of templates to the "include" and "extends" tags ({% include ['foo', 'bar'] %})
+ * added support for bitwise operators in expressions
+ * added the "attribute" function to allow getting dynamic attributes on variables
+ * added Twig_Loader_Chain
+ * added Twig_Loader_Array::setTemplate()
+ * added an optimization for the set tag when used to capture a large chunk of static text
+ * changed name regex to match PHP one "[a-zA-Z_\x7f-\xff][a-zA-Z0-9_\x7f-\xff]*" (works for blocks, tags, functions, filters, and macros)
+ * removed the possibility to use the "extends" tag from a block
+ * added "if" modifier support to "for" loops
+
+# 1.1.2 (2011-07-30)
+
+ * fixed json_encode filter on PHP 5.2
+ * fixed regression introduced in 1.1.1 ({{ block(foo|lower) }})
+ * fixed inheritance when using conditional parents
+ * fixed compilation of templates when the body of a child template is not empty
+ * fixed output when a macro throws an exception
+ * fixed a parsing problem when a large chunk of text is enclosed in a comment tag
+ * added PHPDoc for all Token parsers and Core extension functions
+
+# 1.1.1 (2011-07-17)
+
+ * added a performance optimization in the Optimizer (also helps to lower the number of nested level calls)
+ * made some performance improvement for some edge cases
+
+# 1.1.0 (2011-06-28)
+
+ * fixed json_encode filter
+
+# 1.1.0-RC3 (2011-06-24)
+
+ * fixed method case-sensitivity when using the sandbox mode
+ * added timezone support for the date filter
+ * fixed possible security problems with NUL bytes
+
+# 1.1.0-RC2 (2011-06-16)
+
+ * added an exception when the template passed to "use" is not a string
+ * made 'a.b is defined' not throw an exception if a is not defined (in strict mode)
+ * added {% line \d+ %} directive
+
+# 1.1.0-RC1 (2011-05-28)
+
+Flush your cache after upgrading.
+
+ * fixed date filter when using a timestamp
+ * fixed the defined test for some cases
+ * fixed a parsing problem when a large chunk of text is enclosed in a raw tag
+ * added support for horizontal reuse of template blocks (see docs for more information)
+ * added whitespace control modifier to all tags (see docs for more information)
+ * added null as an alias for none (the null test is also an alias for the none test now)
+ * made TRUE, FALSE, NONE equivalent to their lowercase counterparts
+ * wrapped all compilation and runtime exceptions with Twig_Error_Runtime and added logic to guess the template name and line
+ * moved display() method to Twig_Template (generated templates should now use doDisplay() instead)
+
+# 1.0.0 (2011-03-27)
+
+ * fixed output when using mbstring
+ * fixed duplicate call of methods when using the sandbox
+ * made the charset configurable for the escape filter
+
+# 1.0.0-RC2 (2011-02-21)
+
+ * changed the way {% set %} works when capturing (the content is now marked as safe)
+ * added support for macro name in the endmacro tag
+ * make Twig_Error compatible with PHP 5.3.0 >
+ * fixed an infinite loop on some Windows configurations
+ * fixed the "length" filter for numbers
+ * fixed Template::getAttribute() as properties in PHP are case sensitive
+ * removed coupling between Twig_Node and Twig_Template
+ * fixed the ternary operator precedence rule
+
+# 1.0.0-RC1 (2011-01-09)
+
+Backward incompatibilities:
+
+ * the "items" filter, which has been deprecated for quite a long time now, has been removed
+ * the "range" filter has been converted to a function: 0|range(10) -> range(0, 10)
+ * the "constant" filter has been converted to a function: {{ some_date|date('DATE_W3C'|constant) }} -> {{ some_date|date(constant('DATE_W3C')) }}
+ * the "cycle" filter has been converted to a function: {{ ['odd', 'even']|cycle(i) }} -> {{ cycle(['odd', 'even'], i) }}
+ * the "for" tag does not support "joined by" anymore
+ * the "autoescape" first argument is now "true"/"false" (instead of "on"/"off")
+ * the "parent" tag has been replaced by a "parent" function ({{ parent() }} instead of {% parent %})
+ * the "display" tag has been replaced by a "block" function ({{ block('title') }} instead of {% display title %})
+ * removed the grammar and simple token parser (moved to the Twig Extensions repository)
+
+Changes:
+
+ * added "needs_context" option for filters and functions (the context is then passed as a first argument)
+ * added global variables support
+ * made macros return their value instead of echoing directly (fixes calling a macro in sandbox mode)
+ * added the "from" tag to import macros as functions
+ * added support for functions (a function is just syntactic sugar for a getAttribute() call)
+ * made macros callable when sandbox mode is enabled
+ * added an exception when a macro uses a reserved name
+ * the "default" filter now uses the "empty" test instead of just checking for null
+ * added the "empty" test
+
+# 0.9.10 (2010-12-16)
+
+Backward incompatibilities:
+
+ * The Escaper extension is enabled by default, which means that all displayed
+   variables are now automatically escaped. You can revert to the previous
+   behavior by removing the extension via $env->removeExtension('escaper')
+   or just set the 'autoescape' option to 'false'.
+ * removed the "without loop" attribute for the "for" tag (not needed anymore
+   as the Optimizer take care of that for most cases)
+ * arrays and hashes have now a different syntax
+     * arrays keep the same syntax with square brackets: [1, 2]
+     * hashes now use curly braces (["a": "b"] should now be written as {"a": "b"})
+     * support for "arrays with keys" and "hashes without keys" is not supported anymore ([1, "foo": "bar"] or {"foo": "bar", 1})
+ * the i18n extension is now part of the Twig Extensions repository
+
+Changes:
+
+ * added the merge filter
+ * removed 'is_escaper' option for filters (a left over from the previous version) -- you must use 'is_safe' now instead
+ * fixed usage of operators as method names (like is, in, and not)
+ * changed the order of execution for node visitors
+ * fixed default() filter behavior when used with strict_variables set to on
+ * fixed filesystem loader compatibility with PHAR files
+ * enhanced error messages when an unexpected token is parsed in an expression
+ * fixed filename not being added to syntax error messages
+ * added the autoescape option to enable/disable autoescaping
+ * removed the newline after a comment (mimics PHP behavior)
+ * added a syntax error exception when parent block is used on a template that does not extend another one
+ * made the Escaper extension enabled by default
+ * fixed sandbox extension when used with auto output escaping
+ * fixed escaper when wrapping a Twig_Node_Print (the original class must be preserved)
+ * added an Optimizer extension (enabled by default; optimizes "for" loops and "raw" filters)
+ * added priority to node visitors
+
+# 0.9.9 (2010-11-28)
+
+Backward incompatibilities:
+ * the self special variable has been renamed to _self
+ * the odd and even filters are now tests:
+     {{ foo|odd }} must now be written {{ foo is odd }}
+ * the "safe" filter has been renamed to "raw"
+ * in Node classes,
+        sub-nodes are now accessed via getNode() (instead of property access)
+        attributes via getAttribute() (instead of array access)
+ * the urlencode filter had been renamed to url_encode
+ * the include tag now merges the passed variables with the current context by default
+   (the old behavior is still possible by adding the "only" keyword)
+ * moved Exceptions to Twig_Error_* (Twig_SyntaxError/Twig_RuntimeError are now Twig_Error_Syntax/Twig_Error_Runtime)
+ * removed support for {{ 1 < i < 3 }} (use {{ i > 1 and i < 3 }} instead)
+ * the "in" filter has been removed ({{ a|in(b) }} should now be written {{ a in b }})
+
+Changes:
+ * added file and line to Twig_Error_Runtime exceptions thrown from Twig_Template
+ * changed trans tag to accept any variable for the plural count
+ * fixed sandbox mode (__toString() method check was not enforced if called implicitly from complex statements)
+ * added the ** (power) operator
+ * changed the algorithm used for parsing expressions
+ * added the spaceless tag
+ * removed trim_blocks option
+ * added support for is*() methods for attributes (foo.bar now looks for foo->getBar() or foo->isBar())
+ * changed all exceptions to extend Twig_Error
+ * fixed unary expressions ({{ not(1 or 0) }})
+ * fixed child templates (with an extend tag) that uses one or more imports
+ * added support for {{ 1 not in [2, 3] }} (more readable than the current {{ not (1 in [2, 3]) }})
+ * escaping has been rewritten
+ * the implementation of template inheritance has been rewritten
+   (blocks can now be called individually and still work with inheritance)
+ * fixed error handling for if tag when a syntax error occurs within a subparse process
+ * added a way to implement custom logic for resolving token parsers given a tag name
+ * fixed js escaper to be stricter (now uses a whilelist-based js escaper)
+ * added the following filers: "constant", "trans", "replace", "json_encode"
+ * added a "constant" test
+ * fixed objects with __toString() not being autoescaped
+ * fixed subscript expressions when calling __call() (methods now keep the case)
+ * added "test" feature (accessible via the "is" operator)
+ * removed the debug tag (should be done in an extension)
+ * fixed trans tag when no vars are used in plural form
+ * fixed race condition when writing template cache
+ * added the special _charset variable to reference the current charset
+ * added the special _context variable to reference the current context
+ * renamed self to _self (to avoid conflict)
+ * fixed Twig_Template::getAttribute() for protected properties
+
+# 0.9.8 (2010-06-28)
+
+Backward incompatibilities:
+ * the trans tag plural count is now attached to the plural tag:
+    old: `{% trans count %}...{% plural %}...{% endtrans %}`
+    new: `{% trans %}...{% plural count %}...{% endtrans %}`
+
+ * added a way to translate strings coming from a variable ({% trans var %})
+ * fixed trans tag when used with the Escaper extension
+ * fixed default cache umask
+ * removed Twig_Template instances from the debug tag output
+ * fixed objects with __isset() defined
+ * fixed set tag when used with a capture
+ * fixed type hinting for Twig_Environment::addFilter() method
+
+# 0.9.7 (2010-06-12)
+
+Backward incompatibilities:
+ * changed 'as' to '=' for the set tag ({% set title as "Title" %} must now be {% set title = "Title" %})
+ * removed the sandboxed attribute of the include tag (use the new sandbox tag instead)
+ * refactored the Node system (if you have custom nodes, you will have to update them to use the new API)
+
+ * added self as a special variable that refers to the current template (useful for importing macros from the current template)
+ * added Twig_Template instance support to the include tag
+ * added support for dynamic and conditional inheritance ({% extends some_var %} and {% extends standalone ? "minimum" : "base" %})
+ * added a grammar sub-framework to ease the creation of custom tags
+ * fixed the for tag for large arrays (some loop variables are now only available for arrays and objects that implement the Countable interface)
+ * removed the Twig_Resource::resolveMissingFilter() method
+ * fixed the filter tag which did not apply filtering to included files
+ * added a bunch of unit tests
+ * added a bunch of phpdoc
+ * added a sandbox tag in the sandbox extension
+ * changed the date filter to support any date format supported by DateTime
+ * added strict_variable setting to throw an exception when an invalid variable is used in a template (disabled by default)
+ * added the lexer, parser, and compiler as arguments to the Twig_Environment constructor
+ * changed the cache option to only accepts an explicit path to a cache directory or false
+ * added a way to add token parsers, filters, and visitors without creating an extension
+ * added three interfaces: Twig_NodeInterface, Twig_TokenParserInterface, and Twig_FilterInterface
+ * changed the generated code to match the new coding standards
+ * fixed sandbox mode (__toString() method check was not enforced if called implicitly from a simple statement like {{ article }})
+ * added an exception when a child template has a non-empty body (as it is always ignored when rendering)
+
+# 0.9.6 (2010-05-12)
+
+ * fixed variables defined outside a loop and for which the value changes in a for loop
+ * fixed the test suite for PHP 5.2 and older versions of PHPUnit
+ * added support for __call() in expression resolution
+ * fixed node visiting for macros (macros are now visited by visitors as any other node)
+ * fixed nested block definitions with a parent call (rarely useful but nonetheless supported now)
+ * added the cycle filter
+ * fixed the Lexer when mbstring.func_overload is used with an mbstring.internal_encoding different from ASCII
+ * added a long-syntax for the set tag ({% set foo %}...{% endset %})
+ * unit tests are now powered by PHPUnit
+ * added support for gettext via the `i18n` extension
+ * fixed twig_capitalize_string_filter() and fixed twig_length_filter() when used with UTF-8 values
+ * added a more useful exception if an if tag is not closed properly
+ * added support for escaping strategy in the autoescape tag
+ * fixed lexer when a template has a big chunk of text between/in a block
+
+# 0.9.5 (2010-01-20)
+
+As for any new release, don't forget to remove all cached templates after
+upgrading.
+
+If you have defined custom filters, you MUST upgrade them for this release. To
+upgrade, replace "array" with "new Twig_Filter_Function", and replace the
+environment constant by the "needs_environment" option:
+
+  // before
+  'even'   => array('twig_is_even_filter', false),
+  'escape' => array('twig_escape_filter', true),
+
+  // after
+  'even'   => new Twig_Filter_Function('twig_is_even_filter'),
+  'escape' => new Twig_Filter_Function('twig_escape_filter', array('needs_environment' => true)),
+
+If you have created NodeTransformer classes, you will need to upgrade them to
+the new interface (please note that the interface is not yet considered
+stable).
+
+ * fixed list nodes that did not extend the Twig_NodeListInterface
+ * added the "without loop" option to the for tag (it disables the generation of the loop variable)
+ * refactored node transformers to node visitors
+ * fixed automatic-escaping for blocks
+ * added a way to specify variables to pass to an included template
+ * changed the automatic-escaping rules to be more sensible and more configurable in custom filters (the documentation lists all the rules)
+ * improved the filter system to allow object methods to be used as filters
+ * changed the Array and String loaders to actually make use of the cache mechanism
+ * included the default filter function definitions in the extension class files directly (Core, Escaper)
+ * added the // operator (like the floor() PHP function)
+ * added the .. operator (as a syntactic sugar for the range filter when the step is 1)
+ * added the in operator (as a syntactic sugar for the in filter)
+ * added the following filters in the Core extension: in, range
+ * added support for arrays (same behavior as in PHP, a mix between lists and dictionaries, arrays and hashes)
+ * enhanced some error messages to provide better feedback in case of parsing errors
+
+# 0.9.4 (2009-12-02)
+
+If you have custom loaders, you MUST upgrade them for this release: The
+Twig_Loader base class has been removed, and the Twig_LoaderInterface has also
+been changed (see the source code for more information or the documentation).
+
+ * added support for DateTime instances for the date filter
+ * fixed loop.last when the array only has one item
+ * made it possible to insert newlines in tag and variable blocks
+ * fixed a bug when a literal '\n' were present in a template text
+ * fixed bug when the filename of a template contains */
+ * refactored loaders
+
+# 0.9.3 (2009-11-11)
+
+This release is NOT backward compatible with the previous releases.
+
+  The loaders do not take the cache and autoReload arguments anymore. Instead,
+  the Twig_Environment class has two new options: cache and auto_reload.
+  Upgrading your code means changing this kind of code:
+
+      $loader = new Twig_Loader_Filesystem('/path/to/templates', '/path/to/compilation_cache', true);
+      $twig = new Twig_Environment($loader);
+
+  to something like this:
+
+      $loader = new Twig_Loader_Filesystem('/path/to/templates');
+      $twig = new Twig_Environment($loader, array(
+        'cache' => '/path/to/compilation_cache',
+        'auto_reload' => true,
+      ));
+
+ * deprecated the "items" filter as it is not needed anymore
+ * made cache and auto_reload options of Twig_Environment instead of arguments of Twig_Loader
+ * optimized template loading speed
+ * removed output when an error occurs in a template and render() is used
+ * made major speed improvements for loops (up to 300% on even the smallest loops)
+ * added properties as part of the sandbox mode
+ * added public properties support (obj.item can now be the item property on the obj object)
+ * extended set tag to support expression as value ({% set foo as 'foo' ~ 'bar' %} )
+ * fixed bug when \ was used in HTML
+
+# 0.9.2 (2009-10-29)
+
+ * made some speed optimizations
+ * changed the cache extension to .php
+ * added a js escaping strategy
+ * added support for short block tag
+ * changed the filter tag to allow chained filters
+ * made lexer more flexible as you can now change the default delimiters
+ * added set tag
+ * changed default directory permission when cache dir does not exist (more secure)
+ * added macro support
+ * changed filters first optional argument to be a Twig_Environment instance instead of a Twig_Template instance
+ * made Twig_Autoloader::autoload() a static method
+ * avoid writing template file if an error occurs
+ * added $ escaping when outputting raw strings
+ * enhanced some error messages to ease debugging
+ * fixed empty cache files when the template contains an error
+
+# 0.9.1 (2009-10-14)
+
+  * fixed a bug in PHP 5.2.6
+  * fixed numbers with one than one decimal
+  * added support for method calls with arguments ({{ foo.bar('a', 43) }})
+  * made small speed optimizations
+  * made minor tweaks to allow better extensibility and flexibility
+
+# 0.9.0 (2009-10-12)
+
+ * Initial release
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/LICENSE b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/LICENSE
new file mode 100644
index 0000000..4371e42
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/LICENSE
@@ -0,0 +1,27 @@
+Copyright (c) 2009-2021 by the Twig Team.
+
+All rights reserved.
+
+Redistribution and use in source and binary forms, with or without modification,
+are permitted provided that the following conditions are met:
+
+    * Redistributions of source code must retain the above copyright notice,
+      this list of conditions and the following disclaimer.
+    * Redistributions in binary form must reproduce the above copyright notice,
+      this list of conditions and the following disclaimer in the documentation
+      and/or other materials provided with the distribution.
+    * Neither the name of Twig nor the names of its contributors
+      may be used to endorse or promote products derived from this software
+      without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
+CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
+EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
+PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
+LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/README.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/README.rst
new file mode 100644
index 0000000..d896ff5
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/README.rst
@@ -0,0 +1,24 @@
+Twig, the flexible, fast, and secure template language for PHP
+==============================================================
+
+Twig is a template language for PHP, released under the new BSD license (code
+and documentation).
+
+Twig uses a syntax similar to the Django and Jinja template languages which
+inspired the Twig runtime environment.
+
+Sponsors
+--------
+
+.. raw:: html
+
+    <a href="https://blackfire.io/docs/introduction?utm_source=twig&utm_medium=github_readme&utm_campaign=logo">
+        <img src="https://static.blackfire.io/assets/intemporals/logo/png/blackfire-io_secondary_horizontal_transparent.png?1" width="255px" alt="Blackfire.io">
+    </a>
+
+More Information
+----------------
+
+Read the `documentation`_ for more information.
+
+.. _documentation: https://twig.symfony.com/documentation
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/composer.json b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/composer.json
new file mode 100644
index 0000000..c344849
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/composer.json
@@ -0,0 +1,50 @@
+{
+    "name": "twig/twig",
+    "type": "library",
+    "description": "Twig, the flexible, fast, and secure template language for PHP",
+    "keywords": ["templating"],
+    "homepage": "https://twig.symfony.com",
+    "license": "BSD-3-Clause",
+    "minimum-stability": "dev",
+    "authors": [
+        {
+            "name": "Fabien Potencier",
+            "email": "fabien@symfony.com",
+            "homepage": "http://fabien.potencier.org",
+            "role": "Lead Developer"
+        },
+        {
+            "name": "Twig Team",
+            "role": "Contributors"
+        },
+        {
+            "name": "Armin Ronacher",
+            "email": "armin.ronacher@active-4.com",
+            "role": "Project Founder"
+        }
+    ],
+    "require": {
+        "php": ">=7.2.5",
+        "symfony/polyfill-mbstring": "^1.3",
+        "symfony/polyfill-ctype": "^1.8"
+    },
+    "require-dev": {
+        "symfony/phpunit-bridge": "^4.4.9|^5.0.9",
+        "psr/container": "^1.0"
+    },
+    "autoload": {
+        "psr-4" : {
+            "Twig\\" : "src/"
+        }
+    },
+    "autoload-dev": {
+        "psr-4" : {
+            "Twig\\Tests\\" : "tests/"
+        }
+    },
+    "extra": {
+        "branch-alias": {
+            "dev-master": "3.3-dev"
+        }
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/.doctor-rst.yaml b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/.doctor-rst.yaml
new file mode 100644
index 0000000..bfb4042
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/.doctor-rst.yaml
@@ -0,0 +1,54 @@
+rules:
+    american_english: ~
+    avoid_repetetive_words: ~
+    blank_line_after_directive: ~
+    blank_line_before_directive: ~
+    composer_dev_option_not_at_the_end: ~
+    correct_code_block_directive_based_on_the_content: ~
+    deprecated_directive_should_have_version: ~
+    ensure_order_of_code_blocks_in_configuration_block: ~
+    extension_xlf_instead_of_xliff: ~
+    indention: ~
+    lowercase_as_in_use_statements: ~
+    max_blank_lines:
+        max: 2
+    no_blank_line_after_filepath_in_php_code_block: ~
+    no_blank_line_after_filepath_in_twig_code_block: ~
+    no_blank_line_after_filepath_in_xml_code_block: ~
+    no_blank_line_after_filepath_in_yaml_code_block: ~
+    no_composer_req: ~
+    no_explicit_use_of_code_block_php: ~
+    no_inheritdoc: ~
+    no_namespace_after_use_statements: ~
+    no_php_open_tag_in_code_block_php_directive: ~
+    no_space_before_self_xml_closing_tag: ~
+    ordered_use_statements: ~
+    php_prefix_before_bin_console: ~
+    replace_code_block_types: ~
+    replacement: ~
+    short_array_syntax: ~
+    typo: ~
+    unused_links: ~
+    use_deprecated_directive_instead_of_versionadded: ~
+    use_https_xsd_urls: ~
+    valid_inline_highlighted_namespaces: ~
+    valid_use_statements: ~
+    versionadded_directive_should_have_version: ~
+    yaml_instead_of_yml_suffix: ~
+    yarn_dev_option_at_the_end: ~
+
+    versionadded_directive_major_version:
+        major_version: 3
+
+    versionadded_directive_min_version:
+        min_version: '3.0'
+
+    deprecated_directive_major_version:
+        major_version: 3
+
+    deprecated_directive_min_version:
+        min_version: '3.0'
+
+whitelist:
+    lines:
+        - 'I like Twig.<br />'
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/_build/.requirements.txt b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/_build/.requirements.txt
new file mode 100644
index 0000000..47f076e
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/_build/.requirements.txt
@@ -0,0 +1,6 @@
+docutils==0.13.1
+Pygments==2.2.0
+sphinx==1.8.5
+git+https://github.com/fabpot/sphinx-php.git@v2.0.0#egg_name=sphinx-php
+jsx-lexer===0.0.8
+sphinx_rtd_theme==0.5.0
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/_build/Makefile b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/_build/Makefile
new file mode 100644
index 0000000..25b6600
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/_build/Makefile
@@ -0,0 +1,153 @@
+# Makefile for Sphinx documentation
+#
+
+# You can set these variables from the command line.
+SPHINXOPTS    =
+SPHINXBUILD   = sphinx-build
+PAPER         =
+BUILDDIR      = .
+
+# Internal variables.
+PAPEROPT_a4     = -D latex_paper_size=a4
+PAPEROPT_letter = -D latex_paper_size=letter
+ALLSPHINXOPTS   = -c $(BUILDDIR) -d $(BUILDDIR)/doctrees $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) ../
+# the i18n builder cannot share the environment and doctrees with the others
+I18NSPHINXOPTS  = $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) .
+
+.PHONY: help clean html dirhtml singlehtml pickle json htmlhelp qthelp devhelp epub latex latexpdf text man changes linkcheck doctest gettext
+
+help:
+	@echo "Please use \`make <target>' where <target> is one of"
+	@echo "  html       to make standalone HTML files"
+	@echo "  dirhtml    to make HTML files named index.html in directories"
+	@echo "  singlehtml to make a single large HTML file"
+	@echo "  pickle     to make pickle files"
+	@echo "  json       to make JSON files"
+	@echo "  htmlhelp   to make HTML files and a HTML help project"
+	@echo "  qthelp     to make HTML files and a qthelp project"
+	@echo "  devhelp    to make HTML files and a Devhelp project"
+	@echo "  epub       to make an epub"
+	@echo "  latex      to make LaTeX files, you can set PAPER=a4 or PAPER=letter"
+	@echo "  latexpdf   to make LaTeX files and run them through pdflatex"
+	@echo "  text       to make text files"
+	@echo "  man        to make manual pages"
+	@echo "  texinfo    to make Texinfo files"
+	@echo "  info       to make Texinfo files and run them through makeinfo"
+	@echo "  gettext    to make PO message catalogs"
+	@echo "  changes    to make an overview of all changed/added/deprecated items"
+	@echo "  linkcheck  to check all external links for integrity"
+	@echo "  doctest    to run all doctests embedded in the documentation (if enabled)"
+
+clean:
+	-rm -rf $(BUILDDIR)/*
+
+html:
+	$(SPHINXBUILD) -b html $(ALLSPHINXOPTS) $(BUILDDIR)/html
+	@echo
+	@echo "Build finished. The HTML pages are in $(BUILDDIR)/html."
+
+dirhtml:
+	$(SPHINXBUILD) -b dirhtml $(ALLSPHINXOPTS) $(BUILDDIR)/dirhtml
+	@echo
+	@echo "Build finished. The HTML pages are in $(BUILDDIR)/dirhtml."
+
+singlehtml:
+	$(SPHINXBUILD) -b singlehtml $(ALLSPHINXOPTS) $(BUILDDIR)/singlehtml
+	@echo
+	@echo "Build finished. The HTML page is in $(BUILDDIR)/singlehtml."
+
+pickle:
+	$(SPHINXBUILD) -b pickle $(ALLSPHINXOPTS) $(BUILDDIR)/pickle
+	@echo
+	@echo "Build finished; now you can process the pickle files."
+
+json:
+	$(SPHINXBUILD) -b json $(ALLSPHINXOPTS) $(BUILDDIR)/json
+	@echo
+	@echo "Build finished; now you can process the JSON files."
+
+htmlhelp:
+	$(SPHINXBUILD) -b htmlhelp $(ALLSPHINXOPTS) $(BUILDDIR)/htmlhelp
+	@echo
+	@echo "Build finished; now you can run HTML Help Workshop with the" \
+	      ".hhp project file in $(BUILDDIR)/htmlhelp."
+
+qthelp:
+	$(SPHINXBUILD) -b qthelp $(ALLSPHINXOPTS) $(BUILDDIR)/qthelp
+	@echo
+	@echo "Build finished; now you can run "qcollectiongenerator" with the" \
+	      ".qhcp project file in $(BUILDDIR)/qthelp, like this:"
+	@echo "# qcollectiongenerator $(BUILDDIR)/qthelp/Symfony.qhcp"
+	@echo "To view the help file:"
+	@echo "# assistant -collectionFile $(BUILDDIR)/qthelp/Symfony.qhc"
+
+devhelp:
+	$(SPHINXBUILD) -b devhelp $(ALLSPHINXOPTS) $(BUILDDIR)/devhelp
+	@echo
+	@echo "Build finished."
+	@echo "To view the help file:"
+	@echo "# mkdir -p $$HOME/.local/share/devhelp/Symfony"
+	@echo "# ln -s $(BUILDDIR)/devhelp $$HOME/.local/share/devhelp/Symfony"
+	@echo "# devhelp"
+
+epub:
+	$(SPHINXBUILD) -b epub $(ALLSPHINXOPTS) $(BUILDDIR)/epub
+	@echo
+	@echo "Build finished. The epub file is in $(BUILDDIR)/epub."
+
+latex:
+	$(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) $(BUILDDIR)/latex
+	@echo
+	@echo "Build finished; the LaTeX files are in $(BUILDDIR)/latex."
+	@echo "Run \`make' in that directory to run these through (pdf)latex" \
+	      "(use \`make latexpdf' here to do that automatically)."
+
+latexpdf:
+	$(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) $(BUILDDIR)/latex
+	@echo "Running LaTeX files through pdflatex..."
+	$(MAKE) -C $(BUILDDIR)/latex all-pdf
+	@echo "pdflatex finished; the PDF files are in $(BUILDDIR)/latex."
+
+text:
+	$(SPHINXBUILD) -b text $(ALLSPHINXOPTS) $(BUILDDIR)/text
+	@echo
+	@echo "Build finished. The text files are in $(BUILDDIR)/text."
+
+man:
+	$(SPHINXBUILD) -b man $(ALLSPHINXOPTS) $(BUILDDIR)/man
+	@echo
+	@echo "Build finished. The manual pages are in $(BUILDDIR)/man."
+
+texinfo:
+	$(SPHINXBUILD) -b texinfo $(ALLSPHINXOPTS) $(BUILDDIR)/texinfo
+	@echo
+	@echo "Build finished. The Texinfo files are in $(BUILDDIR)/texinfo."
+	@echo "Run \`make' in that directory to run these through makeinfo" \
+	      "(use \`make info' here to do that automatically)."
+
+info:
+	$(SPHINXBUILD) -b texinfo $(ALLSPHINXOPTS) $(BUILDDIR)/texinfo
+	@echo "Running Texinfo files through makeinfo..."
+	make -C $(BUILDDIR)/texinfo info
+	@echo "makeinfo finished; the Info files are in $(BUILDDIR)/texinfo."
+
+gettext:
+	$(SPHINXBUILD) -b gettext $(I18NSPHINXOPTS) $(BUILDDIR)/locale
+	@echo
+	@echo "Build finished. The message catalogs are in $(BUILDDIR)/locale."
+
+changes:
+	$(SPHINXBUILD) -b changes $(ALLSPHINXOPTS) $(BUILDDIR)/changes
+	@echo
+	@echo "The overview file is in $(BUILDDIR)/changes."
+
+linkcheck:
+	$(SPHINXBUILD) -b linkcheck $(ALLSPHINXOPTS) $(BUILDDIR)/linkcheck
+	@echo
+	@echo "Link check complete; look for any errors in the above output " \
+	      "or in $(BUILDDIR)/linkcheck/output.txt."
+
+doctest:
+	$(SPHINXBUILD) -b doctest $(ALLSPHINXOPTS) $(BUILDDIR)/doctest
+	@echo "Testing of doctests in the sources finished, look at the " \
+	      "results in $(BUILDDIR)/doctest/output.txt."
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/_build/conf.py b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/_build/conf.py
new file mode 100644
index 0000000..1e3a8ab
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/_build/conf.py
@@ -0,0 +1,271 @@
+# -*- coding: utf-8 -*-
+#
+# Symfony documentation build configuration file, created by
+# sphinx-quickstart on Sat Jul 28 21:58:57 2012.
+#
+# This file is execfile()d with the current directory set to its containing dir.
+#
+# Note that not all possible configuration values are present in this
+# autogenerated file.
+#
+# All configuration values have a default; values that are commented out
+# serve to show the default.
+
+import sys, os
+
+# If extensions (or modules to document with autodoc) are in another directory,
+# add these directories to sys.path here. If the directory is relative to the
+# documentation root, use os.path.abspath to make it absolute, like shown here.
+#sys.path.append(os.path.abspath('_exts'))
+
+# adding PhpLexer
+from sphinx.highlighting import lexers
+from pygments.lexers.special import TextLexer
+from pygments.lexers.text import RstLexer
+from pygments.lexers.web import PhpLexer
+
+# -- General configuration -----------------------------------------------------
+
+# If your documentation needs a minimal Sphinx version, state it here.
+needs_sphinx = '1.8.5'
+
+# Add any Sphinx extension module names here, as strings. They can be extensions
+# coming with Sphinx (named 'sphinx.ext.*') or your custom ones.
+extensions = [
+    'sphinx.ext.autodoc', 'sphinx.ext.doctest',
+    'sphinx.ext.todo', 'sphinx.ext.coverage', 'sphinx.ext.ifconfig',
+    'sphinx.ext.viewcode', 'sphinx.ext.extlinks',
+    'sensio.sphinx.codeblock', 'sensio.sphinx.configurationblock', 'sensio.sphinx.phpcode', 'sensio.sphinx.bestpractice'
+]
+
+#spelling_show_sugestions=True
+#spelling_lang='en_US'
+#spelling_word_list_filename='_build/spelling_word_list.txt'
+
+# Add any paths that contain templates here, relative to this directory.
+# templates_path = ['_theme/_templates']
+
+# The suffix of source filenames.
+source_suffix = '.rst'
+
+# The encoding of source files.
+#source_encoding = 'utf-8-sig'
+
+# The master toctree document.
+master_doc = 'index'
+
+# General information about the project.
+project = 'Twig'
+copyright = ''
+
+# The version info for the project you're documenting, acts as replacement for
+# |version| and |release|, also used in various other places throughout the
+# built documents.
+#
+# The short X.Y version.
+# version = '2.2'
+# The full version, including alpha/beta/rc tags.
+# release = '2.2.13'
+
+# The language for content autogenerated by Sphinx. Refer to documentation
+# for a list of supported languages.
+#language = None
+
+# There are two options for replacing |today|: either, you set today to some
+# non-false value, then it is used:
+#today = ''
+# Else, today_fmt is used as the format for a strftime call.
+#today_fmt = '%B %d, %Y'
+
+# List of patterns, relative to source directory, that match files and
+# directories to ignore when looking for source files.
+exclude_patterns = ['_build']
+
+# The reST default role (used for this markup: `text`) to use for all documents.
+#default_role = None
+
+# If true, '()' will be appended to :func: etc. cross-reference text.
+#add_function_parentheses = True
+
+# If true, the current module name will be prepended to all description
+# unit titles (such as .. function::).
+#add_module_names = True
+
+# If true, sectionauthor and moduleauthor directives will be shown in the
+# output. They are ignored by default.
+#show_authors = False
+
+# The name of the Pygments (syntax highlighting) style to use.
+#pygments_style = 'symfonycom.sphinx.SensioStyle'
+
+# A list of ignored prefixes for module index sorting.
+#modindex_common_prefix = []
+
+# -- Settings for symfony doc extension ---------------------------------------------------
+
+# enable highlighting for PHP code not between ``<?php ... ?>`` by default
+lexers['php'] = PhpLexer(startinline=True)
+lexers['rst'] = RstLexer()
+
+config_block = {
+    'rst': 'reStructuredText',
+}
+
+# don't enable Sphinx Domains
+primary_domain = None
+
+# set url for API links
+#api_url = 'https://github.com/symfony/symfony/blob/master/src/%s.php'
+
+
+# -- Options for HTML output ---------------------------------------------------
+
+# The theme to use for HTML and HTML Help pages.  See the documentation for
+# a list of builtin themes.
+html_theme = "sphinx_rtd_theme"
+
+# Theme options are theme-specific and customize the look and feel of a theme
+# further.  For a list of options available for each theme, see the
+# documentation.
+html_theme_options = {
+    'logo_only': True,
+    'prev_next_buttons_location': None,
+    'style_nav_header_background': '#f0f0f0'
+}
+
+# Add any paths that contain custom themes here, relative to this directory.
+#html_theme_path = []
+
+# The name for this set of Sphinx documents.  If None, it defaults to
+# "<project> v<release> documentation".
+#html_title = None
+
+# A shorter title for the navigation bar.  Default is the same as html_title.
+#html_short_title = None
+
+# The name of an image file (relative to this directory) to place at the top
+# of the sidebar.
+#html_logo = '_static/symfony-logo.svg'
+
+# The name of an image file (within the static path) to use as favicon of the
+# docs.  This file should be a Windows icon file (.ico) being 16x16 or 32x32
+# pixels large.
+#html_favicon = None
+
+# Add any paths that contain custom static files (such as style sheets) here,
+# relative to this directory. They are copied after the builtin static files,
+# so a file named "default.css" will overwrite the builtin "default.css".
+#html_static_path = ['_static']
+#html_css_files = ['rtd_custom.css']
+
+# If not '', a 'Last updated on:' timestamp is inserted at every page bottom,
+# using the given strftime format.
+#html_last_updated_fmt = '%b %d, %Y'
+
+# If true, SmartyPants will be used to convert quotes and dashes to
+# typographically correct entities.
+#html_use_smartypants = True
+
+# Custom sidebar templates, maps document names to template names.
+#html_sidebars = {}
+
+# Additional templates that should be rendered to pages, maps page names to
+# template names.
+#html_additional_pages = {}
+
+# If false, no module index is generated.
+#html_domain_indices = True
+
+# If false, no index is generated.
+#html_use_index = True
+
+# If true, the index is split into individual pages for each letter.
+#html_split_index = False
+
+# If true, links to the reST sources are added to the pages.
+#html_show_sourcelink = True
+
+# If true, "Created using Sphinx" is shown in the HTML footer. Default is True.
+#html_show_sphinx = True
+
+# If true, "(C) Copyright ..." is shown in the HTML footer. Default is True.
+#html_show_copyright = True
+
+# If true, an OpenSearch description file will be output, and all pages will
+# contain a <link> tag referring to it.  The value of this option must be the
+# base URL from which the finished HTML is served.
+#html_use_opensearch = ''
+
+# This is the file name suffix for HTML files (e.g. ".xhtml").
+#html_file_suffix = None
+
+# Output file base name for HTML help builder.
+htmlhelp_basename = 'Twig'
+
+
+# -- Options for LaTeX output --------------------------------------------------
+
+latex_elements = {
+# The paper size ('letterpaper' or 'a4paper').
+#'papersize': 'letterpaper',
+
+# The font size ('10pt', '11pt' or '12pt').
+#'pointsize': '10pt',
+
+# Additional stuff for the LaTeX preamble.
+#'preamble': '',
+}
+
+# Grouping the document tree into LaTeX files. List of tuples
+# (source start file, target name, title, author, documentclass [howto/manual]).
+#latex_documents = []
+
+# The name of an image file (relative to this directory) to place at the top of
+# the title page.
+#latex_logo = None
+
+# For "manual" documents, if this is true, then toplevel headings are parts,
+# not chapters.
+#latex_use_parts = False
+
+# If true, show page references after internal links.
+#latex_show_pagerefs = False
+
+# If true, show URL addresses after external links.
+#latex_show_urls = False
+
+# Documents to append as an appendix to all manuals.
+#latex_appendices = []
+
+# If false, no module index is generated.
+#latex_domain_indices = True
+
+
+# -- Options for manual page output --------------------------------------------
+
+# One entry per manual page. List of tuples
+# (source start file, name, description, authors, manual section).
+#man_pages = []
+
+# If true, show URL addresses after external links.
+#man_show_urls = False
+
+
+# -- Options for Texinfo output ------------------------------------------------
+
+# Grouping the document tree into Texinfo files. List of tuples
+# (source start file, target name, title, author,
+#  dir menu entry, description, category)
+#texinfo_documents = []
+
+# Documents to append as an appendix to all manuals.
+#texinfo_appendices = []
+
+# If false, no module index is generated.
+#texinfo_domain_indices = True
+
+# How to display URL addresses: 'footnote', 'no', or 'inline'.
+#texinfo_show_urls = 'footnote'
+
+# Use PHP syntax highlighting in code examples by default
+highlight_language='php'
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/advanced.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/advanced.rst
new file mode 100644
index 0000000..f801348
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/advanced.rst
@@ -0,0 +1,911 @@
+Extending Twig
+==============
+
+Twig can be extended in many ways; you can add extra tags, filters, tests,
+operators, global variables, and functions. You can even extend the parser
+itself with node visitors.
+
+.. note::
+
+    The first section of this chapter describes how to extend Twig. If you want
+    to reuse your changes in different projects or if you want to share them
+    with others, you should then create an extension as described in the
+    following section.
+
+.. caution::
+
+    When extending Twig without creating an extension, Twig won't be able to
+    recompile your templates when the PHP code is updated. To see your changes
+    in real-time, either disable template caching or package your code into an
+    extension (see the next section of this chapter).
+
+Before extending Twig, you must understand the differences between all the
+different possible extension points and when to use them.
+
+First, remember that Twig has two main language constructs:
+
+* ``{{ }}``: used to print the result of an expression evaluation;
+
+* ``{% %}``: used to execute statements.
+
+To understand why Twig exposes so many extension points, let's see how to
+implement a *Lorem ipsum* generator (it needs to know the number of words to
+generate).
+
+You can use a ``lipsum`` *tag*:
+
+.. code-block:: twig
+
+    {% lipsum 40 %}
+
+That works, but using a tag for ``lipsum`` is not a good idea for at least
+three main reasons:
+
+* ``lipsum`` is not a language construct;
+* The tag outputs something;
+* The tag is not flexible as you cannot use it in an expression:
+
+  .. code-block:: twig
+
+      {{ 'some text' ~ {% lipsum 40 %} ~ 'some more text' }}
+
+In fact, you rarely need to create tags; and that's good news because tags are
+the most complex extension point.
+
+Now, let's use a ``lipsum`` *filter*:
+
+.. code-block:: twig
+
+    {{ 40|lipsum }}
+
+Again, it works. But a filter should transform the passed value to something
+else. Here, we use the value to indicate the number of words to generate (so,
+``40`` is an argument of the filter, not the value we want to transform).
+
+Next, let's use a ``lipsum`` *function*:
+
+.. code-block:: twig
+
+    {{ lipsum(40) }}
+
+Here we go. For this specific example, the creation of a function is the
+extension point to use. And you can use it anywhere an expression is accepted:
+
+.. code-block:: twig
+
+    {{ 'some text' ~ lipsum(40) ~ 'some more text' }}
+
+    {% set lipsum = lipsum(40) %}
+
+Lastly, you can also use a *global* object with a method able to generate lorem
+ipsum text:
+
+.. code-block:: twig
+
+    {{ text.lipsum(40) }}
+
+As a rule of thumb, use functions for frequently used features and global
+objects for everything else.
+
+Keep in mind the following when you want to extend Twig:
+
+========== ========================== ========== =========================
+What?      Implementation difficulty? How often? When?
+========== ========================== ========== =========================
+*macro*    simple                     frequent   Content generation
+*global*   simple                     frequent   Helper object
+*function* simple                     frequent   Content generation
+*filter*   simple                     frequent   Value transformation
+*tag*      complex                    rare       DSL language construct
+*test*     simple                     rare       Boolean decision
+*operator* simple                     rare       Values transformation
+========== ========================== ========== =========================
+
+Globals
+-------
+
+A global variable is like any other template variable, except that it's
+available in all templates and macros::
+
+    $twig = new \Twig\Environment($loader);
+    $twig->addGlobal('text', new Text());
+
+You can then use the ``text`` variable anywhere in a template:
+
+.. code-block:: twig
+
+    {{ text.lipsum(40) }}
+
+Filters
+-------
+
+Creating a filter consists of associating a name with a PHP callable::
+
+    // an anonymous function
+    $filter = new \Twig\TwigFilter('rot13', function ($string) {
+        return str_rot13($string);
+    });
+
+    // or a simple PHP function
+    $filter = new \Twig\TwigFilter('rot13', 'str_rot13');
+
+    // or a class static method
+    $filter = new \Twig\TwigFilter('rot13', ['SomeClass', 'rot13Filter']);
+    $filter = new \Twig\TwigFilter('rot13', 'SomeClass::rot13Filter');
+
+    // or a class method
+    $filter = new \Twig\TwigFilter('rot13', [$this, 'rot13Filter']);
+    // the one below needs a runtime implementation (see below for more information)
+    $filter = new \Twig\TwigFilter('rot13', ['SomeClass', 'rot13Filter']);
+
+The first argument passed to the ``\Twig\TwigFilter`` constructor is the name of the
+filter you will use in templates and the second one is the PHP callable to
+associate with it.
+
+Then, add the filter to the Twig environment::
+
+    $twig = new \Twig\Environment($loader);
+    $twig->addFilter($filter);
+
+And here is how to use it in a template:
+
+.. code-block:: twig
+
+    {{ 'Twig'|rot13 }}
+
+    {# will output Gjvt #}
+
+When called by Twig, the PHP callable receives the left side of the filter
+(before the pipe ``|``) as the first argument and the extra arguments passed
+to the filter (within parentheses ``()``) as extra arguments.
+
+For instance, the following code:
+
+.. code-block:: twig
+
+    {{ 'TWIG'|lower }}
+    {{ now|date('d/m/Y') }}
+
+is compiled to something like the following::
+
+    <?php echo strtolower('TWIG') ?>
+    <?php echo twig_date_format_filter($now, 'd/m/Y') ?>
+
+The ``\Twig\TwigFilter`` class takes an array of options as its last argument::
+
+    $filter = new \Twig\TwigFilter('rot13', 'str_rot13', $options);
+
+Environment-aware Filters
+~~~~~~~~~~~~~~~~~~~~~~~~~
+
+If you want to access the current environment instance in your filter, set the
+``needs_environment`` option to ``true``; Twig will pass the current
+environment as the first argument to the filter call::
+
+    $filter = new \Twig\TwigFilter('rot13', function (\Twig\Environment $env, $string) {
+        // get the current charset for instance
+        $charset = $env->getCharset();
+
+        return str_rot13($string);
+    }, ['needs_environment' => true]);
+
+Context-aware Filters
+~~~~~~~~~~~~~~~~~~~~~
+
+If you want to access the current context in your filter, set the
+``needs_context`` option to ``true``; Twig will pass the current context as
+the first argument to the filter call (or the second one if
+``needs_environment`` is also set to ``true``)::
+
+    $filter = new \Twig\TwigFilter('rot13', function ($context, $string) {
+        // ...
+    }, ['needs_context' => true]);
+
+    $filter = new \Twig\TwigFilter('rot13', function (\Twig\Environment $env, $context, $string) {
+        // ...
+    }, ['needs_context' => true, 'needs_environment' => true]);
+
+Automatic Escaping
+~~~~~~~~~~~~~~~~~~
+
+If automatic escaping is enabled, the output of the filter may be escaped
+before printing. If your filter acts as an escaper (or explicitly outputs HTML
+or JavaScript code), you will want the raw output to be printed. In such a
+case, set the ``is_safe`` option::
+
+    $filter = new \Twig\TwigFilter('nl2br', 'nl2br', ['is_safe' => ['html']]);
+
+Some filters may need to work on input that is already escaped or safe, for
+example when adding (safe) HTML tags to originally unsafe output. In such a
+case, set the ``pre_escape`` option to escape the input data before it is run
+through your filter::
+
+    $filter = new \Twig\TwigFilter('somefilter', 'somefilter', ['pre_escape' => 'html', 'is_safe' => ['html']]);
+
+Variadic Filters
+~~~~~~~~~~~~~~~~
+
+When a filter should accept an arbitrary number of arguments, set the
+``is_variadic`` option to ``true``; Twig will pass the extra arguments as the
+last argument to the filter call as an array::
+
+    $filter = new \Twig\TwigFilter('thumbnail', function ($file, array $options = []) {
+        // ...
+    }, ['is_variadic' => true]);
+
+Be warned that :ref:`named arguments <named-arguments>` passed to a variadic
+filter cannot be checked for validity as they will automatically end up in the
+option array.
+
+Dynamic Filters
+~~~~~~~~~~~~~~~
+
+A filter name containing the special ``*`` character is a dynamic filter and
+the ``*`` part will match any string::
+
+    $filter = new \Twig\TwigFilter('*_path', function ($name, $arguments) {
+        // ...
+    });
+
+The following filters are matched by the above defined dynamic filter:
+
+* ``product_path``
+* ``category_path``
+
+A dynamic filter can define more than one dynamic parts::
+
+    $filter = new \Twig\TwigFilter('*_path_*', function ($name, $suffix, $arguments) {
+        // ...
+    });
+
+The filter receives all dynamic part values before the normal filter arguments,
+but after the environment and the context. For instance, a call to
+``'foo'|a_path_b()`` will result in the following arguments to be passed to the
+filter: ``('a', 'b', 'foo')``.
+
+Deprecated Filters
+~~~~~~~~~~~~~~~~~~
+
+You can mark a filter as being deprecated by setting the ``deprecated`` option
+to ``true``. You can also give an alternative filter that replaces the
+deprecated one when that makes sense::
+
+    $filter = new \Twig\TwigFilter('obsolete', function () {
+        // ...
+    }, ['deprecated' => true, 'alternative' => 'new_one']);
+
+When a filter is deprecated, Twig emits a deprecation notice when compiling a
+template using it. See :ref:`deprecation-notices` for more information.
+
+Functions
+---------
+
+Functions are defined in the exact same way as filters, but you need to create
+an instance of ``\Twig\TwigFunction``::
+
+    $twig = new \Twig\Environment($loader);
+    $function = new \Twig\TwigFunction('function_name', function () {
+        // ...
+    });
+    $twig->addFunction($function);
+
+Functions support the same features as filters, except for the ``pre_escape``
+and ``preserves_safety`` options.
+
+Tests
+-----
+
+Tests are defined in the exact same way as filters and functions, but you need
+to create an instance of ``\Twig\TwigTest``::
+
+    $twig = new \Twig\Environment($loader);
+    $test = new \Twig\TwigTest('test_name', function () {
+        // ...
+    });
+    $twig->addTest($test);
+
+Tests allow you to create custom application specific logic for evaluating
+boolean conditions. As a simple example, let's create a Twig test that checks if
+objects are 'red'::
+
+    $twig = new \Twig\Environment($loader);
+    $test = new \Twig\TwigTest('red', function ($value) {
+        if (isset($value->color) && $value->color == 'red') {
+            return true;
+        }
+        if (isset($value->paint) && $value->paint == 'red') {
+            return true;
+        }
+        return false;
+    });
+    $twig->addTest($test);
+
+Test functions must always return ``true``/``false``.
+
+When creating tests you can use the ``node_class`` option to provide custom test
+compilation. This is useful if your test can be compiled into PHP primitives.
+This is used by many of the tests built into Twig::
+
+    namespace App;
+    
+    use Twig\Environment;
+    use Twig\Node\Expression\TestExpression;
+    use Twig\TwigTest;
+    
+    $twig = new Environment($loader);
+    $test = new TwigTest(
+        'odd',
+        null,
+        ['node_class' => OddTestExpression::class]);
+    $twig->addTest($test);
+
+    class OddTestExpression extends TestExpression
+    {
+        public function compile(\Twig\Compiler $compiler)
+        {
+            $compiler
+                ->raw('(')
+                ->subcompile($this->getNode('node'))
+                ->raw(' % 2 != 0')
+                ->raw(')')
+            ;
+        }
+    }
+
+The above example shows how you can create tests that use a node class. The node
+class has access to one sub-node called ``node``. This sub-node contains the
+value that is being tested. When the ``odd`` filter is used in code such as:
+
+.. code-block:: twig
+
+    {% if my_value is odd %}
+
+The ``node`` sub-node will contain an expression of ``my_value``. Node-based
+tests also have access to the ``arguments`` node. This node will contain the
+various other arguments that have been provided to your test.
+
+If you want to pass a variable number of positional or named arguments to the
+test, set the ``is_variadic`` option to ``true``. Tests support dynamic
+names (see dynamic filters for the syntax).
+
+Tags
+----
+
+One of the most exciting features of a template engine like Twig is the
+possibility to define new **language constructs**. This is also the most complex
+feature as you need to understand how Twig's internals work.
+
+Most of the time though, a tag is not needed:
+
+* If your tag generates some output, use a **function** instead.
+
+* If your tag modifies some content and returns it, use a **filter** instead.
+
+  For instance, if you want to create a tag that converts a Markdown formatted
+  text to HTML, create a ``markdown`` filter instead:
+
+  .. code-block:: twig
+
+      {{ '**markdown** text'|markdown }}
+
+  If you want use this filter on large amounts of text, wrap it with the
+  :doc:`apply <tags/apply>` tag:
+
+  .. code-block:: twig
+
+      {% apply markdown %}
+      Title
+      =====
+
+      Much better than creating a tag as you can **compose** filters.
+      {% endapply %}
+
+* If your tag does not output anything, but only exists because of a side
+  effect, create a **function** that returns nothing and call it via the
+  :doc:`filter <tags/do>` tag.
+
+  For instance, if you want to create a tag that logs text, create a ``log``
+  function instead and call it via the :doc:`do <tags/do>` tag:
+
+  .. code-block:: twig
+
+      {% do log('Log some things') %}
+
+If you still want to create a tag for a new language construct, great!
+
+Let's create a ``set`` tag that allows the definition of simple variables from
+within a template. The tag can be used like follows:
+
+.. code-block:: twig
+
+    {% set name = "value" %}
+
+    {{ name }}
+
+    {# should output value #}
+
+.. note::
+
+    The ``set`` tag is part of the Core extension and as such is always
+    available. The built-in version is slightly more powerful and supports
+    multiple assignments by default.
+
+Three steps are needed to define a new tag:
+
+* Defining a Token Parser class (responsible for parsing the template code);
+
+* Defining a Node class (responsible for converting the parsed code to PHP);
+
+* Registering the tag.
+
+Registering a new tag
+~~~~~~~~~~~~~~~~~~~~~
+
+Add a tag by calling the ``addTokenParser`` method on the ``\Twig\Environment``
+instance::
+
+    $twig = new \Twig\Environment($loader);
+    $twig->addTokenParser(new Project_Set_TokenParser());
+
+Defining a Token Parser
+~~~~~~~~~~~~~~~~~~~~~~~
+
+Now, let's see the actual code of this class::
+
+    class Project_Set_TokenParser extends \Twig\TokenParser\AbstractTokenParser
+    {
+        public function parse(\Twig\Token $token)
+        {
+            $parser = $this->parser;
+            $stream = $parser->getStream();
+
+            $name = $stream->expect(\Twig\Token::NAME_TYPE)->getValue();
+            $stream->expect(\Twig\Token::OPERATOR_TYPE, '=');
+            $value = $parser->getExpressionParser()->parseExpression();
+            $stream->expect(\Twig\Token::BLOCK_END_TYPE);
+
+            return new Project_Set_Node($name, $value, $token->getLine(), $this->getTag());
+        }
+
+        public function getTag()
+        {
+            return 'set';
+        }
+    }
+
+The ``getTag()`` method must return the tag we want to parse, here ``set``.
+
+The ``parse()`` method is invoked whenever the parser encounters a ``set``
+tag. It should return a ``\Twig\Node\Node`` instance that represents the node (the
+``Project_Set_Node`` calls creating is explained in the next section).
+
+The parsing process is simplified thanks to a bunch of methods you can call
+from the token stream (``$this->parser->getStream()``):
+
+* ``getCurrent()``: Gets the current token in the stream.
+
+* ``next()``: Moves to the next token in the stream, *but returns the old one*.
+
+* ``test($type)``, ``test($value)`` or ``test($type, $value)``: Determines whether
+  the current token is of a particular type or value (or both). The value may be an
+  array of several possible values.
+
+* ``expect($type[, $value[, $message]])``: If the current token isn't of the given
+  type/value a syntax error is thrown. Otherwise, if the type and value are correct,
+  the token is returned and the stream moves to the next token.
+
+* ``look()``: Looks at the next token without consuming it.
+
+Parsing expressions is done by calling the ``parseExpression()`` like we did for
+the ``set`` tag.
+
+.. tip::
+
+    Reading the existing ``TokenParser`` classes is the best way to learn all
+    the nitty-gritty details of the parsing process.
+
+Defining a Node
+~~~~~~~~~~~~~~~
+
+The ``Project_Set_Node`` class itself is quite short::
+
+    class Project_Set_Node extends \Twig\Node\Node
+    {
+        public function __construct($name, \Twig\Node\Expression\AbstractExpression $value, $line, $tag = null)
+        {
+            parent::__construct(['value' => $value], ['name' => $name], $line, $tag);
+        }
+
+        public function compile(\Twig\Compiler $compiler)
+        {
+            $compiler
+                ->addDebugInfo($this)
+                ->write('$context[\''.$this->getAttribute('name').'\'] = ')
+                ->subcompile($this->getNode('value'))
+                ->raw(";\n")
+            ;
+        }
+    }
+
+The compiler implements a fluid interface and provides methods that helps the
+developer generate beautiful and readable PHP code:
+
+* ``subcompile()``: Compiles a node.
+
+* ``raw()``: Writes the given string as is.
+
+* ``write()``: Writes the given string by adding indentation at the beginning
+  of each line.
+
+* ``string()``: Writes a quoted string.
+
+* ``repr()``: Writes a PHP representation of a given value (see
+  ``\Twig\Node\ForNode`` for a usage example).
+
+* ``addDebugInfo()``: Adds the line of the original template file related to
+  the current node as a comment.
+
+* ``indent()``: Indents the generated code (see ``\Twig\Node\BlockNode`` for a
+  usage example).
+
+* ``outdent()``: Outdents the generated code (see ``\Twig\Node\BlockNode`` for a
+  usage example).
+
+.. _creating_extensions:
+
+Creating an Extension
+---------------------
+
+The main motivation for writing an extension is to move often used code into a
+reusable class like adding support for internationalization. An extension can
+define tags, filters, tests, operators, functions, and node visitors.
+
+Most of the time, it is useful to create a single extension for your project,
+to host all the specific tags and filters you want to add to Twig.
+
+.. tip::
+
+    When packaging your code into an extension, Twig is smart enough to
+    recompile your templates whenever you make a change to it (when
+    ``auto_reload`` is enabled).
+
+An extension is a class that implements the following interface::
+
+    interface \Twig\Extension\ExtensionInterface
+    {
+        /**
+         * Returns the token parser instances to add to the existing list.
+         *
+         * @return \Twig\TokenParser\TokenParserInterface[]
+         */
+        public function getTokenParsers();
+
+        /**
+         * Returns the node visitor instances to add to the existing list.
+         *
+         * @return \Twig\NodeVisitor\NodeVisitorInterface[]
+         */
+        public function getNodeVisitors();
+
+        /**
+         * Returns a list of filters to add to the existing list.
+         *
+         * @return \Twig\TwigFilter[]
+         */
+        public function getFilters();
+
+        /**
+         * Returns a list of tests to add to the existing list.
+         *
+         * @return \Twig\TwigTest[]
+         */
+        public function getTests();
+
+        /**
+         * Returns a list of functions to add to the existing list.
+         *
+         * @return \Twig\TwigFunction[]
+         */
+        public function getFunctions();
+
+        /**
+         * Returns a list of operators to add to the existing list.
+         *
+         * @return array<array> First array of unary operators, second array of binary operators
+         */
+        public function getOperators();
+    }
+
+To keep your extension class clean and lean, inherit from the built-in
+``\Twig\Extension\AbstractExtension`` class instead of implementing the interface as it provides
+empty implementations for all methods::
+
+    class Project_Twig_Extension extends \Twig\Extension\AbstractExtension
+    {
+    }
+
+This extension does nothing for now. We will customize it in the next sections.
+
+You can save your extension anywhere on the filesystem, as all extensions must
+be registered explicitly to be available in your templates.
+
+You can register an extension by using the ``addExtension()`` method on your
+main ``Environment`` object::
+
+    $twig = new \Twig\Environment($loader);
+    $twig->addExtension(new Project_Twig_Extension());
+
+.. tip::
+
+    The Twig core extensions are great examples of how extensions work.
+
+Globals
+~~~~~~~
+
+Global variables can be registered in an extension via the ``getGlobals()``
+method::
+
+    class Project_Twig_Extension extends \Twig\Extension\AbstractExtension implements \Twig\Extension\GlobalsInterface
+    {
+        public function getGlobals(): array
+        {
+            return [
+                'text' => new Text(),
+            ];
+        }
+
+        // ...
+    }
+
+Functions
+~~~~~~~~~
+
+Functions can be registered in an extension via the ``getFunctions()``
+method::
+
+    class Project_Twig_Extension extends \Twig\Extension\AbstractExtension
+    {
+        public function getFunctions()
+        {
+            return [
+                new \Twig\TwigFunction('lipsum', 'generate_lipsum'),
+            ];
+        }
+
+        // ...
+    }
+
+Filters
+~~~~~~~
+
+To add a filter to an extension, you need to override the ``getFilters()``
+method. This method must return an array of filters to add to the Twig
+environment::
+
+    class Project_Twig_Extension extends \Twig\Extension\AbstractExtension
+    {
+        public function getFilters()
+        {
+            return [
+                new \Twig\TwigFilter('rot13', 'str_rot13'),
+            ];
+        }
+
+        // ...
+    }
+
+Tags
+~~~~
+
+Adding a tag in an extension can be done by overriding the
+``getTokenParsers()`` method. This method must return an array of tags to add
+to the Twig environment::
+
+    class Project_Twig_Extension extends \Twig\Extension\AbstractExtension
+    {
+        public function getTokenParsers()
+        {
+            return [new Project_Set_TokenParser()];
+        }
+
+        // ...
+    }
+
+In the above code, we have added a single new tag, defined by the
+``Project_Set_TokenParser`` class. The ``Project_Set_TokenParser`` class is
+responsible for parsing the tag and compiling it to PHP.
+
+Operators
+~~~~~~~~~
+
+The ``getOperators()`` methods lets you add new operators. Here is how to add
+the ``!``, ``||``, and ``&&`` operators::
+
+    class Project_Twig_Extension extends \Twig\Extension\AbstractExtension
+    {
+        public function getOperators()
+        {
+            return [
+                [
+                    '!' => ['precedence' => 50, 'class' => \Twig\Node\Expression\Unary\NotUnary::class],
+                ],
+                [
+                    '||' => ['precedence' => 10, 'class' => \Twig\Node\Expression\Binary\OrBinary::class, 'associativity' => \Twig\ExpressionParser::OPERATOR_LEFT],
+                    '&&' => ['precedence' => 15, 'class' => \Twig\Node\Expression\Binary\AndBinary::class, 'associativity' => \Twig\ExpressionParser::OPERATOR_LEFT],
+                ],
+            ];
+        }
+
+        // ...
+    }
+
+Tests
+~~~~~
+
+The ``getTests()`` method lets you add new test functions::
+
+    class Project_Twig_Extension extends \Twig\Extension\AbstractExtension
+    {
+        public function getTests()
+        {
+            return [
+                new \Twig\TwigTest('even', 'twig_test_even'),
+            ];
+        }
+
+        // ...
+    }
+
+Definition vs Runtime
+~~~~~~~~~~~~~~~~~~~~~
+
+Twig filters, functions, and tests runtime implementations can be defined as
+any valid PHP callable:
+
+* **functions/static methods**: Simple to implement and fast (used by all Twig
+  core extensions); but it is hard for the runtime to depend on external
+  objects;
+
+* **closures**: Simple to implement;
+
+* **object methods**: More flexible and required if your runtime code depends
+  on external objects.
+
+The simplest way to use methods is to define them on the extension itself::
+
+    class Project_Twig_Extension extends \Twig\Extension\AbstractExtension
+    {
+        private $rot13Provider;
+
+        public function __construct($rot13Provider)
+        {
+            $this->rot13Provider = $rot13Provider;
+        }
+
+        public function getFunctions()
+        {
+            return [
+                new \Twig\TwigFunction('rot13', [$this, 'rot13']),
+            ];
+        }
+
+        public function rot13($value)
+        {
+            return $this->rot13Provider->rot13($value);
+        }
+    }
+
+This is very convenient but not recommended as it makes template compilation
+depend on runtime dependencies even if they are not needed (think for instance
+as a dependency that connects to a database engine).
+
+You can decouple the extension definitions from their runtime implementations by
+registering a ``\Twig\RuntimeLoader\RuntimeLoaderInterface`` instance on the
+environment that knows how to instantiate such runtime classes (runtime classes
+must be autoload-able)::
+
+    class RuntimeLoader implements \Twig\RuntimeLoader\RuntimeLoaderInterface
+    {
+        public function load($class)
+        {
+            // implement the logic to create an instance of $class
+            // and inject its dependencies
+            // most of the time, it means using your dependency injection container
+            if ('Project_Twig_RuntimeExtension' === $class) {
+                return new $class(new Rot13Provider());
+            } else {
+                // ...
+            }
+        }
+    }
+
+    $twig->addRuntimeLoader(new RuntimeLoader());
+
+.. note::
+
+    Twig comes with a PSR-11 compatible runtime loader
+    (``\Twig\RuntimeLoader\ContainerRuntimeLoader``).
+
+It is now possible to move the runtime logic to a new
+``Project_Twig_RuntimeExtension`` class and use it directly in the extension::
+
+    class Project_Twig_RuntimeExtension
+    {
+        private $rot13Provider;
+
+        public function __construct($rot13Provider)
+        {
+            $this->rot13Provider = $rot13Provider;
+        }
+
+        public function rot13($value)
+        {
+            return $this->rot13Provider->rot13($value);
+        }
+    }
+
+    class Project_Twig_Extension extends \Twig\Extension\AbstractExtension
+    {
+        public function getFunctions()
+        {
+            return [
+                new \Twig\TwigFunction('rot13', ['Project_Twig_RuntimeExtension', 'rot13']),
+                // or
+                new \Twig\TwigFunction('rot13', 'Project_Twig_RuntimeExtension::rot13'),
+            ];
+        }
+    }
+
+Testing an Extension
+--------------------
+
+Functional Tests
+~~~~~~~~~~~~~~~~
+
+You can create functional tests for extensions by creating the following file
+structure in your test directory::
+
+    Fixtures/
+        filters/
+            foo.test
+            bar.test
+        functions/
+            foo.test
+            bar.test
+        tags/
+            foo.test
+            bar.test
+    IntegrationTest.php
+
+The ``IntegrationTest.php`` file should look like this::
+
+    use Twig\Test\IntegrationTestCase;
+
+    class Project_Tests_IntegrationTest extends IntegrationTestCase
+    {
+        public function getExtensions()
+        {
+            return [
+                new Project_Twig_Extension1(),
+                new Project_Twig_Extension2(),
+            ];
+        }
+
+        public function getFixturesDir()
+        {
+            return __DIR__.'/Fixtures/';
+        }
+    }
+
+Fixtures examples can be found within the Twig repository
+`tests/Twig/Fixtures`_ directory.
+
+Node Tests
+~~~~~~~~~~
+
+Testing the node visitors can be complex, so extend your test cases from
+``\Twig\Test\NodeTestCase``. Examples can be found in the Twig repository
+`tests/Twig/Node`_ directory.
+
+.. _`tests/Twig/Fixtures`: https://github.com/twigphp/Twig/tree/3.x/tests/Fixtures
+.. _`tests/Twig/Node`:     https://github.com/twigphp/Twig/tree/3.x/tests/Node
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/api.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/api.rst
new file mode 100644
index 0000000..80dfaa5
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/api.rst
@@ -0,0 +1,583 @@
+Twig for Developers
+===================
+
+This chapter describes the API to Twig and not the template language. It will
+be most useful as reference to those implementing the template interface to
+the application and not those who are creating Twig templates.
+
+Basics
+------
+
+Twig uses a central object called the **environment** (of class
+``\Twig\Environment``). Instances of this class are used to store the
+configuration and extensions, and are used to load templates.
+
+Most applications create one ``\Twig\Environment`` object on application
+initialization and use that to load templates. In some cases, it might be useful
+to have multiple environments side by side, with different configurations.
+
+The typical way to configure Twig to load templates for an application looks
+roughly like this::
+
+    require_once '/path/to/vendor/autoload.php';
+
+    $loader = new \Twig\Loader\FilesystemLoader('/path/to/templates');
+    $twig = new \Twig\Environment($loader, [
+        'cache' => '/path/to/compilation_cache',
+    ]);
+
+This creates a template environment with a default configuration and a loader
+that looks up templates in the ``/path/to/templates/`` directory. Different
+loaders are available and you can also write your own if you want to load
+templates from a database or other resources.
+
+.. note::
+
+    Notice that the second argument of the environment is an array of options.
+    The ``cache`` option is a compilation cache directory, where Twig caches
+    the compiled templates to avoid the parsing phase for sub-sequent
+    requests. It is very different from the cache you might want to add for
+    the evaluated templates. For such a need, you can use any available PHP
+    cache library.
+
+Rendering Templates
+-------------------
+
+To load a template from a Twig environment, call the ``load()`` method which
+returns a ``\Twig\TemplateWrapper`` instance::
+
+    $template = $twig->load('index.html');
+
+To render the template with some variables, call the ``render()`` method::
+
+    echo $template->render(['the' => 'variables', 'go' => 'here']);
+
+.. note::
+
+    The ``display()`` method is a shortcut to output the rendered template.
+
+You can also load and render the template in one fell swoop::
+
+    echo $twig->render('index.html', ['the' => 'variables', 'go' => 'here']);
+
+If a template defines blocks, they can be rendered individually via the
+``renderBlock()`` call::
+
+    echo $template->renderBlock('block_name', ['the' => 'variables', 'go' => 'here']);
+
+.. _environment_options:
+
+Environment Options
+-------------------
+
+When creating a new ``\Twig\Environment`` instance, you can pass an array of
+options as the constructor second argument::
+
+    $twig = new \Twig\Environment($loader, ['debug' => true]);
+
+The following options are available:
+
+* ``debug`` *boolean*
+
+  When set to ``true``, the generated templates have a
+  ``__toString()`` method that you can use to display the generated nodes
+  (default to ``false``).
+
+* ``charset`` *string* (defaults to ``utf-8``)
+
+  The charset used by the templates.
+
+* ``cache`` *string* or ``false``
+
+  An absolute path where to store the compiled templates, or
+  ``false`` to disable caching (which is the default).
+
+* ``auto_reload`` *boolean*
+
+  When developing with Twig, it's useful to recompile the
+  template whenever the source code changes. If you don't provide a value for
+  the ``auto_reload`` option, it will be determined automatically based on the
+  ``debug`` value.
+
+* ``strict_variables`` *boolean*
+
+  If set to ``false``, Twig will silently ignore invalid
+  variables (variables and or attributes/methods that do not exist) and
+  replace them with a ``null`` value. When set to ``true``, Twig throws an
+  exception instead (default to ``false``).
+
+* ``autoescape`` *string*
+
+  Sets the default auto-escaping strategy (``name``, ``html``, ``js``, ``css``,
+  ``url``, ``html_attr``, or a PHP callback that takes the template "filename"
+  and returns the escaping strategy to use -- the callback cannot be a function
+  name to avoid collision with built-in escaping strategies); set it to
+  ``false`` to disable auto-escaping. The ``name`` escaping strategy determines
+  the escaping strategy to use for a template based on the template filename
+  extension (this strategy does not incur any overhead at runtime as
+  auto-escaping is done at compilation time.)
+
+* ``optimizations`` *integer*
+
+  A flag that indicates which optimizations to apply
+  (default to ``-1`` -- all optimizations are enabled; set it to ``0`` to
+  disable).
+
+Loaders
+-------
+
+Loaders are responsible for loading templates from a resource such as the file
+system.
+
+Compilation Cache
+~~~~~~~~~~~~~~~~~
+
+All template loaders can cache the compiled templates on the filesystem for
+future reuse. It speeds up Twig a lot as templates are only compiled once.
+
+Built-in Loaders
+~~~~~~~~~~~~~~~~
+
+Here is a list of the built-in loaders:
+
+``\Twig\Loader\FilesystemLoader``
+.................................
+
+``\Twig\Loader\FilesystemLoader`` loads templates from the file system. This loader
+can find templates in folders on the file system and is the preferred way to
+load them::
+
+    $loader = new \Twig\Loader\FilesystemLoader($templateDir);
+
+It can also look for templates in an array of directories::
+
+    $loader = new \Twig\Loader\FilesystemLoader([$templateDir1, $templateDir2]);
+
+With such a configuration, Twig will first look for templates in
+``$templateDir1`` and if they do not exist, it will fallback to look for them
+in the ``$templateDir2``.
+
+You can add or prepend paths via the ``addPath()`` and ``prependPath()``
+methods::
+
+    $loader->addPath($templateDir3);
+    $loader->prependPath($templateDir4);
+
+The filesystem loader also supports namespaced templates. This allows to group
+your templates under different namespaces which have their own template paths.
+
+When using the ``setPaths()``, ``addPath()``, and ``prependPath()`` methods,
+specify the namespace as the second argument (when not specified, these
+methods act on the "main" namespace)::
+
+    $loader->addPath($templateDir, 'admin');
+
+Namespaced templates can be accessed via the special
+``@namespace_name/template_path`` notation::
+
+    $twig->render('@admin/index.html', []);
+
+``\Twig\Loader\FilesystemLoader`` support absolute and relative paths. Using relative
+paths is preferred as it makes the cache keys independent of the project root
+directory (for instance, it allows warming the cache from a build server where
+the directory might be different from the one used on production servers)::
+
+    $loader = new \Twig\Loader\FilesystemLoader('templates', getcwd().'/..');
+
+.. note::
+
+    When not passing the root path as a second argument, Twig uses ``getcwd()``
+    for relative paths.
+
+``\Twig\Loader\ArrayLoader``
+............................
+
+``\Twig\Loader\ArrayLoader`` loads a template from a PHP array. It is passed an
+array of strings bound to template names::
+
+    $loader = new \Twig\Loader\ArrayLoader([
+        'index.html' => 'Hello {{ name }}!',
+    ]);
+    $twig = new \Twig\Environment($loader);
+
+    echo $twig->render('index.html', ['name' => 'Fabien']);
+
+This loader is very useful for unit testing. It can also be used for small
+projects where storing all templates in a single PHP file might make sense.
+
+.. tip::
+
+    When using the ``Array`` loader with a cache mechanism, you should know that
+    a new cache key is generated each time a template content "changes" (the
+    cache key being the source code of the template). If you don't want to see
+    your cache grows out of control, you need to take care of clearing the old
+    cache file by yourself.
+
+``\Twig\Loader\ChainLoader``
+............................
+
+``\Twig\Loader\ChainLoader`` delegates the loading of templates to other loaders::
+
+    $loader1 = new \Twig\Loader\ArrayLoader([
+        'base.html' => '{% block content %}{% endblock %}',
+    ]);
+    $loader2 = new \Twig\Loader\ArrayLoader([
+        'index.html' => '{% extends "base.html" %}{% block content %}Hello {{ name }}{% endblock %}',
+        'base.html'  => 'Will never be loaded',
+    ]);
+
+    $loader = new \Twig\Loader\ChainLoader([$loader1, $loader2]);
+
+    $twig = new \Twig\Environment($loader);
+
+When looking for a template, Twig tries each loader in turn and returns as soon
+as the template is found. When rendering the ``index.html`` template from the
+above example, Twig will load it with ``$loader2`` but the ``base.html``
+template will be loaded from ``$loader1``.
+
+.. note::
+
+    You can also add loaders via the ``addLoader()`` method.
+
+Create your own Loader
+~~~~~~~~~~~~~~~~~~~~~~
+
+All loaders implement the ``\Twig\Loader\LoaderInterface``::
+
+    interface \Twig\Loader\LoaderInterface
+    {
+        /**
+         * Returns the source context for a given template logical name.
+         *
+         * @param string $name The template logical name
+         *
+         * @return \Twig\Source
+         *
+         * @throws \Twig\Error\LoaderError When $name is not found
+         */
+        public function getSourceContext($name);
+
+        /**
+         * Gets the cache key to use for the cache for a given template name.
+         *
+         * @param string $name The name of the template to load
+         *
+         * @return string The cache key
+         *
+         * @throws \Twig\Error\LoaderError When $name is not found
+         */
+        public function getCacheKey($name);
+
+        /**
+         * Returns true if the template is still fresh.
+         *
+         * @param string    $name The template name
+         * @param timestamp $time The last modification time of the cached template
+         *
+         * @return bool    true if the template is fresh, false otherwise
+         *
+         * @throws \Twig\Error\LoaderError When $name is not found
+         */
+        public function isFresh($name, $time);
+
+        /**
+         * Check if we have the source code of a template, given its name.
+         *
+         * @param string $name The name of the template to check if we can load
+         *
+         * @return bool    If the template source code is handled by this loader or not
+         */
+        public function exists($name);
+    }
+
+The ``isFresh()`` method must return ``true`` if the current cached template
+is still fresh, given the last modification time, or ``false`` otherwise.
+
+The ``getSourceContext()`` method must return an instance of ``\Twig\Source``.
+
+Using Extensions
+----------------
+
+Twig extensions are packages that add new features to Twig. Register an
+extension via the ``addExtension()`` method::
+
+    $twig->addExtension(new \Twig\Extension\SandboxExtension());
+
+Twig comes bundled with the following extensions:
+
+* *Twig\Extension\CoreExtension*: Defines all the core features of Twig.
+
+* *Twig\Extension\DebugExtension*: Defines the ``dump`` function to help debug
+  template variables.
+
+* *Twig\Extension\EscaperExtension*: Adds automatic output-escaping and the
+  possibility to escape/unescape blocks of code.
+
+* *Twig\Extension\SandboxExtension*: Adds a sandbox mode to the default Twig
+  environment, making it safe to evaluate untrusted code.
+
+* *Twig\Extension\ProfilerExtension*: Enables the built-in Twig profiler.
+
+* *Twig\Extension\OptimizerExtension*: Optimizes the node tree before
+  compilation.
+
+* *Twig\Extension\StringLoaderExtension*: Defines the ``template_from_string``
+   function to allow loading templates from string in a template.
+
+The Core, Escaper, and Optimizer extensions are registered by default.
+
+Built-in Extensions
+-------------------
+
+This section describes the features added by the built-in extensions.
+
+.. tip::
+
+    Read the chapter about :doc:`extending Twig <advanced>` to learn how to
+    create your own extensions.
+
+Core Extension
+~~~~~~~~~~~~~~
+
+The ``core`` extension defines all the core features of Twig:
+
+* :doc:`Tags <tags/index>`;
+* :doc:`Filters <filters/index>`;
+* :doc:`Functions <functions/index>`;
+* :doc:`Tests <tests/index>`.
+
+Escaper Extension
+~~~~~~~~~~~~~~~~~
+
+The ``escaper`` extension adds automatic output escaping to Twig. It defines a
+tag, ``autoescape``, and a filter, ``raw``.
+
+When creating the escaper extension, you can switch on or off the global
+output escaping strategy::
+
+    $escaper = new \Twig\Extension\EscaperExtension('html');
+    $twig->addExtension($escaper);
+
+If set to ``html``, all variables in templates are escaped (using the ``html``
+escaping strategy), except those using the ``raw`` filter:
+
+.. code-block:: twig
+
+    {{ article.to_html|raw }}
+
+You can also change the escaping mode locally by using the ``autoescape`` tag:
+
+.. code-block:: twig
+
+    {% autoescape 'html' %}
+        {{ var }}
+        {{ var|raw }}      {# var won't be escaped #}
+        {{ var|escape }}   {# var won't be double-escaped #}
+    {% endautoescape %}
+
+.. warning::
+
+    The ``autoescape`` tag has no effect on included files.
+
+The escaping rules are implemented as follows:
+
+* Literals (integers, booleans, arrays, ...) used in the template directly as
+  variables or filter arguments are never automatically escaped:
+
+  .. code-block:: html+twig
+
+        {{ "Twig<br/>" }} {# won't be escaped #}
+
+        {% set text = "Twig<br/>" %}
+        {{ text }} {# will be escaped #}
+
+* Expressions which the result is a literal or a variable marked safe
+  are never automatically escaped:
+
+  .. code-block:: html+twig
+
+        {{ foo ? "Twig<br/>" : "<br/>Twig" }} {# won't be escaped #}
+
+        {% set text = "Twig<br/>" %}
+        {{ true ? text : "<br/>Twig" }} {# will be escaped #}
+        {{ false ? text : "<br/>Twig" }} {# won't be escaped #}
+
+        {% set text = "Twig<br/>" %}
+        {{ foo ? text|raw : "<br/>Twig" }} {# won't be escaped #}
+
+* Objects with a ``__toString`` method are converted to strings and
+  escaped. You can mark some classes and/or interfaces as being safe for some
+  strategies via ``EscaperExtension::addSafeClass()``:
+
+  .. code-block:: twig
+
+        // mark object of class Foo as safe for the HTML strategy
+        $escaper->addSafeClass('Foo', ['html']);
+
+        // mark object of interface Foo as safe for the HTML strategy
+        $escaper->addSafeClass('FooInterface', ['html']);
+
+        // mark object of class Foo as safe for the HTML and JS strategies
+        $escaper->addSafeClass('Foo', ['html', 'js']);
+
+        // mark object of class Foo as safe for all strategies
+        $escaper->addSafeClass('Foo', ['all']);
+
+* Escaping is applied before printing, after any other filter is applied:
+
+  .. code-block:: twig
+
+        {{ var|upper }} {# is equivalent to {{ var|upper|escape }} #}
+
+* The `raw` filter should only be used at the end of the filter chain:
+
+  .. code-block:: twig
+
+        {{ var|raw|upper }} {# will be escaped #}
+
+        {{ var|upper|raw }} {# won't be escaped #}
+
+* Automatic escaping is not applied if the last filter in the chain is marked
+  safe for the current context (e.g. ``html`` or ``js``). ``escape`` and
+  ``escape('html')`` are marked safe for HTML, ``escape('js')`` is marked
+  safe for JavaScript, ``raw`` is marked safe for everything.
+
+  .. code-block:: twig
+
+        {% autoescape 'js' %}
+            {{ var|escape('html') }} {# will be escaped for HTML and JavaScript #}
+            {{ var }} {# will be escaped for JavaScript #}
+            {{ var|escape('js') }} {# won't be double-escaped #}
+        {% endautoescape %}
+
+.. note::
+
+    Note that autoescaping has some limitations as escaping is applied on
+    expressions after evaluation. For instance, when working with
+    concatenation, ``{{ foo|raw ~ bar }}`` won't give the expected result as
+    escaping is applied on the result of the concatenation, not on the
+    individual variables (so, the ``raw`` filter won't have any effect here).
+
+Sandbox Extension
+~~~~~~~~~~~~~~~~~
+
+The ``sandbox`` extension can be used to evaluate untrusted code. Access to
+unsafe attributes and methods is prohibited. The sandbox security is managed
+by a policy instance. By default, Twig comes with one policy class:
+``\Twig\Sandbox\SecurityPolicy``. This class allows you to white-list some
+tags, filters, properties, and methods::
+
+    $tags = ['if'];
+    $filters = ['upper'];
+    $methods = [
+        'Article' => ['getTitle', 'getBody'],
+    ];
+    $properties = [
+        'Article' => ['title', 'body'],
+    ];
+    $functions = ['range'];
+    $policy = new \Twig\Sandbox\SecurityPolicy($tags, $filters, $methods, $properties, $functions);
+
+With the previous configuration, the security policy will only allow usage of
+the ``if`` tag, and the ``upper`` filter. Moreover, the templates will only be
+able to call the ``getTitle()`` and ``getBody()`` methods on ``Article``
+objects, and the ``title`` and ``body`` public properties. Everything else
+won't be allowed and will generate a ``\Twig\Sandbox\SecurityError`` exception.
+
+The policy object is the first argument of the sandbox constructor::
+
+    $sandbox = new \Twig\Extension\SandboxExtension($policy);
+    $twig->addExtension($sandbox);
+
+By default, the sandbox mode is disabled and should be enabled when including
+untrusted template code by using the ``sandbox`` tag:
+
+.. code-block:: twig
+
+    {% sandbox %}
+        {% include 'user.html' %}
+    {% endsandbox %}
+
+You can sandbox all templates by passing ``true`` as the second argument of
+the extension constructor::
+
+    $sandbox = new \Twig\Extension\SandboxExtension($policy, true);
+
+Profiler Extension
+~~~~~~~~~~~~~~~~~~
+
+The ``profiler`` extension enables a profiler for Twig templates; it should
+only be used on your development machines as it adds some overhead::
+
+    $profile = new \Twig\Profiler\Profile();
+    $twig->addExtension(new \Twig\Extension\ProfilerExtension($profile));
+
+    $dumper = new \Twig\Profiler\Dumper\TextDumper();
+    echo $dumper->dump($profile);
+
+A profile contains information about time and memory consumption for template,
+block, and macro executions.
+
+You can also dump the data in a `Blackfire.io <https://blackfire.io/>`_
+compatible format::
+
+    $dumper = new \Twig\Profiler\Dumper\BlackfireDumper();
+    file_put_contents('/path/to/profile.prof', $dumper->dump($profile));
+
+Upload the profile to visualize it (create a `free account
+<https://blackfire.io/signup?utm_source=twig&utm_medium=doc&utm_campaign=profiler>`_
+first):
+
+.. code-block:: sh
+
+    blackfire --slot=7 upload /path/to/profile.prof
+
+Optimizer Extension
+~~~~~~~~~~~~~~~~~~~
+
+The ``optimizer`` extension optimizes the node tree before compilation::
+
+    $twig->addExtension(new \Twig\Extension\OptimizerExtension());
+
+By default, all optimizations are turned on. You can select the ones you want
+to enable by passing them to the constructor::
+
+    $optimizer = new \Twig\Extension\OptimizerExtension(\Twig\NodeVisitor\OptimizerNodeVisitor::OPTIMIZE_FOR);
+
+    $twig->addExtension($optimizer);
+
+Twig supports the following optimizations:
+
+* ``\Twig\NodeVisitor\OptimizerNodeVisitor::OPTIMIZE_ALL``, enables all optimizations
+  (this is the default value).
+
+* ``\Twig\NodeVisitor\OptimizerNodeVisitor::OPTIMIZE_NONE``, disables all optimizations.
+  This reduces the compilation time, but it can increase the execution time
+  and the consumed memory.
+
+* ``\Twig\NodeVisitor\OptimizerNodeVisitor::OPTIMIZE_FOR``, optimizes the ``for`` tag by
+  removing the ``loop`` variable creation whenever possible.
+
+* ``\Twig\NodeVisitor\OptimizerNodeVisitor::OPTIMIZE_RAW_FILTER``, removes the ``raw``
+  filter whenever possible.
+
+* ``\Twig\NodeVisitor\OptimizerNodeVisitor::OPTIMIZE_VAR_ACCESS``, simplifies the creation
+  and access of variables in the compiled templates whenever possible.
+
+Exceptions
+----------
+
+Twig can throw exceptions:
+
+* ``\Twig\Error\Error``: The base exception for all errors.
+
+* ``\Twig\Error\SyntaxError``: Thrown to tell the user that there is a problem with
+  the template syntax.
+
+* ``\Twig\Error\RuntimeError``: Thrown when an error occurs at runtime (when a filter
+  does not exist for instance).
+
+* ``\Twig\Error\LoaderError``: Thrown when an error occurs during template loading.
+
+* ``\Twig\Sandbox\SecurityError``: Thrown when an unallowed tag, filter, or
+  method is called in a sandboxed template.
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/coding_standards.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/coding_standards.rst
new file mode 100644
index 0000000..721b0f1
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/coding_standards.rst
@@ -0,0 +1,101 @@
+Coding Standards
+================
+
+When writing Twig templates, we recommend you to follow these official coding
+standards:
+
+* Put one (and only one) space after the start of a delimiter (``{{``, ``{%``,
+  and ``{#``) and before the end of a delimiter (``}}``, ``%}``, and ``#}``):
+
+  .. code-block:: twig
+
+    {{ foo }}
+    {# comment #}
+    {% if foo %}{% endif %}
+
+  When using the whitespace control character, do not put any spaces between
+  it and the delimiter:
+
+  .. code-block:: twig
+
+    {{- foo -}}
+    {#- comment -#}
+    {%- if foo -%}{%- endif -%}
+
+* Put one (and only one) space before and after the following operators:
+  comparison operators (``==``, ``!=``, ``<``, ``>``, ``>=``, ``<=``), math
+  operators (``+``, ``-``, ``/``, ``*``, ``%``, ``//``, ``**``), logic
+  operators (``not``, ``and``, ``or``), ``~``, ``is``, ``in``, and the ternary
+  operator (``?:``):
+
+  .. code-block:: twig
+
+     {{ 1 + 2 }}
+     {{ foo ~ bar }}
+     {{ true ? true : false }}
+
+* Put one (and only one) space after the ``:`` sign in hashes and ``,`` in
+  arrays and hashes:
+
+  .. code-block:: twig
+
+     {{ [1, 2, 3] }}
+     {{ {'foo': 'bar'} }}
+
+* Do not put any spaces after an opening parenthesis and before a closing
+  parenthesis in expressions:
+
+  .. code-block:: twig
+
+    {{ 1 + (2 * 3) }}
+
+* Do not put any spaces before and after string delimiters:
+
+  .. code-block:: twig
+
+    {{ 'foo' }}
+    {{ "foo" }}
+
+* Do not put any spaces before and after the following operators: ``|``,
+  ``.``, ``..``, ``[]``:
+
+  .. code-block:: twig
+
+    {{ foo|upper|lower }}
+    {{ user.name }}
+    {{ user[name] }}
+    {% for i in 1..12 %}{% endfor %}
+
+* Do not put any spaces before and after the parenthesis used for filter and
+  function calls:
+
+  .. code-block:: twig
+
+     {{ foo|default('foo') }}
+     {{ range(1..10) }}
+
+* Do not put any spaces before and after the opening and the closing of arrays
+  and hashes:
+
+  .. code-block:: twig
+
+     {{ [1, 2, 3] }}
+     {{ {'foo': 'bar'} }}
+
+* Use lower cased and underscored variable names:
+
+  .. code-block:: twig
+
+     {% set foo = 'foo' %}
+     {% set foo_bar = 'foo' %}
+
+* Indent your code inside tags (use the same indentation as the one used for
+  the target language of the rendered template):
+
+  .. code-block:: twig
+
+     {% block foo %}
+         {% if true %}
+             true
+         {% endif %}
+     {% endblock %}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/deprecated.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/deprecated.rst
new file mode 100644
index 0000000..ac22338
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/deprecated.rst
@@ -0,0 +1,6 @@
+Deprecated Features
+===================
+
+This document lists deprecated features in Twig 3.x. Deprecated features are
+kept for backward compatibility and removed in the next major release (a
+feature that was deprecated in Twig 3.x is removed in Twig 4.0).
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/abs.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/abs.rst
new file mode 100644
index 0000000..77d5cf0
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/abs.rst
@@ -0,0 +1,18 @@
+``abs``
+=======
+
+The ``abs`` filter returns the absolute value.
+
+.. code-block:: twig
+
+    {# number = -5 #}
+
+    {{ number|abs }}
+
+    {# outputs 5 #}
+
+.. note::
+
+    Internally, Twig uses the PHP `abs`_ function.
+
+.. _`abs`: https://secure.php.net/abs
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/batch.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/batch.rst
new file mode 100644
index 0000000..18a227f
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/batch.rst
@@ -0,0 +1,44 @@
+``batch``
+=========
+
+The ``batch`` filter "batches" items by returning a list of lists with the
+given number of items. A second parameter can be provided and used to fill in
+missing items:
+
+.. code-block:: html+twig
+
+    {% set items = ['a', 'b', 'c', 'd'] %}
+
+    <table>
+        {% for row in items|batch(3, 'No item') %}
+            <tr>
+                {% for column in row %}
+                    <td>{{ column }}</td>
+                {% endfor %}
+            </tr>
+        {% endfor %}
+    </table>
+
+The above example will be rendered as:
+
+.. code-block:: html+twig
+
+    <table>
+        <tr>
+            <td>a</td>
+            <td>b</td>
+            <td>c</td>
+        </tr>
+        <tr>
+            <td>d</td>
+            <td>No item</td>
+            <td>No item</td>
+        </tr>
+    </table>
+
+Arguments
+---------
+
+* ``size``: The size of the batch; fractional numbers will be rounded up
+* ``fill``: Used to fill in missing items
+* ``preserve_keys``: Whether to preserve keys or not
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/capitalize.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/capitalize.rst
new file mode 100644
index 0000000..2353658
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/capitalize.rst
@@ -0,0 +1,11 @@
+``capitalize``
+==============
+
+The ``capitalize`` filter capitalizes a value. The first character will be
+uppercase, all others lowercase:
+
+.. code-block:: twig
+
+    {{ 'my first car'|capitalize }}
+
+    {# outputs 'My first car' #}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/column.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/column.rst
new file mode 100644
index 0000000..5b6769b
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/column.rst
@@ -0,0 +1,24 @@
+``column``
+==========
+
+The ``column`` filter returns the values from a single column in the input
+array.
+
+.. code-block:: twig
+
+    {% set items = [{ 'fruit' : 'apple'}, {'fruit' : 'orange' }] %}
+
+    {% set fruits = items|column('fruit') %}
+
+    {# fruits now contains ['apple', 'orange'] #}
+
+.. note::
+
+    Internally, Twig uses the PHP `array_column`_ function.
+
+Arguments
+---------
+
+* ``name``: The column name to extract
+
+.. _`array_column`: https://secure.php.net/array_column
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/convert_encoding.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/convert_encoding.rst
new file mode 100644
index 0000000..d977c75
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/convert_encoding.rst
@@ -0,0 +1,22 @@
+``convert_encoding``
+====================
+
+The ``convert_encoding`` filter converts a string from one encoding to
+another. The first argument is the expected output charset and the second one
+is the input charset:
+
+.. code-block:: twig
+
+    {{ data|convert_encoding('UTF-8', 'iso-2022-jp') }}
+
+.. note::
+
+    This filter relies on the `iconv`_ extension.
+
+Arguments
+---------
+
+* ``to``:   The output charset
+* ``from``: The input charset
+
+.. _`iconv`: https://secure.php.net/iconv
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/country_name.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/country_name.rst
new file mode 100644
index 0000000..434b0bd
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/country_name.rst
@@ -0,0 +1,44 @@
+``country_name``
+================
+
+The ``country_name`` filter returns the country name given its ISO-3166
+two-letter code:
+
+.. code-block:: twig
+
+    {# France #}
+    {{ 'FR'|country_name }}
+
+By default, the filter uses the current locale. You can pass it explicitly:
+
+.. code-block:: twig
+
+    {# États-Unis #}
+    {{ 'US'|country_name('fr') }}
+
+.. note::
+
+    The ``country_name`` filter is part of the ``IntlExtension`` which is not
+    installed by default. Install it first:
+
+    .. code-block:: bash
+
+        $ composer require twig/intl-extra
+
+    Then, on Symfony projects, install the ``twig/extra-bundle``:
+
+    .. code-block:: bash
+
+        $ composer require twig/extra-bundle
+
+    Otherwise, add the extension explicitly on the Twig environment::
+
+        use Twig\Extra\Intl\IntlExtension;
+
+        $twig = new \Twig\Environment(...);
+        $twig->addExtension(new IntlExtension());
+
+Arguments
+---------
+
+* ``locale``: The locale
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/currency_name.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/currency_name.rst
new file mode 100644
index 0000000..a35c499
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/currency_name.rst
@@ -0,0 +1,47 @@
+``currency_name``
+=================
+
+The ``currency_name`` filter returns the currency name given its three-letter
+code:
+
+.. code-block:: twig
+
+    {# Euro #}
+    {{ 'EUR'|currency_name }}
+
+    {# Japanese Yen #}
+    {{ 'JPY'|currency_name }}
+
+By default, the filter uses the current locale. You can pass it explicitly:
+
+.. code-block:: twig
+
+    {# yen japonais #}
+    {{ 'JPY'|currency_name('fr_FR') }}
+
+.. note::
+
+    The ``currency_name`` filter is part of the ``IntlExtension`` which is not
+    installed by default. Install it first:
+
+    .. code-block:: bash
+
+        $ composer require twig/intl-extra
+
+    Then, on Symfony projects, install the ``twig/extra-bundle``:
+
+    .. code-block:: bash
+
+        $ composer require twig/extra-bundle
+
+    Otherwise, add the extension explicitly on the Twig environment::
+
+        use Twig\Extra\Intl\IntlExtension;
+
+        $twig = new \Twig\Environment(...);
+        $twig->addExtension(new IntlExtension());
+
+Arguments
+---------
+
+* ``locale``: The locale
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/currency_symbol.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/currency_symbol.rst
new file mode 100644
index 0000000..84a048e
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/currency_symbol.rst
@@ -0,0 +1,47 @@
+``currency_symbol``
+===================
+
+The ``currency_symbol`` filter returns the currency symbol given its three-letter
+code:
+
+.. code-block:: twig
+
+    {# € #}
+    {{ 'EUR'|currency_symbol }}
+
+    {# ¥ #}
+    {{ 'JPY'|currency_symbol }}
+
+By default, the filter uses the current locale. You can pass it explicitly:
+
+.. code-block:: twig
+
+    {# ¥ #}
+    {{ 'JPY'|currency_symbol('fr') }}
+
+.. note::
+
+    The ``currency_symbol`` filter is part of the ``IntlExtension`` which is not
+    installed by default. Install it first:
+
+    .. code-block:: bash
+
+        $ composer require twig/intl-extra
+
+    Then, on Symfony projects, install the ``twig/extra-bundle``:
+
+    .. code-block:: bash
+
+        $ composer require twig/extra-bundle
+
+    Otherwise, add the extension explicitly on the Twig environment::
+
+        use Twig\Extra\Intl\IntlExtension;
+
+        $twig = new \Twig\Environment(...);
+        $twig->addExtension(new IntlExtension());
+
+Arguments
+---------
+
+* ``locale``: The locale
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/data_uri.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/data_uri.rst
new file mode 100644
index 0000000..e008266
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/data_uri.rst
@@ -0,0 +1,55 @@
+``data_uri``
+============
+
+The ``data_uri`` filter generates a URL using the data scheme as defined in
+`RFC 2397`_:
+
+.. code-block:: html+twig
+
+    {{ image_data|data_uri }}
+
+    {{ source('path_to_image')|data_uri }}
+
+    {# force the mime type, disable the guessing of the mime type #}
+    {{ image_data|data_uri(mime="image/svg") }}
+
+    {# also works with plain text #}
+    {{ '<b>foobar</b>'|data_uri(mime="text/html") }}
+
+    {# add some extra parameters #}
+    {{ '<b>foobar</b>'|data_uri(mime="text/html", parameters={charset: "ascii"}) }}
+
+.. note::
+
+    The ``data_uri`` filter is part of the ``HtmlExtension`` which is not
+    installed by default. Install it first:
+
+    .. code-block:: bash
+
+        $ composer require twig/html-extra
+
+    Then, on Symfony projects, install the ``twig/extra-bundle``:
+
+    .. code-block:: bash
+
+        $ composer require twig/extra-bundle
+
+    Otherwise, add the extension explicitly on the Twig environment::
+
+        use Twig\Extra\Html\HtmlExtension;
+
+        $twig = new \Twig\Environment(...);
+        $twig->addExtension(new HtmlExtension());
+
+.. note::
+
+    The filter does not perform any length validation on purpose (limit depends
+    on the usage context), validation should be done before calling this filter.
+
+Arguments
+---------
+
+* ``mime``: The mime type
+* ``parameters``: An array of parameters
+
+.. _RFC 2397: https://tools.ietf.org/html/rfc2397
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/date.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/date.rst
new file mode 100644
index 0000000..ec08d55
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/date.rst
@@ -0,0 +1,78 @@
+``date``
+========
+
+The ``date`` filter formats a date to a given format:
+
+.. code-block:: twig
+
+    {{ post.published_at|date("m/d/Y") }}
+
+The format specifier is the same as supported by `date`_,
+except when the filtered data is of type `DateInterval`_, when the format must conform to
+`DateInterval::format`_ instead.
+
+The ``date`` filter accepts strings (it must be in a format supported by the
+`strtotime`_ function), `DateTime`_ instances, or `DateInterval`_ instances. For
+instance, to display the current date, filter the word "now":
+
+.. code-block:: twig
+
+    {{ "now"|date("m/d/Y") }}
+
+To escape words and characters in the date format use ``\\`` in front of each
+character:
+
+.. code-block:: twig
+
+    {{ post.published_at|date("F jS \\a\\t g:ia") }}
+
+If the value passed to the ``date`` filter is ``null``, it will return the
+current date by default. If an empty string is desired instead of the current
+date, use a ternary operator:
+
+.. code-block:: twig
+
+    {{ post.published_at is empty ? "" : post.published_at|date("m/d/Y") }}
+
+If no format is provided, Twig will use the default one: ``F j, Y H:i``. This
+default can be changed by calling the ``setDateFormat()`` method on the
+``core`` extension instance. The first argument is the default format for
+dates and the second one is the default format for date intervals::
+
+    $twig = new \Twig\Environment($loader);
+    $twig->getExtension(\Twig\Extension\CoreExtension::class)->setDateFormat('d/m/Y', '%d days');
+
+Timezone
+--------
+
+By default, the date is displayed by applying the default timezone (the one
+specified in php.ini or declared in Twig -- see below), but you can override
+it by explicitly specifying a timezone:
+
+.. code-block:: twig
+
+    {{ post.published_at|date("m/d/Y", "Europe/Paris") }}
+
+If the date is already a DateTime object, and if you want to keep its current
+timezone, pass ``false`` as the timezone value:
+
+.. code-block:: twig
+
+    {{ post.published_at|date("m/d/Y", false) }}
+
+The default timezone can also be set globally by calling ``setTimezone()``::
+
+    $twig = new \Twig\Environment($loader);
+    $twig->getExtension(\Twig\Extension\CoreExtension::class)->setTimezone('Europe/Paris');
+
+Arguments
+---------
+
+* ``format``:   The date format
+* ``timezone``: The date timezone
+
+.. _`strtotime`:            https://secure.php.net/strtotime
+.. _`DateTime`:             https://secure.php.net/DateTime
+.. _`DateInterval`:         https://secure.php.net/DateInterval
+.. _`date`:                 https://secure.php.net/date
+.. _`DateInterval::format`: https://secure.php.net/DateInterval.format
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/date_modify.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/date_modify.rst
new file mode 100644
index 0000000..cc5d6df
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/date_modify.rst
@@ -0,0 +1,20 @@
+``date_modify``
+===============
+
+The ``date_modify`` filter modifies a date with a given modifier string:
+
+.. code-block:: twig
+
+    {{ post.published_at|date_modify("+1 day")|date("m/d/Y") }}
+
+The ``date_modify`` filter accepts strings (it must be in a format supported
+by the `strtotime`_ function) or `DateTime`_ instances. You can combine
+it with the :doc:`date<date>` filter for formatting.
+
+Arguments
+---------
+
+* ``modifier``: The modifier
+
+.. _`strtotime`: https://secure.php.net/strtotime
+.. _`DateTime`:  https://secure.php.net/DateTime
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/default.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/default.rst
new file mode 100644
index 0000000..2376fe7
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/default.rst
@@ -0,0 +1,42 @@
+``default``
+===========
+
+The ``default`` filter returns the passed default value if the value is
+undefined or empty, otherwise the value of the variable:
+
+.. code-block:: twig
+
+    {{ var|default('var is not defined') }}
+
+    {{ var.foo|default('foo item on var is not defined') }}
+
+    {{ var['foo']|default('foo item on var is not defined') }}
+
+    {{ ''|default('passed var is empty')  }}
+
+When using the ``default`` filter on an expression that uses variables in some
+method calls, be sure to use the ``default`` filter whenever a variable can be
+undefined:
+
+.. code-block:: twig
+
+    {{ var.method(foo|default('foo'))|default('foo') }}
+    
+Using the ``default`` filter on a boolean variable might trigger unexpected behavior, as
+``false`` is treated as an empty value. Consider using ``??`` instead:
+
+.. code-block:: twig
+
+    {% set foo = false %}
+    {{ foo|default(true) }} {# true #}
+    {{ foo ?? true }} {# false #}
+
+.. note::
+
+    Read the documentation for the :doc:`defined<../tests/defined>` and
+    :doc:`empty<../tests/empty>` tests to learn more about their semantics.
+
+Arguments
+---------
+
+* ``default``: The default value
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/escape.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/escape.rst
new file mode 100644
index 0000000..f105d97
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/escape.rst
@@ -0,0 +1,117 @@
+``escape``
+==========
+
+The ``escape`` filter escapes a string using strategies that depend on the
+context.
+
+By default, it uses the HTML escaping strategy:
+
+.. code-block:: html+twig
+
+    <p>
+        {{ user.username|escape }}
+    </p>
+
+For convenience, the ``e`` filter is defined as an alias:
+
+.. code-block:: html+twig
+
+    <p>
+        {{ user.username|e }}
+    </p>
+
+The ``escape`` filter can also be used in other contexts than HTML thanks to
+an optional argument which defines the escaping strategy to use:
+
+.. code-block:: twig
+
+    {{ user.username|e }}
+    {# is equivalent to #}
+    {{ user.username|e('html') }}
+
+And here is how to escape variables included in JavaScript code:
+
+.. code-block:: twig
+
+    {{ user.username|escape('js') }}
+    {{ user.username|e('js') }}
+
+The ``escape`` filter supports the following escaping strategies for HTML
+documents:
+
+* ``html``: escapes a string for the **HTML body** context.
+
+* ``js``: escapes a string for the **JavaScript** context.
+
+* ``css``: escapes a string for the **CSS** context. CSS escaping can be
+  applied to any string being inserted into CSS and escapes everything except
+  alphanumerics.
+
+* ``url``: escapes a string for the **URI or parameter** contexts. This should
+  not be used to escape an entire URI; only a subcomponent being inserted.
+
+* ``html_attr``: escapes a string for the **HTML attribute** context.
+
+Note that doing contextual escaping in HTML documents is hard and choosing the
+right escaping strategy depends on a lot of factors. Please, read related
+documentation like `the OWASP prevention cheat sheet
+<https://github.com/OWASP/CheatSheetSeries/blob/master/cheatsheets/Cross_Site_Scripting_Prevention_Cheat_Sheet.md>`_
+to learn more about this topic.
+
+.. note::
+
+    Internally, ``escape`` uses the PHP native `htmlspecialchars`_ function
+    for the HTML escaping strategy.
+
+.. caution::
+
+    When using automatic escaping, Twig tries to not double-escape a variable
+    when the automatic escaping strategy is the same as the one applied by the
+    escape filter; but that does not work when using a variable as the
+    escaping strategy:
+
+    .. code-block:: twig
+
+        {% set strategy = 'html' %}
+
+        {% autoescape 'html' %}
+            {{ var|escape('html') }}   {# won't be double-escaped #}
+            {{ var|escape(strategy) }} {# will be double-escaped #}
+        {% endautoescape %}
+
+    When using a variable as the escaping strategy, you should disable
+    automatic escaping:
+
+    .. code-block:: twig
+
+        {% set strategy = 'html' %}
+
+        {% autoescape 'html' %}
+            {{ var|escape(strategy)|raw }} {# won't be double-escaped #}
+        {% endautoescape %}
+
+Custom Escapers
+---------------
+
+You can define custom escapers by calling the ``setEscaper()`` method on the
+escaper extension instance. The first argument is the escaper name (to be
+used in the ``escape`` call) and the second one must be a valid PHP callable::
+
+    $twig = new \Twig\Environment($loader);
+    $twig->getExtension(\Twig\Extension\EscaperExtension::class)->setEscaper('csv', 'csv_escaper');
+
+When called by Twig, the callable receives the Twig environment instance, the
+string to escape, and the charset.
+
+.. note::
+
+    Built-in escapers cannot be overridden mainly because they should be
+    considered as the final implementation and also for better performance.
+
+Arguments
+---------
+
+* ``strategy``: The escaping strategy
+* ``charset``:  The string charset
+
+.. _`htmlspecialchars`: https://secure.php.net/htmlspecialchars
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/filter.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/filter.rst
new file mode 100644
index 0000000..257421f
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/filter.rst
@@ -0,0 +1,55 @@
+``filter``
+==========
+
+The ``filter`` filter filters elements of a sequence or a mapping using an arrow
+function. The arrow function receives the value of the sequence or mapping:
+
+.. code-block:: twig
+
+    {% set sizes = [34, 36, 38, 40, 42] %}
+
+    {{ sizes|filter(v => v > 38)|join(', ') }}
+    {# output 40, 42 #}
+
+Combined with the ``for`` tag, it allows to filter the items to iterate over:
+
+.. code-block:: twig
+
+    {% for v in sizes|filter(v => v > 38) -%}
+        {{ v }}
+    {% endfor %}
+    {# output 40 42 #}
+
+It also works with mappings:
+
+.. code-block:: twig
+
+    {% set sizes = {
+        xs: 34,
+        s:  36,
+        m:  38,
+        l:  40,
+        xl: 42,
+    } %}
+
+    {% for k, v in sizes|filter(v => v > 38) -%}
+        {{ k }} = {{ v }}
+    {% endfor %}
+    {# output l = 40 xl = 42 #}
+
+The arrow function also receives the key as a second argument:
+
+.. code-block:: twig
+
+    {% for k, v in sizes|filter((v, k) => v > 38 and k != "xl") -%}
+        {{ k }} = {{ v }}
+    {% endfor %}
+    {# output l = 40 #}
+
+Note that the arrow function has access to the current context.
+
+Arguments
+---------
+
+* ``array``: The sequence or mapping
+* ``arrow``: The arrow function
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/first.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/first.rst
new file mode 100644
index 0000000..8d7081a
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/first.rst
@@ -0,0 +1,22 @@
+``first``
+=========
+
+The ``first`` filter returns the first "element" of a sequence, a mapping, or
+a string:
+
+.. code-block:: twig
+
+    {{ [1, 2, 3, 4]|first }}
+    {# outputs 1 #}
+
+    {{ { a: 1, b: 2, c: 3, d: 4 }|first }}
+    {# outputs 1 #}
+
+    {{ '1234'|first }}
+    {# outputs 1 #}
+
+.. note::
+
+    It also works with objects implementing the `Traversable`_ interface.
+
+.. _`Traversable`: https://secure.php.net/manual/en/class.traversable.php
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/format.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/format.rst
new file mode 100644
index 0000000..782ea75
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/format.rst
@@ -0,0 +1,18 @@
+``format``
+==========
+
+The ``format`` filter formats a given string by replacing the placeholders
+(placeholders follows the `sprintf`_ notation):
+
+.. code-block:: twig
+
+    {{ "I like %s and %s."|format(foo, "bar") }}
+
+    {# outputs I like foo and bar
+       if the foo parameter equals to the foo string. #}
+
+.. seealso::
+
+    :doc:`replace<replace>`
+
+.. _`sprintf`: https://secure.php.net/sprintf
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/format_currency.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/format_currency.rst
new file mode 100644
index 0000000..8b649bf
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/format_currency.rst
@@ -0,0 +1,77 @@
+``format_currency``
+===================
+
+The ``format_currency`` filter formats a number as a currency:
+
+.. code-block:: twig
+
+    {# €1,000,000.00 #}
+    {{ '1000000'|format_currency('EUR') }}
+
+You can pass attributes to tweak the output:
+
+.. code-block:: twig
+
+    {# €12.34 #}
+    {{ '12.345'|format_currency('EUR', {rounding_mode: 'floor'}) }}
+
+    {# €1,000,000.0000 #}
+    {{ '1000000'|format_currency('EUR', {fraction_digit: 4}) }}
+
+The list of supported options:
+
+* ``grouping_used``;
+* ``decimal_always_shown``;
+* ``max_integer_digit``;
+* ``min_integer_digit``;
+* ``integer_digit``;
+* ``max_fraction_digit``;
+* ``min_fraction_digit``;
+* ``fraction_digit``;
+* ``multiplier``;
+* ``grouping_size``;
+* ``rounding_mode``;
+* ``rounding_increment``;
+* ``format_width``;
+* ``padding_position``;
+* ``secondary_grouping_size``;
+* ``significant_digits_used``;
+* ``min_significant_digits_used``;
+* ``max_significant_digits_used``;
+* ``lenient_parse``.
+
+By default, the filter uses the current locale. You can pass it explicitly:
+
+.. code-block:: twig
+
+    {# 1.000.000,00 € #}
+    {{ '1000000'|format_currency('EUR', locale='de') }}
+
+.. note::
+
+    The ``format_currency`` filter is part of the ``IntlExtension`` which is not
+    installed by default. Install it first:
+
+    .. code-block:: bash
+
+        $ composer require twig/intl-extra
+
+    Then, on Symfony projects, install the ``twig/extra-bundle``:
+
+    .. code-block:: bash
+
+        $ composer require twig/extra-bundle
+
+    Otherwise, add the extension explicitly on the Twig environment::
+
+        use Twig\Extra\Intl\IntlExtension;
+
+        $twig = new \Twig\Environment(...);
+        $twig->addExtension(new IntlExtension());
+
+Arguments
+---------
+
+* ``currency``: The currency
+* ``attrs``: A map of attributes
+* ``locale``: The locale
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/format_date.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/format_date.rst
new file mode 100644
index 0000000..c4a900a
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/format_date.rst
@@ -0,0 +1,36 @@
+``format_date``
+===============
+
+The ``format_date`` filter formats a date. It behaves in the exact same way as
+the :doc:`format_datetime<format_datetime>` filter, but without the time.
+
+.. note::
+
+    The ``format_date`` filter is part of the ``IntlExtension`` which is not
+    installed by default. Install it first:
+
+    .. code-block:: bash
+
+        $ composer require twig/intl-extra
+
+    Then, on Symfony projects, install the ``twig/extra-bundle``:
+
+    .. code-block:: bash
+
+        $ composer require twig/extra-bundle
+
+    Otherwise, add the extension explicitly on the Twig environment::
+
+        use Twig\Extra\Intl\IntlExtension;
+
+        $twig = new \Twig\Environment(...);
+        $twig->addExtension(new IntlExtension());
+
+Arguments
+---------
+
+* ``locale``: The locale
+* ``dateFormat``: The date format
+* ``pattern``: A date time pattern
+* ``timezone``: The date timezone
+* ``calendar``: The calendar (Gregorian by default)
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/format_datetime.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/format_datetime.rst
new file mode 100644
index 0000000..1fdaa1e
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/format_datetime.rst
@@ -0,0 +1,73 @@
+``format_datetime``
+===================
+
+The ``format_datetime`` filter formats a date time:
+
+.. code-block:: twig
+
+    {# Aug 7, 2019, 11:39:12 PM #}
+    {{ '2019-08-07 23:39:12'|format_datetime() }}
+
+You can tweak the output for the date part and the time part:
+
+.. code-block:: twig
+
+    {# 23:39 #}
+    {{ '2019-08-07 23:39:12'|format_datetime('none', 'short', locale='fr') }}
+
+    {# 07/08/2019 #}
+    {{ '2019-08-07 23:39:12'|format_datetime('short', 'none', locale='fr') }}
+
+    {# mercredi 7 août 2019 23:39:12 UTC #}
+    {{ '2019-08-07 23:39:12'|format_datetime('full', 'full', locale='fr') }}
+
+Supported values are: ``none``, ``short``, ``medium``, ``long``, and ``full``.
+
+For greater flexiblity, you can even define your own pattern (see the `ICU user
+guide
+<https://unicode-org.github.io/icu/userguide/format_parse/datetime/#datetime-format-syntax>`_
+for supported patterns).
+
+.. code-block:: twig
+
+    {# 11 oclock PM, GMT #}
+    {{ '2019-08-07 23:39:12'|format_datetime(pattern="hh 'oclock' a, zzzz") }}
+
+By default, the filter uses the current locale. You can pass it explicitly:
+
+.. code-block:: twig
+
+    {# 7 août 2019 23:39:12 #}
+    {{ '2019-08-07 23:39:12'|format_datetime(locale='fr') }}
+
+.. note::
+
+    The ``format_datetime`` filter is part of the ``IntlExtension`` which is not
+    installed by default. Install it first:
+
+    .. code-block:: bash
+
+        $ composer require twig/intl-extra
+
+    Then, on Symfony projects, install the ``twig/extra-bundle``:
+
+    .. code-block:: bash
+
+        $ composer require twig/extra-bundle
+
+    Otherwise, add the extension explicitly on the Twig environment::
+
+        use Twig\Extra\Intl\IntlExtension;
+
+        $twig = new \Twig\Environment(...);
+        $twig->addExtension(new IntlExtension());
+
+Arguments
+---------
+
+* ``locale``: The locale
+* ``dateFormat``: The date format
+* ``timeFormat``: The time format
+* ``pattern``: A date time pattern
+* ``timezone``: The date timezone
+* ``calendar``: The calendar (Gregorian by default)
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/format_number.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/format_number.rst
new file mode 100644
index 0000000..a1c2804
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/format_number.rst
@@ -0,0 +1,117 @@
+``format_number``
+=================
+
+The ``format_number`` filter formats a number:
+
+.. code-block:: twig
+
+    {{ '12.345'|format_number }}
+
+You can pass attributes to tweak the output:
+
+.. code-block:: twig
+
+    {# 12.34 #}
+    {{ '12.345'|format_number({rounding_mode: 'floor'}) }}
+
+    {# 1000000.0000 #}
+    {{ '1000000'|format_number({fraction_digit: 4}) }}
+
+The list of supported options:
+
+* ``grouping_used``;
+* ``decimal_always_shown``;
+* ``max_integer_digit``;
+* ``min_integer_digit``;
+* ``integer_digit``;
+* ``max_fraction_digit``;
+* ``min_fraction_digit``;
+* ``fraction_digit``;
+* ``multiplier``;
+* ``grouping_size``;
+* ``rounding_mode``;
+* ``rounding_increment``;
+* ``format_width``;
+* ``padding_position``;
+* ``secondary_grouping_size``;
+* ``significant_digits_used``;
+* ``min_significant_digits_used``;
+* ``max_significant_digits_used``;
+* ``lenient_parse``.
+
+Besides plain numbers, the filter can also format numbers in various styles:
+
+.. code-block:: twig
+
+    {# 1,234% #}
+    {{ '12.345'|format_number(style='percent') }}
+
+    {# twelve point three four five #}
+    {{ '12.345'|format_number(style='spellout') }}
+
+    {# 12 sec. #}
+    {{ '12'|format_duration_number }}
+
+The list of supported styles:
+
+* ``decimal``;
+* ``currency``;
+* ``percent``;
+* ``scientific``;
+* ``spellout``;
+* ``ordinal``;
+* ``duration``.
+
+As a shortcut, you can use the ``format_*_number`` filters by replacing `*` with
+a style:
+
+.. code-block:: twig
+
+    {# 1,234% #}
+    {{ '12.345'|format_percent_number }}
+
+    {# twelve point three four five #}
+    {{ '12.345'|format_spellout_number }}
+
+You can pass attributes to tweak the output:
+
+.. code-block:: twig
+
+    {# 12.3% #}
+    {{ '0.12345'|format_percent_number({rounding_mode: 'floor', fraction_digit: 1}) }}
+
+By default, the filter uses the current locale. You can pass it explicitly:
+
+.. code-block:: twig
+
+    {# 12,345 #}
+    {{ '12.345'|format_number(locale='fr') }}
+
+.. note::
+
+    The ``format_number`` filter is part of the ``IntlExtension`` which is not
+    installed by default. Install it first:
+
+    .. code-block:: bash
+
+        $ composer require twig/intl-extra
+
+    Then, on Symfony projects, install the ``twig/extra-bundle``:
+
+    .. code-block:: bash
+
+        $ composer require twig/extra-bundle
+
+    Otherwise, add the extension explicitly on the Twig environment::
+
+        use Twig\Extra\Intl\IntlExtension;
+
+        $twig = new \Twig\Environment(...);
+        $twig->addExtension(new IntlExtension());
+
+Arguments
+---------
+
+* ``locale``: The locale
+* ``attrs``: A map of attributes
+* ``style``: The style of the number output
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/format_time.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/format_time.rst
new file mode 100644
index 0000000..417b8a9
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/format_time.rst
@@ -0,0 +1,36 @@
+``format_time``
+===============
+
+The ``format_time`` filter formats a time. It behaves in the exact same way as
+the :doc:`format_datetime<format_datetime>` filter, but without the date.
+
+.. note::
+
+    The ``format_time`` filter is part of the ``IntlExtension`` which is not
+    installed by default. Install it first:
+
+    .. code-block:: bash
+
+        $ composer require twig/intl-extra
+
+    Then, on Symfony projects, install the ``twig/extra-bundle``:
+
+    .. code-block:: bash
+
+        $ composer require twig/extra-bundle
+
+    Otherwise, add the extension explicitly on the Twig environment::
+
+        use Twig\Extra\Intl\IntlExtension;
+
+        $twig = new \Twig\Environment(...);
+        $twig->addExtension(new IntlExtension());
+
+Arguments
+---------
+
+* ``locale``: The locale
+* ``timeFormat``: The time format
+* ``pattern``: A date time pattern
+* ``timezone``: The date timezone
+* ``calendar``: The calendar (Gregorian by default)
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/html_to_markdown.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/html_to_markdown.rst
new file mode 100644
index 0000000..80145df
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/html_to_markdown.rst
@@ -0,0 +1,77 @@
+``html_to_markdown``
+====================
+
+The ``html_to_markdown`` filter converts a block of HTML to Markdown:
+
+.. code-block:: html+twig
+
+    {% apply html_to_markdown %}
+        <html>
+            <h1>Hello!</h1>
+        </html>
+    {% endapply %}
+
+You can also use the filter on an entire template which you ``include``:
+
+.. code-block:: twig
+
+    {{ include('some_template.html.twig')|html_to_markdown }}
+
+.. note::
+
+    The ``html_to_markdown`` filter is part of the ``MarkdownExtension`` which
+    is not installed by default. Install it first:
+
+    .. code-block:: bash
+
+        $ composer require twig/markdown-extra
+
+    On Symfony projects, you can automatically enable it by installing the
+    ``twig/extra-bundle``:
+
+    .. code-block:: bash
+
+        $ composer require twig/extra-bundle
+
+    Or add the extension explicitly on the Twig environment::
+
+        use Twig\Extra\Markdown\MarkdownExtension;
+
+        $twig = new \Twig\Environment(...);
+        $twig->addExtension(new MarkdownExtension());
+
+    If you are not using Symfony, you must also register the extension runtime::
+
+        use Twig\Extra\Markdown\DefaultMarkdown;
+        use Twig\Extra\Markdown\MarkdownRuntime;
+        use Twig\RuntimeLoader\RuntimeLoaderInterface;
+
+        $twig->addRuntimeLoader(new class implements RuntimeLoaderInterface {
+            public function load($class) {
+                if (MarkdownRuntime::class === $class) {
+                    return new MarkdownRuntime(new DefaultMarkdown());
+                }
+            }
+        });
+
+``html_to_markdown`` is just a frontend; the actual conversion is done by one of
+the following compatible libraries, from which you can choose:
+
+* `erusev/parsedown`_
+* `league/html-to-markdown`_
+* `michelf/php-markdown`_
+
+Depending on the library, you can also add some options by passing them as an argument
+to the filter. Example for ``league/html-to-markdown``:
+
+.. code-block:: html+twig
+
+    {% apply html_to_markdown({hard_break: false}) %}
+        <html>
+            <h1>Hello!</h1>
+        </html>
+    {% endapply %}
+    
+.. _erusev/parsedown: https://github.com/erusev/parsedown
+.. _league/html-to-markdown: https://github.com/thephpleague/html-to-markdown
+.. _michelf/php-markdown: https://github.com/michelf/php-markdown
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/index.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/index.rst
new file mode 100644
index 0000000..eea2383
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/index.rst
@@ -0,0 +1,60 @@
+Filters
+=======
+
+.. toctree::
+    :maxdepth: 1
+
+    abs
+    batch
+    capitalize
+    column
+    convert_encoding
+    country_name
+    currency_name
+    currency_symbol
+    data_uri
+    date
+    date_modify
+    default
+    escape
+    filter
+    first
+    format
+    format_currency
+    format_date
+    format_datetime
+    format_number
+    format_time
+    html_to_markdown
+    inline_css
+    inky_to_html
+    join
+    json_encode
+    keys
+    language_name
+    last
+    length
+    locale_name
+    lower
+    map
+    markdown_to_html
+    merge
+    nl2br
+    number_format
+    raw
+    reduce
+    replace
+    reverse
+    round
+    slice
+    slug
+    sort
+    spaceless
+    split
+    striptags
+    timezone_name
+    title
+    trim
+    u
+    upper
+    url_encode
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/inky_to_html.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/inky_to_html.rst
new file mode 100644
index 0000000..563baba
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/inky_to_html.rst
@@ -0,0 +1,42 @@
+``inky_to_html``
+================
+
+The ``inky_to_html`` filter processes an `inky email template
+<https://github.com/zurb/inky>`_:
+
+.. code-block:: html+twig
+
+    {% apply inky_to_html %}
+        <row>
+            <columns large="6"></columns>
+            <columns large="6"></columns>
+        </row>
+    {% endapply %}
+
+You can also use the filter on an included file:
+
+.. code-block:: twig
+
+    {{ include('some_template.inky.twig')|inky_to_html }}
+
+.. note::
+
+    The ``inky_to_html`` filter is part of the ``InkyExtension`` which is not
+    installed by default. Install it first:
+
+    .. code-block:: bash
+
+        $ composer require twig/inky-extra
+
+    Then, on Symfony projects, install the ``twig/extra-bundle``:
+
+    .. code-block:: bash
+
+        $ composer require twig/extra-bundle
+
+    Otherwise, add the extension explicitly on the Twig environment::
+
+        use Twig\Extra\Inky\InkyExtension;
+
+        $twig = new \Twig\Environment(...);
+        $twig->addExtension(new InkyExtension());
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/inline_css.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/inline_css.rst
new file mode 100644
index 0000000..44b1426
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/inline_css.rst
@@ -0,0 +1,66 @@
+``inline_css``
+==============
+
+The ``inline_css`` filter inline CSS styles in HTML documents:
+
+.. code-block:: html+twig
+
+    {% apply inline_css %}
+        <html>
+            <head>
+                <style>
+                    p { color: red; }
+                </style>
+            </head>
+            <body>
+                <p>Hello CSS!</p>
+            </body>
+        </html>
+    {% endapply %}
+
+You can also add some stylesheets by passing them as arguments to the filter:
+
+.. code-block:: html+twig
+
+    {% apply inline_css(source("some_styles.css"), source("another.css")) %}
+        <html>
+            <body>
+                <p>Hello CSS!</p>
+            </body>
+        </html>
+    {% endapply %}
+
+Styles loaded via the filter override the styles defined in the ``<style>`` tag
+of the HTML document.
+
+You can also use the filter on an included file:
+
+.. code-block:: twig
+
+    {{ include('some_template.html.twig')|inline_css }}
+
+    {{ include('some_template.html.twig')|inline_css(source("some_styles.css")) }}
+
+Note that the CSS inliner works on an entire HTML document, not a fragment.
+
+.. note::
+
+    The ``inline_css`` filter is part of the ``CssInlinerExtension`` which is not
+    installed by default. Install it first:
+
+    .. code-block:: bash
+
+        $ composer require twig/cssinliner-extra
+
+    Then, on Symfony projects, install the ``twig/extra-bundle``:
+
+    .. code-block:: bash
+
+        $ composer require twig/extra-bundle
+
+    Otherwise, add the extension explicitly on the Twig environment::
+
+        use Twig\Extra\CssInliner\CssInlinerExtension;
+
+        $twig = new \Twig\Environment(...);
+        $twig->addExtension(new CssInlinerExtension());
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/join.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/join.rst
new file mode 100644
index 0000000..d57be66
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/join.rst
@@ -0,0 +1,32 @@
+``join``
+========
+
+The ``join`` filter returns a string which is the concatenation of the items
+of a sequence:
+
+.. code-block:: twig
+
+    {{ [1, 2, 3]|join }}
+    {# returns 123 #}
+
+The separator between elements is an empty string per default, but you can
+define it with the optional first parameter:
+
+.. code-block:: twig
+
+    {{ [1, 2, 3]|join('|') }}
+    {# outputs 1|2|3 #}
+
+A second parameter can also be provided that will be the separator used between
+the last two items of the sequence:
+
+.. code-block:: twig
+
+    {{ [1, 2, 3]|join(', ', ' and ') }}
+    {# outputs 1, 2 and 3 #}
+
+Arguments
+---------
+
+* ``glue``: The separator
+* ``and``: The separator for the last pair of input items
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/json_encode.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/json_encode.rst
new file mode 100644
index 0000000..434e2f1
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/json_encode.rst
@@ -0,0 +1,23 @@
+``json_encode``
+===============
+
+The ``json_encode`` filter returns the JSON representation of a value:
+
+.. code-block:: twig
+
+    {{ data|json_encode() }}
+
+.. note::
+
+    Internally, Twig uses the PHP `json_encode`_ function.
+
+Arguments
+---------
+
+* ``options``: A bitmask of `json_encode options`_: ``{{
+  data|json_encode(constant('JSON_PRETTY_PRINT')) }}``.
+  Combine constants using :ref:`bitwise operators<template_logic>`:
+  ``{{ data|json_encode(constant('JSON_PRETTY_PRINT') b-or constant('JSON_HEX_QUOT')) }}``
+
+.. _`json_encode`: https://secure.php.net/json_encode
+.. _`json_encode options`: https://secure.php.net/manual/en/json.constants.php
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/keys.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/keys.rst
new file mode 100644
index 0000000..5860947
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/keys.rst
@@ -0,0 +1,11 @@
+``keys``
+========
+
+The ``keys`` filter returns the keys of an array. It is useful when you want to
+iterate over the keys of an array:
+
+.. code-block:: twig
+
+    {% for key in array|keys %}
+        ...
+    {% endfor %}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/language_name.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/language_name.rst
new file mode 100644
index 0000000..55c2439
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/language_name.rst
@@ -0,0 +1,47 @@
+``language_name``
+=================
+
+The ``language_name`` filter returns the language name given its two-letter
+code:
+
+.. code-block:: twig
+
+    {# German #}
+    {{ 'de'|language_name }}
+
+By default, the filter uses the current locale. You can pass it explicitly:
+
+.. code-block:: twig
+
+    {# allemand #}
+    {{ 'de'|language_name('fr') }}
+
+    {# français canadien #}
+    {{ 'fr_CA'|language_name('fr_FR') }}
+
+.. note::
+
+    The ``language_name`` filter is part of the ``IntlExtension`` which is not
+    installed by default. Install it first:
+
+    .. code-block:: bash
+
+        $ composer require twig/intl-extra
+
+    Then, on Symfony projects, install the ``twig/extra-bundle``:
+
+    .. code-block:: bash
+
+        $ composer require twig/extra-bundle
+
+    Otherwise, add the extension explicitly on the Twig environment::
+
+        use Twig\Extra\Intl\IntlExtension;
+
+        $twig = new \Twig\Environment(...);
+        $twig->addExtension(new IntlExtension());
+
+Arguments
+---------
+
+* ``locale``: The locale
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/last.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/last.rst
new file mode 100644
index 0000000..2b7c45b
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/last.rst
@@ -0,0 +1,22 @@
+``last``
+========
+
+The ``last`` filter returns the last "element" of a sequence, a mapping, or
+a string:
+
+.. code-block:: twig
+
+    {{ [1, 2, 3, 4]|last }}
+    {# outputs 4 #}
+
+    {{ { a: 1, b: 2, c: 3, d: 4 }|last }}
+    {# outputs 4 #}
+
+    {{ '1234'|last }}
+    {# outputs 4 #}
+
+.. note::
+
+    It also works with objects implementing the `Traversable`_ interface.
+
+.. _`Traversable`: https://secure.php.net/manual/en/class.traversable.php
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/length.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/length.rst
new file mode 100644
index 0000000..d367122
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/length.rst
@@ -0,0 +1,19 @@
+``length``
+==========
+
+The ``length`` filter returns the number of items of a sequence or mapping, or
+the length of a string.
+
+For objects that implement the ``Countable`` interface, ``length`` will use the
+return value of the ``count()`` method.
+
+For objects that implement the ``__toString()`` magic method (and not ``Countable``),
+it will return the length of the string provided by that method.
+
+For objects that implement the ``Traversable`` interface, ``length`` will use the return value of the ``iterator_count()`` method.
+
+.. code-block:: twig
+
+    {% if users|length > 10 %}
+        ...
+    {% endif %}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/locale_name.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/locale_name.rst
new file mode 100644
index 0000000..c6d34cb
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/locale_name.rst
@@ -0,0 +1,47 @@
+``locale_name``
+===============
+
+The ``locale_name`` filter returns the locale name given its two-letter
+code:
+
+.. code-block:: twig
+
+    {# German #}
+    {{ 'de'|locale_name }}
+
+By default, the filter uses the current locale. You can pass it explicitly:
+
+.. code-block:: twig
+
+    {# allemand #}
+    {{ 'de'|locale_name('fr') }}
+
+    {# français (Canada) #}
+    {{ 'fr_CA'|locale_name('fr_FR') }}
+
+.. note::
+
+    The ``locale_name`` filter is part of the ``IntlExtension`` which is not
+    installed by default. Install it first:
+
+    .. code-block:: bash
+
+        $ composer require twig/intl-extra
+
+    Then, on Symfony projects, install the ``twig/extra-bundle``:
+
+    .. code-block:: bash
+
+        $ composer require twig/extra-bundle
+
+    Otherwise, add the extension explicitly on the Twig environment::
+
+        use Twig\Extra\Intl\IntlExtension;
+
+        $twig = new \Twig\Environment(...);
+        $twig->addExtension(new IntlExtension());
+
+Arguments
+---------
+
+* ``locale``: The locale
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/lower.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/lower.rst
new file mode 100644
index 0000000..c0a0e0c
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/lower.rst
@@ -0,0 +1,10 @@
+``lower``
+=========
+
+The ``lower`` filter converts a value to lowercase:
+
+.. code-block:: twig
+
+    {{ 'WELCOME'|lower }}
+
+    {# outputs 'welcome' #}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/map.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/map.rst
new file mode 100644
index 0000000..1083bfe
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/map.rst
@@ -0,0 +1,34 @@
+``map``
+=======
+
+The ``map`` filter applies an arrow function to the elements of a sequence or a
+mapping. The arrow function receives the value of the sequence or mapping:
+
+.. code-block:: twig
+
+    {% set people = [
+        {first: "Bob", last: "Smith"},
+        {first: "Alice", last: "Dupond"},
+    ] %}
+
+    {{ people|map(p => "#{p.first} #{p.last}")|join(', ') }}
+    {# outputs Bob Smith, Alice Dupond #}
+
+The arrow function also receives the key as a second argument:
+
+.. code-block:: twig
+
+    {% set people = {
+        "Bob": "Smith",
+        "Alice": "Dupond",
+    } %}
+
+    {{ people|map((last, first) => "#{first} #{last}")|join(', ') }}
+    {# outputs Bob Smith, Alice Dupond #}
+
+Note that the arrow function has access to the current context.
+
+Arguments
+---------
+
+* ``arrow``: The arrow function
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/markdown_to_html.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/markdown_to_html.rst
new file mode 100644
index 0000000..3903746
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/markdown_to_html.rst
@@ -0,0 +1,72 @@
+``markdown_to_html``
+====================
+
+The ``markdown_to_html`` filter converts a block of Markdown to HTML:
+
+.. code-block:: twig
+
+    {% apply markdown_to_html %}
+    Title
+    ======
+
+    Hello!
+    {% endapply %}
+
+Note that you can indent the Markdown content as leading whitespaces will be
+removed consistently before conversion:
+
+.. code-block:: twig
+
+    {% apply markdown_to_html %}
+        Title
+        ======
+
+        Hello!
+    {% endapply %}
+
+You can also use the filter on an included file or a variable:
+
+.. code-block:: twig
+
+    {{ include('some_template.markdown.twig')|markdown_to_html }}
+    
+    {{ changelog|markdown_to_html }}
+
+.. note::
+
+    The ``markdown_to_html`` filter is part of the ``MarkdownExtension`` which
+    is not installed by default. Install it first:
+
+    .. code-block:: bash
+
+        $ composer require twig/markdown-extra
+
+    Then, on Symfony projects, install the ``twig/extra-bundle``:
+
+    .. code-block:: bash
+
+        $ composer require twig/extra-bundle
+
+    Otherwise, add the extension explicitly on the Twig environment::
+
+        use Twig\Extra\Markdown\MarkdownExtension;
+
+        $twig = new \Twig\Environment(...);
+        $twig->addExtension(new MarkdownExtension());
+
+    If you are not using Symfony, you must also register the extension runtime::
+
+        use Twig\Extra\Markdown\DefaultMarkdown;
+        use Twig\Extra\Markdown\MarkdownRuntime;
+        use Twig\RuntimeLoader\RuntimeLoaderInterface;
+
+        $twig->addRuntimeLoader(new class implements RuntimeLoaderInterface {
+            public function load($class) {
+                if (MarkdownRuntime::class === $class) {
+                    return new MarkdownRuntime(new DefaultMarkdown());
+                }
+            }
+        });
+       
+    Afterwards you need to install a markdown library of your choice. Some of them are
+    mentioned in the ``require-dev`` section of the ``twig/markdown-extra`` package.
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/merge.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/merge.rst
new file mode 100644
index 0000000..e26e51c
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/merge.rst
@@ -0,0 +1,48 @@
+``merge``
+=========
+
+The ``merge`` filter merges an array with another array:
+
+.. code-block:: twig
+
+    {% set values = [1, 2] %}
+
+    {% set values = values|merge(['apple', 'orange']) %}
+
+    {# values now contains [1, 2, 'apple', 'orange'] #}
+
+New values are added at the end of the existing ones.
+
+The ``merge`` filter also works on hashes:
+
+.. code-block:: twig
+
+    {% set items = { 'apple': 'fruit', 'orange': 'fruit', 'peugeot': 'unknown' } %}
+
+    {% set items = items|merge({ 'peugeot': 'car', 'renault': 'car' }) %}
+
+    {# items now contains { 'apple': 'fruit', 'orange': 'fruit', 'peugeot': 'car', 'renault': 'car' } #}
+
+For hashes, the merging process occurs on the keys: if the key does not
+already exist, it is added but if the key already exists, its value is
+overridden.
+
+.. tip::
+
+    If you want to ensure that some values are defined in an array (by given
+    default values), reverse the two elements in the call:
+
+    .. code-block:: twig
+
+        {% set items = { 'apple': 'fruit', 'orange': 'fruit' } %}
+
+        {% set items = { 'apple': 'unknown' }|merge(items) %}
+
+        {# items now contains { 'apple': 'fruit', 'orange': 'fruit' } #}
+        
+.. note::
+
+    Internally, Twig uses the PHP `array_merge`_ function. It supports
+    Traversable objects by transforming those to arrays.
+
+.. _`array_merge`: https://secure.php.net/array_merge
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/nl2br.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/nl2br.rst
new file mode 100644
index 0000000..7c84c22
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/nl2br.rst
@@ -0,0 +1,19 @@
+``nl2br``
+=========
+
+The ``nl2br`` filter inserts HTML line breaks before all newlines in a string:
+
+.. code-block:: html+twig
+
+    {{ "I like Twig.\nYou will like it too."|nl2br }}
+    {# outputs
+
+        I like Twig.<br />
+        You will like it too.
+
+    #}
+
+.. note::
+
+    The ``nl2br`` filter pre-escapes the input before applying the
+    transformation.
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/number_format.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/number_format.rst
new file mode 100644
index 0000000..c44e2e3
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/number_format.rst
@@ -0,0 +1,51 @@
+``number_format``
+=================
+
+The ``number_format`` filter formats numbers.  It is a wrapper around PHP's
+`number_format`_ function:
+
+.. code-block:: twig
+
+    {{ 200.35|number_format }}
+
+You can control the number of decimal places, decimal point, and thousands
+separator using the additional arguments:
+
+.. code-block:: twig
+
+    {{ 9800.333|number_format(2, '.', ',') }}
+
+To format negative numbers or math calculation, wrap the previous statement
+with parentheses (needed because of Twig's :ref:`precedence of operators
+<twig-expressions>`):
+
+.. code-block:: twig
+
+    {{ -9800.333|number_format(2, '.', ',') }} {# outputs : -9 #}
+    {{ (-9800.333)|number_format(2, '.', ',') }} {# outputs : -9,800.33 #}
+    {{  1 + 0.2|number_format(2) }} {# outputs : 1.2 #}
+    {{ (1 + 0.2)|number_format(2) }} {# outputs : 1.20 #}
+
+If no formatting options are provided then Twig will use the default formatting
+options of:
+
+* 0 decimal places.
+* ``.`` as the decimal point.
+* ``,`` as the thousands separator.
+
+These defaults can be changed through the core extension::
+
+    $twig = new \Twig\Environment($loader);
+    $twig->getExtension(\Twig\Extension\CoreExtension::class)->setNumberFormat(3, '.', ',');
+
+The defaults set for ``number_format`` can be over-ridden upon each call using the
+additional parameters.
+
+Arguments
+---------
+
+* ``decimal``:       The number of decimal points to display
+* ``decimal_point``: The character(s) to use for the decimal point
+* ``thousand_sep``:   The character(s) to use for the thousands separator
+
+.. _`number_format`: https://secure.php.net/number_format
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/raw.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/raw.rst
new file mode 100644
index 0000000..856e969
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/raw.rst
@@ -0,0 +1,12 @@
+``raw``
+=======
+
+The ``raw`` filter marks the value as being "safe", which means that in an
+environment with automatic escaping enabled this variable will not be escaped
+if ``raw`` is the last filter applied to it:
+
+.. code-block:: twig
+
+    {% autoescape %}
+        {{ var|raw }} {# var won't be escaped #}
+    {% endautoescape %}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/reduce.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/reduce.rst
new file mode 100644
index 0000000..7df4646
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/reduce.rst
@@ -0,0 +1,29 @@
+``reduce``
+==========
+
+The ``reduce`` filter iteratively reduces a sequence or a mapping to a single
+value using an arrow function, so as to reduce it to a single value. The arrow
+function receives the return value of the previous iteration and the current
+value of the sequence or mapping:
+
+.. code-block:: twig
+
+    {% set numbers = [1, 2, 3] %}
+
+    {{ numbers|reduce((carry, v) => carry + v) }}
+    {# output 6 #}
+
+The ``reduce`` filter takes an ``initial`` value as a second argument:
+
+.. code-block:: twig
+
+    {{ numbers|reduce((carry, v) => carry + v, 10) }}
+    {# output 16 #}
+
+Note that the arrow function has access to the current context.
+
+Arguments
+---------
+
+* ``arrow``: The arrow function
+* ``initial``: The initial value
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/replace.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/replace.rst
new file mode 100644
index 0000000..5761a21
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/replace.rst
@@ -0,0 +1,27 @@
+``replace``
+===========
+
+The ``replace`` filter formats a given string by replacing the placeholders
+(placeholders are free-form):
+
+.. code-block:: twig
+
+    {{ "I like %this% and %that%."|replace({'%this%': foo, '%that%': "bar"}) }}
+
+    {# outputs I like foo and bar
+       if the foo parameter equals to the foo string. #}
+
+    {# using % as a delimiter is purely conventional and optional #}
+
+    {{ "I like this and --that--."|replace({'this': foo, '--that--': "bar"}) }}
+
+    {# outputs I like foo and bar #}
+
+Arguments
+---------
+
+* ``from``: The placeholder values
+
+.. seealso::
+
+    :doc:`format<format>`
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/reverse.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/reverse.rst
new file mode 100644
index 0000000..c5ceb7d
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/reverse.rst
@@ -0,0 +1,44 @@
+``reverse``
+===========
+
+The ``reverse`` filter reverses a sequence, a mapping, or a string:
+
+.. code-block:: twig
+
+    {% for user in users|reverse %}
+        ...
+    {% endfor %}
+
+    {{ '1234'|reverse }}
+
+    {# outputs 4321 #}
+
+.. tip::
+
+    For sequences and mappings, numeric keys are not preserved. To reverse
+    them as well, pass ``true`` as an argument to the ``reverse`` filter:
+
+    .. code-block:: twig
+
+        {% for key, value in {1: "a", 2: "b", 3: "c"}|reverse %}
+            {{ key }}: {{ value }}
+        {%- endfor %}
+
+        {# output: 0: c    1: b    2: a #}
+
+        {% for key, value in {1: "a", 2: "b", 3: "c"}|reverse(true) %}
+            {{ key }}: {{ value }}
+        {%- endfor %}
+
+        {# output: 3: c    2: b    1: a #}
+
+.. note::
+
+    It also works with objects implementing the `Traversable`_ interface.
+
+Arguments
+---------
+
+* ``preserve_keys``: Preserve keys when reversing a mapping or a sequence.
+
+.. _`Traversable`: https://secure.php.net/Traversable
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/round.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/round.rst
new file mode 100644
index 0000000..2c970b7
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/round.rst
@@ -0,0 +1,34 @@
+``round``
+=========
+
+The ``round`` filter rounds a number to a given precision:
+
+.. code-block:: twig
+
+    {{ 42.55|round }}
+    {# outputs 43 #}
+
+    {{ 42.55|round(1, 'floor') }}
+    {# outputs 42.5 #}
+
+The ``round`` filter takes two optional arguments; the first one specifies the
+precision (default is ``0``) and the second the rounding method (default is
+``common``):
+
+* ``common`` rounds either up or down (rounds the value up to precision decimal
+  places away from zero, when it is half way there -- making 1.5 into 2 and
+  -1.5 into -2);
+
+* ``ceil`` always rounds up;
+
+* ``floor`` always rounds down.
+
+.. note::
+
+    The ``//`` operator is equivalent to ``|round(0, 'floor')``.
+
+Arguments
+---------
+
+* ``precision``: The rounding precision
+* ``method``: The rounding method
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/slice.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/slice.rst
new file mode 100644
index 0000000..ff38bbc
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/slice.rst
@@ -0,0 +1,68 @@
+``slice``
+===========
+
+The ``slice`` filter extracts a slice of a sequence, a mapping, or a string:
+
+.. code-block:: twig
+
+    {% for i in [1, 2, 3, 4, 5]|slice(1, 2) %}
+        {# will iterate over 2 and 3 #}
+    {% endfor %}
+
+    {{ '12345'|slice(1, 2) }}
+
+    {# outputs 23 #}
+
+You can use any valid expression for both the start and the length:
+
+.. code-block:: twig
+
+    {% for i in [1, 2, 3, 4, 5]|slice(start, length) %}
+        {# ... #}
+    {% endfor %}
+
+As syntactic sugar, you can also use the ``[]`` notation:
+
+.. code-block:: twig
+
+    {% for i in [1, 2, 3, 4, 5][start:length] %}
+        {# ... #}
+    {% endfor %}
+
+    {{ '12345'[1:2] }} {# will display "23" #}
+
+    {# you can omit the first argument -- which is the same as 0 #}
+    {{ '12345'[:2] }} {# will display "12" #}
+
+    {# you can omit the last argument -- which will select everything till the end #}
+    {{ '12345'[2:] }} {# will display "345" #}
+
+The ``slice`` filter works as the `array_slice`_ PHP function for arrays and
+`mb_substr`_ for strings with a fallback to `substr`_.
+
+If the start is non-negative, the sequence will start at that start in the
+variable. If start is negative, the sequence will start that far from the end
+of the variable.
+
+If length is given and is positive, then the sequence will have up to that
+many elements in it. If the variable is shorter than the length, then only the
+available variable elements will be present. If length is given and is
+negative then the sequence will stop that many elements from the end of the
+variable. If it is omitted, then the sequence will have everything from offset
+up until the end of the variable.
+
+.. note::
+
+    It also works with objects implementing the `Traversable`_ interface.
+
+Arguments
+---------
+
+* ``start``:         The start of the slice
+* ``length``:        The size of the slice
+* ``preserve_keys``: Whether to preserve key or not (when the input is an array)
+
+.. _`Traversable`: https://secure.php.net/manual/en/class.traversable.php
+.. _`array_slice`: https://secure.php.net/array_slice
+.. _`mb_substr`:   https://secure.php.net/mb-substr
+.. _`substr`:      https://secure.php.net/substr
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/slug.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/slug.rst
new file mode 100644
index 0000000..773a42f
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/slug.rst
@@ -0,0 +1,59 @@
+``slug``
+========
+
+The ``slug`` filter transforms a given string into another string that
+only includes safe ASCII characters. 
+
+Here is an example:
+
+.. code-block:: twig
+
+    {{ 'Wôrķšƥáçè ~~sèťtïñğš~~'|slug }}
+    Workspace-settings
+
+The default separator between words is a dash (``-``), but you can 
+define a selector of your choice by passing it as an argument:
+
+.. code-block:: twig
+
+    {{ 'Wôrķšƥáçè ~~sèťtïñğš~~'|slug('/') }}
+    Workspace/settings
+
+The slugger automatically detects the language of the original
+string, but you can also specify it explicitly using the second
+argument:
+
+.. code-block:: twig
+
+    {{ '...'|slug('-', 'ko') }}
+
+The ``slug`` filter uses the method by the same name in Symfony's 
+`AsciiSlugger <https://symfony.com/doc/current/components/string.html#slugger>`_. 
+
+.. note::
+
+    The ``slug`` filter is part of the ``StringExtension`` which is not
+    installed by default. Install it first:
+
+    .. code-block:: bash
+
+        $ composer require twig/string-extra
+
+    Then, on Symfony projects, install the ``twig/extra-bundle``:
+
+    .. code-block:: bash
+
+        $ composer require twig/extra-bundle
+
+    Otherwise, add the extension explicitly on the Twig environment::
+
+        use Twig\Extra\String\StringExtension;
+
+        $twig = new \Twig\Environment(...);
+        $twig->addExtension(new StringExtension());
+
+Arguments
+---------
+
+* ``separator``: The separator that is used to join words (defaults to ``-``)
+* ``locale``: The locale of the original string (if none is specified, it will be automatically detected)
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/sort.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/sort.rst
new file mode 100644
index 0000000..3dc5f4d
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/sort.rst
@@ -0,0 +1,42 @@
+``sort``
+========
+
+The ``sort`` filter sorts an array:
+
+.. code-block:: twig
+
+    {% for user in users|sort %}
+        ...
+    {% endfor %}
+
+.. note::
+
+    Internally, Twig uses the PHP `asort`_ function to maintain index
+    association. It supports Traversable objects by transforming
+    those to arrays.
+
+You can pass an arrow function to sort the array:
+
+.. code-block:: html+twig
+
+    {% set fruits = [
+        { name: 'Apples', quantity: 5 },
+        { name: 'Oranges', quantity: 2 },
+        { name: 'Grapes', quantity: 4 },
+    ] %}
+
+    {% for fruit in fruits|sort((a, b) => a.quantity <=> b.quantity)|column('name') %}
+        {{ fruit }}
+    {% endfor %}
+
+    {# output in this order: Oranges, Grapes, Apples #}
+
+Note the usage of the `spaceship`_ operator to simplify the comparison.
+
+Arguments
+---------
+
+* ``arrow``: An arrow function
+
+.. _`asort`: https://secure.php.net/asort
+.. _`spaceship`: https://www.php.net/manual/en/language.operators.comparison.php
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/spaceless.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/spaceless.rst
new file mode 100644
index 0000000..9a213c3
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/spaceless.rst
@@ -0,0 +1,56 @@
+``spaceless``
+=============
+
+Use the ``spaceless`` filter to remove whitespace *between HTML tags*, not
+whitespace within HTML tags or whitespace in plain text:
+
+.. code-block:: html+twig
+
+    {{
+        "<div>
+            <strong>foo</strong>
+        </div>
+        "|spaceless }}
+
+    {# output will be <div><strong>foo</strong></div> #}
+
+You can combine ``spaceless`` with the ``apply`` tag to apply the transformation
+on large amounts of HTML:
+
+.. code-block:: html+twig
+
+    {% apply spaceless %}
+        <div>
+            <strong>foo</strong>
+        </div>
+    {% endapply %}
+
+    {# output will be <div><strong>foo</strong></div> #}
+
+This tag is not meant to "optimize" the size of the generated HTML content but
+merely to avoid extra whitespace between HTML tags to avoid browser rendering
+quirks under some circumstances.
+
+.. caution::
+
+    As the filter uses a regular expression behind the scenes, its performance
+    is directly related to the text size you are working on (remember that
+    filters are executed at runtime).
+
+.. tip::
+
+    If you want to optimize the size of the generated HTML content, gzip
+    compress the output instead.
+
+.. tip::
+
+    If you want to create a tag that actually removes all extra whitespace in
+    an HTML string, be warned that this is not as easy as it seems to be
+    (think of ``textarea`` or ``pre`` tags for instance). Using a third-party
+    library like Tidy is probably a better idea.
+
+.. tip::
+
+    For more information on whitespace control, read the
+    :ref:`dedicated section <templates-whitespace-control>` of the documentation and learn how
+    you can also use the whitespace control modifier on your tags.
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/split.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/split.rst
new file mode 100644
index 0000000..38c4b7d
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/split.rst
@@ -0,0 +1,50 @@
+``split``
+=========
+
+The ``split`` filter splits a string by the given delimiter and returns a list
+of strings:
+
+.. code-block:: twig
+
+    {% set foo = "one,two,three"|split(',') %}
+    {# foo contains ['one', 'two', 'three'] #}
+
+You can also pass a ``limit`` argument:
+
+* If ``limit`` is positive, the returned array will contain a maximum of
+  limit elements with the last element containing the rest of string;
+
+* If ``limit`` is negative, all components except the last -limit are
+  returned;
+
+* If ``limit`` is zero, then this is treated as 1.
+
+.. code-block:: twig
+
+    {% set foo = "one,two,three,four,five"|split(',', 3) %}
+    {# foo contains ['one', 'two', 'three,four,five'] #}
+
+If the ``delimiter`` is an empty string, then value will be split by equal
+chunks. Length is set by the ``limit`` argument (one character by default).
+
+.. code-block:: twig
+
+    {% set foo = "123"|split('') %}
+    {# foo contains ['1', '2', '3'] #}
+
+    {% set bar = "aabbcc"|split('', 2) %}
+    {# bar contains ['aa', 'bb', 'cc'] #}
+
+.. note::
+
+    Internally, Twig uses the PHP `explode`_ or `str_split`_ (if delimiter is
+    empty) functions for string splitting.
+
+Arguments
+---------
+
+* ``delimiter``: The delimiter
+* ``limit``:     The limit argument
+
+.. _`explode`:   https://secure.php.net/explode
+.. _`str_split`: https://secure.php.net/str_split
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/striptags.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/striptags.rst
new file mode 100644
index 0000000..7a0aabd
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/striptags.rst
@@ -0,0 +1,29 @@
+``striptags``
+=============
+
+The ``striptags`` filter strips SGML/XML tags and replace adjacent whitespace
+by one space:
+
+.. code-block:: twig
+
+    {{ some_html|striptags }}
+
+You can also provide tags which should not be stripped:
+
+.. code-block:: html+twig
+
+    {{ some_html|striptags('<br><p>') }}
+
+In this example, the ``<br/>``, ``<br>``, ``<p>``, and ``</p>`` tags won't be
+removed from the string.
+
+.. note::
+
+    Internally, Twig uses the PHP `strip_tags`_ function.
+
+Arguments
+---------
+
+* ``allowable_tags``: Tags which should not be stripped
+
+.. _`strip_tags`: https://secure.php.net/strip_tags
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/timezone_name.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/timezone_name.rst
new file mode 100644
index 0000000..dfb2281
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/timezone_name.rst
@@ -0,0 +1,46 @@
+``timezone_name``
+=================
+
+The ``timezone_name`` filter returns the timezone name given a timezone identifier:
+
+.. code-block:: twig
+
+    {# Central European Time (Paris) #}
+    {{ 'Europe/Paris'|timezone_name }}
+
+    {# Pacific Time (Los Angeles) #}
+    {{ 'America/Los_Angeles'|timezone_name }}
+
+By default, the filter uses the current locale. You can pass it explicitly:
+
+.. code-block:: twig
+
+    {# heure du Pacifique nord-américain (Los Angeles) #}
+    {{ 'America/Los_Angeles'|timezone_name('fr') }}
+
+.. note::
+
+    The ``timezone_name`` filter is part of the ``IntlExtension`` which is not
+    installed by default. Install it first:
+
+    .. code-block:: bash
+
+        $ composer require twig/intl-extra
+
+    Then, on Symfony projects, install the ``twig/extra-bundle``:
+
+    .. code-block:: bash
+
+        $ composer require twig/extra-bundle
+
+    Otherwise, add the extension explicitly on the Twig environment::
+
+        use Twig\Extra\Intl\IntlExtension;
+
+        $twig = new \Twig\Environment(...);
+        $twig->addExtension(new IntlExtension());
+
+Arguments
+---------
+
+* ``locale``: The locale
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/title.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/title.rst
new file mode 100644
index 0000000..dd0311c
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/title.rst
@@ -0,0 +1,11 @@
+``title``
+=========
+
+The ``title`` filter returns a titlecased version of the value. Words will
+start with uppercase letters, all remaining characters are lowercase:
+
+.. code-block:: twig
+
+    {{ 'my first car'|title }}
+
+    {# outputs 'My First Car' #}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/trim.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/trim.rst
new file mode 100644
index 0000000..81d5e04
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/trim.rst
@@ -0,0 +1,39 @@
+``trim``
+========
+
+The ``trim`` filter strips whitespace (or other characters) from the beginning
+and end of a string:
+
+.. code-block:: twig
+
+    {{ '  I like Twig.  '|trim }}
+
+    {# outputs 'I like Twig.' #}
+
+    {{ '  I like Twig.'|trim('.') }}
+
+    {# outputs '  I like Twig' #}
+
+    {{ '  I like Twig.  '|trim(side='left') }}
+
+    {# outputs 'I like Twig.  ' #}
+
+    {{ '  I like Twig.  '|trim(' ', 'right') }}
+
+    {# outputs '  I like Twig.' #}
+
+.. note::
+
+    Internally, Twig uses the PHP `trim`_, `ltrim`_, and `rtrim`_ functions.
+
+Arguments
+---------
+
+* ``character_mask``: The characters to strip
+
+* ``side``: The default is to strip from the left and the right (`both`) sides, but `left`
+  and `right` will strip from either the left side or right side only
+
+.. _`trim`: https://secure.php.net/trim
+.. _`ltrim`: https://secure.php.net/ltrim
+.. _`rtrim`: https://secure.php.net/rtrim
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/u.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/u.rst
new file mode 100644
index 0000000..20bb0d5
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/u.rst
@@ -0,0 +1,87 @@
+``u``
+=====
+
+The ``u`` filter wraps a text in a Unicode object (a `Symfony UnicodeString
+instance <https://symfony.com/doc/current/components/string.html>`_) that
+exposes methods to "manipulate" the string.
+
+Let's see some common use cases.
+
+Wrapping a text to a given number of characters:
+
+.. code-block:: twig
+
+    {{ 'Symfony String + Twig = <3'|u.wordwrap(5) }}
+    Symfony
+    String
+    +
+    Twig
+    = <3
+
+Truncating a string:
+
+.. code-block:: twig
+
+    {{ 'Lorem ipsum'|u.truncate(8) }}
+    Lorem ip
+
+    {{ 'Lorem ipsum'|u.truncate(8, '...') }}
+    Lorem...
+
+The ``truncate`` method also accepts a third argument to preserve whole words:
+
+.. code-block:: twig
+
+    {{ 'Lorem ipsum dolor'|u.truncate(10, '...', false) }}
+    Lorem ipsum...
+
+Converting a string to *snake* case or *camelCase*:
+
+.. code-block:: twig
+
+    {{ 'SymfonyStringWithTwig'|u.snake }}
+    symfony_string_with_twig
+
+    {{ 'symfony_string with twig'|u.camel.title }}
+    SymfonyStringWithTwig
+
+You can also chain methods:
+
+.. code-block:: twig
+
+    {{ 'Symfony String + Twig = <3'|u.wordwrap(5).upper }}
+    SYMFONY
+    STRING
+    +
+    TWIG
+    = <3
+
+For large strings manipulation, use the ``apply`` tag:
+
+.. code-block:: twig
+
+    {% apply u.wordwrap(5) %}
+        Some large amount of text...
+    {% endapply %}
+
+.. note::
+
+    The ``u`` filter is part of the ``StringExtension`` which is not installed
+    by default. Install it first:
+
+    .. code-block:: bash
+
+        $ composer require twig/string-extra
+
+    Then, on Symfony projects, install the ``twig/extra-bundle``:
+
+    .. code-block:: bash
+
+        $ composer require twig/extra-bundle
+
+    Otherwise, add the extension explicitly on the Twig environment::
+
+        use Twig\Extra\String\StringExtension;
+
+        $twig = new \Twig\Environment(...);
+        $twig->addExtension(new StringExtension());
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/upper.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/upper.rst
new file mode 100644
index 0000000..01c9fbb
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/upper.rst
@@ -0,0 +1,10 @@
+``upper``
+=========
+
+The ``upper`` filter converts a value to uppercase:
+
+.. code-block:: twig
+
+    {{ 'welcome'|upper }}
+
+    {# outputs 'WELCOME' #}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/url_encode.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/url_encode.rst
new file mode 100644
index 0000000..60cf365
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/filters/url_encode.rst
@@ -0,0 +1,23 @@
+``url_encode``
+==============
+
+The ``url_encode`` filter percent encodes a given string as URL segment
+or an array as query string:
+
+.. code-block:: twig
+
+    {{ "path-seg*ment"|url_encode }}
+    {# outputs "path-seg%2Ament" #}
+
+    {{ "string with spaces"|url_encode }}
+    {# outputs "string%20with%20spaces" #}
+
+    {{ {'param': 'value', 'foo': 'bar'}|url_encode }}
+    {# outputs "param=value&foo=bar" #}
+
+.. note::
+
+    Internally, Twig uses the PHP `rawurlencode`_ or the `http_build_query`_ function.
+
+.. _`rawurlencode`: https://secure.php.net/rawurlencode
+.. _`http_build_query`: https://secure.php.net/http_build_query
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/attribute.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/attribute.rst
new file mode 100644
index 0000000..e9d9a84
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/attribute.rst
@@ -0,0 +1,23 @@
+``attribute``
+=============
+
+The ``attribute`` function can be used to access a "dynamic" attribute of a
+variable:
+
+.. code-block:: twig
+
+    {{ attribute(object, method) }}
+    {{ attribute(object, method, arguments) }}
+    {{ attribute(array, item) }}
+
+In addition, the ``defined`` test can check for the existence of a dynamic
+attribute:
+
+.. code-block:: twig
+
+    {{ attribute(object, method) is defined ? 'Method exists' : 'Method does not exist' }}
+
+.. note::
+
+    The resolution algorithm is the same as the one used for the ``.``
+    notation, except that the item can be any valid expression.
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/block.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/block.rst
new file mode 100644
index 0000000..117e160
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/block.rst
@@ -0,0 +1,37 @@
+``block``
+=========
+
+When a template uses inheritance and if you want to print a block multiple
+times, use the ``block`` function:
+
+.. code-block:: html+twig
+
+    <title>{% block title %}{% endblock %}</title>
+
+    <h1>{{ block('title') }}</h1>
+
+    {% block body %}{% endblock %}
+
+The ``block`` function can also be used to display one block from another
+template:
+
+.. code-block:: twig
+
+    {{ block("title", "common_blocks.twig") }}
+
+Use the ``defined`` test to check if a block exists in the context of the
+current template:
+
+.. code-block:: twig
+
+    {% if block("footer") is defined %}
+        ...
+    {% endif %}
+
+    {% if block("footer", "common_blocks.twig") is defined %}
+        ...
+    {% endif %}
+
+.. seealso::
+
+    :doc:`extends<../tags/extends>`, :doc:`parent<../functions/parent>`
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/constant.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/constant.rst
new file mode 100644
index 0000000..660bf87
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/constant.rst
@@ -0,0 +1,23 @@
+``constant``
+============
+
+``constant`` returns the constant value for a given string:
+
+.. code-block:: twig
+
+    {{ some_date|date(constant('DATE_W3C')) }}
+    {{ constant('Namespace\\Classname::CONSTANT_NAME') }}
+
+You can read constants from object instances as well:
+
+.. code-block:: twig
+
+    {{ constant('RSS', date) }}
+
+Use the ``defined`` test to check if a constant is defined:
+
+.. code-block:: twig
+
+    {% if constant('SOME_CONST') is defined %}
+        ...
+    {% endif %}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/country_timezones.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/country_timezones.rst
new file mode 100644
index 0000000..ecbbc1c
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/country_timezones.rst
@@ -0,0 +1,32 @@
+``country_timezones``
+=====================
+
+The ``country_timezones`` function returns the names of the timezones associated
+with a given country code:
+
+.. code-block:: twig
+
+    {# Europe/Paris #}
+    {{ country_timezones('FR')|join(', ') }}
+
+.. note::
+
+    The ``country_timezones`` function is part of the ``IntlExtension`` which is not
+    installed by default. Install it first:
+
+    .. code-block:: bash
+
+        $ composer require twig/intl-extra
+
+    Then, on Symfony projects, install the ``twig/extra-bundle``:
+
+    .. code-block:: bash
+
+        $ composer require twig/extra-bundle
+
+    Otherwise, add the extension explicitly on the Twig environment::
+
+        use Twig\Extra\Intl\IntlExtension;
+
+        $twig = new \Twig\Environment(...);
+        $twig->addExtension(new IntlExtension());
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/cycle.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/cycle.rst
new file mode 100644
index 0000000..84cff6a
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/cycle.rst
@@ -0,0 +1,28 @@
+``cycle``
+=========
+
+The ``cycle`` function cycles on an array of values:
+
+.. code-block:: twig
+
+    {% set start_year = date() | date('Y') %}
+    {% set end_year = start_year + 5 %}
+
+    {% for year in start_year..end_year %}
+        {{ cycle(['odd', 'even'], loop.index0) }}
+    {% endfor %}
+
+The array can contain any number of values:
+
+.. code-block:: twig
+
+    {% set fruits = ['apple', 'orange', 'citrus'] %}
+
+    {% for i in 0..10 %}
+        {{ cycle(fruits, i) }}
+    {% endfor %}
+
+Arguments
+---------
+
+* ``position``: The cycle position
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/date.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/date.rst
new file mode 100644
index 0000000..3329a56
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/date.rst
@@ -0,0 +1,44 @@
+``date``
+========
+
+Converts an argument to a date to allow date comparison:
+
+.. code-block:: html+twig
+
+    {% if date(user.created_at) < date('-2days') %}
+        {# do something #}
+    {% endif %}
+
+The argument must be in one of PHP’s supported `date and time formats`_.
+
+You can pass a timezone as the second argument:
+
+.. code-block:: html+twig
+
+    {% if date(user.created_at) < date('-2days', 'Europe/Paris') %}
+        {# do something #}
+    {% endif %}
+
+If no argument is passed, the function returns the current date:
+
+.. code-block:: html+twig
+
+    {% if date(user.created_at) < date() %}
+        {# always! #}
+    {% endif %}
+
+.. note::
+
+    You can set the default timezone globally by calling ``setTimezone()`` on
+    the ``core`` extension instance::
+
+        $twig = new \Twig\Environment($loader);
+        $twig->getExtension(\Twig\Extension\CoreExtension::class)->setTimezone('Europe/Paris');
+
+Arguments
+---------
+
+* ``date``:     The date
+* ``timezone``: The timezone
+
+.. _`date and time formats`: https://secure.php.net/manual/en/datetime.formats.php
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/dump.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/dump.rst
new file mode 100644
index 0000000..c7264ed
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/dump.rst
@@ -0,0 +1,66 @@
+``dump``
+========
+
+The ``dump`` function dumps information about a template variable. This is
+mostly useful to debug a template that does not behave as expected by
+introspecting its variables:
+
+.. code-block:: twig
+
+    {{ dump(user) }}
+
+.. note::
+
+    The ``dump`` function is not available by default. You must add the
+    ``\Twig\Extension\DebugExtension`` extension explicitly when creating your Twig
+    environment::
+
+        $twig = new \Twig\Environment($loader, [
+            'debug' => true,
+            // ...
+        ]);
+        $twig->addExtension(new \Twig\Extension\DebugExtension());
+
+    Even when enabled, the ``dump`` function won't display anything if the
+    ``debug`` option on the environment is not enabled (to avoid leaking debug
+    information on a production server).
+
+In an HTML context, wrap the output with a ``pre`` tag to make it easier to
+read:
+
+.. code-block:: html+twig
+
+    <pre>
+        {{ dump(user) }}
+    </pre>
+
+.. tip::
+
+    Using a ``pre`` tag is not needed when `XDebug`_ is enabled and
+    ``html_errors`` is ``on``; as a bonus, the output is also nicer with
+    XDebug enabled.
+
+You can debug several variables by passing them as additional arguments:
+
+.. code-block:: twig
+
+    {{ dump(user, categories) }}
+
+If you don't pass any value, all variables from the current context are
+dumped:
+
+.. code-block:: twig
+
+    {{ dump() }}
+
+.. note::
+
+    Internally, Twig uses the PHP `var_dump`_ function.
+
+Arguments
+---------
+
+* ``context``: The context to dump
+
+.. _`XDebug`:   https://xdebug.org/docs/display
+.. _`var_dump`: https://secure.php.net/var_dump
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/html_classes.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/html_classes.rst
new file mode 100644
index 0000000..80bc796
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/html_classes.rst
@@ -0,0 +1,35 @@
+``html_classes``
+================
+
+The ``html_classes`` function returns a string by conditionally joining class
+names together:
+
+.. code-block:: html+twig
+
+    <p class="{{ html_classes('a-class', 'another-class', {
+        'errored': object.errored,
+        'finished': object.finished,
+        'pending': object.pending,
+    }) }}">How are you doing?</p>
+
+.. note::
+
+    The ``html_classes`` function is part of the ``HtmlExtension`` which is not
+    installed by default. Install it first:
+
+    .. code-block:: bash
+
+        $ composer require twig/html-extra
+
+    Then, on Symfony projects, install the ``twig/extra-bundle``:
+
+    .. code-block:: bash
+
+        $ composer require twig/extra-bundle
+
+    Otherwise, add the extension explicitly on the Twig environment::
+
+        use Twig\Extra\Html\HtmlExtension;
+
+        $twig = new \Twig\Environment(...);
+        $twig->addExtension(new HtmlExtension());
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/include.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/include.rst
new file mode 100644
index 0000000..f49971a
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/include.rst
@@ -0,0 +1,77 @@
+``include``
+===========
+
+The ``include`` function returns the rendered content of a template:
+
+.. code-block:: twig
+
+    {{ include('template.html') }}
+    {{ include(some_var) }}
+
+Included templates have access to the variables of the active context.
+
+If you are using the filesystem loader, the templates are looked for in the
+paths defined by it.
+
+The context is passed by default to the template but you can also pass
+additional variables:
+
+.. code-block:: twig
+
+    {# template.html will have access to the variables from the current context and the additional ones provided #}
+    {{ include('template.html', {foo: 'bar'}) }}
+
+You can disable access to the context by setting ``with_context`` to
+``false``:
+
+.. code-block:: twig
+
+    {# only the foo variable will be accessible #}
+    {{ include('template.html', {foo: 'bar'}, with_context = false) }}
+
+.. code-block:: twig
+
+    {# no variables will be accessible #}
+    {{ include('template.html', with_context = false) }}
+
+And if the expression evaluates to a ``\Twig\Template`` or a
+``\Twig\TemplateWrapper`` instance, Twig will use it directly::
+
+    // {{ include(template) }}
+
+    $template = $twig->load('some_template.twig');
+
+    $twig->display('template.twig', ['template' => $template]);
+
+When you set the ``ignore_missing`` flag, Twig will return an empty string if
+the template does not exist:
+
+.. code-block:: twig
+
+    {{ include('sidebar.html', ignore_missing = true) }}
+
+You can also provide a list of templates that are checked for existence before
+inclusion. The first template that exists will be rendered:
+
+.. code-block:: twig
+
+    {{ include(['page_detailed.html', 'page.html']) }}
+
+If ``ignore_missing`` is set, it will fall back to rendering nothing if none
+of the templates exist, otherwise it will throw an exception.
+
+When including a template created by an end user, you should consider
+sandboxing it:
+
+.. code-block:: twig
+
+    {{ include('page.html', sandboxed = true) }}
+
+Arguments
+---------
+
+* ``template``:       The template to render
+* ``variables``:      The variables to pass to the template
+* ``with_context``:   Whether to pass the current context variables or not
+* ``ignore_missing``: Whether to ignore missing templates or not
+* ``sandboxed``:      Whether to sandbox the template or not
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/index.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/index.rst
new file mode 100644
index 0000000..97465ed
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/index.rst
@@ -0,0 +1,22 @@
+Functions
+=========
+
+.. toctree::
+    :maxdepth: 1
+
+    attribute
+    block
+    constant
+    cycle
+    date
+    dump
+    html_classes
+    include
+    max
+    min
+    parent
+    random
+    range
+    source
+    country_timezones
+    template_from_string
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/max.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/max.rst
new file mode 100644
index 0000000..230b3c8
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/max.rst
@@ -0,0 +1,17 @@
+``max``
+=======
+
+``max`` returns the biggest value of a sequence or a set of values:
+
+.. code-block:: twig
+
+    {{ max(1, 3, 2) }}
+    {{ max([1, 3, 2]) }}
+
+When called with a mapping, max ignores keys and only compares values:
+
+.. code-block:: twig
+
+    {{ max({2: "e", 1: "a", 3: "b", 5: "d", 4: "c"}) }}
+    {# returns "e" #}
+
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/min.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/min.rst
new file mode 100644
index 0000000..6531858
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/min.rst
@@ -0,0 +1,17 @@
+``min``
+=======
+
+``min`` returns the lowest value of a sequence or a set of values:
+
+.. code-block:: twig
+
+    {{ min(1, 3, 2) }}
+    {{ min([1, 3, 2]) }}
+
+When called with a mapping, min ignores keys and only compares values:
+
+.. code-block:: twig
+
+    {{ min({2: "e", 3: "a", 1: "b", 5: "d", 4: "c"}) }}
+    {# returns "a" #}
+
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/parent.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/parent.rst
new file mode 100644
index 0000000..158bac7
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/parent.rst
@@ -0,0 +1,22 @@
+``parent``
+==========
+
+When a template uses inheritance, it's possible to render the contents of the
+parent block when overriding a block by using the ``parent`` function:
+
+.. code-block:: html+twig
+
+    {% extends "base.html" %}
+
+    {% block sidebar %}
+        <h3>Table Of Contents</h3>
+        ...
+        {{ parent() }}
+    {% endblock %}
+
+The ``parent()`` call will return the content of the ``sidebar`` block as
+defined in the ``base.html`` template.
+
+.. seealso::
+
+    :doc:`extends<../tags/extends>`, :doc:`block<../functions/block>`, :doc:`block<../tags/block>`
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/random.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/random.rst
new file mode 100644
index 0000000..aac2986
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/random.rst
@@ -0,0 +1,25 @@
+``random``
+==========
+
+The ``random`` function returns a random value depending on the supplied
+parameter type:
+
+* a random item from a sequence;
+* a random character from a string;
+* a random integer between 0 and the integer parameter (inclusive).
+* a random integer between the integer parameter (when negative) and 0 (inclusive).
+* a random integer between the first integer and the second integer parameter (inclusive).
+
+.. code-block:: twig
+
+    {{ random(['apple', 'orange', 'citrus']) }} {# example output: orange #}
+    {{ random('ABC') }}                         {# example output: C #}
+    {{ random() }}                              {# example output: 15386094 (works as the native PHP mt_rand function) #}
+    {{ random(5) }}                             {# example output: 3 #}
+    {{ random(50, 100) }}                       {# example output: 63 #}
+
+Arguments
+---------
+
+* ``values``: The values
+* ``max``: The max value when values is an integer
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/range.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/range.rst
new file mode 100644
index 0000000..a1f0e7c
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/range.rst
@@ -0,0 +1,58 @@
+``range``
+=========
+
+Returns a list containing an arithmetic progression of integers:
+
+.. code-block:: twig
+
+    {% for i in range(0, 3) %}
+        {{ i }},
+    {% endfor %}
+
+    {# outputs 0, 1, 2, 3, #}
+
+When step is given (as the third parameter), it specifies the increment (or
+decrement for negative values):
+
+.. code-block:: twig
+
+    {% for i in range(0, 6, 2) %}
+        {{ i }},
+    {% endfor %}
+
+    {# outputs 0, 2, 4, 6, #}
+
+.. note::
+
+    Note that if the start is greater than the end, ``range`` assumes a step of
+    ``-1``:
+
+    .. code-block:: twig
+
+        {% for i in range(3, 0) %}
+            {{ i }},
+        {% endfor %}
+
+        {# outputs 3, 2, 1, 0, #}
+
+The Twig built-in ``..`` operator is just syntactic sugar for the ``range``
+function (with a step of ``1``, or ``-1`` if the start is greater than the end):
+
+.. code-block:: twig
+
+    {% for i in 0..3 %}
+        {{ i }},
+    {% endfor %}
+
+.. tip::
+
+    The ``range`` function works as the native PHP `range`_ function.
+
+Arguments
+---------
+
+* ``low``:  The first value of the sequence.
+* ``high``: The highest possible value of the sequence.
+* ``step``: The increment between elements of the sequence.
+
+.. _`range`: https://secure.php.net/range
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/source.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/source.rst
new file mode 100644
index 0000000..080e2be
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/source.rst
@@ -0,0 +1,26 @@
+``source``
+==========
+
+The ``source`` function returns the content of a template without rendering it:
+
+.. code-block:: twig
+
+    {{ source('template.html') }}
+    {{ source(some_var) }}
+
+When you set the ``ignore_missing`` flag, Twig will return an empty string if
+the template does not exist:
+
+.. code-block:: twig
+
+    {{ source('template.html', ignore_missing = true) }}
+
+The function uses the same template loaders as the ones used to include
+templates. So, if you are using the filesystem loader, the templates are looked
+for in the paths defined by it.
+
+Arguments
+---------
+
+* ``name``: The name of the template to read
+* ``ignore_missing``: Whether to ignore missing templates or not
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/template_from_string.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/template_from_string.rst
new file mode 100644
index 0000000..80e9d2d
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/functions/template_from_string.rst
@@ -0,0 +1,37 @@
+``template_from_string``
+========================
+
+The ``template_from_string`` function loads a template from a string:
+
+.. code-block:: twig
+
+    {{ include(template_from_string("Hello {{ name }}")) }}
+    {{ include(template_from_string(page.template)) }}
+
+To ease debugging, you can also give the template a name that will be part of
+any related error message:
+
+.. code-block:: twig
+
+    {{ include(template_from_string(page.template, "template for page " ~ page.name)) }}
+
+.. note::
+
+    The ``template_from_string`` function is not available by default. You
+    must add the ``\Twig\Extension\StringLoaderExtension`` extension explicitly when
+    creating your Twig environment::
+
+        $twig = new \Twig\Environment(...);
+        $twig->addExtension(new \Twig\Extension\StringLoaderExtension());
+
+.. note::
+
+    Even if you will probably always use the ``template_from_string`` function
+    with the ``include`` function, you can use it with any tag or function that
+    takes a template as an argument (like the ``embed`` or ``extends`` tags).
+
+Arguments
+---------
+
+* ``template``: The template
+* ``name``: A name for the template
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/index.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/index.rst
new file mode 100644
index 0000000..358bd73
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/index.rst
@@ -0,0 +1,19 @@
+Twig
+====
+
+.. toctree::
+    :maxdepth: 2
+
+    intro
+    installation
+    templates
+    api
+    advanced
+    internals
+    deprecated
+    recipes
+    coding_standards
+    tags/index
+    filters/index
+    functions/index
+    tests/index
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/installation.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/installation.rst
new file mode 100644
index 0000000..5fd5650
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/installation.rst
@@ -0,0 +1,10 @@
+Installation
+============
+
+Install `Composer`_ and run the following command to get the latest version:
+
+.. code-block:: bash
+
+    composer require "twig/twig:^3.0"
+
+.. _`Composer`: https://getcomposer.org/download/
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/internals.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/internals.rst
new file mode 100644
index 0000000..0421e7c
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/internals.rst
@@ -0,0 +1,140 @@
+Twig Internals
+==============
+
+Twig is very extensible and you can hack it. Keep in mind that you
+should probably try to create an extension before hacking the core, as most
+features and enhancements can be handled with extensions. This chapter is also
+useful for people who want to understand how Twig works under the hood.
+
+How does Twig work?
+-------------------
+
+The rendering of a Twig template can be summarized into four key steps:
+
+* **Load** the template: If the template is already compiled, load it and go
+  to the *evaluation* step, otherwise:
+
+  * First, the **lexer** tokenizes the template source code into small pieces
+    for easier processing;
+
+  * Then, the **parser** converts the token stream into a meaningful tree
+    of nodes (the Abstract Syntax Tree);
+
+  * Finally, the *compiler* transforms the AST into PHP code.
+
+* **Evaluate** the template: It means calling the ``display()``
+  method of the compiled template and passing it the context.
+
+The Lexer
+---------
+
+The lexer tokenizes a template source code into a token stream (each token is
+an instance of ``\Twig\Token``, and the stream is an instance of
+``\Twig\TokenStream``). The default lexer recognizes 13 different token types:
+
+* ``\Twig\Token::BLOCK_START_TYPE``, ``\Twig\Token::BLOCK_END_TYPE``: Delimiters for blocks (``{% %}``)
+* ``\Twig\Token::VAR_START_TYPE``, ``\Twig\Token::VAR_END_TYPE``: Delimiters for variables (``{{ }}``)
+* ``\Twig\Token::TEXT_TYPE``: A text outside an expression;
+* ``\Twig\Token::NAME_TYPE``: A name in an expression;
+* ``\Twig\Token::NUMBER_TYPE``: A number in an expression;
+* ``\Twig\Token::STRING_TYPE``: A string in an expression;
+* ``\Twig\Token::OPERATOR_TYPE``: An operator;
+* ``\Twig\Token::PUNCTUATION_TYPE``: A punctuation sign;
+* ``\Twig\Token::INTERPOLATION_START_TYPE``, ``\Twig\Token::INTERPOLATION_END_TYPE``: Delimiters for string interpolation;
+* ``\Twig\Token::EOF_TYPE``: Ends of template.
+
+You can manually convert a source code into a token stream by calling the
+``tokenize()`` method of an environment::
+
+    $stream = $twig->tokenize(new \Twig\Source($source, $identifier));
+
+As the stream has a ``__toString()`` method, you can have a textual
+representation of it by echoing the object::
+
+    echo $stream."\n";
+
+Here is the output for the ``Hello {{ name }}`` template:
+
+.. code-block:: text
+
+    TEXT_TYPE(Hello )
+    VAR_START_TYPE()
+    NAME_TYPE(name)
+    VAR_END_TYPE()
+    EOF_TYPE()
+
+.. note::
+
+    The default lexer (``\Twig\Lexer``) can be changed by calling
+    the ``setLexer()`` method::
+
+        $twig->setLexer($lexer);
+
+The Parser
+----------
+
+The parser converts the token stream into an AST (Abstract Syntax Tree), or a
+node tree (an instance of ``\Twig\Node\ModuleNode``). The core extension defines
+the basic nodes like: ``for``, ``if``, ... and the expression nodes.
+
+You can manually convert a token stream into a node tree by calling the
+``parse()`` method of an environment::
+
+    $nodes = $twig->parse($stream);
+
+Echoing the node object gives you a nice representation of the tree::
+
+    echo $nodes."\n";
+
+Here is the output for the ``Hello {{ name }}`` template:
+
+.. code-block:: text
+
+    \Twig\Node\ModuleNode(
+      \Twig\Node\TextNode(Hello )
+      \Twig\Node\PrintNode(
+        \Twig\Node\Expression\NameExpression(name)
+      )
+    )
+
+.. note::
+
+    The default parser (``\Twig\TokenParser\AbstractTokenParser``) can be changed by calling the
+    ``setParser()`` method::
+
+        $twig->setParser($parser);
+
+The Compiler
+------------
+
+The last step is done by the compiler. It takes a node tree as an input and
+generates PHP code usable for runtime execution of the template.
+
+You can manually compile a node tree to PHP code with the ``compile()`` method
+of an environment::
+
+    $php = $twig->compile($nodes);
+
+The generated template for a ``Hello {{ name }}`` template reads as follows
+(the actual output can differ depending on the version of Twig you are
+using)::
+
+    /* Hello {{ name }} */
+    class __TwigTemplate_1121b6f109fe93ebe8c6e22e3712bceb extends Template
+    {
+        protected function doDisplay(array $context, array $blocks = [])
+        {
+            // line 1
+            echo "Hello ";
+            echo twig_escape_filter($this->env, (isset($context["name"]) ? $context["name"] : null), "html", null, true);
+        }
+
+        // some more code
+    }
+
+.. note::
+
+    The default compiler (``\Twig\Compiler``) can be changed by calling the
+    ``setCompiler()`` method::
+
+        $twig->setCompiler($compiler);
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/intro.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/intro.rst
new file mode 100644
index 0000000..8914507
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/intro.rst
@@ -0,0 +1,74 @@
+Introduction
+============
+
+Welcome to the documentation for Twig, the flexible, fast, and secure template
+engine for PHP.
+
+Twig is both designer and developer friendly by sticking to PHP's principles and
+adding functionality useful for templating environments.
+
+The key-features are...
+
+* *Fast*: Twig compiles templates down to plain optimized PHP code. The
+  overhead compared to regular PHP code was reduced to the very minimum.
+
+* *Secure*: Twig has a sandbox mode to evaluate untrusted template code. This
+  allows Twig to be used as a template language for applications where users
+  may modify the template design.
+
+* *Flexible*: Twig is powered by a flexible lexer and parser. This allows the
+  developer to define their own custom tags and filters, and to create their own DSL.
+
+Twig is used by many Open-Source projects like Symfony, Drupal8, eZPublish,
+phpBB, Matomo, OroCRM; and many frameworks have support for it as well like
+Slim, Yii, Laravel, and Codeigniter — just to name a few.
+
+.. admonition:: Screencast
+
+    Like to learn from video tutorials? Check out the `SymfonyCasts Twig Tutorial`_!
+
+Prerequisites
+-------------
+
+Twig 3.x needs at least **PHP 7.2.5** to run.
+
+Installation
+------------
+
+The recommended way to install Twig is via Composer:
+
+.. code-block:: bash
+
+    composer require "twig/twig:^3.0"
+
+Basic API Usage
+---------------
+
+This section gives you a brief introduction to the PHP API for Twig::
+
+    require_once '/path/to/vendor/autoload.php';
+
+    $loader = new \Twig\Loader\ArrayLoader([
+        'index' => 'Hello {{ name }}!',
+    ]);
+    $twig = new \Twig\Environment($loader);
+
+    echo $twig->render('index', ['name' => 'Fabien']);
+
+Twig uses a loader (``\Twig\Loader\ArrayLoader``) to locate templates, and an
+environment (``\Twig\Environment``) to store its configuration.
+
+The ``render()`` method loads the template passed as a first argument and
+renders it with the variables passed as a second argument.
+
+As templates are generally stored on the filesystem, Twig also comes with a
+filesystem loader::
+
+    $loader = new \Twig\Loader\FilesystemLoader('/path/to/templates');
+    $twig = new \Twig\Environment($loader, [
+        'cache' => '/path/to/compilation_cache',
+    ]);
+
+    echo $twig->render('index.html', ['name' => 'Fabien']);
+
+.. _`SymfonyCasts Twig Tutorial`: https://symfonycasts.com/screencast/twig
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/recipes.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/recipes.rst
new file mode 100644
index 0000000..01c937d
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/recipes.rst
@@ -0,0 +1,531 @@
+Recipes
+=======
+
+.. _deprecation-notices:
+
+Displaying Deprecation Notices
+------------------------------
+
+Deprecated features generate deprecation notices (via a call to the
+``trigger_error()`` PHP function). By default, they are silenced and never
+displayed nor logged.
+
+To remove all deprecated feature usages from your templates, write and run a
+script along the lines of the following::
+
+    require_once __DIR__.'/vendor/autoload.php';
+
+    $twig = create_your_twig_env();
+
+    $deprecations = new \Twig\Util\DeprecationCollector($twig);
+
+    print_r($deprecations->collectDir(__DIR__.'/templates'));
+
+The ``collectDir()`` method compiles all templates found in a directory,
+catches deprecation notices, and return them.
+
+.. tip::
+
+    If your templates are not stored on the filesystem, use the ``collect()``
+    method instead. ``collect()`` takes a ``Traversable`` which must return
+    template names as keys and template contents as values (as done by
+    ``\Twig\Util\TemplateDirIterator``).
+
+However, this code won't find all deprecations (like using deprecated some Twig
+classes). To catch all notices, register a custom error handler like the one
+below::
+
+    $deprecations = [];
+    set_error_handler(function ($type, $msg) use (&$deprecations) {
+        if (E_USER_DEPRECATED === $type) {
+            $deprecations[] = $msg;
+        }
+    });
+
+    // run your application
+
+    print_r($deprecations);
+
+Note that most deprecation notices are triggered during **compilation**, so
+they won't be generated when templates are already cached.
+
+.. tip::
+
+    If you want to manage the deprecation notices from your PHPUnit tests, have
+    a look at the `symfony/phpunit-bridge
+    <https://github.com/symfony/phpunit-bridge>`_ package, which eases the
+    process.
+
+Making a Layout conditional
+---------------------------
+
+Working with Ajax means that the same content is sometimes displayed as is,
+and sometimes decorated with a layout. As Twig layout template names can be
+any valid expression, you can pass a variable that evaluates to ``true`` when
+the request is made via Ajax and choose the layout accordingly:
+
+.. code-block:: twig
+
+    {% extends request.ajax ? "base_ajax.html" : "base.html" %}
+
+    {% block content %}
+        This is the content to be displayed.
+    {% endblock %}
+
+Making an Include dynamic
+-------------------------
+
+When including a template, its name does not need to be a string. For
+instance, the name can depend on the value of a variable:
+
+.. code-block:: twig
+
+    {% include var ~ '_foo.html' %}
+
+If ``var`` evaluates to ``index``, the ``index_foo.html`` template will be
+rendered.
+
+As a matter of fact, the template name can be any valid expression, such as
+the following:
+
+.. code-block:: twig
+
+    {% include var|default('index') ~ '_foo.html' %}
+
+Overriding a Template that also extends itself
+----------------------------------------------
+
+A template can be customized in two different ways:
+
+* *Inheritance*: A template *extends* a parent template and overrides some
+  blocks;
+
+* *Replacement*: If you use the filesystem loader, Twig loads the first
+  template it finds in a list of configured directories; a template found in a
+  directory *replaces* another one from a directory further in the list.
+
+But how do you combine both: *replace* a template that also extends itself
+(aka a template in a directory further in the list)?
+
+Let's say that your templates are loaded from both ``.../templates/mysite``
+and ``.../templates/default`` in this order. The ``page.twig`` template,
+stored in ``.../templates/default`` reads as follows:
+
+.. code-block:: twig
+
+    {# page.twig #}
+    {% extends "layout.twig" %}
+
+    {% block content %}
+    {% endblock %}
+
+You can replace this template by putting a file with the same name in
+``.../templates/mysite``. And if you want to extend the original template, you
+might be tempted to write the following:
+
+.. code-block:: twig
+
+    {# page.twig in .../templates/mysite #}
+    {% extends "page.twig" %} {# from .../templates/default #}
+
+However, this will not work as Twig will always load the template from
+``.../templates/mysite``.
+
+It turns out it is possible to get this to work, by adding a directory right
+at the end of your template directories, which is the parent of all of the
+other directories: ``.../templates`` in our case. This has the effect of
+making every template file within our system uniquely addressable. Most of the
+time you will use the "normal" paths, but in the special case of wanting to
+extend a template with an overriding version of itself we can reference its
+parent's full, unambiguous template path in the extends tag:
+
+.. code-block:: twig
+
+    {# page.twig in .../templates/mysite #}
+    {% extends "default/page.twig" %} {# from .../templates #}
+
+.. note::
+
+    This recipe was inspired by the following Django wiki page:
+    https://code.djangoproject.com/wiki/ExtendingTemplates
+
+Customizing the Syntax
+----------------------
+
+Twig allows some syntax customization for the block delimiters. It's **not**
+recommended to use this feature as templates will be tied with your custom
+syntax. But for specific projects, it can make sense to change the defaults.
+
+To change the block delimiters, you need to create your own lexer object::
+
+    $twig = new \Twig\Environment(...);
+
+    $lexer = new \Twig\Lexer($twig, [
+        'tag_comment'   => ['{#', '#}'],
+        'tag_block'     => ['{%', '%}'],
+        'tag_variable'  => ['{{', '}}'],
+        'interpolation' => ['#{', '}'],
+    ]);
+    $twig->setLexer($lexer);
+
+Here are some configuration example that simulates some other template engines
+syntax::
+
+    // Ruby erb syntax
+    $lexer = new \Twig\Lexer($twig, [
+        'tag_comment'  => ['<%#', '%>'],
+        'tag_block'    => ['<%', '%>'],
+        'tag_variable' => ['<%=', '%>'],
+    ]);
+
+    // SGML Comment Syntax
+    $lexer = new \Twig\Lexer($twig, [
+        'tag_comment'  => ['<!--#', '-->'],
+        'tag_block'    => ['<!--', '-->'],
+        'tag_variable' => ['${', '}'],
+    ]);
+
+    // Smarty like
+    $lexer = new \Twig\Lexer($twig, [
+        'tag_comment'  => ['{*', '*}'],
+        'tag_block'    => ['{', '}'],
+        'tag_variable' => ['{$', '}'],
+    ]);
+
+Using dynamic Object Properties
+-------------------------------
+
+When Twig encounters a variable like ``article.title``, it tries to find a
+``title`` public property in the ``article`` object.
+
+It also works if the property does not exist but is rather defined dynamically
+thanks to the magic ``__get()`` method; you need to also implement the
+``__isset()`` magic method like shown in the following snippet of code::
+
+    class Article
+    {
+        public function __get($name)
+        {
+            if ('title' == $name) {
+                return 'The title';
+            }
+
+            // throw some kind of error
+        }
+
+        public function __isset($name)
+        {
+            if ('title' == $name) {
+                return true;
+            }
+
+            return false;
+        }
+    }
+
+Accessing the parent Context in Nested Loops
+--------------------------------------------
+
+Sometimes, when using nested loops, you need to access the parent context. The
+parent context is always accessible via the ``loop.parent`` variable. For
+instance, if you have the following template data::
+
+    $data = [
+        'topics' => [
+            'topic1' => ['Message 1 of topic 1', 'Message 2 of topic 1'],
+            'topic2' => ['Message 1 of topic 2', 'Message 2 of topic 2'],
+        ],
+    ];
+
+And the following template to display all messages in all topics:
+
+.. code-block:: twig
+
+    {% for topic, messages in topics %}
+        * {{ loop.index }}: {{ topic }}
+      {% for message in messages %}
+          - {{ loop.parent.loop.index }}.{{ loop.index }}: {{ message }}
+      {% endfor %}
+    {% endfor %}
+
+The output will be similar to:
+
+.. code-block:: text
+
+    * 1: topic1
+      - 1.1: The message 1 of topic 1
+      - 1.2: The message 2 of topic 1
+    * 2: topic2
+      - 2.1: The message 1 of topic 2
+      - 2.2: The message 2 of topic 2
+
+In the inner loop, the ``loop.parent`` variable is used to access the outer
+context. So, the index of the current ``topic`` defined in the outer for loop
+is accessible via the ``loop.parent.loop.index`` variable.
+
+Defining undefined Functions, Filters, and Tags on the Fly
+----------------------------------------------------------
+
+.. versionadded:: 3.2
+
+    The ``registerUndefinedTokenParserCallback()`` method was added in Twig
+    3.2.
+
+When a function/filter/tag is not defined, Twig defaults to throw a
+``\Twig\Error\SyntaxError`` exception. However, it can also call a `callback`_
+(any valid PHP callable) which should return a function/filter/tag.
+
+For tags, register callbacks with ``registerUndefinedTokenParserCallback()``.
+For filters, register callbacks with ``registerUndefinedFilterCallback()``.
+For functions, use ``registerUndefinedFunctionCallback()``::
+
+    // auto-register all native PHP functions as Twig functions
+    // NEVER do this in a project as it's NOT secure
+    $twig->registerUndefinedFunctionCallback(function ($name) {
+        if (function_exists($name)) {
+            return new \Twig\TwigFunction($name, $name);
+        }
+
+        return false;
+    });
+
+If the callable is not able to return a valid function/filter/tag, it must
+return ``false``.
+
+If you register more than one callback, Twig will call them in turn until one
+does not return ``false``.
+
+.. tip::
+
+    As the resolution of functions/filters/tags is done during compilation,
+    there is no overhead when registering these callbacks.
+
+Validating the Template Syntax
+------------------------------
+
+When template code is provided by a third-party (through a web interface for
+instance), it might be interesting to validate the template syntax before
+saving it. If the template code is stored in a ``$template`` variable, here is
+how you can do it::
+
+    try {
+        $twig->parse($twig->tokenize(new \Twig\Source($template)));
+
+        // the $template is valid
+    } catch (\Twig\Error\SyntaxError $e) {
+        // $template contains one or more syntax errors
+    }
+
+If you iterate over a set of files, you can pass the filename to the
+``tokenize()`` method to get the filename in the exception message::
+
+    foreach ($files as $file) {
+        try {
+            $twig->parse($twig->tokenize(new \Twig\Source($template, $file->getFilename(), $file)));
+
+            // the $template is valid
+        } catch (\Twig\Error\SyntaxError $e) {
+            // $template contains one or more syntax errors
+        }
+    }
+
+.. note::
+
+    This method won't catch any sandbox policy violations because the policy
+    is enforced during template rendering (as Twig needs the context for some
+    checks like allowed methods on objects).
+
+Refreshing modified Templates when OPcache or APC is enabled
+------------------------------------------------------------
+
+When using OPcache with ``opcache.validate_timestamps`` set to ``0`` or APC
+with ``apc.stat`` set to ``0`` and Twig cache enabled, clearing the template
+cache won't update the cache.
+
+To get around this, force Twig to invalidate the bytecode cache::
+
+    $twig = new \Twig\Environment($loader, [
+        'cache' => new \Twig\Cache\FilesystemCache('/some/cache/path', \Twig\Cache\FilesystemCache::FORCE_BYTECODE_INVALIDATION),
+        // ...
+    ]);
+
+Reusing a stateful Node Visitor
+-------------------------------
+
+When attaching a visitor to a ``\Twig\Environment`` instance, Twig uses it to
+visit *all* templates it compiles. If you need to keep some state information
+around, you probably want to reset it when visiting a new template.
+
+This can be achieved with the following code::
+
+    protected $someTemplateState = [];
+
+    public function enterNode(\Twig\Node\Node $node, \Twig\Environment $env)
+    {
+        if ($node instanceof \Twig\Node\ModuleNode) {
+            // reset the state as we are entering a new template
+            $this->someTemplateState = [];
+        }
+
+        // ...
+
+        return $node;
+    }
+
+Using a Database to store Templates
+-----------------------------------
+
+If you are developing a CMS, templates are usually stored in a database. This
+recipe gives you a simple PDO template loader you can use as a starting point
+for your own.
+
+First, let's create a temporary in-memory SQLite3 database to work with::
+
+    $dbh = new PDO('sqlite::memory:');
+    $dbh->exec('CREATE TABLE templates (name STRING, source STRING, last_modified INTEGER)');
+    $base = '{% block content %}{% endblock %}';
+    $index = '
+    {% extends "base.twig" %}
+    {% block content %}Hello {{ name }}{% endblock %}
+    ';
+    $now = time();
+    $dbh->prepare('INSERT INTO templates (name, source, last_modified) VALUES (?, ?, ?)')->execute(['base.twig', $base, $now]);
+    $dbh->prepare('INSERT INTO templates (name, source, last_modified) VALUES (?, ?, ?)')->execute(['index.twig', $index, $now]);
+
+We have created a simple ``templates`` table that hosts two templates:
+``base.twig`` and ``index.twig``.
+
+Now, let's define a loader able to use this database::
+
+    class DatabaseTwigLoader implements \Twig\Loader\LoaderInterface
+    {
+        protected $dbh;
+
+        public function __construct(PDO $dbh)
+        {
+            $this->dbh = $dbh;
+        }
+
+        public function getSourceContext(string $name): Source
+        {
+            if (false === $source = $this->getValue('source', $name)) {
+                throw new \Twig\Error\LoaderError(sprintf('Template "%s" does not exist.', $name));
+            }
+
+            return new \Twig\Source($source, $name);
+        }
+
+        public function exists(string $name)
+        {
+            return $name === $this->getValue('name', $name);
+        }
+
+        public function getCacheKey(string $name): string
+        {
+            return $name;
+        }
+
+        public function isFresh(string $name, int $time): bool
+        {
+            if (false === $lastModified = $this->getValue('last_modified', $name)) {
+                return false;
+            }
+
+            return $lastModified <= $time;
+        }
+
+        protected function getValue($column, $name)
+        {
+            $sth = $this->dbh->prepare('SELECT '.$column.' FROM templates WHERE name = :name');
+            $sth->execute([':name' => (string) $name]);
+
+            return $sth->fetchColumn();
+        }
+    }
+
+Finally, here is an example on how you can use it::
+
+    $loader = new DatabaseTwigLoader($dbh);
+    $twig = new \Twig\Environment($loader);
+
+    echo $twig->render('index.twig', ['name' => 'Fabien']);
+
+Using different Template Sources
+--------------------------------
+
+This recipe is the continuation of the previous one. Even if you store the
+contributed templates in a database, you might want to keep the original/base
+templates on the filesystem. When templates can be loaded from different
+sources, you need to use the ``\Twig\Loader\ChainLoader`` loader.
+
+As you can see in the previous recipe, we reference the template in the exact
+same way as we would have done it with a regular filesystem loader. This is
+the key to be able to mix and match templates coming from the database, the
+filesystem, or any other loader for that matter: the template name should be a
+logical name, and not the path from the filesystem::
+
+    $loader1 = new DatabaseTwigLoader($dbh);
+    $loader2 = new \Twig\Loader\ArrayLoader([
+        'base.twig' => '{% block content %}{% endblock %}',
+    ]);
+    $loader = new \Twig\Loader\ChainLoader([$loader1, $loader2]);
+
+    $twig = new \Twig\Environment($loader);
+
+    echo $twig->render('index.twig', ['name' => 'Fabien']);
+
+Now that the ``base.twig`` templates is defined in an array loader, you can
+remove it from the database, and everything else will still work as before.
+
+Loading a Template from a String
+--------------------------------
+
+From a template, you can load a template stored in a string via the
+``template_from_string`` function (via the
+``\Twig\Extension\StringLoaderExtension`` extension):
+
+.. code-block:: twig
+
+    {{ include(template_from_string("Hello {{ name }}")) }}
+
+From PHP, it's also possible to load a template stored in a string via
+``\Twig\Environment::createTemplate()``::
+
+    $template = $twig->createTemplate('hello {{ name }}');
+    echo $template->render(['name' => 'Fabien']);
+
+Using Twig and AngularJS in the same Templates
+----------------------------------------------
+
+Mixing different template syntaxes in the same file is not a recommended
+practice as both AngularJS and Twig use the same delimiters in their syntax:
+``{{`` and ``}}``.
+
+Still, if you want to use AngularJS and Twig in the same template, there are
+two ways to make it work depending on the amount of AngularJS you need to
+include in your templates:
+
+* Escaping the AngularJS delimiters by wrapping AngularJS sections with the
+  ``{% verbatim %}`` tag or by escaping each delimiter via ``{{ '{{' }}`` and
+  ``{{ '}}' }}``;
+
+* Changing the delimiters of one of the template engines (depending on which
+  engine you introduced last):
+
+  * For AngularJS, change the interpolation tags using the
+    ``interpolateProvider`` service, for instance at the module initialization
+    time:
+
+    ..  code-block:: javascript
+
+        angular.module('myApp', []).config(function($interpolateProvider) {
+            $interpolateProvider.startSymbol('{[').endSymbol(']}');
+        });
+
+  * For Twig, change the delimiters via the ``tag_variable`` Lexer option::
+
+        $env->setLexer(new \Twig\Lexer($env, [
+            'tag_variable' => ['{[', ']}'],
+        ]));
+
+.. _callback: https://secure.php.net/manual/en/function.is-callable.php
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/apply.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/apply.rst
new file mode 100644
index 0000000..27f25f9
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/apply.rst
@@ -0,0 +1,20 @@
+``apply``
+=========
+
+The ``apply`` tag allows you to apply Twig filters on a block of template data:
+
+.. code-block:: twig
+
+    {% apply upper %}
+        This text becomes uppercase
+    {% endapply %}
+
+You can also chain filters and pass arguments to them:
+
+.. code-block:: html+twig
+
+    {% apply lower|escape('html') %}
+        <strong>SOME TEXT</strong>
+    {% endapply %}
+
+    {# outputs "&lt;strong&gt;some text&lt;/strong&gt;" #}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/autoescape.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/autoescape.rst
new file mode 100644
index 0000000..8c621d3
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/autoescape.rst
@@ -0,0 +1,61 @@
+``autoescape``
+==============
+
+Whether automatic escaping is enabled or not, you can mark a section of a
+template to be escaped or not by using the ``autoescape`` tag:
+
+.. code-block:: twig
+
+    {% autoescape %}
+        Everything will be automatically escaped in this block
+        using the HTML strategy
+    {% endautoescape %}
+
+    {% autoescape 'html' %}
+        Everything will be automatically escaped in this block
+        using the HTML strategy
+    {% endautoescape %}
+
+    {% autoescape 'js' %}
+        Everything will be automatically escaped in this block
+        using the js escaping strategy
+    {% endautoescape %}
+
+    {% autoescape false %}
+        Everything will be outputted as is in this block
+    {% endautoescape %}
+
+When automatic escaping is enabled everything is escaped by default except for
+values explicitly marked as safe. Those can be marked in the template by using
+the :doc:`raw<../filters/raw>` filter:
+
+.. code-block:: twig
+
+    {% autoescape %}
+        {{ safe_value|raw }}
+    {% endautoescape %}
+
+Functions returning template data (like :doc:`macros<macro>` and
+:doc:`parent<../functions/parent>`) always return safe markup.
+
+.. note::
+
+    Twig is smart enough to not escape an already escaped value by the
+    :doc:`escape<../filters/escape>` filter.
+
+.. note::
+
+    Twig does not escape static expressions:
+
+    .. code-block:: html+twig
+
+        {% set hello = "<strong>Hello</strong>" %}
+        {{ hello }}
+        {{ "<strong>world</strong>" }}
+
+    Will be rendered "<strong>Hello</strong> **world**".
+
+.. note::
+
+    The chapter :doc:`Twig for Developers<../api>` gives more information
+    about when and how automatic escaping is applied.
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/block.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/block.rst
new file mode 100644
index 0000000..272bc7f
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/block.rst
@@ -0,0 +1,12 @@
+``block``
+=========
+
+Blocks are used for inheritance and act as placeholders and replacements at
+the same time. They are documented in detail in the documentation for the
+:doc:`extends<../tags/extends>` tag.
+
+Block names must consist of alphanumeric characters, and underscores. The first char can't be a digit and dashes are not permitted.
+
+.. seealso::
+
+    :doc:`block<../functions/block>`, :doc:`parent<../functions/parent>`, :doc:`use<../tags/use>`, :doc:`extends<../tags/extends>`
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/cache.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/cache.rst
new file mode 100644
index 0000000..b1d032b
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/cache.rst
@@ -0,0 +1,113 @@
+``cache``
+=========
+
+.. versionadded:: 3.2
+
+    The ``cache`` tag was added in Twig 3.2.
+
+The ``cache`` tag tells Twig to cache a template fragment:
+
+.. code-block:: twig
+
+    {% cache "cache key" %}
+        Cached forever (depending on the cache implementation)
+    {% endcache %}
+
+If you want to expire the cache after a certain amount of time, specify an
+expiration in seconds via the ``ttl()`` modifier:
+
+.. code-block:: twig
+
+    {% cache "cache key" ttl(300) %}
+        Cached for 300 seconds
+    {% endcache %}
+
+The cache key can be any string that does not use the following reserved
+characters ``{}()/\@:``; a good practice is to embed some useful information in
+the key that allows the cache to automatically expire when it must be
+refreshed:
+
+* Give each cache a unique name and namespace it like your templates;
+
+* Embed an integer that you increment whenever the template code changes (to
+  automatically invalidate all current caches);
+
+* Embed a unique key that is updated whenever the variables used in the
+  template code changes.
+
+For instance, I would use ``{% cache "blog_post;v1;" ~ post.id ~ ";" ~
+post.updated_at %}`` to cache a blog content template fragment where
+``blog_post`` describes the template fragment, ``v1`` represents the first
+version of the template code, ``post.id`` represent the id of the blog post,
+and ``post.updated_at`` returns a timestamp that represents the time where the
+blog post was last modified.
+
+Using such a strategy for naming cache keys allows to avoid using a ``ttl``.
+It's like using a "validation" strategy instead of an "expiration" strategy as
+we do for HTTP caches.
+
+If your cache implementation supports tags, you can also tag your cache items:
+
+.. code-block:: twig
+
+    {% cache "cache key" tags('blog') %}
+        Some code
+    {% endcache %}
+
+    {% cache "cache key" tags(['cms', 'blog']) %}
+        Some code
+    {% endcache %}
+
+The ``cache`` tag creates a new "scope" for variables, meaning that the changes
+are local to the template fragment:
+
+.. code-block:: twig
+
+    {% set count = 1 %}
+
+    {% cache "cache key" tags('blog') %}
+        {# Won't affect the value of count outside of the cache tag #}
+        {% set count = 2 %}
+        Some code
+    {% endcache %}
+
+    {# Displays 1 #}
+    {{ count }}
+
+.. note::
+
+    The ``cache`` tag is part of the ``CacheExtension`` which is not installed
+    by default. Install it first:
+
+    .. code-block:: bash
+
+        $ composer require twig/cache-extra
+
+    On Symfony projects, you can automatically enable it by installing the
+    ``twig/extra-bundle``:
+
+    .. code-block:: bash
+
+        $ composer require twig/extra-bundle
+
+    Or add the extension explicitly on the Twig environment::
+
+        use Twig\Extra\Cache\CacheExtension;
+
+        $twig = new \Twig\Environment(...);
+        $twig->addExtension(new CacheExtension());
+
+    If you are not using Symfony, you must also register the extension runtime::
+
+        use Symfony\Component\Cache\Adapter\FilesystemAdapter;
+        use Symfony\Component\Cache\Adapter\TagAwareAdapter;
+        use Twig\Extra\Cache\CacheRuntime;
+        use Twig\RuntimeLoader\RuntimeLoaderInterface;
+
+        $twig->addRuntimeLoader(new class implements RuntimeLoaderInterface {
+            public function load($class) {
+                if (CacheRuntime::class === $class) {
+                    return new CacheRuntime(new TagAwareAdapter(new FilesystemAdapter()));
+                }
+            }
+        });
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/deprecated.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/deprecated.rst
new file mode 100644
index 0000000..c078eef
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/deprecated.rst
@@ -0,0 +1,27 @@
+``deprecated``
+==============
+
+Twig generates a deprecation notice (via a call to the ``trigger_error()``
+PHP function) where the ``deprecated`` tag is used in a template:
+
+.. code-block:: twig
+
+    {# base.twig #}
+    {% deprecated 'The "base.twig" template is deprecated, use "layout.twig" instead.' %}
+    {% extends 'layout.twig' %}
+
+Also you can deprecate a block in the following way:
+
+.. code-block:: twig
+
+    {% block hey %}
+        {% deprecated 'The "hey" block is deprecated, use "greet" instead.' %}
+        {{ block('greet') }}
+    {% endblock %}
+
+    {% block greet %}
+        Hey you!
+    {% endblock %}
+
+Note that by default, the deprecation notices are silenced and never displayed nor logged.
+See :ref:`deprecation-notices` to learn how to handle them.
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/do.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/do.rst
new file mode 100644
index 0000000..b8fe9f0
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/do.rst
@@ -0,0 +1,9 @@
+``do``
+======
+
+The ``do`` tag works exactly like the regular variable expression (``{{ ...
+}}``) just that it doesn't print anything:
+
+.. code-block:: twig
+
+    {% do 1 + 2 %}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/embed.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/embed.rst
new file mode 100644
index 0000000..42e33b1
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/embed.rst
@@ -0,0 +1,177 @@
+``embed``
+=========
+
+The ``embed`` tag combines the behavior of :doc:`include<include>` and
+:doc:`extends<extends>`.
+It allows you to include another template's contents, just like ``include``
+does. But it also allows you to override any block defined inside the
+included template, like when extending a template.
+
+Think of an embedded template as a "micro layout skeleton".
+
+.. code-block:: twig
+
+    {% embed "teasers_skeleton.twig" %}
+        {# These blocks are defined in "teasers_skeleton.twig" #}
+        {# and we override them right here:                    #}
+        {% block left_teaser %}
+            Some content for the left teaser box
+        {% endblock %}
+        {% block right_teaser %}
+            Some content for the right teaser box
+        {% endblock %}
+    {% endembed %}
+
+The ``embed`` tag takes the idea of template inheritance to the level of
+content fragments. While template inheritance allows for "document skeletons",
+which are filled with life by child templates, the ``embed`` tag allows you to
+create "skeletons" for smaller units of content and re-use and fill them
+anywhere you like.
+
+Since the use case may not be obvious, let's look at a simplified example.
+Imagine a base template shared by multiple HTML pages, defining a single block
+named "content":
+
+.. code-block:: text
+
+    ┌─── page layout ─────────────────────┐
+    │                                     │
+    │           ┌── block "content" ──┐   │
+    │           │                     │   │
+    │           │                     │   │
+    │           │ (child template to  │   │
+    │           │  put content here)  │   │
+    │           │                     │   │
+    │           │                     │   │
+    │           └─────────────────────┘   │
+    │                                     │
+    └─────────────────────────────────────┘
+
+Some pages ("foo" and "bar") share the same content structure -
+two vertically stacked boxes:
+
+.. code-block:: text
+
+    ┌─── page layout ─────────────────────┐
+    │                                     │
+    │           ┌── block "content" ──┐   │
+    │           │ ┌─ block "top" ───┐ │   │
+    │           │ │                 │ │   │
+    │           │ └─────────────────┘ │   │
+    │           │ ┌─ block "bottom" ┐ │   │
+    │           │ │                 │ │   │
+    │           │ └─────────────────┘ │   │
+    │           └─────────────────────┘   │
+    │                                     │
+    └─────────────────────────────────────┘
+
+While other pages ("boom" and "baz") share a different content structure -
+two boxes side by side:
+
+.. code-block:: text
+
+    ┌─── page layout ─────────────────────┐
+    │                                     │
+    │           ┌── block "content" ──┐   │
+    │           │                     │   │    
+    │           │ ┌ block ┐ ┌ block ┐ │   │
+    │           │ │"left" │ │"right"│ │   │
+    │           │ │       │ │       │ │   │
+    │           │ │       │ │       │ │   │
+    │           │ └───────┘ └───────┘ │   │
+    │           └─────────────────────┘   │
+    │                                     │
+    └─────────────────────────────────────┘
+
+Without the ``embed`` tag, you have two ways to design your templates:
+
+* Create two "intermediate" base templates that extend the master layout
+  template: one with vertically stacked boxes to be used by the "foo" and
+  "bar" pages and another one with side-by-side boxes for the "boom" and
+  "baz" pages.
+
+* Embed the markup for the top/bottom and left/right boxes into each page
+  template directly.
+
+These two solutions do not scale well because they each have a major drawback:
+
+* The first solution may indeed work for this simplified example. But imagine
+  we add a sidebar, which may again contain different, recurring structures
+  of content. Now we would need to create intermediate base templates for
+  all occurring combinations of content structure and sidebar structure...
+  and so on.
+
+* The second solution involves duplication of common code with all its negative
+  consequences: any change involves finding and editing all affected copies
+  of the structure, correctness has to be verified for each copy, copies may
+  go out of sync by careless modifications etc.
+
+In such a situation, the ``embed`` tag comes in handy. The common layout
+code can live in a single base template, and the two different content structures,
+let's call them "micro layouts" go into separate templates which are embedded
+as necessary:
+
+Page template ``foo.twig``:
+
+.. code-block:: twig
+
+    {% extends "layout_skeleton.twig" %}
+
+    {% block content %}
+        {% embed "vertical_boxes_skeleton.twig" %}
+            {% block top %}
+                Some content for the top box
+            {% endblock %}
+
+            {% block bottom %}
+                Some content for the bottom box
+            {% endblock %}
+        {% endembed %}
+    {% endblock %}
+
+And here is the code for ``vertical_boxes_skeleton.twig``:
+
+.. code-block:: html+twig
+
+    <div class="top_box">
+        {% block top %}
+            Top box default content
+        {% endblock %}
+    </div>
+
+    <div class="bottom_box">
+        {% block bottom %}
+            Bottom box default content
+        {% endblock %}
+    </div>
+
+The goal of the ``vertical_boxes_skeleton.twig`` template being to factor
+out the HTML markup for the boxes.
+
+The ``embed`` tag takes the exact same arguments as the ``include`` tag:
+
+.. code-block:: twig
+
+    {% embed "base" with {'foo': 'bar'} %}
+        ...
+    {% endembed %}
+
+    {% embed "base" with {'foo': 'bar'} only %}
+        ...
+    {% endembed %}
+
+    {% embed "base" ignore missing %}
+        ...
+    {% endembed %}
+
+.. warning::
+
+    As embedded templates do not have "names", auto-escaping strategies based
+    on the template name won't work as expected if you change the context (for
+    instance, if you embed a CSS/JavaScript template into an HTML one). In that
+    case, explicitly set the default auto-escaping strategy with the
+    ``autoescape`` tag.
+
+.. seealso::
+
+    :doc:`include<../tags/include>`
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/extends.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/extends.rst
new file mode 100644
index 0000000..7f1c1e8
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/extends.rst
@@ -0,0 +1,263 @@
+``extends``
+===========
+
+The ``extends`` tag can be used to extend a template from another one.
+
+.. note::
+
+    Like PHP, Twig does not support multiple inheritance. So you can only have
+    one extends tag called per rendering. However, Twig supports horizontal
+    :doc:`reuse<use>`.
+
+Let's define a base template, ``base.html``, which defines a simple HTML
+skeleton document:
+
+.. code-block:: html+twig
+
+    <!DOCTYPE html>
+    <html>
+        <head>
+            {% block head %}
+                <link rel="stylesheet" href="style.css"/>
+                <title>{% block title %}{% endblock %} - My Webpage</title>
+            {% endblock %}
+        </head>
+        <body>
+            <div id="content">{% block content %}{% endblock %}</div>
+            <div id="footer">
+                {% block footer %}
+                    &copy; Copyright 2011 by <a href="http://domain.invalid/">you</a>.
+                {% endblock %}
+            </div>
+        </body>
+    </html>
+
+In this example, the :doc:`block<block>` tags define four blocks that child
+templates can fill in.
+
+All the ``block`` tag does is to tell the template engine that a child
+template may override those portions of the template.
+
+Child Template
+--------------
+
+A child template might look like this:
+
+.. code-block:: html+twig
+
+    {% extends "base.html" %}
+
+    {% block title %}Index{% endblock %}
+    {% block head %}
+        {{ parent() }}
+        <style type="text/css">
+            .important { color: #336699; }
+        </style>
+    {% endblock %}
+    {% block content %}
+        <h1>Index</h1>
+        <p class="important">
+            Welcome on my awesome homepage.
+        </p>
+    {% endblock %}
+
+The ``extends`` tag is the key here. It tells the template engine that this
+template "extends" another template. When the template system evaluates this
+template, first it locates the parent. The extends tag should be the first tag
+in the template.
+
+Note that since the child template doesn't define the ``footer`` block, the
+value from the parent template is used instead.
+
+You can't define multiple ``block`` tags with the same name in the same
+template. This limitation exists because a block tag works in "both"
+directions. That is, a block tag doesn't just provide a hole to fill - it also
+defines the content that fills the hole in the *parent*. If there were two
+similarly-named ``block`` tags in a template, that template's parent wouldn't
+know which one of the blocks' content to use.
+
+If you want to print a block multiple times you can however use the
+``block`` function:
+
+.. code-block:: html+twig
+
+    <title>{% block title %}{% endblock %}</title>
+    <h1>{{ block('title') }}</h1>
+    {% block body %}{% endblock %}
+
+Parent Blocks
+-------------
+
+It's possible to render the contents of the parent block by using the
+:doc:`parent<../functions/parent>` function. This gives back the results of
+the parent block:
+
+.. code-block:: html+twig
+
+    {% block sidebar %}
+        <h3>Table Of Contents</h3>
+        ...
+        {{ parent() }}
+    {% endblock %}
+
+Named Block End-Tags
+--------------------
+
+Twig allows you to put the name of the block after the end tag for better
+readability (the name after the ``endblock`` word must match the block name):
+
+.. code-block:: twig
+
+    {% block sidebar %}
+        {% block inner_sidebar %}
+            ...
+        {% endblock inner_sidebar %}
+    {% endblock sidebar %}
+
+Block Nesting and Scope
+-----------------------
+
+Blocks can be nested for more complex layouts. Per default, blocks have access
+to variables from outer scopes:
+
+.. code-block:: html+twig
+
+    {% for item in seq %}
+        <li>{% block loop_item %}{{ item }}{% endblock %}</li>
+    {% endfor %}
+
+Block Shortcuts
+---------------
+
+For blocks with little content, it's possible to use a shortcut syntax. The
+following constructs do the same thing:
+
+.. code-block:: twig
+
+    {% block title %}
+        {{ page_title|title }}
+    {% endblock %}
+
+.. code-block:: twig
+
+    {% block title page_title|title %}
+
+Dynamic Inheritance
+-------------------
+
+Twig supports dynamic inheritance by using a variable as the base template:
+
+.. code-block:: twig
+
+    {% extends some_var %}
+
+If the variable evaluates to a ``\Twig\Template`` or a ``\Twig\TemplateWrapper``
+instance, Twig will use it as the parent template::
+
+    // {% extends layout %}
+
+    $layout = $twig->load('some_layout_template.twig');
+
+    $twig->display('template.twig', ['layout' => $layout]);
+
+You can also provide a list of templates that are checked for existence. The
+first template that exists will be used as a parent:
+
+.. code-block:: twig
+
+    {% extends ['layout.html', 'base_layout.html'] %}
+
+Conditional Inheritance
+-----------------------
+
+As the template name for the parent can be any valid Twig expression, it's
+possible to make the inheritance mechanism conditional:
+
+.. code-block:: twig
+
+    {% extends standalone ? "minimum.html" : "base.html" %}
+
+In this example, the template will extend the "minimum.html" layout template
+if the ``standalone`` variable evaluates to ``true``, and "base.html"
+otherwise.
+
+How do blocks work?
+-------------------
+
+A block provides a way to change how a certain part of a template is rendered
+but it does not interfere in any way with the logic around it.
+
+Let's take the following example to illustrate how a block works and more
+importantly, how it does not work:
+
+.. code-block:: html+twig
+
+    {# base.twig #}
+    {% for post in posts %}
+        {% block post %}
+            <h1>{{ post.title }}</h1>
+            <p>{{ post.body }}</p>
+        {% endblock %}
+    {% endfor %}
+
+If you render this template, the result would be exactly the same with or
+without the ``block`` tag. The ``block`` inside the ``for`` loop is just a way
+to make it overridable by a child template:
+
+.. code-block:: html+twig
+
+    {# child.twig #}
+    {% extends "base.twig" %}
+
+    {% block post %}
+        <article>
+            <header>{{ post.title }}</header>
+            <section>{{ post.text }}</section>
+        </article>
+    {% endblock %}
+
+Now, when rendering the child template, the loop is going to use the block
+defined in the child template instead of the one defined in the base one; the
+executed template is then equivalent to the following one:
+
+.. code-block:: html+twig
+
+    {% for post in posts %}
+        <article>
+            <header>{{ post.title }}</header>
+            <section>{{ post.text }}</section>
+        </article>
+    {% endfor %}
+
+Let's take another example: a block included within an ``if`` statement:
+
+.. code-block:: html+twig
+
+    {% if posts is empty %}
+        {% block head %}
+            {{ parent() }}
+
+            <meta name="robots" content="noindex, follow">
+        {% endblock head %}
+    {% endif %}
+
+Contrary to what you might think, this template does not define a block
+conditionally; it just makes overridable by a child template the output of
+what will be rendered when the condition is ``true``.
+
+If you want the output to be displayed conditionally, use the following
+instead:
+
+.. code-block:: html+twig
+
+    {% block head %}
+        {{ parent() }}
+
+        {% if posts is empty %}
+            <meta name="robots" content="noindex, follow">
+        {% endif %}
+    {% endblock head %}
+
+.. seealso::
+
+    :doc:`block<../functions/block>`, :doc:`block<../tags/block>`, :doc:`parent<../functions/parent>`, :doc:`use<../tags/use>`
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/flush.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/flush.rst
new file mode 100644
index 0000000..332e982
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/flush.rst
@@ -0,0 +1,14 @@
+``flush``
+=========
+
+The ``flush`` tag tells Twig to flush the output buffer:
+
+.. code-block:: twig
+
+    {% flush %}
+
+.. note::
+
+    Internally, Twig uses the PHP `flush`_ function.
+
+.. _`flush`: https://secure.php.net/flush
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/for.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/for.rst
new file mode 100644
index 0000000..4517f59
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/for.rst
@@ -0,0 +1,141 @@
+``for``
+=======
+
+Loop over each item in a sequence. For example, to display a list of users
+provided in a variable called ``users``:
+
+.. code-block:: html+twig
+
+    <h1>Members</h1>
+    <ul>
+        {% for user in users %}
+            <li>{{ user.username|e }}</li>
+        {% endfor %}
+    </ul>
+
+.. note::
+
+    A sequence can be either an array or an object implementing the
+    ``Traversable`` interface.
+
+If you do need to iterate over a sequence of numbers, you can use the ``..``
+operator:
+
+.. code-block:: twig
+
+    {% for i in 0..10 %}
+        * {{ i }}
+    {% endfor %}
+
+The above snippet of code would print all numbers from 0 to 10.
+
+It can be also useful with letters:
+
+.. code-block:: twig
+
+    {% for letter in 'a'..'z' %}
+        * {{ letter }}
+    {% endfor %}
+
+The ``..`` operator can take any expression at both sides:
+
+.. code-block:: twig
+
+    {% for letter in 'a'|upper..'z'|upper %}
+        * {{ letter }}
+    {% endfor %}
+
+.. tip:
+
+    If you need a step different from 1, you can use the ``range`` function
+    instead.
+
+The `loop` variable
+-------------------
+
+Inside of a ``for`` loop block you can access some special variables:
+
+===================== =============================================================
+Variable              Description
+===================== =============================================================
+``loop.index``        The current iteration of the loop. (1 indexed)
+``loop.index0``       The current iteration of the loop. (0 indexed)
+``loop.revindex``     The number of iterations from the end of the loop (1 indexed)
+``loop.revindex0``    The number of iterations from the end of the loop (0 indexed)
+``loop.first``        True if first iteration
+``loop.last``         True if last iteration
+``loop.length``       The number of items in the sequence
+``loop.parent``       The parent context
+===================== =============================================================
+
+.. code-block:: twig
+
+    {% for user in users %}
+        {{ loop.index }} - {{ user.username }}
+    {% endfor %}
+
+.. note::
+
+    The ``loop.length``, ``loop.revindex``, ``loop.revindex0``, and
+    ``loop.last`` variables are only available for PHP arrays, or objects that
+    implement the ``Countable`` interface.
+
+The `else` Clause
+-----------------
+
+If no iteration took place because the sequence was empty, you can render a
+replacement block by using ``else``:
+
+.. code-block:: html+twig
+
+    <ul>
+        {% for user in users %}
+            <li>{{ user.username|e }}</li>
+        {% else %}
+            <li><em>no user found</em></li>
+        {% endfor %}
+    </ul>
+
+Iterating over Keys
+-------------------
+
+By default, a loop iterates over the values of the sequence. You can iterate
+on keys by using the ``keys`` filter:
+
+.. code-block:: html+twig
+
+    <h1>Members</h1>
+    <ul>
+        {% for key in users|keys %}
+            <li>{{ key }}</li>
+        {% endfor %}
+    </ul>
+
+Iterating over Keys and Values
+------------------------------
+
+You can also access both keys and values:
+
+.. code-block:: html+twig
+
+    <h1>Members</h1>
+    <ul>
+        {% for key, user in users %}
+            <li>{{ key }}: {{ user.username|e }}</li>
+        {% endfor %}
+    </ul>
+
+Iterating over a Subset
+-----------------------
+
+You might want to iterate over a subset of values. This can be achieved using
+the :doc:`slice <../filters/slice>` filter:
+
+.. code-block:: html+twig
+
+    <h1>Top Ten Members</h1>
+    <ul>
+        {% for user in users|slice(0, 10) %}
+            <li>{{ user.username|e }}</li>
+        {% endfor %}
+    </ul>
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/from.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/from.rst
new file mode 100644
index 0000000..96c439a
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/from.rst
@@ -0,0 +1,6 @@
+``from``
+========
+
+The ``from`` tag imports :doc:`macro<../tags/macro>` names into the current
+namespace. The tag is documented in detail in the documentation for the
+:doc:`macro<../tags/macro>` tag.
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/if.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/if.rst
new file mode 100644
index 0000000..2d74752
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/if.rst
@@ -0,0 +1,79 @@
+``if``
+======
+
+The ``if`` statement in Twig is comparable with the if statements of PHP.
+
+In the simplest form you can use it to test if an expression evaluates to
+``true``:
+
+.. code-block:: html+twig
+
+    {% if online == false %}
+        <p>Our website is in maintenance mode. Please, come back later.</p>
+    {% endif %}
+
+You can also test if an array is not empty:
+
+.. code-block:: html+twig
+
+    {% if users %}
+        <ul>
+            {% for user in users %}
+                <li>{{ user.username|e }}</li>
+            {% endfor %}
+        </ul>
+    {% endif %}
+
+.. note::
+
+    If you want to test if the variable is defined, use ``if users is
+    defined`` instead.
+
+You can also use ``not`` to check for values that evaluate to ``false``:
+
+.. code-block:: html+twig
+
+    {% if not user.subscribed %}
+        <p>You are not subscribed to our mailing list.</p>
+    {% endif %}
+
+For multiple conditions, ``and`` and ``or`` can be used:
+
+.. code-block:: html+twig
+
+    {% if temperature > 18 and temperature < 27 %}
+        <p>It's a nice day for a walk in the park.</p>
+    {% endif %}
+
+For multiple branches ``elseif`` and ``else`` can be used like in PHP. You can
+use more complex ``expressions`` there too:
+
+.. code-block:: twig
+
+    {% if product.stock > 10 %}
+       Available
+    {% elseif product.stock > 0 %}
+       Only {{ product.stock }} left!
+    {% else %}
+       Sold-out!
+    {% endif %}
+
+.. note::
+
+    The rules to determine if an expression is ``true`` or ``false`` are the
+    same as in PHP; here are the edge cases rules:
+
+    ====================== ====================
+    Value                  Boolean evaluation
+    ====================== ====================
+    empty string           false
+    numeric zero           false
+    NAN (Not A Number)     true
+    INF (Infinity)         true
+    whitespace-only string true
+    string "0" or '0'      false
+    empty array            false
+    null                   false
+    non-empty array        true
+    object                 true
+    ====================== ====================
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/import.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/import.rst
new file mode 100644
index 0000000..f217479
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/import.rst
@@ -0,0 +1,6 @@
+``import``
+==========
+
+The ``import`` tag imports :doc:`macro<../tags/macro>` names in a local
+variable. The tag is documented in detail in the documentation for the
+:doc:`macro<../tags/macro>` tag.
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/include.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/include.rst
new file mode 100644
index 0000000..93fb037
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/include.rst
@@ -0,0 +1,110 @@
+``include``
+===========
+
+The ``include`` statement includes a template and outputs the rendered content
+of that file:
+
+.. code-block:: twig
+
+    {% include 'header.html' %}
+        Body
+    {% include 'footer.html' %}
+
+.. note::
+
+    It is recommended to use the :doc:`include<../functions/include>` function
+    instead as it provides the same features with a bit more flexibility:
+
+    * The ``include`` function is semantically more "correct" (including a
+      template outputs its rendered contents in the current scope; a tag should
+      not display anything);
+
+    * The ``include`` function is more "composable":
+
+      .. code-block:: twig
+
+          {# Store a rendered template in a variable #}
+          {% set content %}
+              {% include 'template.html' %}
+          {% endset %}
+          {# vs #}
+          {% set content = include('template.html') %}
+
+          {# Apply filter on a rendered template #}
+          {% apply upper %}
+              {% include 'template.html' %}
+          {% endapply %}
+          {# vs #}
+          {{ include('template.html')|upper }}
+
+    * The ``include`` function does not impose any specific order for
+      arguments thanks to :ref:`named arguments <named-arguments>`.
+
+Included templates have access to the variables of the active context.
+
+If you are using the filesystem loader, the templates are looked for in the
+paths defined by it.
+
+You can add additional variables by passing them after the ``with`` keyword:
+
+.. code-block:: twig
+
+    {# template.html will have access to the variables from the current context and the additional ones provided #}
+    {% include 'template.html' with {'foo': 'bar'} %}
+
+    {% set vars = {'foo': 'bar'} %}
+    {% include 'template.html' with vars %}
+
+You can disable access to the context by appending the ``only`` keyword:
+
+.. code-block:: twig
+
+    {# only the foo variable will be accessible #}
+    {% include 'template.html' with {'foo': 'bar'} only %}
+
+.. code-block:: twig
+
+    {# no variables will be accessible #}
+    {% include 'template.html' only %}
+
+.. tip::
+
+    When including a template created by an end user, you should consider
+    sandboxing it. More information in the :doc:`Twig for Developers<../api>`
+    chapter and in the :doc:`sandbox<../tags/sandbox>` tag documentation.
+
+The template name can be any valid Twig expression:
+
+.. code-block:: twig
+
+    {% include some_var %}
+    {% include ajax ? 'ajax.html' : 'not_ajax.html' %}
+
+And if the expression evaluates to a ``\Twig\Template`` or a
+``\Twig\TemplateWrapper`` instance, Twig will use it directly::
+
+    // {% include template %}
+
+    $template = $twig->load('some_template.twig');
+
+    $twig->display('template.twig', ['template' => $template]);
+
+You can mark an include with ``ignore missing`` in which case Twig will ignore
+the statement if the template to be included does not exist. It has to be
+placed just after the template name. Here some valid examples:
+
+.. code-block:: twig
+
+    {% include 'sidebar.html' ignore missing %}
+    {% include 'sidebar.html' ignore missing with {'foo': 'bar'} %}
+    {% include 'sidebar.html' ignore missing only %}
+
+You can also provide a list of templates that are checked for existence before
+inclusion. The first template that exists will be included:
+
+.. code-block:: twig
+
+    {% include ['page_detailed.html', 'page.html'] %}
+
+If ``ignore missing`` is given, it will fall back to rendering nothing if none
+of the templates exist, otherwise it will throw an exception.
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/index.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/index.rst
new file mode 100644
index 0000000..b3c1040
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/index.rst
@@ -0,0 +1,26 @@
+Tags
+====
+
+.. toctree::
+    :maxdepth: 1
+
+    apply
+    autoescape
+    block
+    cache
+    deprecated
+    do
+    embed
+    extends
+    flush
+    for
+    from
+    if
+    import
+    include
+    macro
+    sandbox
+    set
+    use
+    verbatim
+    with
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/macro.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/macro.rst
new file mode 100644
index 0000000..42fc460
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/macro.rst
@@ -0,0 +1,140 @@
+``macro``
+=========
+
+Macros are comparable with functions in regular programming languages. They
+are useful to reuse template fragments to not repeat yourself.
+
+Macros are defined in regular templates.
+
+Imagine having a generic helper template that define how to render HTML forms
+via macros (called ``forms.html``):
+
+.. code-block:: html+twig
+
+    {% macro input(name, value, type = "text", size = 20) %}
+        <input type="{{ type }}" name="{{ name }}" value="{{ value|e }}" size="{{ size }}"/>
+    {% endmacro %}
+
+    {% macro textarea(name, value, rows = 10, cols = 40) %}
+        <textarea name="{{ name }}" rows="{{ rows }}" cols="{{ cols }}">{{ value|e }}</textarea>
+    {% endmacro %}
+
+Each macro argument can have a default value (here ``text`` is the default value
+for ``type`` if not provided in the call).
+
+Macros differ from native PHP functions in a few ways:
+
+* Arguments of a macro are always optional.
+
+* If extra positional arguments are passed to a macro, they end up in the
+  special ``varargs`` variable as a list of values.
+
+But as with PHP functions, macros don't have access to the current template
+variables.
+
+.. tip::
+
+    You can pass the whole context as an argument by using the special
+    ``_context`` variable.
+
+Importing Macros
+----------------
+
+There are two ways to import macros. You can import the complete template
+containing the macros into a local variable (via the ``import`` tag) or only
+import specific macros from the template (via the ``from`` tag).
+
+To import all macros from a template into a local variable, use the ``import``
+tag:
+
+.. code-block:: twig
+
+    {% import "forms.html" as forms %}
+
+The above ``import`` call imports the ``forms.html`` file (which can contain
+only macros, or a template and some macros), and import the macros as items of
+the ``forms`` local variable.
+
+The macros can then be called at will in the *current* template:
+
+.. code-block:: html+twig
+
+    <p>{{ forms.input('username') }}</p>
+    <p>{{ forms.input('password', null, 'password') }}</p>
+
+Alternatively you can import names from the template into the current namespace
+via the ``from`` tag:
+
+.. code-block:: html+twig
+
+    {% from 'forms.html' import input as input_field, textarea %}
+
+    <p>{{ input_field('password', '', 'password') }}</p>
+    <p>{{ textarea('comment') }}</p>
+
+.. tip::
+
+    When macro usages and definitions are in the same template, you don't need to
+    import the macros as they are automatically available under the special
+    ``_self`` variable:
+
+    .. code-block:: html+twig
+
+        <p>{{ _self.input('password', '', 'password') }}</p>
+
+        {% macro input(name, value, type = "text", size = 20) %}
+            <input type="{{ type }}" name="{{ name }}" value="{{ value|e }}" size="{{ size }}"/>
+        {% endmacro %}
+
+Macros Scoping
+--------------
+
+The scoping rules are the same whether you imported macros via ``import`` or
+``from``.
+
+Imported macros are always **local** to the current template. It means that
+macros are available in all blocks and other macros defined in the current
+template, but they are not available in included templates or child templates;
+you need to explicitly re-import macros in each template.
+
+Imported macros are not available in the body of ``embed`` tags, you need
+to explicitly re-import macros inside the tag.
+
+When calling ``import`` or ``from`` from a ``block`` tag, the imported macros
+are only defined in the current block and they override macros defined at the
+template level with the same names.
+
+When calling ``import`` or ``from`` from a ``macro`` tag, the imported macros
+are only defined in the current macro and they override macros defined at the
+template level with the same names.
+
+Checking if a Macro is defined
+------------------------------
+
+You can check if a macro is defined via the ``defined`` test:
+
+.. code-block:: twig
+
+    {% import "macros.twig" as macros %}
+
+    {% from "macros.twig" import hello %}
+
+    {% if macros.hello is defined -%}
+        OK
+    {% endif %}
+
+    {% if hello is defined -%}
+        OK
+    {% endif %}
+
+Named Macro End-Tags
+--------------------
+
+Twig allows you to put the name of the macro after the end tag for better
+readability (the name after the ``endmacro`` word must match the macro name):
+
+.. code-block:: twig
+
+    {% macro input() %}
+        ...
+    {% endmacro input %}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/sandbox.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/sandbox.rst
new file mode 100644
index 0000000..b331fdb
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/sandbox.rst
@@ -0,0 +1,30 @@
+``sandbox``
+===========
+
+The ``sandbox`` tag can be used to enable the sandboxing mode for an included
+template, when sandboxing is not enabled globally for the Twig environment:
+
+.. code-block:: twig
+
+    {% sandbox %}
+        {% include 'user.html' %}
+    {% endsandbox %}
+
+.. warning::
+
+    The ``sandbox`` tag is only available when the sandbox extension is
+    enabled (see the :doc:`Twig for Developers<../api>` chapter).
+
+.. note::
+
+    The ``sandbox`` tag can only be used to sandbox an include tag and it
+    cannot be used to sandbox a section of a template. The following example
+    won't work:
+
+    .. code-block:: twig
+
+        {% sandbox %}
+            {% for i in 1..2 %}
+                {{ i }}
+            {% endfor %}
+        {% endsandbox %}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/set.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/set.rst
new file mode 100644
index 0000000..7a3a784
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/set.rst
@@ -0,0 +1,78 @@
+``set``
+=======
+
+Inside code blocks you can also assign values to variables. Assignments use
+the ``set`` tag and can have multiple targets.
+
+Here is how you can assign the ``bar`` value to the ``foo`` variable:
+
+.. code-block:: twig
+
+    {% set foo = 'bar' %}
+
+After the ``set`` call, the ``foo`` variable is available in the template like
+any other ones:
+
+.. code-block:: twig
+
+    {# displays bar #}
+    {{ foo }}
+
+The assigned value can be any valid :ref:`Twig expression
+<twig-expressions>`:
+
+.. code-block:: twig
+
+    {% set foo = [1, 2] %}
+    {% set foo = {'foo': 'bar'} %}
+    {% set foo = 'foo' ~ 'bar' %}
+
+Several variables can be assigned in one block:
+
+.. code-block:: twig
+
+    {% set foo, bar = 'foo', 'bar' %}
+
+    {# is equivalent to #}
+
+    {% set foo = 'foo' %}
+    {% set bar = 'bar' %}
+
+The ``set`` tag can also be used to 'capture' chunks of text:
+
+.. code-block:: html+twig
+
+    {% set foo %}
+        <div id="pagination">
+            ...
+        </div>
+    {% endset %}
+
+.. caution::
+
+    If you enable automatic output escaping, Twig will only consider the
+    content to be safe when capturing chunks of text.
+
+.. note::
+
+    Note that loops are scoped in Twig; therefore a variable declared inside a
+    ``for`` loop is not accessible outside the loop itself:
+
+    .. code-block:: twig
+
+        {% for item in list %}
+            {% set foo = item %}
+        {% endfor %}
+
+        {# foo is NOT available #}
+
+    If you want to access the variable, just declare it before the loop:
+
+    .. code-block:: twig
+
+        {% set foo = "" %}
+        {% for item in list %}
+            {% set foo = item %}
+        {% endfor %}
+
+        {# foo is available #}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/use.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/use.rst
new file mode 100644
index 0000000..2aca6a0
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/use.rst
@@ -0,0 +1,117 @@
+``use``
+=======
+
+.. note::
+
+    Horizontal reuse is an advanced Twig feature that is hardly ever needed in
+    regular templates. It is mainly used by projects that need to make
+    template blocks reusable without using inheritance.
+
+Template inheritance is one of the most powerful features of Twig but it is
+limited to single inheritance; a template can only extend one other template.
+This limitation makes template inheritance simple to understand and easy to
+debug:
+
+.. code-block:: twig
+
+    {% extends "base.html" %}
+
+    {% block title %}{% endblock %}
+    {% block content %}{% endblock %}
+
+Horizontal reuse is a way to achieve the same goal as multiple inheritance,
+but without the associated complexity:
+
+.. code-block:: twig
+
+    {% extends "base.html" %}
+
+    {% use "blocks.html" %}
+
+    {% block title %}{% endblock %}
+    {% block content %}{% endblock %}
+
+The ``use`` statement tells Twig to import the blocks defined in
+``blocks.html`` into the current template (it's like macros, but for blocks):
+
+.. code-block:: twig
+
+    {# blocks.html #}
+    
+    {% block sidebar %}{% endblock %}
+
+In this example, the ``use`` statement imports the ``sidebar`` block into the
+main template. The code is mostly equivalent to the following one (the
+imported blocks are not outputted automatically):
+
+.. code-block:: twig
+
+    {% extends "base.html" %}
+
+    {% block sidebar %}{% endblock %}
+    {% block title %}{% endblock %}
+    {% block content %}{% endblock %}
+
+.. note::
+
+    The ``use`` tag only imports a template if it does not extend another
+    template, if it does not define macros, and if the body is empty. But it
+    can *use* other templates.
+
+.. note::
+
+    Because ``use`` statements are resolved independently of the context
+    passed to the template, the template reference cannot be an expression.
+
+The main template can also override any imported block. If the template
+already defines the ``sidebar`` block, then the one defined in ``blocks.html``
+is ignored. To avoid name conflicts, you can rename imported blocks:
+
+.. code-block:: twig
+
+    {% extends "base.html" %}
+
+    {% use "blocks.html" with sidebar as base_sidebar, title as base_title %}
+
+    {% block sidebar %}{% endblock %}
+    {% block title %}{% endblock %}
+    {% block content %}{% endblock %}
+
+The ``parent()`` function automatically determines the correct inheritance
+tree, so it can be used when overriding a block defined in an imported
+template:
+
+.. code-block:: twig
+
+    {% extends "base.html" %}
+
+    {% use "blocks.html" %}
+
+    {% block sidebar %}
+        {{ parent() }}
+    {% endblock %}
+
+    {% block title %}{% endblock %}
+    {% block content %}{% endblock %}
+
+In this example, ``parent()`` will correctly call the ``sidebar`` block from
+the ``blocks.html`` template.
+
+.. tip::
+
+    Renaming allows you to simulate inheritance by calling the "parent" block:
+
+    .. code-block:: twig
+
+        {% extends "base.html" %}
+
+        {% use "blocks.html" with sidebar as parent_sidebar %}
+
+        {% block sidebar %}
+            {{ block('parent_sidebar') }}
+        {% endblock %}
+
+.. note::
+
+    You can use as many ``use`` statements as you want in any given template.
+    If two imported templates define the same block, the latest one wins.
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/verbatim.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/verbatim.rst
new file mode 100644
index 0000000..3d7115a
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/verbatim.rst
@@ -0,0 +1,16 @@
+``verbatim``
+============
+
+The ``verbatim`` tag marks sections as being raw text that should not be
+parsed. For example to put Twig syntax as example into a template you can use
+this snippet:
+
+.. code-block:: html+twig
+
+    {% verbatim %}
+        <ul>
+        {% for item in seq %}
+            <li>{{ item }}</li>
+        {% endfor %}
+        </ul>
+    {% endverbatim %}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/with.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/with.rst
new file mode 100644
index 0000000..107432f
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tags/with.rst
@@ -0,0 +1,41 @@
+``with``
+========
+
+Use the ``with`` tag to create a new inner scope. Variables set within this
+scope are not visible outside of the scope:
+
+.. code-block:: twig
+
+    {% with %}
+        {% set foo = 42 %}
+        {{ foo }} {# foo is 42 here #}
+    {% endwith %}
+    foo is not visible here any longer
+
+Instead of defining variables at the beginning of the scope, you can pass a
+hash of variables you want to define in the ``with`` tag; the previous example
+is equivalent to the following one:
+
+.. code-block:: twig
+
+    {% with { foo: 42 } %}
+        {{ foo }} {# foo is 42 here #}
+    {% endwith %}
+    foo is not visible here any longer
+
+    {# it works with any expression that resolves to a hash #}
+    {% set vars = { foo: 42 } %}
+    {% with vars %}
+        ...
+    {% endwith %}
+
+By default, the inner scope has access to the outer scope context; you can
+disable this behavior by appending the ``only`` keyword:
+
+.. code-block:: twig
+
+    {% set bar = 'bar' %}
+    {% with { foo: 42 } only %}
+        {# only foo is defined #}
+        {# bar is not defined #}
+    {% endwith %}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/templates.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/templates.rst
new file mode 100644
index 0000000..2a8f380
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/templates.rst
@@ -0,0 +1,859 @@
+Twig for Template Designers
+===========================
+
+This document describes the syntax and semantics of the template engine and
+will be most useful as reference to those creating Twig templates.
+
+Synopsis
+--------
+
+A template is a regular text file. It can generate any text-based format (HTML,
+XML, CSV, LaTeX, etc.). It doesn't have a specific extension, ``.html`` or
+``.xml`` are just fine.
+
+A template contains **variables** or **expressions**, which get replaced with
+values when the template is evaluated, and **tags**, which control the
+template's logic.
+
+Below is a minimal template that illustrates a few basics. We will cover further
+details later on:
+
+.. code-block:: html+twig
+
+    <!DOCTYPE html>
+    <html>
+        <head>
+            <title>My Webpage</title>
+        </head>
+        <body>
+            <ul id="navigation">
+            {% for item in navigation %}
+                <li><a href="{{ item.href }}">{{ item.caption }}</a></li>
+            {% endfor %}
+            </ul>
+
+            <h1>My Webpage</h1>
+            {{ a_variable }}
+        </body>
+    </html>
+
+There are two kinds of delimiters: ``{% ... %}`` and ``{{ ... }}``. The first
+one is used to execute statements such as for-loops, the latter outputs the
+result of an expression.
+
+IDEs Integration
+----------------
+
+Many IDEs support syntax highlighting and auto-completion for Twig:
+
+* *Textmate* via the `Twig bundle`_
+* *Vim* via the `Jinja syntax plugin`_ or the `vim-twig plugin`_
+* *Netbeans* via the `Twig syntax plugin`_ (until 7.1, native as of 7.2)
+* *PhpStorm* (native as of 2.1)
+* *Eclipse* via the `Twig plugin`_
+* *Sublime Text* via the `Twig bundle`_
+* *GtkSourceView* via the `Twig language definition`_ (used by gedit and other projects)
+* *Coda* and *SubEthaEdit* via the `Twig syntax mode`_
+* *Coda 2* via the `other Twig syntax mode`_
+* *Komodo* and *Komodo Edit* via the Twig highlight/syntax check mode
+* *Notepad++* via the `Notepad++ Twig Highlighter`_
+* *Emacs* via `web-mode.el`_
+* *Atom* via the `PHP-twig for atom`_
+* *Visual Studio Code* via the `Twig pack`_
+
+Also, `TwigFiddle`_ is an online service that allows you to execute Twig templates
+from a browser; it supports all versions of Twig.
+
+Variables
+---------
+
+The application passes variables to the templates for manipulation in the
+template. Variables may have attributes or elements you can access, too. The
+visual representation of a variable depends heavily on the application providing
+it.
+
+Use a dot (``.``) to access attributes of a variable (methods or properties of a
+PHP object, or items of a PHP array):
+
+.. code-block:: twig
+
+    {{ foo.bar }}
+
+.. note::
+
+    It's important to know that the curly braces are *not* part of the
+    variable but the print statement. When accessing variables inside tags,
+    don't put the braces around them.
+
+.. sidebar:: Implementation
+
+    For convenience's sake ``foo.bar`` does the following things on the PHP
+    layer:
+
+    * check if ``foo`` is an array and ``bar`` a valid element;
+    * if not, and if ``foo`` is an object, check that ``bar`` is a valid property;
+    * if not, and if ``foo`` is an object, check that ``bar`` is a valid method
+      (even if ``bar`` is the constructor - use ``__construct()`` instead);
+    * if not, and if ``foo`` is an object, check that ``getBar`` is a valid method;
+    * if not, and if ``foo`` is an object, check that ``isBar`` is a valid method;
+    * if not, and if ``foo`` is an object, check that ``hasBar`` is a valid method;
+    * if not, return a ``null`` value.
+
+    Twig also supports a specific syntax for accessing items on PHP arrays,
+    ``foo['bar']``:
+
+    * check if ``foo`` is an array and ``bar`` a valid element;
+    * if not, return a ``null`` value.
+
+If a variable or attribute does not exist, you will receive a ``null`` value
+when the ``strict_variables`` option is set to ``false``; alternatively, if ``strict_variables``
+is set, Twig will throw an error (see :ref:`environment options<environment_options>`).
+
+.. note::
+
+    If you want to access a dynamic attribute of a variable, use the
+    :doc:`attribute<functions/attribute>` function instead.
+
+    The ``attribute`` function is also useful when the attribute contains
+    special characters (like ``-`` that would be interpreted as the minus
+    operator):
+
+    .. code-block:: twig
+
+        {# equivalent to the non-working foo.data-foo #}
+        {{ attribute(foo, 'data-foo') }}
+
+Global Variables
+~~~~~~~~~~~~~~~~
+
+The following variables are always available in templates:
+
+* ``_self``: references the current template name;
+* ``_context``: references the current context;
+* ``_charset``: references the current charset.
+
+Setting Variables
+~~~~~~~~~~~~~~~~~
+
+You can assign values to variables inside code blocks. Assignments use the
+:doc:`set<tags/set>` tag:
+
+.. code-block:: twig
+
+    {% set foo = 'foo' %}
+    {% set foo = [1, 2] %}
+    {% set foo = {'foo': 'bar'} %}
+
+Filters
+-------
+
+Variables can be modified by **filters**. Filters are separated from the
+variable by a pipe symbol (``|``). Multiple filters can be chained. The output
+of one filter is applied to the next.
+
+The following example removes all HTML tags from the ``name`` and title-cases
+it:
+
+.. code-block:: twig
+
+    {{ name|striptags|title }}
+
+Filters that accept arguments have parentheses around the arguments. This
+example joins the elements of a list by commas:
+
+.. code-block:: twig
+
+    {{ list|join(', ') }}
+
+To apply a filter on a section of code, wrap it with the
+:doc:`apply<tags/apply>` tag:
+
+.. code-block:: twig
+
+    {% apply upper %}
+        This text becomes uppercase
+    {% endapply %}
+
+Go to the :doc:`filters<filters/index>` page to learn more about built-in
+filters.
+
+Functions
+---------
+
+Functions can be called to generate content. Functions are called by their
+name followed by parentheses (``()``) and may have arguments.
+
+For instance, the ``range`` function returns a list containing an arithmetic
+progression of integers:
+
+.. code-block:: twig
+
+    {% for i in range(0, 3) %}
+        {{ i }},
+    {% endfor %}
+
+Go to the :doc:`functions<functions/index>` page to learn more about the
+built-in functions.
+
+.. _named-arguments:
+
+Named Arguments
+---------------
+
+.. code-block:: twig
+
+    {% for i in range(low=1, high=10, step=2) %}
+        {{ i }},
+    {% endfor %}
+
+Using named arguments makes your templates more explicit about the meaning of
+the values you pass as arguments:
+
+.. code-block:: twig
+
+    {{ data|convert_encoding('UTF-8', 'iso-2022-jp') }}
+
+    {# versus #}
+
+    {{ data|convert_encoding(from='iso-2022-jp', to='UTF-8') }}
+
+Named arguments also allow you to skip some arguments for which you don't want
+to change the default value:
+
+.. code-block:: twig
+
+    {# the first argument is the date format, which defaults to the global date format if null is passed #}
+    {{ "now"|date(null, "Europe/Paris") }}
+
+    {# or skip the format value by using a named argument for the time zone #}
+    {{ "now"|date(timezone="Europe/Paris") }}
+
+You can also use both positional and named arguments in one call, in which
+case positional arguments must always come before named arguments:
+
+.. code-block:: twig
+
+    {{ "now"|date('d/m/Y H:i', timezone="Europe/Paris") }}
+
+.. tip::
+
+    Each function and filter documentation page has a section where the names
+    of all arguments are listed when supported.
+
+Control Structure
+-----------------
+
+A control structure refers to all those things that control the flow of a
+program - conditionals (i.e. ``if``/``elseif``/``else``), ``for``-loops, as
+well as things like blocks. Control structures appear inside ``{% ... %}``
+blocks.
+
+For example, to display a list of users provided in a variable called
+``users``, use the :doc:`for<tags/for>` tag:
+
+.. code-block:: html+twig
+
+    <h1>Members</h1>
+    <ul>
+        {% for user in users %}
+            <li>{{ user.username|e }}</li>
+        {% endfor %}
+    </ul>
+
+The :doc:`if<tags/if>` tag can be used to test an expression:
+
+.. code-block:: html+twig
+
+    {% if users|length > 0 %}
+        <ul>
+            {% for user in users %}
+                <li>{{ user.username|e }}</li>
+            {% endfor %}
+        </ul>
+    {% endif %}
+
+Go to the :doc:`tags<tags/index>` page to learn more about the built-in tags.
+
+Comments
+--------
+
+To comment-out part of a line in a template, use the comment syntax ``{# ...
+#}``. This is useful for debugging or to add information for other template
+designers or yourself:
+
+.. code-block:: twig
+
+    {# note: disabled template because we no longer use this
+        {% for user in users %}
+            ...
+        {% endfor %}
+    #}
+
+Including other Templates
+-------------------------
+
+The :doc:`include<functions/include>` function is useful to include a template
+and return the rendered content of that template into the current one:
+
+.. code-block:: twig
+
+    {{ include('sidebar.html') }}
+
+By default, included templates have access to the same context as the template
+which includes them. This means that any variable defined in the main template
+will be available in the included template too:
+
+.. code-block:: twig
+
+    {% for box in boxes %}
+        {{ include('render_box.html') }}
+    {% endfor %}
+
+The included template ``render_box.html`` is able to access the ``box`` variable.
+
+The name of the template depends on the template loader. For instance, the
+``\Twig\Loader\FilesystemLoader`` allows you to access other templates by giving the
+filename. You can access templates in subdirectories with a slash:
+
+.. code-block:: twig
+
+    {{ include('sections/articles/sidebar.html') }}
+
+This behavior depends on the application embedding Twig.
+
+Template Inheritance
+--------------------
+
+The most powerful part of Twig is template inheritance. Template inheritance
+allows you to build a base "skeleton" template that contains all the common
+elements of your site and defines **blocks** that child templates can
+override.
+
+It's easier to understand the concept by starting with an example.
+
+Let's define a base template, ``base.html``, which defines an HTML skeleton
+document that might be used for a two-column page:
+
+.. code-block:: html+twig
+
+    <!DOCTYPE html>
+    <html>
+        <head>
+            {% block head %}
+                <link rel="stylesheet" href="style.css"/>
+                <title>{% block title %}{% endblock %} - My Webpage</title>
+            {% endblock %}
+        </head>
+        <body>
+            <div id="content">{% block content %}{% endblock %}</div>
+            <div id="footer">
+                {% block footer %}
+                    &copy; Copyright 2011 by <a href="http://domain.invalid/">you</a>.
+                {% endblock %}
+            </div>
+        </body>
+    </html>
+
+In this example, the :doc:`block<tags/block>` tags define four blocks that
+child templates can fill in. All the ``block`` tag does is to tell the
+template engine that a child template may override those portions of the
+template.
+
+A child template might look like this:
+
+.. code-block:: html+twig
+
+    {% extends "base.html" %}
+
+    {% block title %}Index{% endblock %}
+    {% block head %}
+        {{ parent() }}
+        <style type="text/css">
+            .important { color: #336699; }
+        </style>
+    {% endblock %}
+    {% block content %}
+        <h1>Index</h1>
+        <p class="important">
+            Welcome to my awesome homepage.
+        </p>
+    {% endblock %}
+
+The :doc:`extends<tags/extends>` tag is the key here. It tells the template
+engine that this template "extends" another template. When the template system
+evaluates this template, first it locates the parent. The extends tag should
+be the first tag in the template.
+
+Note that since the child template doesn't define the ``footer`` block, the
+value from the parent template is used instead.
+
+It's possible to render the contents of the parent block by using the
+:doc:`parent<functions/parent>` function. This gives back the results of the
+parent block:
+
+.. code-block:: html+twig
+
+    {% block sidebar %}
+        <h3>Table Of Contents</h3>
+        ...
+        {{ parent() }}
+    {% endblock %}
+
+.. tip::
+
+    The documentation page for the :doc:`extends<tags/extends>` tag describes
+    more advanced features like block nesting, scope, dynamic inheritance, and
+    conditional inheritance.
+
+.. note::
+
+    Twig also supports multiple inheritance via "horizontal reuse" with the help
+    of the :doc:`use<tags/use>` tag.
+
+HTML Escaping
+-------------
+
+When generating HTML from templates, there's always a risk that a variable
+will include characters that affect the resulting HTML. There are two
+approaches: manually escaping each variable or automatically escaping
+everything by default.
+
+Twig supports both, automatic escaping is enabled by default.
+
+The automatic escaping strategy can be configured via the
+:ref:`autoescape<environment_options>` option and defaults to ``html``.
+
+Working with Manual Escaping
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+If manual escaping is enabled, it is **your** responsibility to escape variables
+if needed. What to escape? Any variable that comes from an untrusted source.
+
+Escaping works by using the :doc:`escape<filters/escape>` or ``e`` filter:
+
+.. code-block:: twig
+
+    {{ user.username|e }}
+
+By default, the ``escape`` filter uses the ``html`` strategy, but depending on
+the escaping context, you might want to explicitly use an other strategy:
+
+.. code-block:: twig
+
+    {{ user.username|e('js') }}
+    {{ user.username|e('css') }}
+    {{ user.username|e('url') }}
+    {{ user.username|e('html_attr') }}
+
+Working with Automatic Escaping
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+Whether automatic escaping is enabled or not, you can mark a section of a
+template to be escaped or not by using the :doc:`autoescape<tags/autoescape>`
+tag:
+
+.. code-block:: twig
+
+    {% autoescape %}
+        Everything will be automatically escaped in this block (using the HTML strategy)
+    {% endautoescape %}
+
+By default, auto-escaping uses the ``html`` escaping strategy. If you output
+variables in other contexts, you need to explicitly escape them with the
+appropriate escaping strategy:
+
+.. code-block:: twig
+
+    {% autoescape 'js' %}
+        Everything will be automatically escaped in this block (using the JS strategy)
+    {% endautoescape %}
+
+Escaping
+--------
+
+It is sometimes desirable or even necessary to have Twig ignore parts it would
+otherwise handle as variables or blocks. For example if the default syntax is
+used and you want to use ``{{`` as raw string in the template and not start a
+variable you have to use a trick.
+
+The easiest way is to output the variable delimiter (``{{``) by using a variable
+expression:
+
+.. code-block:: twig
+
+    {{ '{{' }}
+
+For bigger sections it makes sense to mark a block
+:doc:`verbatim<tags/verbatim>`.
+
+Macros
+------
+
+Macros are comparable with functions in regular programming languages. They are
+useful to reuse HTML fragments to not repeat yourself. They are described in the
+:doc:`macro<tags/macro>` tag documentation.
+
+.. _twig-expressions:
+
+Expressions
+-----------
+
+Twig allows expressions everywhere.
+
+.. note::
+
+    The operator precedence is as follows, with the lowest-precedence operators
+    listed first: ``?:`` (ternary operator), ``b-and``, ``b-xor``, ``b-or``,
+    ``or``, ``and``, ``==``, ``!=``, ``<=>``, ``<``, ``>``, ``>=``, ``<=``,
+    ``in``, ``matches``, ``starts with``, ``ends with``, ``..``, ``+``, ``-``,
+    ``~``, ``*``, ``/``, ``//``, ``%``, ``is`` (tests), ``**``, ``??``, ``|``
+    (filters), ``[]``, and ``.``:
+
+    .. code-block:: twig
+
+        {% set greeting = 'Hello ' %}
+        {% set name = 'Fabien' %}
+
+        {{ greeting ~ name|lower }}   {# Hello fabien #}
+
+        {# use parenthesis to change precedence #}
+        {{ (greeting ~ name)|lower }} {# hello fabien #}
+
+Literals
+~~~~~~~~
+
+The simplest form of expressions are literals. Literals are representations
+for PHP types such as strings, numbers, and arrays. The following literals
+exist:
+
+* ``"Hello World"``: Everything between two double or single quotes is a
+  string. They are useful whenever you need a string in the template (for
+  example as arguments to function calls, filters or just to extend or include
+  a template). A string can contain a delimiter if it is preceded by a
+  backslash (``\``) -- like in ``'It\'s good'``. If the string contains a
+  backslash (e.g. ``'c:\Program Files'``) escape it by doubling it
+  (e.g. ``'c:\\Program Files'``).
+
+* ``42`` / ``42.23``: Integers and floating point numbers are created by
+  writing the number down. If a dot is present the number is a float,
+  otherwise an integer.
+
+* ``["foo", "bar"]``: Arrays are defined by a sequence of expressions
+  separated by a comma (``,``) and wrapped with squared brackets (``[]``).
+
+* ``{"foo": "bar"}``: Hashes are defined by a list of keys and values
+  separated by a comma (``,``) and wrapped with curly braces (``{}``):
+
+  .. code-block:: twig
+
+    {# keys as string #}
+    { 'foo': 'foo', 'bar': 'bar' }
+
+    {# keys as names (equivalent to the previous hash) #}
+    { foo: 'foo', bar: 'bar' }
+
+    {# keys as integer #}
+    { 2: 'foo', 4: 'bar' }
+
+    {# keys can be omitted if it is the same as the variable name #}
+    { foo }
+    {# is equivalent to the following #}
+    { 'foo': foo }
+
+    {# keys as expressions (the expression must be enclosed into parentheses) #}
+    {% set foo = 'foo' %}
+    { (foo): 'foo', (1 + 1): 'bar', (foo ~ 'b'): 'baz' }
+
+* ``true`` / ``false``: ``true`` represents the true value, ``false``
+  represents the false value.
+
+* ``null``: ``null`` represents no specific value. This is the value returned
+  when a variable does not exist. ``none`` is an alias for ``null``.
+
+Arrays and hashes can be nested:
+
+.. code-block:: twig
+
+    {% set foo = [1, {"foo": "bar"}] %}
+
+.. tip::
+
+    Using double-quoted or single-quoted strings has no impact on performance
+    but :ref:`string interpolation <templates-string-interpolation>` is only
+    supported in double-quoted strings.
+
+Math
+~~~~
+
+Twig allows you to do math in templates; the following operators are supported:
+
+* ``+``: Adds two numbers together (the operands are casted to numbers). ``{{
+  1 + 1 }}`` is ``2``.
+
+* ``-``: Subtracts the second number from the first one. ``{{ 3 - 2 }}`` is
+  ``1``.
+
+* ``/``: Divides two numbers. The returned value will be a floating point
+  number. ``{{ 1 / 2 }}`` is ``{{ 0.5 }}``.
+
+* ``%``: Calculates the remainder of an integer division. ``{{ 11 % 7 }}`` is
+  ``4``.
+
+* ``//``: Divides two numbers and returns the floored integer result. ``{{ 20
+  // 7 }}`` is ``2``, ``{{ -20  // 7 }}`` is ``-3`` (this is just syntactic
+  sugar for the :doc:`round<filters/round>` filter).
+
+* ``*``: Multiplies the left operand with the right one. ``{{ 2 * 2 }}`` would
+  return ``4``.
+
+* ``**``: Raises the left operand to the power of the right operand. ``{{ 2 **
+  3 }}`` would return ``8``.
+
+.. _template_logic:
+
+Logic
+~~~~~
+
+You can combine multiple expressions with the following operators:
+
+* ``and``: Returns true if the left and the right operands are both true.
+
+* ``or``: Returns true if the left or the right operand is true.
+
+* ``not``: Negates a statement.
+
+* ``(expr)``: Groups an expression.
+
+.. note::
+
+    Twig also supports bitwise operators (``b-and``, ``b-xor``, and ``b-or``).
+
+.. note::
+
+    Operators are case sensitive.
+
+Comparisons
+~~~~~~~~~~~
+
+The following comparison operators are supported in any expression: ``==``,
+``!=``, ``<``, ``>``, ``>=``, and ``<=``.
+
+You can also check if a string ``starts with`` or ``ends with`` another
+string:
+
+.. code-block:: twig
+
+    {% if 'Fabien' starts with 'F' %}
+    {% endif %}
+
+    {% if 'Fabien' ends with 'n' %}
+    {% endif %}
+
+.. note::
+
+    For complex string comparisons, the ``matches`` operator allows you to use
+    `regular expressions`_:
+
+    .. code-block:: twig
+
+        {% if phone matches '/^[\\d\\.]+$/' %}
+        {% endif %}
+
+Containment Operator
+~~~~~~~~~~~~~~~~~~~~
+
+The ``in`` operator performs containment test. It returns ``true`` if the left
+operand is contained in the right:
+
+.. code-block:: twig
+
+    {# returns true #}
+
+    {{ 1 in [1, 2, 3] }}
+
+    {{ 'cd' in 'abcde' }}
+
+.. tip::
+
+    You can use this filter to perform a containment test on strings, arrays,
+    or objects implementing the ``Traversable`` interface.
+
+To perform a negative test, use the ``not in`` operator:
+
+.. code-block:: twig
+
+    {% if 1 not in [1, 2, 3] %}
+
+    {# is equivalent to #}
+    {% if not (1 in [1, 2, 3]) %}
+
+Test Operator
+~~~~~~~~~~~~~
+
+The ``is`` operator performs tests. Tests can be used to test a variable against
+a common expression. The right operand is name of the test:
+
+.. code-block:: twig
+
+    {# find out if a variable is odd #}
+
+    {{ name is odd }}
+
+Tests can accept arguments too:
+
+.. code-block:: twig
+
+    {% if post.status is constant('Post::PUBLISHED') %}
+
+Tests can be negated by using the ``is not`` operator:
+
+.. code-block:: twig
+
+    {% if post.status is not constant('Post::PUBLISHED') %}
+
+    {# is equivalent to #}
+    {% if not (post.status is constant('Post::PUBLISHED')) %}
+
+Go to the :doc:`tests<tests/index>` page to learn more about the built-in
+tests.
+
+Other Operators
+~~~~~~~~~~~~~~~
+
+The following operators don't fit into any of the other categories:
+
+* ``|``: Applies a filter.
+
+* ``..``: Creates a sequence based on the operand before and after the operator
+  (this is syntactic sugar for the :doc:`range<functions/range>` function):
+
+  .. code-block:: twig
+
+      {{ 1..5 }}
+
+      {# equivalent to #}
+      {{ range(1, 5) }}
+
+  Note that you must use parentheses when combining it with the filter operator
+  due to the :ref:`operator precedence rules <twig-expressions>`:
+
+  .. code-block:: twig
+
+      (1..5)|join(', ')
+
+* ``~``: Converts all operands into strings and concatenates them. ``{{ "Hello
+  " ~ name ~ "!" }}`` would return (assuming ``name`` is ``'John'``) ``Hello
+  John!``.
+
+* ``.``, ``[]``: Gets an attribute of a variable.
+
+* ``?:``: The ternary operator:
+
+  .. code-block:: twig
+
+      {{ foo ? 'yes' : 'no' }}
+      {{ foo ?: 'no' }} is the same as {{ foo ? foo : 'no' }}
+      {{ foo ? 'yes' }} is the same as {{ foo ? 'yes' : '' }}
+
+* ``??``: The null-coalescing operator:
+
+  .. code-block:: twig
+
+      {# returns the value of foo if it is defined and not null, 'no' otherwise #}
+      {{ foo ?? 'no' }}
+
+.. _templates-string-interpolation:
+
+String Interpolation
+~~~~~~~~~~~~~~~~~~~~
+
+String interpolation (``#{expression}``) allows any valid expression to appear
+within a *double-quoted string*. The result of evaluating that expression is
+inserted into the string:
+
+.. code-block:: twig
+
+    {{ "foo #{bar} baz" }}
+    {{ "foo #{1 + 2} baz" }}
+
+.. _templates-whitespace-control:
+
+Whitespace Control
+------------------
+
+The first newline after a template tag is removed automatically (like in PHP).
+Whitespace is not further modified by the template engine, so each whitespace
+(spaces, tabs, newlines etc.) is returned unchanged.
+
+You can also control whitespace on a per tag level. By using the whitespace
+control modifiers on your tags, you can trim leading and or trailing whitespace.
+
+Twig supports two modifiers:
+
+* *Whitespace trimming* via the ``-`` modifier: Removes all whitespace
+  (including newlines);
+
+* *Line whitespace trimming* via the ``~`` modifier: Removes all whitespace
+  (excluding newlines). Using this modifier on the right disables the default
+  removal of the first newline inherited from PHP.
+
+The modifiers can be used on either side of the tags like in ``{%-`` or ``-%}``
+and they consume all whitespace for that side of the tag. It is possible to use
+the modifiers on one side of a tag or on both sides:
+
+.. code-block:: html+twig
+
+    {% set value = 'no spaces' %}
+    {#- No leading/trailing whitespace -#}
+    {%- if true -%}
+        {{- value -}}
+    {%- endif -%}
+    {# output 'no spaces' #}
+
+    <li>
+        {{ value }}    </li>
+    {# outputs '<li>\n    no spaces    </li>' #}
+
+    <li>
+        {{- value }}    </li>
+    {# outputs '<li>no spaces    </li>' #}
+
+    <li>
+        {{~ value }}    </li>
+    {# outputs '<li>\nno spaces    </li>' #}
+
+.. tip::
+
+    In addition to the whitespace modifiers, Twig also has a ``spaceless`` filter
+    that removes whitespace **between HTML tags**:
+
+    .. code-block:: html+twig
+
+        {% apply spaceless %}
+            <div>
+                <strong>foo bar</strong>
+            </div>
+        {% endapply %}
+
+        {# output will be <div><strong>foo bar</strong></div> #}
+
+Extensions
+----------
+
+Twig can be extended. If you want to create your own extensions, read the
+:ref:`Creating an Extension <creating_extensions>` chapter.
+
+.. _`Twig bundle`:                https://github.com/Anomareh/PHP-Twig.tmbundle
+.. _`Jinja syntax plugin`:        http://jinja.pocoo.org/docs/integration/#vim
+.. _`vim-twig plugin`:            https://github.com/lumiliet/vim-twig
+.. _`Twig syntax plugin`:         http://plugins.netbeans.org/plugin/37069/php-twig
+.. _`Twig plugin`:                https://github.com/pulse00/Twig-Eclipse-Plugin
+.. _`Twig language definition`:   https://github.com/gabrielcorpse/gedit-twig-template-language
+.. _`Twig syntax mode`:           https://github.com/bobthecow/Twig-HTML.mode
+.. _`other Twig syntax mode`:     https://github.com/muxx/Twig-HTML.mode
+.. _`Notepad++ Twig Highlighter`: https://github.com/Banane9/notepadplusplus-twig
+.. _`web-mode.el`:                http://web-mode.org/
+.. _`regular expressions`:        https://secure.php.net/manual/en/pcre.pattern.php
+.. _`PHP-twig for atom`:          https://github.com/reesef/php-twig
+.. _`TwigFiddle`:                 https://twigfiddle.com/
+.. _`Twig pack`:                  https://marketplace.visualstudio.com/items?itemName=bajdzis.vscode-twig-pack
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tests/constant.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tests/constant.rst
new file mode 100644
index 0000000..448c238
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tests/constant.rst
@@ -0,0 +1,19 @@
+``constant``
+============
+
+``constant`` checks if a variable has the exact same value as a constant. You
+can use either global constants or class constants:
+
+.. code-block:: twig
+
+    {% if post.status is constant('Post::PUBLISHED') %}
+        the status attribute is exactly the same as Post::PUBLISHED
+    {% endif %}
+
+You can test constants from object instances as well:
+
+.. code-block:: twig
+
+    {% if post.status is constant('PUBLISHED', post) %}
+        the status attribute is exactly the same as Post::PUBLISHED
+    {% endif %}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tests/defined.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tests/defined.rst
new file mode 100644
index 0000000..234a289
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tests/defined.rst
@@ -0,0 +1,30 @@
+``defined``
+===========
+
+``defined`` checks if a variable is defined in the current context. This is very
+useful if you use the ``strict_variables`` option:
+
+.. code-block:: twig
+
+    {# defined works with variable names #}
+    {% if foo is defined %}
+        ...
+    {% endif %}
+
+    {# and attributes on variables names #}
+    {% if foo.bar is defined %}
+        ...
+    {% endif %}
+
+    {% if foo['bar'] is defined %}
+        ...
+    {% endif %}
+
+When using the ``defined`` test on an expression that uses variables in some
+method calls, be sure that they are all defined first:
+
+.. code-block:: twig
+
+    {% if var is defined and foo.method(var) is defined %}
+        ...
+    {% endif %}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tests/divisibleby.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tests/divisibleby.rst
new file mode 100644
index 0000000..8032d34
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tests/divisibleby.rst
@@ -0,0 +1,10 @@
+``divisible by``
+================
+
+``divisible by`` checks if a variable is divisible by a number:
+
+.. code-block:: twig
+
+    {% if loop.index is divisible by(3) %}
+        ...
+    {% endif %}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tests/empty.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tests/empty.rst
new file mode 100644
index 0000000..0233eca
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tests/empty.rst
@@ -0,0 +1,18 @@
+``empty``
+=========
+
+``empty`` checks if a variable is an empty string, an empty array, an empty
+hash, exactly ``false``, or exactly ``null``.
+
+For objects that implement the ``Countable`` interface, ``empty`` will check the
+return value of the ``count()`` method.
+
+For objects that implement the ``__toString()`` magic method (and not ``Countable``),
+it will check if an empty string is returned.
+
+.. code-block:: twig
+
+    {% if foo is empty %}
+        ...
+    {% endif %}
+
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tests/even.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tests/even.rst
new file mode 100644
index 0000000..2de0de2
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tests/even.rst
@@ -0,0 +1,12 @@
+``even``
+========
+
+``even`` returns ``true`` if the given number is even:
+
+.. code-block:: twig
+
+    {{ var is even }}
+
+.. seealso::
+
+    :doc:`odd<../tests/odd>`
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tests/index.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tests/index.rst
new file mode 100644
index 0000000..c63208e
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tests/index.rst
@@ -0,0 +1,15 @@
+Tests
+=====
+
+.. toctree::
+    :maxdepth: 1
+
+    constant
+    defined
+    divisibleby
+    empty
+    even
+    iterable
+    null
+    odd
+    sameas
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tests/iterable.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tests/iterable.rst
new file mode 100644
index 0000000..4ebfe9d
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tests/iterable.rst
@@ -0,0 +1,16 @@
+``iterable``
+============
+
+``iterable`` checks if a variable is an array or a traversable object:
+
+.. code-block:: twig
+
+    {# evaluates to true if the foo variable is iterable #}
+    {% if users is iterable %}
+        {% for user in users %}
+            Hello {{ user }}!
+        {% endfor %}
+    {% else %}
+        {# users is probably a string #}
+        Hello {{ users }}!
+    {% endif %}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tests/null.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tests/null.rst
new file mode 100644
index 0000000..9ed93f6
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tests/null.rst
@@ -0,0 +1,12 @@
+``null``
+========
+
+``null`` returns ``true`` if the variable is ``null``:
+
+.. code-block:: twig
+
+    {{ var is null }}
+
+.. note::
+
+    ``none`` is an alias for ``null``.
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tests/odd.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tests/odd.rst
new file mode 100644
index 0000000..27fe7e4
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tests/odd.rst
@@ -0,0 +1,12 @@
+``odd``
+=======
+
+``odd`` returns ``true`` if the given number is odd:
+
+.. code-block:: twig
+
+    {{ var is odd }}
+
+.. seealso::
+
+    :doc:`even<../tests/even>`
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tests/sameas.rst b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tests/sameas.rst
new file mode 100644
index 0000000..c092971
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/doc/tests/sameas.rst
@@ -0,0 +1,11 @@
+``same as``
+===========
+
+``same as`` checks if a variable is the same as another variable.
+This is equivalent to ``===`` in PHP:
+
+.. code-block:: twig
+
+    {% if foo.attribute is same as(false) %}
+        the foo attribute really is the 'false' PHP value
+    {% endif %}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/drupal_test.sh b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/drupal_test.sh
new file mode 100755
index 0000000..a25d886
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/drupal_test.sh
@@ -0,0 +1,50 @@
+#!/bin/bash
+
+set -x
+set -e
+
+REPO=`pwd`
+cd /tmp
+rm -rf drupal-twig-test
+composer create-project --no-interaction drupal/recommended-project:9.1.x-dev drupal-twig-test
+cd drupal-twig-test
+(cd vendor/twig && rm -rf twig && ln -sf $REPO twig)
+php ./web/core/scripts/drupal install --no-interaction demo_umami > output
+perl -p -i -e 's/^([A-Za-z]+)\: (.+)$/export DRUPAL_\1=\2/' output
+source output
+#echo '$config["system.logging"]["error_level"] = "verbose";' >> web/sites/default/settings.php
+
+wget https://get.symfony.com/cli/installer -O - | bash
+export PATH="$HOME/.symfony/bin:$PATH"
+symfony server:start -d --no-tls
+
+curl -OLsS https://get.blackfire.io/blackfire-player.phar
+chmod +x blackfire-player.phar
+cat > drupal-tests.bkf <<EOF
+name "Drupal tests"
+
+scenario
+    name "homepage"
+    set name "admin"
+    set pass "pass"
+
+    visit url('/')
+        expect status_code() == 200
+    click link('Articles')
+        expect status_code() == 200
+    click link('Dairy-free and delicious milk chocolate')
+        expect body() matches "/Dairy\-free milk chocolate is made in largely the same way as regular chocolate/"
+        expect status_code() == 200
+    click link('Log in')
+        expect status_code() == 200
+    submit button("Log in")
+        param name name
+        param pass pass
+        expect status_code() == 303
+    follow
+        expect status_code() == 200
+    click link('Structure')
+        expect status_code() == 200
+EOF
+./blackfire-player.phar run drupal-tests.bkf --endpoint=`symfony var:export SYMFONY_DEFAULT_ROUTE_URL` --variable name=$DRUPAL_Username --variable pass=$DRUPAL_Password
+symfony server:stop
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Cache/CacheInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Cache/CacheInterface.php
new file mode 100644
index 0000000..6e8c409
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Cache/CacheInterface.php
@@ -0,0 +1,46 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Cache;
+
+/**
+ * Interface implemented by cache classes.
+ *
+ * It is highly recommended to always store templates on the filesystem to
+ * benefit from the PHP opcode cache. This interface is mostly useful if you
+ * need to implement a custom strategy for storing templates on the filesystem.
+ *
+ * @author Andrew Tch <andrew@noop.lv>
+ */
+interface CacheInterface
+{
+    /**
+     * Generates a cache key for the given template class name.
+     */
+    public function generateKey(string $name, string $className): string;
+
+    /**
+     * Writes the compiled template to cache.
+     *
+     * @param string $content The template representation as a PHP class
+     */
+    public function write(string $key, string $content): void;
+
+    /**
+     * Loads a template from the cache.
+     */
+    public function load(string $key): void;
+
+    /**
+     * Returns the modification timestamp of a key.
+     */
+    public function getTimestamp(string $key): int;
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Cache/FilesystemCache.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Cache/FilesystemCache.php
new file mode 100644
index 0000000..a9f1f46
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Cache/FilesystemCache.php
@@ -0,0 +1,87 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Cache;
+
+/**
+ * Implements a cache on the filesystem.
+ *
+ * @author Andrew Tch <andrew@noop.lv>
+ */
+class FilesystemCache implements CacheInterface
+{
+    public const FORCE_BYTECODE_INVALIDATION = 1;
+
+    private $directory;
+    private $options;
+
+    public function __construct(string $directory, int $options = 0)
+    {
+        $this->directory = rtrim($directory, '\/').'/';
+        $this->options = $options;
+    }
+
+    public function generateKey(string $name, string $className): string
+    {
+        $hash = hash('sha256', $className);
+
+        return $this->directory.$hash[0].$hash[1].'/'.$hash.'.php';
+    }
+
+    public function load(string $key): void
+    {
+        if (is_file($key)) {
+            @include_once $key;
+        }
+    }
+
+    public function write(string $key, string $content): void
+    {
+        $dir = \dirname($key);
+        if (!is_dir($dir)) {
+            if (false === @mkdir($dir, 0777, true)) {
+                clearstatcache(true, $dir);
+                if (!is_dir($dir)) {
+                    throw new \RuntimeException(sprintf('Unable to create the cache directory (%s).', $dir));
+                }
+            }
+        } elseif (!is_writable($dir)) {
+            throw new \RuntimeException(sprintf('Unable to write in the cache directory (%s).', $dir));
+        }
+
+        $tmpFile = tempnam($dir, basename($key));
+        if (false !== @file_put_contents($tmpFile, $content) && @rename($tmpFile, $key)) {
+            @chmod($key, 0666 & ~umask());
+
+            if (self::FORCE_BYTECODE_INVALIDATION == ($this->options & self::FORCE_BYTECODE_INVALIDATION)) {
+                // Compile cached file into bytecode cache
+                if (\function_exists('opcache_invalidate') && filter_var(ini_get('opcache.enable'), \FILTER_VALIDATE_BOOLEAN)) {
+                    @opcache_invalidate($key, true);
+                } elseif (\function_exists('apc_compile_file')) {
+                    apc_compile_file($key);
+                }
+            }
+
+            return;
+        }
+
+        throw new \RuntimeException(sprintf('Failed to write cache file "%s".', $key));
+    }
+
+    public function getTimestamp(string $key): int
+    {
+        if (!is_file($key)) {
+            return 0;
+        }
+
+        return (int) @filemtime($key);
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Cache/NullCache.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Cache/NullCache.php
new file mode 100644
index 0000000..8d20d59
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Cache/NullCache.php
@@ -0,0 +1,38 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Cache;
+
+/**
+ * Implements a no-cache strategy.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+final class NullCache implements CacheInterface
+{
+    public function generateKey(string $name, string $className): string
+    {
+        return '';
+    }
+
+    public function write(string $key, string $content): void
+    {
+    }
+
+    public function load(string $key): void
+    {
+    }
+
+    public function getTimestamp(string $key): int
+    {
+        return 0;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Compiler.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Compiler.php
new file mode 100644
index 0000000..b3f1eca
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Compiler.php
@@ -0,0 +1,214 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig;
+
+use Twig\Node\Node;
+
+/**
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class Compiler
+{
+    private $lastLine;
+    private $source;
+    private $indentation;
+    private $env;
+    private $debugInfo = [];
+    private $sourceOffset;
+    private $sourceLine;
+    private $varNameSalt = 0;
+
+    public function __construct(Environment $env)
+    {
+        $this->env = $env;
+    }
+
+    public function getEnvironment(): Environment
+    {
+        return $this->env;
+    }
+
+    public function getSource(): string
+    {
+        return $this->source;
+    }
+
+    /**
+     * @return $this
+     */
+    public function compile(Node $node, int $indentation = 0)
+    {
+        $this->lastLine = null;
+        $this->source = '';
+        $this->debugInfo = [];
+        $this->sourceOffset = 0;
+        // source code starts at 1 (as we then increment it when we encounter new lines)
+        $this->sourceLine = 1;
+        $this->indentation = $indentation;
+        $this->varNameSalt = 0;
+
+        $node->compile($this);
+
+        return $this;
+    }
+
+    /**
+     * @return $this
+     */
+    public function subcompile(Node $node, bool $raw = true)
+    {
+        if (false === $raw) {
+            $this->source .= str_repeat(' ', $this->indentation * 4);
+        }
+
+        $node->compile($this);
+
+        return $this;
+    }
+
+    /**
+     * Adds a raw string to the compiled code.
+     *
+     * @return $this
+     */
+    public function raw(string $string)
+    {
+        $this->source .= $string;
+
+        return $this;
+    }
+
+    /**
+     * Writes a string to the compiled code by adding indentation.
+     *
+     * @return $this
+     */
+    public function write(...$strings)
+    {
+        foreach ($strings as $string) {
+            $this->source .= str_repeat(' ', $this->indentation * 4).$string;
+        }
+
+        return $this;
+    }
+
+    /**
+     * Adds a quoted string to the compiled code.
+     *
+     * @return $this
+     */
+    public function string(string $value)
+    {
+        $this->source .= sprintf('"%s"', addcslashes($value, "\0\t\"\$\\"));
+
+        return $this;
+    }
+
+    /**
+     * Returns a PHP representation of a given value.
+     *
+     * @return $this
+     */
+    public function repr($value)
+    {
+        if (\is_int($value) || \is_float($value)) {
+            if (false !== $locale = setlocale(\LC_NUMERIC, '0')) {
+                setlocale(\LC_NUMERIC, 'C');
+            }
+
+            $this->raw(var_export($value, true));
+
+            if (false !== $locale) {
+                setlocale(\LC_NUMERIC, $locale);
+            }
+        } elseif (null === $value) {
+            $this->raw('null');
+        } elseif (\is_bool($value)) {
+            $this->raw($value ? 'true' : 'false');
+        } elseif (\is_array($value)) {
+            $this->raw('array(');
+            $first = true;
+            foreach ($value as $key => $v) {
+                if (!$first) {
+                    $this->raw(', ');
+                }
+                $first = false;
+                $this->repr($key);
+                $this->raw(' => ');
+                $this->repr($v);
+            }
+            $this->raw(')');
+        } else {
+            $this->string($value);
+        }
+
+        return $this;
+    }
+
+    /**
+     * @return $this
+     */
+    public function addDebugInfo(Node $node)
+    {
+        if ($node->getTemplateLine() != $this->lastLine) {
+            $this->write(sprintf("// line %d\n", $node->getTemplateLine()));
+
+            $this->sourceLine += substr_count($this->source, "\n", $this->sourceOffset);
+            $this->sourceOffset = \strlen($this->source);
+            $this->debugInfo[$this->sourceLine] = $node->getTemplateLine();
+
+            $this->lastLine = $node->getTemplateLine();
+        }
+
+        return $this;
+    }
+
+    public function getDebugInfo(): array
+    {
+        ksort($this->debugInfo);
+
+        return $this->debugInfo;
+    }
+
+    /**
+     * @return $this
+     */
+    public function indent(int $step = 1)
+    {
+        $this->indentation += $step;
+
+        return $this;
+    }
+
+    /**
+     * @return $this
+     *
+     * @throws \LogicException When trying to outdent too much so the indentation would become negative
+     */
+    public function outdent(int $step = 1)
+    {
+        // can't outdent by more steps than the current indentation level
+        if ($this->indentation < $step) {
+            throw new \LogicException('Unable to call outdent() as the indentation would become negative.');
+        }
+
+        $this->indentation -= $step;
+
+        return $this;
+    }
+
+    public function getVarName(): string
+    {
+        return sprintf('__internal_%s', hash('sha256', __METHOD__.$this->varNameSalt++));
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Environment.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Environment.php
new file mode 100644
index 0000000..889df49
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Environment.php
@@ -0,0 +1,814 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig;
+
+use Twig\Cache\CacheInterface;
+use Twig\Cache\FilesystemCache;
+use Twig\Cache\NullCache;
+use Twig\Error\Error;
+use Twig\Error\LoaderError;
+use Twig\Error\RuntimeError;
+use Twig\Error\SyntaxError;
+use Twig\Extension\CoreExtension;
+use Twig\Extension\EscaperExtension;
+use Twig\Extension\ExtensionInterface;
+use Twig\Extension\OptimizerExtension;
+use Twig\Loader\ArrayLoader;
+use Twig\Loader\ChainLoader;
+use Twig\Loader\LoaderInterface;
+use Twig\Node\ModuleNode;
+use Twig\Node\Node;
+use Twig\NodeVisitor\NodeVisitorInterface;
+use Twig\RuntimeLoader\RuntimeLoaderInterface;
+use Twig\TokenParser\TokenParserInterface;
+
+/**
+ * Stores the Twig configuration and renders templates.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class Environment
+{
+    public const VERSION = '3.3.2';
+    public const VERSION_ID = 30302;
+    public const MAJOR_VERSION = 3;
+    public const MINOR_VERSION = 3;
+    public const RELEASE_VERSION = 2;
+    public const EXTRA_VERSION = '';
+
+    private $charset;
+    private $loader;
+    private $debug;
+    private $autoReload;
+    private $cache;
+    private $lexer;
+    private $parser;
+    private $compiler;
+    private $globals = [];
+    private $resolvedGlobals;
+    private $loadedTemplates;
+    private $strictVariables;
+    private $templateClassPrefix = '__TwigTemplate_';
+    private $originalCache;
+    private $extensionSet;
+    private $runtimeLoaders = [];
+    private $runtimes = [];
+    private $optionsHash;
+
+    /**
+     * Constructor.
+     *
+     * Available options:
+     *
+     *  * debug: When set to true, it automatically set "auto_reload" to true as
+     *           well (default to false).
+     *
+     *  * charset: The charset used by the templates (default to UTF-8).
+     *
+     *  * cache: An absolute path where to store the compiled templates,
+     *           a \Twig\Cache\CacheInterface implementation,
+     *           or false to disable compilation cache (default).
+     *
+     *  * auto_reload: Whether to reload the template if the original source changed.
+     *                 If you don't provide the auto_reload option, it will be
+     *                 determined automatically based on the debug value.
+     *
+     *  * strict_variables: Whether to ignore invalid variables in templates
+     *                      (default to false).
+     *
+     *  * autoescape: Whether to enable auto-escaping (default to html):
+     *                  * false: disable auto-escaping
+     *                  * html, js: set the autoescaping to one of the supported strategies
+     *                  * name: set the autoescaping strategy based on the template name extension
+     *                  * PHP callback: a PHP callback that returns an escaping strategy based on the template "name"
+     *
+     *  * optimizations: A flag that indicates which optimizations to apply
+     *                   (default to -1 which means that all optimizations are enabled;
+     *                   set it to 0 to disable).
+     */
+    public function __construct(LoaderInterface $loader, $options = [])
+    {
+        $this->setLoader($loader);
+
+        $options = array_merge([
+            'debug' => false,
+            'charset' => 'UTF-8',
+            'strict_variables' => false,
+            'autoescape' => 'html',
+            'cache' => false,
+            'auto_reload' => null,
+            'optimizations' => -1,
+        ], $options);
+
+        $this->debug = (bool) $options['debug'];
+        $this->setCharset($options['charset'] ?? 'UTF-8');
+        $this->autoReload = null === $options['auto_reload'] ? $this->debug : (bool) $options['auto_reload'];
+        $this->strictVariables = (bool) $options['strict_variables'];
+        $this->setCache($options['cache']);
+        $this->extensionSet = new ExtensionSet();
+
+        $this->addExtension(new CoreExtension());
+        $this->addExtension(new EscaperExtension($options['autoescape']));
+        $this->addExtension(new OptimizerExtension($options['optimizations']));
+    }
+
+    /**
+     * Enables debugging mode.
+     */
+    public function enableDebug()
+    {
+        $this->debug = true;
+        $this->updateOptionsHash();
+    }
+
+    /**
+     * Disables debugging mode.
+     */
+    public function disableDebug()
+    {
+        $this->debug = false;
+        $this->updateOptionsHash();
+    }
+
+    /**
+     * Checks if debug mode is enabled.
+     *
+     * @return bool true if debug mode is enabled, false otherwise
+     */
+    public function isDebug()
+    {
+        return $this->debug;
+    }
+
+    /**
+     * Enables the auto_reload option.
+     */
+    public function enableAutoReload()
+    {
+        $this->autoReload = true;
+    }
+
+    /**
+     * Disables the auto_reload option.
+     */
+    public function disableAutoReload()
+    {
+        $this->autoReload = false;
+    }
+
+    /**
+     * Checks if the auto_reload option is enabled.
+     *
+     * @return bool true if auto_reload is enabled, false otherwise
+     */
+    public function isAutoReload()
+    {
+        return $this->autoReload;
+    }
+
+    /**
+     * Enables the strict_variables option.
+     */
+    public function enableStrictVariables()
+    {
+        $this->strictVariables = true;
+        $this->updateOptionsHash();
+    }
+
+    /**
+     * Disables the strict_variables option.
+     */
+    public function disableStrictVariables()
+    {
+        $this->strictVariables = false;
+        $this->updateOptionsHash();
+    }
+
+    /**
+     * Checks if the strict_variables option is enabled.
+     *
+     * @return bool true if strict_variables is enabled, false otherwise
+     */
+    public function isStrictVariables()
+    {
+        return $this->strictVariables;
+    }
+
+    /**
+     * Gets the current cache implementation.
+     *
+     * @param bool $original Whether to return the original cache option or the real cache instance
+     *
+     * @return CacheInterface|string|false A Twig\Cache\CacheInterface implementation,
+     *                                     an absolute path to the compiled templates,
+     *                                     or false to disable cache
+     */
+    public function getCache($original = true)
+    {
+        return $original ? $this->originalCache : $this->cache;
+    }
+
+    /**
+     * Sets the current cache implementation.
+     *
+     * @param CacheInterface|string|false $cache A Twig\Cache\CacheInterface implementation,
+     *                                           an absolute path to the compiled templates,
+     *                                           or false to disable cache
+     */
+    public function setCache($cache)
+    {
+        if (\is_string($cache)) {
+            $this->originalCache = $cache;
+            $this->cache = new FilesystemCache($cache);
+        } elseif (false === $cache) {
+            $this->originalCache = $cache;
+            $this->cache = new NullCache();
+        } elseif ($cache instanceof CacheInterface) {
+            $this->originalCache = $this->cache = $cache;
+        } else {
+            throw new \LogicException('Cache can only be a string, false, or a \Twig\Cache\CacheInterface implementation.');
+        }
+    }
+
+    /**
+     * Gets the template class associated with the given string.
+     *
+     * The generated template class is based on the following parameters:
+     *
+     *  * The cache key for the given template;
+     *  * The currently enabled extensions;
+     *  * Whether the Twig C extension is available or not;
+     *  * PHP version;
+     *  * Twig version;
+     *  * Options with what environment was created.
+     *
+     * @param string   $name  The name for which to calculate the template class name
+     * @param int|null $index The index if it is an embedded template
+     *
+     * @internal
+     */
+    public function getTemplateClass(string $name, int $index = null): string
+    {
+        $key = $this->getLoader()->getCacheKey($name).$this->optionsHash;
+
+        return $this->templateClassPrefix.hash('sha256', $key).(null === $index ? '' : '___'.$index);
+    }
+
+    /**
+     * Renders a template.
+     *
+     * @param string|TemplateWrapper $name The template name
+     *
+     * @throws LoaderError  When the template cannot be found
+     * @throws SyntaxError  When an error occurred during compilation
+     * @throws RuntimeError When an error occurred during rendering
+     */
+    public function render($name, array $context = []): string
+    {
+        return $this->load($name)->render($context);
+    }
+
+    /**
+     * Displays a template.
+     *
+     * @param string|TemplateWrapper $name The template name
+     *
+     * @throws LoaderError  When the template cannot be found
+     * @throws SyntaxError  When an error occurred during compilation
+     * @throws RuntimeError When an error occurred during rendering
+     */
+    public function display($name, array $context = []): void
+    {
+        $this->load($name)->display($context);
+    }
+
+    /**
+     * Loads a template.
+     *
+     * @param string|TemplateWrapper $name The template name
+     *
+     * @throws LoaderError  When the template cannot be found
+     * @throws RuntimeError When a previously generated cache is corrupted
+     * @throws SyntaxError  When an error occurred during compilation
+     */
+    public function load($name): TemplateWrapper
+    {
+        if ($name instanceof TemplateWrapper) {
+            return $name;
+        }
+
+        return new TemplateWrapper($this, $this->loadTemplate($this->getTemplateClass($name), $name));
+    }
+
+    /**
+     * Loads a template internal representation.
+     *
+     * This method is for internal use only and should never be called
+     * directly.
+     *
+     * @param string $name  The template name
+     * @param int    $index The index if it is an embedded template
+     *
+     * @throws LoaderError  When the template cannot be found
+     * @throws RuntimeError When a previously generated cache is corrupted
+     * @throws SyntaxError  When an error occurred during compilation
+     *
+     * @internal
+     */
+    public function loadTemplate(string $cls, string $name, int $index = null): Template
+    {
+        $mainCls = $cls;
+        if (null !== $index) {
+            $cls .= '___'.$index;
+        }
+
+        if (isset($this->loadedTemplates[$cls])) {
+            return $this->loadedTemplates[$cls];
+        }
+
+        if (!class_exists($cls, false)) {
+            $key = $this->cache->generateKey($name, $mainCls);
+
+            if (!$this->isAutoReload() || $this->isTemplateFresh($name, $this->cache->getTimestamp($key))) {
+                $this->cache->load($key);
+            }
+
+            $source = null;
+            if (!class_exists($cls, false)) {
+                $source = $this->getLoader()->getSourceContext($name);
+                $content = $this->compileSource($source);
+                $this->cache->write($key, $content);
+                $this->cache->load($key);
+
+                if (!class_exists($mainCls, false)) {
+                    /* Last line of defense if either $this->bcWriteCacheFile was used,
+                     * $this->cache is implemented as a no-op or we have a race condition
+                     * where the cache was cleared between the above calls to write to and load from
+                     * the cache.
+                     */
+                    eval('?>'.$content);
+                }
+
+                if (!class_exists($cls, false)) {
+                    throw new RuntimeError(sprintf('Failed to load Twig template "%s", index "%s": cache might be corrupted.', $name, $index), -1, $source);
+                }
+            }
+        }
+
+        $this->extensionSet->initRuntime();
+
+        return $this->loadedTemplates[$cls] = new $cls($this);
+    }
+
+    /**
+     * Creates a template from source.
+     *
+     * This method should not be used as a generic way to load templates.
+     *
+     * @param string $template The template source
+     * @param string $name     An optional name of the template to be used in error messages
+     *
+     * @throws LoaderError When the template cannot be found
+     * @throws SyntaxError When an error occurred during compilation
+     */
+    public function createTemplate(string $template, string $name = null): TemplateWrapper
+    {
+        $hash = hash('sha256', $template, false);
+        if (null !== $name) {
+            $name = sprintf('%s (string template %s)', $name, $hash);
+        } else {
+            $name = sprintf('__string_template__%s', $hash);
+        }
+
+        $loader = new ChainLoader([
+            new ArrayLoader([$name => $template]),
+            $current = $this->getLoader(),
+        ]);
+
+        $this->setLoader($loader);
+        try {
+            return new TemplateWrapper($this, $this->loadTemplate($this->getTemplateClass($name), $name));
+        } finally {
+            $this->setLoader($current);
+        }
+    }
+
+    /**
+     * Returns true if the template is still fresh.
+     *
+     * Besides checking the loader for freshness information,
+     * this method also checks if the enabled extensions have
+     * not changed.
+     *
+     * @param int $time The last modification time of the cached template
+     */
+    public function isTemplateFresh(string $name, int $time): bool
+    {
+        return $this->extensionSet->getLastModified() <= $time && $this->getLoader()->isFresh($name, $time);
+    }
+
+    /**
+     * Tries to load a template consecutively from an array.
+     *
+     * Similar to load() but it also accepts instances of \Twig\Template and
+     * \Twig\TemplateWrapper, and an array of templates where each is tried to be loaded.
+     *
+     * @param string|TemplateWrapper|array $names A template or an array of templates to try consecutively
+     *
+     * @throws LoaderError When none of the templates can be found
+     * @throws SyntaxError When an error occurred during compilation
+     */
+    public function resolveTemplate($names): TemplateWrapper
+    {
+        if (!\is_array($names)) {
+            return $this->load($names);
+        }
+
+        foreach ($names as $name) {
+            try {
+                return $this->load($name);
+            } catch (LoaderError $e) {
+            }
+        }
+
+        throw new LoaderError(sprintf('Unable to find one of the following templates: "%s".', implode('", "', $names)));
+    }
+
+    public function setLexer(Lexer $lexer)
+    {
+        $this->lexer = $lexer;
+    }
+
+    /**
+     * @throws SyntaxError When the code is syntactically wrong
+     */
+    public function tokenize(Source $source): TokenStream
+    {
+        if (null === $this->lexer) {
+            $this->lexer = new Lexer($this);
+        }
+
+        return $this->lexer->tokenize($source);
+    }
+
+    public function setParser(Parser $parser)
+    {
+        $this->parser = $parser;
+    }
+
+    /**
+     * Converts a token stream to a node tree.
+     *
+     * @throws SyntaxError When the token stream is syntactically or semantically wrong
+     */
+    public function parse(TokenStream $stream): ModuleNode
+    {
+        if (null === $this->parser) {
+            $this->parser = new Parser($this);
+        }
+
+        return $this->parser->parse($stream);
+    }
+
+    public function setCompiler(Compiler $compiler)
+    {
+        $this->compiler = $compiler;
+    }
+
+    /**
+     * Compiles a node and returns the PHP code.
+     */
+    public function compile(Node $node): string
+    {
+        if (null === $this->compiler) {
+            $this->compiler = new Compiler($this);
+        }
+
+        return $this->compiler->compile($node)->getSource();
+    }
+
+    /**
+     * Compiles a template source code.
+     *
+     * @throws SyntaxError When there was an error during tokenizing, parsing or compiling
+     */
+    public function compileSource(Source $source): string
+    {
+        try {
+            return $this->compile($this->parse($this->tokenize($source)));
+        } catch (Error $e) {
+            $e->setSourceContext($source);
+            throw $e;
+        } catch (\Exception $e) {
+            throw new SyntaxError(sprintf('An exception has been thrown during the compilation of a template ("%s").', $e->getMessage()), -1, $source, $e);
+        }
+    }
+
+    public function setLoader(LoaderInterface $loader)
+    {
+        $this->loader = $loader;
+    }
+
+    public function getLoader(): LoaderInterface
+    {
+        return $this->loader;
+    }
+
+    public function setCharset(string $charset)
+    {
+        if ('UTF8' === $charset = null === $charset ? null : strtoupper($charset)) {
+            // iconv on Windows requires "UTF-8" instead of "UTF8"
+            $charset = 'UTF-8';
+        }
+
+        $this->charset = $charset;
+    }
+
+    public function getCharset(): string
+    {
+        return $this->charset;
+    }
+
+    public function hasExtension(string $class): bool
+    {
+        return $this->extensionSet->hasExtension($class);
+    }
+
+    public function addRuntimeLoader(RuntimeLoaderInterface $loader)
+    {
+        $this->runtimeLoaders[] = $loader;
+    }
+
+    public function getExtension(string $class): ExtensionInterface
+    {
+        return $this->extensionSet->getExtension($class);
+    }
+
+    /**
+     * Returns the runtime implementation of a Twig element (filter/function/tag/test).
+     *
+     * @param string $class A runtime class name
+     *
+     * @return object The runtime implementation
+     *
+     * @throws RuntimeError When the template cannot be found
+     */
+    public function getRuntime(string $class)
+    {
+        if (isset($this->runtimes[$class])) {
+            return $this->runtimes[$class];
+        }
+
+        foreach ($this->runtimeLoaders as $loader) {
+            if (null !== $runtime = $loader->load($class)) {
+                return $this->runtimes[$class] = $runtime;
+            }
+        }
+
+        throw new RuntimeError(sprintf('Unable to load the "%s" runtime.', $class));
+    }
+
+    public function addExtension(ExtensionInterface $extension)
+    {
+        $this->extensionSet->addExtension($extension);
+        $this->updateOptionsHash();
+    }
+
+    /**
+     * @param ExtensionInterface[] $extensions An array of extensions
+     */
+    public function setExtensions(array $extensions)
+    {
+        $this->extensionSet->setExtensions($extensions);
+        $this->updateOptionsHash();
+    }
+
+    /**
+     * @return ExtensionInterface[] An array of extensions (keys are for internal usage only and should not be relied on)
+     */
+    public function getExtensions(): array
+    {
+        return $this->extensionSet->getExtensions();
+    }
+
+    public function addTokenParser(TokenParserInterface $parser)
+    {
+        $this->extensionSet->addTokenParser($parser);
+    }
+
+    /**
+     * @return TokenParserInterface[]
+     *
+     * @internal
+     */
+    public function getTokenParsers(): array
+    {
+        return $this->extensionSet->getTokenParsers();
+    }
+
+    /**
+     * @internal
+     */
+    public function getTokenParser(string $name): ?TokenParserInterface
+    {
+        return $this->extensionSet->getTokenParser($name);
+    }
+
+    public function registerUndefinedTokenParserCallback(callable $callable): void
+    {
+        $this->extensionSet->registerUndefinedTokenParserCallback($callable);
+    }
+
+    public function addNodeVisitor(NodeVisitorInterface $visitor)
+    {
+        $this->extensionSet->addNodeVisitor($visitor);
+    }
+
+    /**
+     * @return NodeVisitorInterface[]
+     *
+     * @internal
+     */
+    public function getNodeVisitors(): array
+    {
+        return $this->extensionSet->getNodeVisitors();
+    }
+
+    public function addFilter(TwigFilter $filter)
+    {
+        $this->extensionSet->addFilter($filter);
+    }
+
+    /**
+     * @internal
+     */
+    public function getFilter(string $name): ?TwigFilter
+    {
+        return $this->extensionSet->getFilter($name);
+    }
+
+    public function registerUndefinedFilterCallback(callable $callable): void
+    {
+        $this->extensionSet->registerUndefinedFilterCallback($callable);
+    }
+
+    /**
+     * Gets the registered Filters.
+     *
+     * Be warned that this method cannot return filters defined with registerUndefinedFilterCallback.
+     *
+     * @return TwigFilter[]
+     *
+     * @see registerUndefinedFilterCallback
+     *
+     * @internal
+     */
+    public function getFilters(): array
+    {
+        return $this->extensionSet->getFilters();
+    }
+
+    public function addTest(TwigTest $test)
+    {
+        $this->extensionSet->addTest($test);
+    }
+
+    /**
+     * @return TwigTest[]
+     *
+     * @internal
+     */
+    public function getTests(): array
+    {
+        return $this->extensionSet->getTests();
+    }
+
+    /**
+     * @internal
+     */
+    public function getTest(string $name): ?TwigTest
+    {
+        return $this->extensionSet->getTest($name);
+    }
+
+    public function addFunction(TwigFunction $function)
+    {
+        $this->extensionSet->addFunction($function);
+    }
+
+    /**
+     * @internal
+     */
+    public function getFunction(string $name): ?TwigFunction
+    {
+        return $this->extensionSet->getFunction($name);
+    }
+
+    public function registerUndefinedFunctionCallback(callable $callable): void
+    {
+        $this->extensionSet->registerUndefinedFunctionCallback($callable);
+    }
+
+    /**
+     * Gets registered functions.
+     *
+     * Be warned that this method cannot return functions defined with registerUndefinedFunctionCallback.
+     *
+     * @return TwigFunction[]
+     *
+     * @see registerUndefinedFunctionCallback
+     *
+     * @internal
+     */
+    public function getFunctions(): array
+    {
+        return $this->extensionSet->getFunctions();
+    }
+
+    /**
+     * Registers a Global.
+     *
+     * New globals can be added before compiling or rendering a template;
+     * but after, you can only update existing globals.
+     *
+     * @param mixed $value The global value
+     */
+    public function addGlobal(string $name, $value)
+    {
+        if ($this->extensionSet->isInitialized() && !\array_key_exists($name, $this->getGlobals())) {
+            throw new \LogicException(sprintf('Unable to add global "%s" as the runtime or the extensions have already been initialized.', $name));
+        }
+
+        if (null !== $this->resolvedGlobals) {
+            $this->resolvedGlobals[$name] = $value;
+        } else {
+            $this->globals[$name] = $value;
+        }
+    }
+
+    /**
+     * @internal
+     */
+    public function getGlobals(): array
+    {
+        if ($this->extensionSet->isInitialized()) {
+            if (null === $this->resolvedGlobals) {
+                $this->resolvedGlobals = array_merge($this->extensionSet->getGlobals(), $this->globals);
+            }
+
+            return $this->resolvedGlobals;
+        }
+
+        return array_merge($this->extensionSet->getGlobals(), $this->globals);
+    }
+
+    public function mergeGlobals(array $context): array
+    {
+        // we don't use array_merge as the context being generally
+        // bigger than globals, this code is faster.
+        foreach ($this->getGlobals() as $key => $value) {
+            if (!\array_key_exists($key, $context)) {
+                $context[$key] = $value;
+            }
+        }
+
+        return $context;
+    }
+
+    /**
+     * @internal
+     */
+    public function getUnaryOperators(): array
+    {
+        return $this->extensionSet->getUnaryOperators();
+    }
+
+    /**
+     * @internal
+     */
+    public function getBinaryOperators(): array
+    {
+        return $this->extensionSet->getBinaryOperators();
+    }
+
+    private function updateOptionsHash(): void
+    {
+        $this->optionsHash = implode(':', [
+            $this->extensionSet->getSignature(),
+            \PHP_MAJOR_VERSION,
+            \PHP_MINOR_VERSION,
+            self::VERSION,
+            (int) $this->debug,
+            (int) $this->strictVariables,
+        ]);
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Error/Error.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Error/Error.php
new file mode 100644
index 0000000..a68be65
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Error/Error.php
@@ -0,0 +1,227 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Error;
+
+use Twig\Source;
+use Twig\Template;
+
+/**
+ * Twig base exception.
+ *
+ * This exception class and its children must only be used when
+ * an error occurs during the loading of a template, when a syntax error
+ * is detected in a template, or when rendering a template. Other
+ * errors must use regular PHP exception classes (like when the template
+ * cache directory is not writable for instance).
+ *
+ * To help debugging template issues, this class tracks the original template
+ * name and line where the error occurred.
+ *
+ * Whenever possible, you must set these information (original template name
+ * and line number) yourself by passing them to the constructor. If some or all
+ * these information are not available from where you throw the exception, then
+ * this class will guess them automatically (when the line number is set to -1
+ * and/or the name is set to null). As this is a costly operation, this
+ * can be disabled by passing false for both the name and the line number
+ * when creating a new instance of this class.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class Error extends \Exception
+{
+    private $lineno;
+    private $name;
+    private $rawMessage;
+    private $sourcePath;
+    private $sourceCode;
+
+    /**
+     * Constructor.
+     *
+     * By default, automatic guessing is enabled.
+     *
+     * @param string      $message The error message
+     * @param int         $lineno  The template line where the error occurred
+     * @param Source|null $source  The source context where the error occurred
+     */
+    public function __construct(string $message, int $lineno = -1, Source $source = null, \Exception $previous = null)
+    {
+        parent::__construct('', 0, $previous);
+
+        if (null === $source) {
+            $name = null;
+        } else {
+            $name = $source->getName();
+            $this->sourceCode = $source->getCode();
+            $this->sourcePath = $source->getPath();
+        }
+
+        $this->lineno = $lineno;
+        $this->name = $name;
+        $this->rawMessage = $message;
+        $this->updateRepr();
+    }
+
+    public function getRawMessage(): string
+    {
+        return $this->rawMessage;
+    }
+
+    public function getTemplateLine(): int
+    {
+        return $this->lineno;
+    }
+
+    public function setTemplateLine(int $lineno): void
+    {
+        $this->lineno = $lineno;
+
+        $this->updateRepr();
+    }
+
+    public function getSourceContext(): ?Source
+    {
+        return $this->name ? new Source($this->sourceCode, $this->name, $this->sourcePath) : null;
+    }
+
+    public function setSourceContext(Source $source = null): void
+    {
+        if (null === $source) {
+            $this->sourceCode = $this->name = $this->sourcePath = null;
+        } else {
+            $this->sourceCode = $source->getCode();
+            $this->name = $source->getName();
+            $this->sourcePath = $source->getPath();
+        }
+
+        $this->updateRepr();
+    }
+
+    public function guess(): void
+    {
+        $this->guessTemplateInfo();
+        $this->updateRepr();
+    }
+
+    public function appendMessage($rawMessage): void
+    {
+        $this->rawMessage .= $rawMessage;
+        $this->updateRepr();
+    }
+
+    private function updateRepr(): void
+    {
+        $this->message = $this->rawMessage;
+
+        if ($this->sourcePath && $this->lineno > 0) {
+            $this->file = $this->sourcePath;
+            $this->line = $this->lineno;
+
+            return;
+        }
+
+        $dot = false;
+        if ('.' === substr($this->message, -1)) {
+            $this->message = substr($this->message, 0, -1);
+            $dot = true;
+        }
+
+        $questionMark = false;
+        if ('?' === substr($this->message, -1)) {
+            $this->message = substr($this->message, 0, -1);
+            $questionMark = true;
+        }
+
+        if ($this->name) {
+            if (\is_string($this->name) || (\is_object($this->name) && method_exists($this->name, '__toString'))) {
+                $name = sprintf('"%s"', $this->name);
+            } else {
+                $name = json_encode($this->name);
+            }
+            $this->message .= sprintf(' in %s', $name);
+        }
+
+        if ($this->lineno && $this->lineno >= 0) {
+            $this->message .= sprintf(' at line %d', $this->lineno);
+        }
+
+        if ($dot) {
+            $this->message .= '.';
+        }
+
+        if ($questionMark) {
+            $this->message .= '?';
+        }
+    }
+
+    private function guessTemplateInfo(): void
+    {
+        $template = null;
+        $templateClass = null;
+
+        $backtrace = debug_backtrace(\DEBUG_BACKTRACE_IGNORE_ARGS | \DEBUG_BACKTRACE_PROVIDE_OBJECT);
+        foreach ($backtrace as $trace) {
+            if (isset($trace['object']) && $trace['object'] instanceof Template) {
+                $currentClass = \get_class($trace['object']);
+                $isEmbedContainer = null === $templateClass ? false : 0 === strpos($templateClass, $currentClass);
+                if (null === $this->name || ($this->name == $trace['object']->getTemplateName() && !$isEmbedContainer)) {
+                    $template = $trace['object'];
+                    $templateClass = \get_class($trace['object']);
+                }
+            }
+        }
+
+        // update template name
+        if (null !== $template && null === $this->name) {
+            $this->name = $template->getTemplateName();
+        }
+
+        // update template path if any
+        if (null !== $template && null === $this->sourcePath) {
+            $src = $template->getSourceContext();
+            $this->sourceCode = $src->getCode();
+            $this->sourcePath = $src->getPath();
+        }
+
+        if (null === $template || $this->lineno > -1) {
+            return;
+        }
+
+        $r = new \ReflectionObject($template);
+        $file = $r->getFileName();
+
+        $exceptions = [$e = $this];
+        while ($e = $e->getPrevious()) {
+            $exceptions[] = $e;
+        }
+
+        while ($e = array_pop($exceptions)) {
+            $traces = $e->getTrace();
+            array_unshift($traces, ['file' => $e->getFile(), 'line' => $e->getLine()]);
+
+            while ($trace = array_shift($traces)) {
+                if (!isset($trace['file']) || !isset($trace['line']) || $file != $trace['file']) {
+                    continue;
+                }
+
+                foreach ($template->getDebugInfo() as $codeLine => $templateLine) {
+                    if ($codeLine <= $trace['line']) {
+                        // update template line
+                        $this->lineno = $templateLine;
+
+                        return;
+                    }
+                }
+            }
+        }
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Error/LoaderError.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Error/LoaderError.php
new file mode 100644
index 0000000..7c8c23c
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Error/LoaderError.php
@@ -0,0 +1,21 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Error;
+
+/**
+ * Exception thrown when an error occurs during template loading.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class LoaderError extends Error
+{
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Error/RuntimeError.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Error/RuntimeError.php
new file mode 100644
index 0000000..f6b8476
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Error/RuntimeError.php
@@ -0,0 +1,22 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Error;
+
+/**
+ * Exception thrown when an error occurs at runtime.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class RuntimeError extends Error
+{
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Error/SyntaxError.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Error/SyntaxError.php
new file mode 100644
index 0000000..726b330
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Error/SyntaxError.php
@@ -0,0 +1,46 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Error;
+
+/**
+ * \Exception thrown when a syntax error occurs during lexing or parsing of a template.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class SyntaxError extends Error
+{
+    /**
+     * Tweaks the error message to include suggestions.
+     *
+     * @param string $name  The original name of the item that does not exist
+     * @param array  $items An array of possible items
+     */
+    public function addSuggestions(string $name, array $items): void
+    {
+        $alternatives = [];
+        foreach ($items as $item) {
+            $lev = levenshtein($name, $item);
+            if ($lev <= \strlen($name) / 3 || false !== strpos($item, $name)) {
+                $alternatives[$item] = $lev;
+            }
+        }
+
+        if (!$alternatives) {
+            return;
+        }
+
+        asort($alternatives);
+
+        $this->appendMessage(sprintf(' Did you mean "%s"?', implode('", "', array_keys($alternatives))));
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/ExpressionParser.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/ExpressionParser.php
new file mode 100644
index 0000000..66acddf
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/ExpressionParser.php
@@ -0,0 +1,825 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig;
+
+use Twig\Error\SyntaxError;
+use Twig\Node\Expression\AbstractExpression;
+use Twig\Node\Expression\ArrayExpression;
+use Twig\Node\Expression\ArrowFunctionExpression;
+use Twig\Node\Expression\AssignNameExpression;
+use Twig\Node\Expression\Binary\ConcatBinary;
+use Twig\Node\Expression\BlockReferenceExpression;
+use Twig\Node\Expression\ConditionalExpression;
+use Twig\Node\Expression\ConstantExpression;
+use Twig\Node\Expression\GetAttrExpression;
+use Twig\Node\Expression\MethodCallExpression;
+use Twig\Node\Expression\NameExpression;
+use Twig\Node\Expression\ParentExpression;
+use Twig\Node\Expression\TestExpression;
+use Twig\Node\Expression\Unary\NegUnary;
+use Twig\Node\Expression\Unary\NotUnary;
+use Twig\Node\Expression\Unary\PosUnary;
+use Twig\Node\Node;
+
+/**
+ * Parses expressions.
+ *
+ * This parser implements a "Precedence climbing" algorithm.
+ *
+ * @see https://www.engr.mun.ca/~theo/Misc/exp_parsing.htm
+ * @see https://en.wikipedia.org/wiki/Operator-precedence_parser
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ *
+ * @internal
+ */
+class ExpressionParser
+{
+    public const OPERATOR_LEFT = 1;
+    public const OPERATOR_RIGHT = 2;
+
+    private $parser;
+    private $env;
+    private $unaryOperators;
+    private $binaryOperators;
+
+    public function __construct(Parser $parser, Environment $env)
+    {
+        $this->parser = $parser;
+        $this->env = $env;
+        $this->unaryOperators = $env->getUnaryOperators();
+        $this->binaryOperators = $env->getBinaryOperators();
+    }
+
+    public function parseExpression($precedence = 0, $allowArrow = false)
+    {
+        if ($allowArrow && $arrow = $this->parseArrow()) {
+            return $arrow;
+        }
+
+        $expr = $this->getPrimary();
+        $token = $this->parser->getCurrentToken();
+        while ($this->isBinary($token) && $this->binaryOperators[$token->getValue()]['precedence'] >= $precedence) {
+            $op = $this->binaryOperators[$token->getValue()];
+            $this->parser->getStream()->next();
+
+            if ('is not' === $token->getValue()) {
+                $expr = $this->parseNotTestExpression($expr);
+            } elseif ('is' === $token->getValue()) {
+                $expr = $this->parseTestExpression($expr);
+            } elseif (isset($op['callable'])) {
+                $expr = $op['callable']($this->parser, $expr);
+            } else {
+                $expr1 = $this->parseExpression(self::OPERATOR_LEFT === $op['associativity'] ? $op['precedence'] + 1 : $op['precedence']);
+                $class = $op['class'];
+                $expr = new $class($expr, $expr1, $token->getLine());
+            }
+
+            $token = $this->parser->getCurrentToken();
+        }
+
+        if (0 === $precedence) {
+            return $this->parseConditionalExpression($expr);
+        }
+
+        return $expr;
+    }
+
+    /**
+     * @return ArrowFunctionExpression|null
+     */
+    private function parseArrow()
+    {
+        $stream = $this->parser->getStream();
+
+        // short array syntax (one argument, no parentheses)?
+        if ($stream->look(1)->test(/* Token::ARROW_TYPE */ 12)) {
+            $line = $stream->getCurrent()->getLine();
+            $token = $stream->expect(/* Token::NAME_TYPE */ 5);
+            $names = [new AssignNameExpression($token->getValue(), $token->getLine())];
+            $stream->expect(/* Token::ARROW_TYPE */ 12);
+
+            return new ArrowFunctionExpression($this->parseExpression(0), new Node($names), $line);
+        }
+
+        // first, determine if we are parsing an arrow function by finding => (long form)
+        $i = 0;
+        if (!$stream->look($i)->test(/* Token::PUNCTUATION_TYPE */ 9, '(')) {
+            return null;
+        }
+        ++$i;
+        while (true) {
+            // variable name
+            ++$i;
+            if (!$stream->look($i)->test(/* Token::PUNCTUATION_TYPE */ 9, ',')) {
+                break;
+            }
+            ++$i;
+        }
+        if (!$stream->look($i)->test(/* Token::PUNCTUATION_TYPE */ 9, ')')) {
+            return null;
+        }
+        ++$i;
+        if (!$stream->look($i)->test(/* Token::ARROW_TYPE */ 12)) {
+            return null;
+        }
+
+        // yes, let's parse it properly
+        $token = $stream->expect(/* Token::PUNCTUATION_TYPE */ 9, '(');
+        $line = $token->getLine();
+
+        $names = [];
+        while (true) {
+            $token = $stream->expect(/* Token::NAME_TYPE */ 5);
+            $names[] = new AssignNameExpression($token->getValue(), $token->getLine());
+
+            if (!$stream->nextIf(/* Token::PUNCTUATION_TYPE */ 9, ',')) {
+                break;
+            }
+        }
+        $stream->expect(/* Token::PUNCTUATION_TYPE */ 9, ')');
+        $stream->expect(/* Token::ARROW_TYPE */ 12);
+
+        return new ArrowFunctionExpression($this->parseExpression(0), new Node($names), $line);
+    }
+
+    private function getPrimary(): AbstractExpression
+    {
+        $token = $this->parser->getCurrentToken();
+
+        if ($this->isUnary($token)) {
+            $operator = $this->unaryOperators[$token->getValue()];
+            $this->parser->getStream()->next();
+            $expr = $this->parseExpression($operator['precedence']);
+            $class = $operator['class'];
+
+            return $this->parsePostfixExpression(new $class($expr, $token->getLine()));
+        } elseif ($token->test(/* Token::PUNCTUATION_TYPE */ 9, '(')) {
+            $this->parser->getStream()->next();
+            $expr = $this->parseExpression();
+            $this->parser->getStream()->expect(/* Token::PUNCTUATION_TYPE */ 9, ')', 'An opened parenthesis is not properly closed');
+
+            return $this->parsePostfixExpression($expr);
+        }
+
+        return $this->parsePrimaryExpression();
+    }
+
+    private function parseConditionalExpression($expr): AbstractExpression
+    {
+        while ($this->parser->getStream()->nextIf(/* Token::PUNCTUATION_TYPE */ 9, '?')) {
+            if (!$this->parser->getStream()->nextIf(/* Token::PUNCTUATION_TYPE */ 9, ':')) {
+                $expr2 = $this->parseExpression();
+                if ($this->parser->getStream()->nextIf(/* Token::PUNCTUATION_TYPE */ 9, ':')) {
+                    $expr3 = $this->parseExpression();
+                } else {
+                    $expr3 = new ConstantExpression('', $this->parser->getCurrentToken()->getLine());
+                }
+            } else {
+                $expr2 = $expr;
+                $expr3 = $this->parseExpression();
+            }
+
+            $expr = new ConditionalExpression($expr, $expr2, $expr3, $this->parser->getCurrentToken()->getLine());
+        }
+
+        return $expr;
+    }
+
+    private function isUnary(Token $token): bool
+    {
+        return $token->test(/* Token::OPERATOR_TYPE */ 8) && isset($this->unaryOperators[$token->getValue()]);
+    }
+
+    private function isBinary(Token $token): bool
+    {
+        return $token->test(/* Token::OPERATOR_TYPE */ 8) && isset($this->binaryOperators[$token->getValue()]);
+    }
+
+    public function parsePrimaryExpression()
+    {
+        $token = $this->parser->getCurrentToken();
+        switch ($token->getType()) {
+            case /* Token::NAME_TYPE */ 5:
+                $this->parser->getStream()->next();
+                switch ($token->getValue()) {
+                    case 'true':
+                    case 'TRUE':
+                        $node = new ConstantExpression(true, $token->getLine());
+                        break;
+
+                    case 'false':
+                    case 'FALSE':
+                        $node = new ConstantExpression(false, $token->getLine());
+                        break;
+
+                    case 'none':
+                    case 'NONE':
+                    case 'null':
+                    case 'NULL':
+                        $node = new ConstantExpression(null, $token->getLine());
+                        break;
+
+                    default:
+                        if ('(' === $this->parser->getCurrentToken()->getValue()) {
+                            $node = $this->getFunctionNode($token->getValue(), $token->getLine());
+                        } else {
+                            $node = new NameExpression($token->getValue(), $token->getLine());
+                        }
+                }
+                break;
+
+            case /* Token::NUMBER_TYPE */ 6:
+                $this->parser->getStream()->next();
+                $node = new ConstantExpression($token->getValue(), $token->getLine());
+                break;
+
+            case /* Token::STRING_TYPE */ 7:
+            case /* Token::INTERPOLATION_START_TYPE */ 10:
+                $node = $this->parseStringExpression();
+                break;
+
+            case /* Token::OPERATOR_TYPE */ 8:
+                if (preg_match(Lexer::REGEX_NAME, $token->getValue(), $matches) && $matches[0] == $token->getValue()) {
+                    // in this context, string operators are variable names
+                    $this->parser->getStream()->next();
+                    $node = new NameExpression($token->getValue(), $token->getLine());
+                    break;
+                }
+
+                if (isset($this->unaryOperators[$token->getValue()])) {
+                    $class = $this->unaryOperators[$token->getValue()]['class'];
+                    if (!\in_array($class, [NegUnary::class, PosUnary::class])) {
+                        throw new SyntaxError(sprintf('Unexpected unary operator "%s".', $token->getValue()), $token->getLine(), $this->parser->getStream()->getSourceContext());
+                    }
+
+                    $this->parser->getStream()->next();
+                    $expr = $this->parsePrimaryExpression();
+
+                    $node = new $class($expr, $token->getLine());
+                    break;
+                }
+
+                // no break
+            default:
+                if ($token->test(/* Token::PUNCTUATION_TYPE */ 9, '[')) {
+                    $node = $this->parseArrayExpression();
+                } elseif ($token->test(/* Token::PUNCTUATION_TYPE */ 9, '{')) {
+                    $node = $this->parseHashExpression();
+                } elseif ($token->test(/* Token::OPERATOR_TYPE */ 8, '=') && ('==' === $this->parser->getStream()->look(-1)->getValue() || '!=' === $this->parser->getStream()->look(-1)->getValue())) {
+                    throw new SyntaxError(sprintf('Unexpected operator of value "%s". Did you try to use "===" or "!==" for strict comparison? Use "is same as(value)" instead.', $token->getValue()), $token->getLine(), $this->parser->getStream()->getSourceContext());
+                } else {
+                    throw new SyntaxError(sprintf('Unexpected token "%s" of value "%s".', Token::typeToEnglish($token->getType()), $token->getValue()), $token->getLine(), $this->parser->getStream()->getSourceContext());
+                }
+        }
+
+        return $this->parsePostfixExpression($node);
+    }
+
+    public function parseStringExpression()
+    {
+        $stream = $this->parser->getStream();
+
+        $nodes = [];
+        // a string cannot be followed by another string in a single expression
+        $nextCanBeString = true;
+        while (true) {
+            if ($nextCanBeString && $token = $stream->nextIf(/* Token::STRING_TYPE */ 7)) {
+                $nodes[] = new ConstantExpression($token->getValue(), $token->getLine());
+                $nextCanBeString = false;
+            } elseif ($stream->nextIf(/* Token::INTERPOLATION_START_TYPE */ 10)) {
+                $nodes[] = $this->parseExpression();
+                $stream->expect(/* Token::INTERPOLATION_END_TYPE */ 11);
+                $nextCanBeString = true;
+            } else {
+                break;
+            }
+        }
+
+        $expr = array_shift($nodes);
+        foreach ($nodes as $node) {
+            $expr = new ConcatBinary($expr, $node, $node->getTemplateLine());
+        }
+
+        return $expr;
+    }
+
+    public function parseArrayExpression()
+    {
+        $stream = $this->parser->getStream();
+        $stream->expect(/* Token::PUNCTUATION_TYPE */ 9, '[', 'An array element was expected');
+
+        $node = new ArrayExpression([], $stream->getCurrent()->getLine());
+        $first = true;
+        while (!$stream->test(/* Token::PUNCTUATION_TYPE */ 9, ']')) {
+            if (!$first) {
+                $stream->expect(/* Token::PUNCTUATION_TYPE */ 9, ',', 'An array element must be followed by a comma');
+
+                // trailing ,?
+                if ($stream->test(/* Token::PUNCTUATION_TYPE */ 9, ']')) {
+                    break;
+                }
+            }
+            $first = false;
+
+            $node->addElement($this->parseExpression());
+        }
+        $stream->expect(/* Token::PUNCTUATION_TYPE */ 9, ']', 'An opened array is not properly closed');
+
+        return $node;
+    }
+
+    public function parseHashExpression()
+    {
+        $stream = $this->parser->getStream();
+        $stream->expect(/* Token::PUNCTUATION_TYPE */ 9, '{', 'A hash element was expected');
+
+        $node = new ArrayExpression([], $stream->getCurrent()->getLine());
+        $first = true;
+        while (!$stream->test(/* Token::PUNCTUATION_TYPE */ 9, '}')) {
+            if (!$first) {
+                $stream->expect(/* Token::PUNCTUATION_TYPE */ 9, ',', 'A hash value must be followed by a comma');
+
+                // trailing ,?
+                if ($stream->test(/* Token::PUNCTUATION_TYPE */ 9, '}')) {
+                    break;
+                }
+            }
+            $first = false;
+
+            // a hash key can be:
+            //
+            //  * a number -- 12
+            //  * a string -- 'a'
+            //  * a name, which is equivalent to a string -- a
+            //  * an expression, which must be enclosed in parentheses -- (1 + 2)
+            if ($token = $stream->nextIf(/* Token::NAME_TYPE */ 5)) {
+                $key = new ConstantExpression($token->getValue(), $token->getLine());
+
+                // {a} is a shortcut for {a:a}
+                if ($stream->test(Token::PUNCTUATION_TYPE, [',', '}'])) {
+                    $value = new NameExpression($key->getAttribute('value'), $key->getTemplateLine());
+                    $node->addElement($value, $key);
+                    continue;
+                }
+            } elseif (($token = $stream->nextIf(/* Token::STRING_TYPE */ 7)) || $token = $stream->nextIf(/* Token::NUMBER_TYPE */ 6)) {
+                $key = new ConstantExpression($token->getValue(), $token->getLine());
+            } elseif ($stream->test(/* Token::PUNCTUATION_TYPE */ 9, '(')) {
+                $key = $this->parseExpression();
+            } else {
+                $current = $stream->getCurrent();
+
+                throw new SyntaxError(sprintf('A hash key must be a quoted string, a number, a name, or an expression enclosed in parentheses (unexpected token "%s" of value "%s".', Token::typeToEnglish($current->getType()), $current->getValue()), $current->getLine(), $stream->getSourceContext());
+            }
+
+            $stream->expect(/* Token::PUNCTUATION_TYPE */ 9, ':', 'A hash key must be followed by a colon (:)');
+            $value = $this->parseExpression();
+
+            $node->addElement($value, $key);
+        }
+        $stream->expect(/* Token::PUNCTUATION_TYPE */ 9, '}', 'An opened hash is not properly closed');
+
+        return $node;
+    }
+
+    public function parsePostfixExpression($node)
+    {
+        while (true) {
+            $token = $this->parser->getCurrentToken();
+            if (/* Token::PUNCTUATION_TYPE */ 9 == $token->getType()) {
+                if ('.' == $token->getValue() || '[' == $token->getValue()) {
+                    $node = $this->parseSubscriptExpression($node);
+                } elseif ('|' == $token->getValue()) {
+                    $node = $this->parseFilterExpression($node);
+                } else {
+                    break;
+                }
+            } else {
+                break;
+            }
+        }
+
+        return $node;
+    }
+
+    public function getFunctionNode($name, $line)
+    {
+        switch ($name) {
+            case 'parent':
+                $this->parseArguments();
+                if (!\count($this->parser->getBlockStack())) {
+                    throw new SyntaxError('Calling "parent" outside a block is forbidden.', $line, $this->parser->getStream()->getSourceContext());
+                }
+
+                if (!$this->parser->getParent() && !$this->parser->hasTraits()) {
+                    throw new SyntaxError('Calling "parent" on a template that does not extend nor "use" another template is forbidden.', $line, $this->parser->getStream()->getSourceContext());
+                }
+
+                return new ParentExpression($this->parser->peekBlockStack(), $line);
+            case 'block':
+                $args = $this->parseArguments();
+                if (\count($args) < 1) {
+                    throw new SyntaxError('The "block" function takes one argument (the block name).', $line, $this->parser->getStream()->getSourceContext());
+                }
+
+                return new BlockReferenceExpression($args->getNode(0), \count($args) > 1 ? $args->getNode(1) : null, $line);
+            case 'attribute':
+                $args = $this->parseArguments();
+                if (\count($args) < 2) {
+                    throw new SyntaxError('The "attribute" function takes at least two arguments (the variable and the attributes).', $line, $this->parser->getStream()->getSourceContext());
+                }
+
+                return new GetAttrExpression($args->getNode(0), $args->getNode(1), \count($args) > 2 ? $args->getNode(2) : null, Template::ANY_CALL, $line);
+            default:
+                if (null !== $alias = $this->parser->getImportedSymbol('function', $name)) {
+                    $arguments = new ArrayExpression([], $line);
+                    foreach ($this->parseArguments() as $n) {
+                        $arguments->addElement($n);
+                    }
+
+                    $node = new MethodCallExpression($alias['node'], $alias['name'], $arguments, $line);
+                    $node->setAttribute('safe', true);
+
+                    return $node;
+                }
+
+                $args = $this->parseArguments(true);
+                $class = $this->getFunctionNodeClass($name, $line);
+
+                return new $class($name, $args, $line);
+        }
+    }
+
+    public function parseSubscriptExpression($node)
+    {
+        $stream = $this->parser->getStream();
+        $token = $stream->next();
+        $lineno = $token->getLine();
+        $arguments = new ArrayExpression([], $lineno);
+        $type = Template::ANY_CALL;
+        if ('.' == $token->getValue()) {
+            $token = $stream->next();
+            if (
+                /* Token::NAME_TYPE */ 5 == $token->getType()
+                ||
+                /* Token::NUMBER_TYPE */ 6 == $token->getType()
+                ||
+                (/* Token::OPERATOR_TYPE */ 8 == $token->getType() && preg_match(Lexer::REGEX_NAME, $token->getValue()))
+            ) {
+                $arg = new ConstantExpression($token->getValue(), $lineno);
+
+                if ($stream->test(/* Token::PUNCTUATION_TYPE */ 9, '(')) {
+                    $type = Template::METHOD_CALL;
+                    foreach ($this->parseArguments() as $n) {
+                        $arguments->addElement($n);
+                    }
+                }
+            } else {
+                throw new SyntaxError('Expected name or number.', $lineno, $stream->getSourceContext());
+            }
+
+            if ($node instanceof NameExpression && null !== $this->parser->getImportedSymbol('template', $node->getAttribute('name'))) {
+                if (!$arg instanceof ConstantExpression) {
+                    throw new SyntaxError(sprintf('Dynamic macro names are not supported (called on "%s").', $node->getAttribute('name')), $token->getLine(), $stream->getSourceContext());
+                }
+
+                $name = $arg->getAttribute('value');
+
+                $node = new MethodCallExpression($node, 'macro_'.$name, $arguments, $lineno);
+                $node->setAttribute('safe', true);
+
+                return $node;
+            }
+        } else {
+            $type = Template::ARRAY_CALL;
+
+            // slice?
+            $slice = false;
+            if ($stream->test(/* Token::PUNCTUATION_TYPE */ 9, ':')) {
+                $slice = true;
+                $arg = new ConstantExpression(0, $token->getLine());
+            } else {
+                $arg = $this->parseExpression();
+            }
+
+            if ($stream->nextIf(/* Token::PUNCTUATION_TYPE */ 9, ':')) {
+                $slice = true;
+            }
+
+            if ($slice) {
+                if ($stream->test(/* Token::PUNCTUATION_TYPE */ 9, ']')) {
+                    $length = new ConstantExpression(null, $token->getLine());
+                } else {
+                    $length = $this->parseExpression();
+                }
+
+                $class = $this->getFilterNodeClass('slice', $token->getLine());
+                $arguments = new Node([$arg, $length]);
+                $filter = new $class($node, new ConstantExpression('slice', $token->getLine()), $arguments, $token->getLine());
+
+                $stream->expect(/* Token::PUNCTUATION_TYPE */ 9, ']');
+
+                return $filter;
+            }
+
+            $stream->expect(/* Token::PUNCTUATION_TYPE */ 9, ']');
+        }
+
+        return new GetAttrExpression($node, $arg, $arguments, $type, $lineno);
+    }
+
+    public function parseFilterExpression($node)
+    {
+        $this->parser->getStream()->next();
+
+        return $this->parseFilterExpressionRaw($node);
+    }
+
+    public function parseFilterExpressionRaw($node, $tag = null)
+    {
+        while (true) {
+            $token = $this->parser->getStream()->expect(/* Token::NAME_TYPE */ 5);
+
+            $name = new ConstantExpression($token->getValue(), $token->getLine());
+            if (!$this->parser->getStream()->test(/* Token::PUNCTUATION_TYPE */ 9, '(')) {
+                $arguments = new Node();
+            } else {
+                $arguments = $this->parseArguments(true, false, true);
+            }
+
+            $class = $this->getFilterNodeClass($name->getAttribute('value'), $token->getLine());
+
+            $node = new $class($node, $name, $arguments, $token->getLine(), $tag);
+
+            if (!$this->parser->getStream()->test(/* Token::PUNCTUATION_TYPE */ 9, '|')) {
+                break;
+            }
+
+            $this->parser->getStream()->next();
+        }
+
+        return $node;
+    }
+
+    /**
+     * Parses arguments.
+     *
+     * @param bool $namedArguments Whether to allow named arguments or not
+     * @param bool $definition     Whether we are parsing arguments for a function definition
+     *
+     * @return Node
+     *
+     * @throws SyntaxError
+     */
+    public function parseArguments($namedArguments = false, $definition = false, $allowArrow = false)
+    {
+        $args = [];
+        $stream = $this->parser->getStream();
+
+        $stream->expect(/* Token::PUNCTUATION_TYPE */ 9, '(', 'A list of arguments must begin with an opening parenthesis');
+        while (!$stream->test(/* Token::PUNCTUATION_TYPE */ 9, ')')) {
+            if (!empty($args)) {
+                $stream->expect(/* Token::PUNCTUATION_TYPE */ 9, ',', 'Arguments must be separated by a comma');
+
+                // if the comma above was a trailing comma, early exit the argument parse loop
+                if ($stream->test(/* Token::PUNCTUATION_TYPE */ 9, ')')) {
+                    break;
+                }
+            }
+
+            if ($definition) {
+                $token = $stream->expect(/* Token::NAME_TYPE */ 5, null, 'An argument must be a name');
+                $value = new NameExpression($token->getValue(), $this->parser->getCurrentToken()->getLine());
+            } else {
+                $value = $this->parseExpression(0, $allowArrow);
+            }
+
+            $name = null;
+            if ($namedArguments && $token = $stream->nextIf(/* Token::OPERATOR_TYPE */ 8, '=')) {
+                if (!$value instanceof NameExpression) {
+                    throw new SyntaxError(sprintf('A parameter name must be a string, "%s" given.', \get_class($value)), $token->getLine(), $stream->getSourceContext());
+                }
+                $name = $value->getAttribute('name');
+
+                if ($definition) {
+                    $value = $this->parsePrimaryExpression();
+
+                    if (!$this->checkConstantExpression($value)) {
+                        throw new SyntaxError('A default value for an argument must be a constant (a boolean, a string, a number, or an array).', $token->getLine(), $stream->getSourceContext());
+                    }
+                } else {
+                    $value = $this->parseExpression(0, $allowArrow);
+                }
+            }
+
+            if ($definition) {
+                if (null === $name) {
+                    $name = $value->getAttribute('name');
+                    $value = new ConstantExpression(null, $this->parser->getCurrentToken()->getLine());
+                }
+                $args[$name] = $value;
+            } else {
+                if (null === $name) {
+                    $args[] = $value;
+                } else {
+                    $args[$name] = $value;
+                }
+            }
+        }
+        $stream->expect(/* Token::PUNCTUATION_TYPE */ 9, ')', 'A list of arguments must be closed by a parenthesis');
+
+        return new Node($args);
+    }
+
+    public function parseAssignmentExpression()
+    {
+        $stream = $this->parser->getStream();
+        $targets = [];
+        while (true) {
+            $token = $this->parser->getCurrentToken();
+            if ($stream->test(/* Token::OPERATOR_TYPE */ 8) && preg_match(Lexer::REGEX_NAME, $token->getValue())) {
+                // in this context, string operators are variable names
+                $this->parser->getStream()->next();
+            } else {
+                $stream->expect(/* Token::NAME_TYPE */ 5, null, 'Only variables can be assigned to');
+            }
+            $value = $token->getValue();
+            if (\in_array(strtr($value, 'ABCDEFGHIJKLMNOPQRSTUVWXYZ', 'abcdefghijklmnopqrstuvwxyz'), ['true', 'false', 'none', 'null'])) {
+                throw new SyntaxError(sprintf('You cannot assign a value to "%s".', $value), $token->getLine(), $stream->getSourceContext());
+            }
+            $targets[] = new AssignNameExpression($value, $token->getLine());
+
+            if (!$stream->nextIf(/* Token::PUNCTUATION_TYPE */ 9, ',')) {
+                break;
+            }
+        }
+
+        return new Node($targets);
+    }
+
+    public function parseMultitargetExpression()
+    {
+        $targets = [];
+        while (true) {
+            $targets[] = $this->parseExpression();
+            if (!$this->parser->getStream()->nextIf(/* Token::PUNCTUATION_TYPE */ 9, ',')) {
+                break;
+            }
+        }
+
+        return new Node($targets);
+    }
+
+    private function parseNotTestExpression(Node $node): NotUnary
+    {
+        return new NotUnary($this->parseTestExpression($node), $this->parser->getCurrentToken()->getLine());
+    }
+
+    private function parseTestExpression(Node $node): TestExpression
+    {
+        $stream = $this->parser->getStream();
+        list($name, $test) = $this->getTest($node->getTemplateLine());
+
+        $class = $this->getTestNodeClass($test);
+        $arguments = null;
+        if ($stream->test(/* Token::PUNCTUATION_TYPE */ 9, '(')) {
+            $arguments = $this->parseArguments(true);
+        } elseif ($test->hasOneMandatoryArgument()) {
+            $arguments = new Node([0 => $this->parsePrimaryExpression()]);
+        }
+
+        if ('defined' === $name && $node instanceof NameExpression && null !== $alias = $this->parser->getImportedSymbol('function', $node->getAttribute('name'))) {
+            $node = new MethodCallExpression($alias['node'], $alias['name'], new ArrayExpression([], $node->getTemplateLine()), $node->getTemplateLine());
+            $node->setAttribute('safe', true);
+        }
+
+        return new $class($node, $name, $arguments, $this->parser->getCurrentToken()->getLine());
+    }
+
+    private function getTest(int $line): array
+    {
+        $stream = $this->parser->getStream();
+        $name = $stream->expect(/* Token::NAME_TYPE */ 5)->getValue();
+
+        if ($test = $this->env->getTest($name)) {
+            return [$name, $test];
+        }
+
+        if ($stream->test(/* Token::NAME_TYPE */ 5)) {
+            // try 2-words tests
+            $name = $name.' '.$this->parser->getCurrentToken()->getValue();
+
+            if ($test = $this->env->getTest($name)) {
+                $stream->next();
+
+                return [$name, $test];
+            }
+        }
+
+        $e = new SyntaxError(sprintf('Unknown "%s" test.', $name), $line, $stream->getSourceContext());
+        $e->addSuggestions($name, array_keys($this->env->getTests()));
+
+        throw $e;
+    }
+
+    private function getTestNodeClass(TwigTest $test): string
+    {
+        if ($test->isDeprecated()) {
+            $stream = $this->parser->getStream();
+            $message = sprintf('Twig Test "%s" is deprecated', $test->getName());
+
+            if ($test->getDeprecatedVersion()) {
+                $message .= sprintf(' since version %s', $test->getDeprecatedVersion());
+            }
+            if ($test->getAlternative()) {
+                $message .= sprintf('. Use "%s" instead', $test->getAlternative());
+            }
+            $src = $stream->getSourceContext();
+            $message .= sprintf(' in %s at line %d.', $src->getPath() ?: $src->getName(), $stream->getCurrent()->getLine());
+
+            @trigger_error($message, \E_USER_DEPRECATED);
+        }
+
+        return $test->getNodeClass();
+    }
+
+    private function getFunctionNodeClass(string $name, int $line): string
+    {
+        if (!$function = $this->env->getFunction($name)) {
+            $e = new SyntaxError(sprintf('Unknown "%s" function.', $name), $line, $this->parser->getStream()->getSourceContext());
+            $e->addSuggestions($name, array_keys($this->env->getFunctions()));
+
+            throw $e;
+        }
+
+        if ($function->isDeprecated()) {
+            $message = sprintf('Twig Function "%s" is deprecated', $function->getName());
+            if ($function->getDeprecatedVersion()) {
+                $message .= sprintf(' since version %s', $function->getDeprecatedVersion());
+            }
+            if ($function->getAlternative()) {
+                $message .= sprintf('. Use "%s" instead', $function->getAlternative());
+            }
+            $src = $this->parser->getStream()->getSourceContext();
+            $message .= sprintf(' in %s at line %d.', $src->getPath() ?: $src->getName(), $line);
+
+            @trigger_error($message, \E_USER_DEPRECATED);
+        }
+
+        return $function->getNodeClass();
+    }
+
+    private function getFilterNodeClass(string $name, int $line): string
+    {
+        if (!$filter = $this->env->getFilter($name)) {
+            $e = new SyntaxError(sprintf('Unknown "%s" filter.', $name), $line, $this->parser->getStream()->getSourceContext());
+            $e->addSuggestions($name, array_keys($this->env->getFilters()));
+
+            throw $e;
+        }
+
+        if ($filter->isDeprecated()) {
+            $message = sprintf('Twig Filter "%s" is deprecated', $filter->getName());
+            if ($filter->getDeprecatedVersion()) {
+                $message .= sprintf(' since version %s', $filter->getDeprecatedVersion());
+            }
+            if ($filter->getAlternative()) {
+                $message .= sprintf('. Use "%s" instead', $filter->getAlternative());
+            }
+            $src = $this->parser->getStream()->getSourceContext();
+            $message .= sprintf(' in %s at line %d.', $src->getPath() ?: $src->getName(), $line);
+
+            @trigger_error($message, \E_USER_DEPRECATED);
+        }
+
+        return $filter->getNodeClass();
+    }
+
+    // checks that the node only contains "constant" elements
+    private function checkConstantExpression(Node $node): bool
+    {
+        if (!($node instanceof ConstantExpression || $node instanceof ArrayExpression
+            || $node instanceof NegUnary || $node instanceof PosUnary
+        )) {
+            return false;
+        }
+
+        foreach ($node as $n) {
+            if (!$this->checkConstantExpression($n)) {
+                return false;
+            }
+        }
+
+        return true;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Extension/AbstractExtension.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Extension/AbstractExtension.php
new file mode 100644
index 0000000..422925f
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Extension/AbstractExtension.php
@@ -0,0 +1,45 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Extension;
+
+abstract class AbstractExtension implements ExtensionInterface
+{
+    public function getTokenParsers()
+    {
+        return [];
+    }
+
+    public function getNodeVisitors()
+    {
+        return [];
+    }
+
+    public function getFilters()
+    {
+        return [];
+    }
+
+    public function getTests()
+    {
+        return [];
+    }
+
+    public function getFunctions()
+    {
+        return [];
+    }
+
+    public function getOperators()
+    {
+        return [];
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Extension/CoreExtension.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Extension/CoreExtension.php
new file mode 100644
index 0000000..a967fd1
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Extension/CoreExtension.php
@@ -0,0 +1,1631 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Extension {
+use Twig\ExpressionParser;
+use Twig\Node\Expression\Binary\AddBinary;
+use Twig\Node\Expression\Binary\AndBinary;
+use Twig\Node\Expression\Binary\BitwiseAndBinary;
+use Twig\Node\Expression\Binary\BitwiseOrBinary;
+use Twig\Node\Expression\Binary\BitwiseXorBinary;
+use Twig\Node\Expression\Binary\ConcatBinary;
+use Twig\Node\Expression\Binary\DivBinary;
+use Twig\Node\Expression\Binary\EndsWithBinary;
+use Twig\Node\Expression\Binary\EqualBinary;
+use Twig\Node\Expression\Binary\FloorDivBinary;
+use Twig\Node\Expression\Binary\GreaterBinary;
+use Twig\Node\Expression\Binary\GreaterEqualBinary;
+use Twig\Node\Expression\Binary\InBinary;
+use Twig\Node\Expression\Binary\LessBinary;
+use Twig\Node\Expression\Binary\LessEqualBinary;
+use Twig\Node\Expression\Binary\MatchesBinary;
+use Twig\Node\Expression\Binary\ModBinary;
+use Twig\Node\Expression\Binary\MulBinary;
+use Twig\Node\Expression\Binary\NotEqualBinary;
+use Twig\Node\Expression\Binary\NotInBinary;
+use Twig\Node\Expression\Binary\OrBinary;
+use Twig\Node\Expression\Binary\PowerBinary;
+use Twig\Node\Expression\Binary\RangeBinary;
+use Twig\Node\Expression\Binary\SpaceshipBinary;
+use Twig\Node\Expression\Binary\StartsWithBinary;
+use Twig\Node\Expression\Binary\SubBinary;
+use Twig\Node\Expression\Filter\DefaultFilter;
+use Twig\Node\Expression\NullCoalesceExpression;
+use Twig\Node\Expression\Test\ConstantTest;
+use Twig\Node\Expression\Test\DefinedTest;
+use Twig\Node\Expression\Test\DivisiblebyTest;
+use Twig\Node\Expression\Test\EvenTest;
+use Twig\Node\Expression\Test\NullTest;
+use Twig\Node\Expression\Test\OddTest;
+use Twig\Node\Expression\Test\SameasTest;
+use Twig\Node\Expression\Unary\NegUnary;
+use Twig\Node\Expression\Unary\NotUnary;
+use Twig\Node\Expression\Unary\PosUnary;
+use Twig\NodeVisitor\MacroAutoImportNodeVisitor;
+use Twig\TokenParser\ApplyTokenParser;
+use Twig\TokenParser\BlockTokenParser;
+use Twig\TokenParser\DeprecatedTokenParser;
+use Twig\TokenParser\DoTokenParser;
+use Twig\TokenParser\EmbedTokenParser;
+use Twig\TokenParser\ExtendsTokenParser;
+use Twig\TokenParser\FlushTokenParser;
+use Twig\TokenParser\ForTokenParser;
+use Twig\TokenParser\FromTokenParser;
+use Twig\TokenParser\IfTokenParser;
+use Twig\TokenParser\ImportTokenParser;
+use Twig\TokenParser\IncludeTokenParser;
+use Twig\TokenParser\MacroTokenParser;
+use Twig\TokenParser\SetTokenParser;
+use Twig\TokenParser\UseTokenParser;
+use Twig\TokenParser\WithTokenParser;
+use Twig\TwigFilter;
+use Twig\TwigFunction;
+use Twig\TwigTest;
+
+final class CoreExtension extends AbstractExtension
+{
+    private $dateFormats = ['F j, Y H:i', '%d days'];
+    private $numberFormat = [0, '.', ','];
+    private $timezone = null;
+
+    /**
+     * Sets the default format to be used by the date filter.
+     *
+     * @param string $format             The default date format string
+     * @param string $dateIntervalFormat The default date interval format string
+     */
+    public function setDateFormat($format = null, $dateIntervalFormat = null)
+    {
+        if (null !== $format) {
+            $this->dateFormats[0] = $format;
+        }
+
+        if (null !== $dateIntervalFormat) {
+            $this->dateFormats[1] = $dateIntervalFormat;
+        }
+    }
+
+    /**
+     * Gets the default format to be used by the date filter.
+     *
+     * @return array The default date format string and the default date interval format string
+     */
+    public function getDateFormat()
+    {
+        return $this->dateFormats;
+    }
+
+    /**
+     * Sets the default timezone to be used by the date filter.
+     *
+     * @param \DateTimeZone|string $timezone The default timezone string or a \DateTimeZone object
+     */
+    public function setTimezone($timezone)
+    {
+        $this->timezone = $timezone instanceof \DateTimeZone ? $timezone : new \DateTimeZone($timezone);
+    }
+
+    /**
+     * Gets the default timezone to be used by the date filter.
+     *
+     * @return \DateTimeZone The default timezone currently in use
+     */
+    public function getTimezone()
+    {
+        if (null === $this->timezone) {
+            $this->timezone = new \DateTimeZone(date_default_timezone_get());
+        }
+
+        return $this->timezone;
+    }
+
+    /**
+     * Sets the default format to be used by the number_format filter.
+     *
+     * @param int    $decimal      the number of decimal places to use
+     * @param string $decimalPoint the character(s) to use for the decimal point
+     * @param string $thousandSep  the character(s) to use for the thousands separator
+     */
+    public function setNumberFormat($decimal, $decimalPoint, $thousandSep)
+    {
+        $this->numberFormat = [$decimal, $decimalPoint, $thousandSep];
+    }
+
+    /**
+     * Get the default format used by the number_format filter.
+     *
+     * @return array The arguments for number_format()
+     */
+    public function getNumberFormat()
+    {
+        return $this->numberFormat;
+    }
+
+    public function getTokenParsers(): array
+    {
+        return [
+            new ApplyTokenParser(),
+            new ForTokenParser(),
+            new IfTokenParser(),
+            new ExtendsTokenParser(),
+            new IncludeTokenParser(),
+            new BlockTokenParser(),
+            new UseTokenParser(),
+            new MacroTokenParser(),
+            new ImportTokenParser(),
+            new FromTokenParser(),
+            new SetTokenParser(),
+            new FlushTokenParser(),
+            new DoTokenParser(),
+            new EmbedTokenParser(),
+            new WithTokenParser(),
+            new DeprecatedTokenParser(),
+        ];
+    }
+
+    public function getFilters(): array
+    {
+        return [
+            // formatting filters
+            new TwigFilter('date', 'twig_date_format_filter', ['needs_environment' => true]),
+            new TwigFilter('date_modify', 'twig_date_modify_filter', ['needs_environment' => true]),
+            new TwigFilter('format', 'sprintf'),
+            new TwigFilter('replace', 'twig_replace_filter'),
+            new TwigFilter('number_format', 'twig_number_format_filter', ['needs_environment' => true]),
+            new TwigFilter('abs', 'abs'),
+            new TwigFilter('round', 'twig_round'),
+
+            // encoding
+            new TwigFilter('url_encode', 'twig_urlencode_filter'),
+            new TwigFilter('json_encode', 'json_encode'),
+            new TwigFilter('convert_encoding', 'twig_convert_encoding'),
+
+            // string filters
+            new TwigFilter('title', 'twig_title_string_filter', ['needs_environment' => true]),
+            new TwigFilter('capitalize', 'twig_capitalize_string_filter', ['needs_environment' => true]),
+            new TwigFilter('upper', 'twig_upper_filter', ['needs_environment' => true]),
+            new TwigFilter('lower', 'twig_lower_filter', ['needs_environment' => true]),
+            new TwigFilter('striptags', 'strip_tags'),
+            new TwigFilter('trim', 'twig_trim_filter'),
+            new TwigFilter('nl2br', 'nl2br', ['pre_escape' => 'html', 'is_safe' => ['html']]),
+            new TwigFilter('spaceless', 'twig_spaceless', ['is_safe' => ['html']]),
+
+            // array helpers
+            new TwigFilter('join', 'twig_join_filter'),
+            new TwigFilter('split', 'twig_split_filter', ['needs_environment' => true]),
+            new TwigFilter('sort', 'twig_sort_filter'),
+            new TwigFilter('merge', 'twig_array_merge'),
+            new TwigFilter('batch', 'twig_array_batch'),
+            new TwigFilter('column', 'twig_array_column'),
+            new TwigFilter('filter', 'twig_array_filter', ['needs_environment' => true]),
+            new TwigFilter('map', 'twig_array_map', ['needs_environment' => true]),
+            new TwigFilter('reduce', 'twig_array_reduce', ['needs_environment' => true]),
+
+            // string/array filters
+            new TwigFilter('reverse', 'twig_reverse_filter', ['needs_environment' => true]),
+            new TwigFilter('length', 'twig_length_filter', ['needs_environment' => true]),
+            new TwigFilter('slice', 'twig_slice', ['needs_environment' => true]),
+            new TwigFilter('first', 'twig_first', ['needs_environment' => true]),
+            new TwigFilter('last', 'twig_last', ['needs_environment' => true]),
+
+            // iteration and runtime
+            new TwigFilter('default', '_twig_default_filter', ['node_class' => DefaultFilter::class]),
+            new TwigFilter('keys', 'twig_get_array_keys_filter'),
+        ];
+    }
+
+    public function getFunctions(): array
+    {
+        return [
+            new TwigFunction('max', 'max'),
+            new TwigFunction('min', 'min'),
+            new TwigFunction('range', 'range'),
+            new TwigFunction('constant', 'twig_constant'),
+            new TwigFunction('cycle', 'twig_cycle'),
+            new TwigFunction('random', 'twig_random', ['needs_environment' => true]),
+            new TwigFunction('date', 'twig_date_converter', ['needs_environment' => true]),
+            new TwigFunction('include', 'twig_include', ['needs_environment' => true, 'needs_context' => true, 'is_safe' => ['all']]),
+            new TwigFunction('source', 'twig_source', ['needs_environment' => true, 'is_safe' => ['all']]),
+        ];
+    }
+
+    public function getTests(): array
+    {
+        return [
+            new TwigTest('even', null, ['node_class' => EvenTest::class]),
+            new TwigTest('odd', null, ['node_class' => OddTest::class]),
+            new TwigTest('defined', null, ['node_class' => DefinedTest::class]),
+            new TwigTest('same as', null, ['node_class' => SameasTest::class, 'one_mandatory_argument' => true]),
+            new TwigTest('none', null, ['node_class' => NullTest::class]),
+            new TwigTest('null', null, ['node_class' => NullTest::class]),
+            new TwigTest('divisible by', null, ['node_class' => DivisiblebyTest::class, 'one_mandatory_argument' => true]),
+            new TwigTest('constant', null, ['node_class' => ConstantTest::class]),
+            new TwigTest('empty', 'twig_test_empty'),
+            new TwigTest('iterable', 'twig_test_iterable'),
+        ];
+    }
+
+    public function getNodeVisitors(): array
+    {
+        return [new MacroAutoImportNodeVisitor()];
+    }
+
+    public function getOperators(): array
+    {
+        return [
+            [
+                'not' => ['precedence' => 50, 'class' => NotUnary::class],
+                '-' => ['precedence' => 500, 'class' => NegUnary::class],
+                '+' => ['precedence' => 500, 'class' => PosUnary::class],
+            ],
+            [
+                'or' => ['precedence' => 10, 'class' => OrBinary::class, 'associativity' => ExpressionParser::OPERATOR_LEFT],
+                'and' => ['precedence' => 15, 'class' => AndBinary::class, 'associativity' => ExpressionParser::OPERATOR_LEFT],
+                'b-or' => ['precedence' => 16, 'class' => BitwiseOrBinary::class, 'associativity' => ExpressionParser::OPERATOR_LEFT],
+                'b-xor' => ['precedence' => 17, 'class' => BitwiseXorBinary::class, 'associativity' => ExpressionParser::OPERATOR_LEFT],
+                'b-and' => ['precedence' => 18, 'class' => BitwiseAndBinary::class, 'associativity' => ExpressionParser::OPERATOR_LEFT],
+                '==' => ['precedence' => 20, 'class' => EqualBinary::class, 'associativity' => ExpressionParser::OPERATOR_LEFT],
+                '!=' => ['precedence' => 20, 'class' => NotEqualBinary::class, 'associativity' => ExpressionParser::OPERATOR_LEFT],
+                '<=>' => ['precedence' => 20, 'class' => SpaceshipBinary::class, 'associativity' => ExpressionParser::OPERATOR_LEFT],
+                '<' => ['precedence' => 20, 'class' => LessBinary::class, 'associativity' => ExpressionParser::OPERATOR_LEFT],
+                '>' => ['precedence' => 20, 'class' => GreaterBinary::class, 'associativity' => ExpressionParser::OPERATOR_LEFT],
+                '>=' => ['precedence' => 20, 'class' => GreaterEqualBinary::class, 'associativity' => ExpressionParser::OPERATOR_LEFT],
+                '<=' => ['precedence' => 20, 'class' => LessEqualBinary::class, 'associativity' => ExpressionParser::OPERATOR_LEFT],
+                'not in' => ['precedence' => 20, 'class' => NotInBinary::class, 'associativity' => ExpressionParser::OPERATOR_LEFT],
+                'in' => ['precedence' => 20, 'class' => InBinary::class, 'associativity' => ExpressionParser::OPERATOR_LEFT],
+                'matches' => ['precedence' => 20, 'class' => MatchesBinary::class, 'associativity' => ExpressionParser::OPERATOR_LEFT],
+                'starts with' => ['precedence' => 20, 'class' => StartsWithBinary::class, 'associativity' => ExpressionParser::OPERATOR_LEFT],
+                'ends with' => ['precedence' => 20, 'class' => EndsWithBinary::class, 'associativity' => ExpressionParser::OPERATOR_LEFT],
+                '..' => ['precedence' => 25, 'class' => RangeBinary::class, 'associativity' => ExpressionParser::OPERATOR_LEFT],
+                '+' => ['precedence' => 30, 'class' => AddBinary::class, 'associativity' => ExpressionParser::OPERATOR_LEFT],
+                '-' => ['precedence' => 30, 'class' => SubBinary::class, 'associativity' => ExpressionParser::OPERATOR_LEFT],
+                '~' => ['precedence' => 40, 'class' => ConcatBinary::class, 'associativity' => ExpressionParser::OPERATOR_LEFT],
+                '*' => ['precedence' => 60, 'class' => MulBinary::class, 'associativity' => ExpressionParser::OPERATOR_LEFT],
+                '/' => ['precedence' => 60, 'class' => DivBinary::class, 'associativity' => ExpressionParser::OPERATOR_LEFT],
+                '//' => ['precedence' => 60, 'class' => FloorDivBinary::class, 'associativity' => ExpressionParser::OPERATOR_LEFT],
+                '%' => ['precedence' => 60, 'class' => ModBinary::class, 'associativity' => ExpressionParser::OPERATOR_LEFT],
+                'is' => ['precedence' => 100, 'associativity' => ExpressionParser::OPERATOR_LEFT],
+                'is not' => ['precedence' => 100, 'associativity' => ExpressionParser::OPERATOR_LEFT],
+                '**' => ['precedence' => 200, 'class' => PowerBinary::class, 'associativity' => ExpressionParser::OPERATOR_RIGHT],
+                '??' => ['precedence' => 300, 'class' => NullCoalesceExpression::class, 'associativity' => ExpressionParser::OPERATOR_RIGHT],
+            ],
+        ];
+    }
+}
+}
+
+namespace {
+    use Twig\Environment;
+    use Twig\Error\LoaderError;
+    use Twig\Error\RuntimeError;
+    use Twig\Extension\CoreExtension;
+    use Twig\Extension\SandboxExtension;
+    use Twig\Markup;
+    use Twig\Source;
+    use Twig\Template;
+    use Twig\TemplateWrapper;
+
+/**
+ * Cycles over a value.
+ *
+ * @param \ArrayAccess|array $values
+ * @param int                $position The cycle position
+ *
+ * @return string The next value in the cycle
+ */
+function twig_cycle($values, $position)
+{
+    if (!\is_array($values) && !$values instanceof \ArrayAccess) {
+        return $values;
+    }
+
+    return $values[$position % \count($values)];
+}
+
+/**
+ * Returns a random value depending on the supplied parameter type:
+ * - a random item from a \Traversable or array
+ * - a random character from a string
+ * - a random integer between 0 and the integer parameter.
+ *
+ * @param \Traversable|array|int|float|string $values The values to pick a random item from
+ * @param int|null                            $max    Maximum value used when $values is an int
+ *
+ * @throws RuntimeError when $values is an empty array (does not apply to an empty string which is returned as is)
+ *
+ * @return mixed A random value from the given sequence
+ */
+function twig_random(Environment $env, $values = null, $max = null)
+{
+    if (null === $values) {
+        return null === $max ? mt_rand() : mt_rand(0, $max);
+    }
+
+    if (\is_int($values) || \is_float($values)) {
+        if (null === $max) {
+            if ($values < 0) {
+                $max = 0;
+                $min = $values;
+            } else {
+                $max = $values;
+                $min = 0;
+            }
+        } else {
+            $min = $values;
+            $max = $max;
+        }
+
+        return mt_rand($min, $max);
+    }
+
+    if (\is_string($values)) {
+        if ('' === $values) {
+            return '';
+        }
+
+        $charset = $env->getCharset();
+
+        if ('UTF-8' !== $charset) {
+            $values = twig_convert_encoding($values, 'UTF-8', $charset);
+        }
+
+        // unicode version of str_split()
+        // split at all positions, but not after the start and not before the end
+        $values = preg_split('/(?<!^)(?!$)/u', $values);
+
+        if ('UTF-8' !== $charset) {
+            foreach ($values as $i => $value) {
+                $values[$i] = twig_convert_encoding($value, $charset, 'UTF-8');
+            }
+        }
+    }
+
+    if (!twig_test_iterable($values)) {
+        return $values;
+    }
+
+    $values = twig_to_array($values);
+
+    if (0 === \count($values)) {
+        throw new RuntimeError('The random function cannot pick from an empty array.');
+    }
+
+    return $values[array_rand($values, 1)];
+}
+
+/**
+ * Converts a date to the given format.
+ *
+ *   {{ post.published_at|date("m/d/Y") }}
+ *
+ * @param \DateTimeInterface|\DateInterval|string $date     A date
+ * @param string|null                             $format   The target format, null to use the default
+ * @param \DateTimeZone|string|false|null         $timezone The target timezone, null to use the default, false to leave unchanged
+ *
+ * @return string The formatted date
+ */
+function twig_date_format_filter(Environment $env, $date, $format = null, $timezone = null)
+{
+    if (null === $format) {
+        $formats = $env->getExtension(CoreExtension::class)->getDateFormat();
+        $format = $date instanceof \DateInterval ? $formats[1] : $formats[0];
+    }
+
+    if ($date instanceof \DateInterval) {
+        return $date->format($format);
+    }
+
+    return twig_date_converter($env, $date, $timezone)->format($format);
+}
+
+/**
+ * Returns a new date object modified.
+ *
+ *   {{ post.published_at|date_modify("-1day")|date("m/d/Y") }}
+ *
+ * @param \DateTimeInterface|string $date     A date
+ * @param string                    $modifier A modifier string
+ *
+ * @return \DateTimeInterface
+ */
+function twig_date_modify_filter(Environment $env, $date, $modifier)
+{
+    $date = twig_date_converter($env, $date, false);
+
+    return $date->modify($modifier);
+}
+
+/**
+ * Converts an input to a \DateTime instance.
+ *
+ *    {% if date(user.created_at) < date('+2days') %}
+ *      {# do something #}
+ *    {% endif %}
+ *
+ * @param \DateTimeInterface|string|null  $date     A date or null to use the current time
+ * @param \DateTimeZone|string|false|null $timezone The target timezone, null to use the default, false to leave unchanged
+ *
+ * @return \DateTimeInterface
+ */
+function twig_date_converter(Environment $env, $date = null, $timezone = null)
+{
+    // determine the timezone
+    if (false !== $timezone) {
+        if (null === $timezone) {
+            $timezone = $env->getExtension(CoreExtension::class)->getTimezone();
+        } elseif (!$timezone instanceof \DateTimeZone) {
+            $timezone = new \DateTimeZone($timezone);
+        }
+    }
+
+    // immutable dates
+    if ($date instanceof \DateTimeImmutable) {
+        return false !== $timezone ? $date->setTimezone($timezone) : $date;
+    }
+
+    if ($date instanceof \DateTimeInterface) {
+        $date = clone $date;
+        if (false !== $timezone) {
+            $date->setTimezone($timezone);
+        }
+
+        return $date;
+    }
+
+    if (null === $date || 'now' === $date) {
+        if (null === $date) {
+            $date = 'now';
+        }
+
+        return new \DateTime($date, false !== $timezone ? $timezone : $env->getExtension(CoreExtension::class)->getTimezone());
+    }
+
+    $asString = (string) $date;
+    if (ctype_digit($asString) || (!empty($asString) && '-' === $asString[0] && ctype_digit(substr($asString, 1)))) {
+        $date = new \DateTime('@'.$date);
+    } else {
+        $date = new \DateTime($date, $env->getExtension(CoreExtension::class)->getTimezone());
+    }
+
+    if (false !== $timezone) {
+        $date->setTimezone($timezone);
+    }
+
+    return $date;
+}
+
+/**
+ * Replaces strings within a string.
+ *
+ * @param string             $str  String to replace in
+ * @param array|\Traversable $from Replace values
+ *
+ * @return string
+ */
+function twig_replace_filter($str, $from)
+{
+    if (!twig_test_iterable($from)) {
+        throw new RuntimeError(sprintf('The "replace" filter expects an array or "Traversable" as replace values, got "%s".', \is_object($from) ? \get_class($from) : \gettype($from)));
+    }
+
+    return strtr($str, twig_to_array($from));
+}
+
+/**
+ * Rounds a number.
+ *
+ * @param int|float $value     The value to round
+ * @param int|float $precision The rounding precision
+ * @param string    $method    The method to use for rounding
+ *
+ * @return int|float The rounded number
+ */
+function twig_round($value, $precision = 0, $method = 'common')
+{
+    if ('common' === $method) {
+        return round($value, $precision);
+    }
+
+    if ('ceil' !== $method && 'floor' !== $method) {
+        throw new RuntimeError('The round filter only supports the "common", "ceil", and "floor" methods.');
+    }
+
+    return $method($value * 10 ** $precision) / 10 ** $precision;
+}
+
+/**
+ * Number format filter.
+ *
+ * All of the formatting options can be left null, in that case the defaults will
+ * be used.  Supplying any of the parameters will override the defaults set in the
+ * environment object.
+ *
+ * @param mixed  $number       A float/int/string of the number to format
+ * @param int    $decimal      the number of decimal points to display
+ * @param string $decimalPoint the character(s) to use for the decimal point
+ * @param string $thousandSep  the character(s) to use for the thousands separator
+ *
+ * @return string The formatted number
+ */
+function twig_number_format_filter(Environment $env, $number, $decimal = null, $decimalPoint = null, $thousandSep = null)
+{
+    $defaults = $env->getExtension(CoreExtension::class)->getNumberFormat();
+    if (null === $decimal) {
+        $decimal = $defaults[0];
+    }
+
+    if (null === $decimalPoint) {
+        $decimalPoint = $defaults[1];
+    }
+
+    if (null === $thousandSep) {
+        $thousandSep = $defaults[2];
+    }
+
+    return number_format((float) $number, $decimal, $decimalPoint, $thousandSep);
+}
+
+/**
+ * URL encodes (RFC 3986) a string as a path segment or an array as a query string.
+ *
+ * @param string|array $url A URL or an array of query parameters
+ *
+ * @return string The URL encoded value
+ */
+function twig_urlencode_filter($url)
+{
+    if (\is_array($url)) {
+        return http_build_query($url, '', '&', \PHP_QUERY_RFC3986);
+    }
+
+    return rawurlencode($url);
+}
+
+/**
+ * Merges an array with another one.
+ *
+ *  {% set items = { 'apple': 'fruit', 'orange': 'fruit' } %}
+ *
+ *  {% set items = items|merge({ 'peugeot': 'car' }) %}
+ *
+ *  {# items now contains { 'apple': 'fruit', 'orange': 'fruit', 'peugeot': 'car' } #}
+ *
+ * @param array|\Traversable $arr1 An array
+ * @param array|\Traversable $arr2 An array
+ *
+ * @return array The merged array
+ */
+function twig_array_merge($arr1, $arr2)
+{
+    if (!twig_test_iterable($arr1)) {
+        throw new RuntimeError(sprintf('The merge filter only works with arrays or "Traversable", got "%s" as first argument.', \gettype($arr1)));
+    }
+
+    if (!twig_test_iterable($arr2)) {
+        throw new RuntimeError(sprintf('The merge filter only works with arrays or "Traversable", got "%s" as second argument.', \gettype($arr2)));
+    }
+
+    return array_merge(twig_to_array($arr1), twig_to_array($arr2));
+}
+
+/**
+ * Slices a variable.
+ *
+ * @param mixed $item         A variable
+ * @param int   $start        Start of the slice
+ * @param int   $length       Size of the slice
+ * @param bool  $preserveKeys Whether to preserve key or not (when the input is an array)
+ *
+ * @return mixed The sliced variable
+ */
+function twig_slice(Environment $env, $item, $start, $length = null, $preserveKeys = false)
+{
+    if ($item instanceof \Traversable) {
+        while ($item instanceof \IteratorAggregate) {
+            $item = $item->getIterator();
+        }
+
+        if ($start >= 0 && $length >= 0 && $item instanceof \Iterator) {
+            try {
+                return iterator_to_array(new \LimitIterator($item, $start, null === $length ? -1 : $length), $preserveKeys);
+            } catch (\OutOfBoundsException $e) {
+                return [];
+            }
+        }
+
+        $item = iterator_to_array($item, $preserveKeys);
+    }
+
+    if (\is_array($item)) {
+        return \array_slice($item, $start, $length, $preserveKeys);
+    }
+
+    $item = (string) $item;
+
+    return mb_substr($item, $start, $length, $env->getCharset());
+}
+
+/**
+ * Returns the first element of the item.
+ *
+ * @param mixed $item A variable
+ *
+ * @return mixed The first element of the item
+ */
+function twig_first(Environment $env, $item)
+{
+    $elements = twig_slice($env, $item, 0, 1, false);
+
+    return \is_string($elements) ? $elements : current($elements);
+}
+
+/**
+ * Returns the last element of the item.
+ *
+ * @param mixed $item A variable
+ *
+ * @return mixed The last element of the item
+ */
+function twig_last(Environment $env, $item)
+{
+    $elements = twig_slice($env, $item, -1, 1, false);
+
+    return \is_string($elements) ? $elements : current($elements);
+}
+
+/**
+ * Joins the values to a string.
+ *
+ * The separators between elements are empty strings per default, you can define them with the optional parameters.
+ *
+ *  {{ [1, 2, 3]|join(', ', ' and ') }}
+ *  {# returns 1, 2 and 3 #}
+ *
+ *  {{ [1, 2, 3]|join('|') }}
+ *  {# returns 1|2|3 #}
+ *
+ *  {{ [1, 2, 3]|join }}
+ *  {# returns 123 #}
+ *
+ * @param array       $value An array
+ * @param string      $glue  The separator
+ * @param string|null $and   The separator for the last pair
+ *
+ * @return string The concatenated string
+ */
+function twig_join_filter($value, $glue = '', $and = null)
+{
+    if (!twig_test_iterable($value)) {
+        $value = (array) $value;
+    }
+
+    $value = twig_to_array($value, false);
+
+    if (0 === \count($value)) {
+        return '';
+    }
+
+    if (null === $and || $and === $glue) {
+        return implode($glue, $value);
+    }
+
+    if (1 === \count($value)) {
+        return $value[0];
+    }
+
+    return implode($glue, \array_slice($value, 0, -1)).$and.$value[\count($value) - 1];
+}
+
+/**
+ * Splits the string into an array.
+ *
+ *  {{ "one,two,three"|split(',') }}
+ *  {# returns [one, two, three] #}
+ *
+ *  {{ "one,two,three,four,five"|split(',', 3) }}
+ *  {# returns [one, two, "three,four,five"] #}
+ *
+ *  {{ "123"|split('') }}
+ *  {# returns [1, 2, 3] #}
+ *
+ *  {{ "aabbcc"|split('', 2) }}
+ *  {# returns [aa, bb, cc] #}
+ *
+ * @param string $value     A string
+ * @param string $delimiter The delimiter
+ * @param int    $limit     The limit
+ *
+ * @return array The split string as an array
+ */
+function twig_split_filter(Environment $env, $value, $delimiter, $limit = null)
+{
+    if (\strlen($delimiter) > 0) {
+        return null === $limit ? explode($delimiter, $value) : explode($delimiter, $value, $limit);
+    }
+
+    if ($limit <= 1) {
+        return preg_split('/(?<!^)(?!$)/u', $value);
+    }
+
+    $length = mb_strlen($value, $env->getCharset());
+    if ($length < $limit) {
+        return [$value];
+    }
+
+    $r = [];
+    for ($i = 0; $i < $length; $i += $limit) {
+        $r[] = mb_substr($value, $i, $limit, $env->getCharset());
+    }
+
+    return $r;
+}
+
+// The '_default' filter is used internally to avoid using the ternary operator
+// which costs a lot for big contexts (before PHP 5.4). So, on average,
+// a function call is cheaper.
+/**
+ * @internal
+ */
+function _twig_default_filter($value, $default = '')
+{
+    if (twig_test_empty($value)) {
+        return $default;
+    }
+
+    return $value;
+}
+
+/**
+ * Returns the keys for the given array.
+ *
+ * It is useful when you want to iterate over the keys of an array:
+ *
+ *  {% for key in array|keys %}
+ *      {# ... #}
+ *  {% endfor %}
+ *
+ * @param array $array An array
+ *
+ * @return array The keys
+ */
+function twig_get_array_keys_filter($array)
+{
+    if ($array instanceof \Traversable) {
+        while ($array instanceof \IteratorAggregate) {
+            $array = $array->getIterator();
+        }
+
+        $keys = [];
+        if ($array instanceof \Iterator) {
+            $array->rewind();
+            while ($array->valid()) {
+                $keys[] = $array->key();
+                $array->next();
+            }
+
+            return $keys;
+        }
+
+        foreach ($array as $key => $item) {
+            $keys[] = $key;
+        }
+
+        return $keys;
+    }
+
+    if (!\is_array($array)) {
+        return [];
+    }
+
+    return array_keys($array);
+}
+
+/**
+ * Reverses a variable.
+ *
+ * @param array|\Traversable|string $item         An array, a \Traversable instance, or a string
+ * @param bool                      $preserveKeys Whether to preserve key or not
+ *
+ * @return mixed The reversed input
+ */
+function twig_reverse_filter(Environment $env, $item, $preserveKeys = false)
+{
+    if ($item instanceof \Traversable) {
+        return array_reverse(iterator_to_array($item), $preserveKeys);
+    }
+
+    if (\is_array($item)) {
+        return array_reverse($item, $preserveKeys);
+    }
+
+    $string = (string) $item;
+
+    $charset = $env->getCharset();
+
+    if ('UTF-8' !== $charset) {
+        $item = twig_convert_encoding($string, 'UTF-8', $charset);
+    }
+
+    preg_match_all('/./us', $item, $matches);
+
+    $string = implode('', array_reverse($matches[0]));
+
+    if ('UTF-8' !== $charset) {
+        $string = twig_convert_encoding($string, $charset, 'UTF-8');
+    }
+
+    return $string;
+}
+
+/**
+ * Sorts an array.
+ *
+ * @param array|\Traversable $array
+ *
+ * @return array
+ */
+function twig_sort_filter($array, $arrow = null)
+{
+    if ($array instanceof \Traversable) {
+        $array = iterator_to_array($array);
+    } elseif (!\is_array($array)) {
+        throw new RuntimeError(sprintf('The sort filter only works with arrays or "Traversable", got "%s".', \gettype($array)));
+    }
+
+    if (null !== $arrow) {
+        uasort($array, $arrow);
+    } else {
+        asort($array);
+    }
+
+    return $array;
+}
+
+/**
+ * @internal
+ */
+function twig_in_filter($value, $compare)
+{
+    if ($value instanceof Markup) {
+        $value = (string) $value;
+    }
+    if ($compare instanceof Markup) {
+        $compare = (string) $compare;
+    }
+
+    if (\is_string($compare)) {
+        if (\is_string($value) || \is_int($value) || \is_float($value)) {
+            return '' === $value || false !== strpos($compare, (string) $value);
+        }
+
+        return false;
+    }
+
+    if (!is_iterable($compare)) {
+        return false;
+    }
+
+    if (\is_object($value) || \is_resource($value)) {
+        if (!\is_array($compare)) {
+            foreach ($compare as $item) {
+                if ($item === $value) {
+                    return true;
+                }
+            }
+
+            return false;
+        }
+
+        return \in_array($value, $compare, true);
+    }
+
+    foreach ($compare as $item) {
+        if (0 === twig_compare($value, $item)) {
+            return true;
+        }
+    }
+
+    return false;
+}
+
+/**
+ * Compares two values using a more strict version of the PHP non-strict comparison operator.
+ *
+ * @see https://wiki.php.net/rfc/string_to_number_comparison
+ * @see https://wiki.php.net/rfc/trailing_whitespace_numerics
+ *
+ * @internal
+ */
+function twig_compare($a, $b)
+{
+    // int <=> string
+    if (\is_int($a) && \is_string($b)) {
+        $bTrim = trim($b, " \t\n\r\v\f");
+        if (!is_numeric($bTrim)) {
+            return (string) $a <=> $b;
+        }
+        if ((int) $bTrim == $bTrim) {
+            return $a <=> (int) $bTrim;
+        } else {
+            return (float) $a <=> (float) $bTrim;
+        }
+    }
+    if (\is_string($a) && \is_int($b)) {
+        $aTrim = trim($a, " \t\n\r\v\f");
+        if (!is_numeric($aTrim)) {
+            return $a <=> (string) $b;
+        }
+        if ((int) $aTrim == $aTrim) {
+            return (int) $aTrim <=> $b;
+        } else {
+            return (float) $aTrim <=> (float) $b;
+        }
+    }
+
+    // float <=> string
+    if (\is_float($a) && \is_string($b)) {
+        if (is_nan($a)) {
+            return 1;
+        }
+        $bTrim = trim($b, " \t\n\r\v\f");
+        if (!is_numeric($bTrim)) {
+            return (string) $a <=> $b;
+        }
+
+        return $a <=> (float) $bTrim;
+    }
+    if (\is_string($a) && \is_float($b)) {
+        if (is_nan($b)) {
+            return 1;
+        }
+        $aTrim = trim($a, " \t\n\r\v\f");
+        if (!is_numeric($aTrim)) {
+            return $a <=> (string) $b;
+        }
+
+        return (float) $aTrim <=> $b;
+    }
+
+    // fallback to <=>
+    return $a <=> $b;
+}
+
+/**
+ * Returns a trimmed string.
+ *
+ * @return string
+ *
+ * @throws RuntimeError When an invalid trimming side is used (not a string or not 'left', 'right', or 'both')
+ */
+function twig_trim_filter($string, $characterMask = null, $side = 'both')
+{
+    if (null === $characterMask) {
+        $characterMask = " \t\n\r\0\x0B";
+    }
+
+    switch ($side) {
+        case 'both':
+            return trim($string, $characterMask);
+        case 'left':
+            return ltrim($string, $characterMask);
+        case 'right':
+            return rtrim($string, $characterMask);
+        default:
+            throw new RuntimeError('Trimming side must be "left", "right" or "both".');
+    }
+}
+
+/**
+ * Removes whitespaces between HTML tags.
+ *
+ * @return string
+ */
+function twig_spaceless($content)
+{
+    return trim(preg_replace('/>\s+</', '><', $content));
+}
+
+function twig_convert_encoding($string, $to, $from)
+{
+    if (!\function_exists('iconv')) {
+        throw new RuntimeError('Unable to convert encoding: required function iconv() does not exist. You should install ext-iconv or symfony/polyfill-iconv.');
+    }
+
+    return iconv($from, $to, $string);
+}
+
+/**
+ * Returns the length of a variable.
+ *
+ * @param mixed $thing A variable
+ *
+ * @return int The length of the value
+ */
+function twig_length_filter(Environment $env, $thing)
+{
+    if (null === $thing) {
+        return 0;
+    }
+
+    if (is_scalar($thing)) {
+        return mb_strlen($thing, $env->getCharset());
+    }
+
+    if ($thing instanceof \Countable || \is_array($thing) || $thing instanceof \SimpleXMLElement) {
+        return \count($thing);
+    }
+
+    if ($thing instanceof \Traversable) {
+        return iterator_count($thing);
+    }
+
+    if (method_exists($thing, '__toString') && !$thing instanceof \Countable) {
+        return mb_strlen((string) $thing, $env->getCharset());
+    }
+
+    return 1;
+}
+
+/**
+ * Converts a string to uppercase.
+ *
+ * @param string $string A string
+ *
+ * @return string The uppercased string
+ */
+function twig_upper_filter(Environment $env, $string)
+{
+    return mb_strtoupper($string, $env->getCharset());
+}
+
+/**
+ * Converts a string to lowercase.
+ *
+ * @param string $string A string
+ *
+ * @return string The lowercased string
+ */
+function twig_lower_filter(Environment $env, $string)
+{
+    return mb_strtolower($string, $env->getCharset());
+}
+
+/**
+ * Returns a titlecased string.
+ *
+ * @param string $string A string
+ *
+ * @return string The titlecased string
+ */
+function twig_title_string_filter(Environment $env, $string)
+{
+    if (null !== $charset = $env->getCharset()) {
+        return mb_convert_case($string, \MB_CASE_TITLE, $charset);
+    }
+
+    return ucwords(strtolower($string));
+}
+
+/**
+ * Returns a capitalized string.
+ *
+ * @param string $string A string
+ *
+ * @return string The capitalized string
+ */
+function twig_capitalize_string_filter(Environment $env, $string)
+{
+    $charset = $env->getCharset();
+
+    return mb_strtoupper(mb_substr($string, 0, 1, $charset), $charset).mb_strtolower(mb_substr($string, 1, null, $charset), $charset);
+}
+
+/**
+ * @internal
+ */
+function twig_call_macro(Template $template, string $method, array $args, int $lineno, array $context, Source $source)
+{
+    if (!method_exists($template, $method)) {
+        $parent = $template;
+        while ($parent = $parent->getParent($context)) {
+            if (method_exists($parent, $method)) {
+                return $parent->$method(...$args);
+            }
+        }
+
+        throw new RuntimeError(sprintf('Macro "%s" is not defined in template "%s".', substr($method, \strlen('macro_')), $template->getTemplateName()), $lineno, $source);
+    }
+
+    return $template->$method(...$args);
+}
+
+/**
+ * @internal
+ */
+function twig_ensure_traversable($seq)
+{
+    if ($seq instanceof \Traversable || \is_array($seq)) {
+        return $seq;
+    }
+
+    return [];
+}
+
+/**
+ * @internal
+ */
+function twig_to_array($seq, $preserveKeys = true)
+{
+    if ($seq instanceof \Traversable) {
+        return iterator_to_array($seq, $preserveKeys);
+    }
+
+    if (!\is_array($seq)) {
+        return $seq;
+    }
+
+    return $preserveKeys ? $seq : array_values($seq);
+}
+
+/**
+ * Checks if a variable is empty.
+ *
+ *    {# evaluates to true if the foo variable is null, false, or the empty string #}
+ *    {% if foo is empty %}
+ *        {# ... #}
+ *    {% endif %}
+ *
+ * @param mixed $value A variable
+ *
+ * @return bool true if the value is empty, false otherwise
+ */
+function twig_test_empty($value)
+{
+    if ($value instanceof \Countable) {
+        return 0 === \count($value);
+    }
+
+    if ($value instanceof \Traversable) {
+        return !iterator_count($value);
+    }
+
+    if (\is_object($value) && method_exists($value, '__toString')) {
+        return '' === (string) $value;
+    }
+
+    return '' === $value || false === $value || null === $value || [] === $value;
+}
+
+/**
+ * Checks if a variable is traversable.
+ *
+ *    {# evaluates to true if the foo variable is an array or a traversable object #}
+ *    {% if foo is iterable %}
+ *        {# ... #}
+ *    {% endif %}
+ *
+ * @param mixed $value A variable
+ *
+ * @return bool true if the value is traversable
+ */
+function twig_test_iterable($value)
+{
+    return $value instanceof \Traversable || \is_array($value);
+}
+
+/**
+ * Renders a template.
+ *
+ * @param array        $context
+ * @param string|array $template      The template to render or an array of templates to try consecutively
+ * @param array        $variables     The variables to pass to the template
+ * @param bool         $withContext
+ * @param bool         $ignoreMissing Whether to ignore missing templates or not
+ * @param bool         $sandboxed     Whether to sandbox the template or not
+ *
+ * @return string The rendered template
+ */
+function twig_include(Environment $env, $context, $template, $variables = [], $withContext = true, $ignoreMissing = false, $sandboxed = false)
+{
+    $alreadySandboxed = false;
+    $sandbox = null;
+    if ($withContext) {
+        $variables = array_merge($context, $variables);
+    }
+
+    if ($isSandboxed = $sandboxed && $env->hasExtension(SandboxExtension::class)) {
+        $sandbox = $env->getExtension(SandboxExtension::class);
+        if (!$alreadySandboxed = $sandbox->isSandboxed()) {
+            $sandbox->enableSandbox();
+        }
+
+        foreach ((\is_array($template) ? $template : [$template]) as $name) {
+            // if a Template instance is passed, it might have been instantiated outside of a sandbox, check security
+            if ($name instanceof TemplateWrapper || $name instanceof Template) {
+                $name->unwrap()->checkSecurity();
+            }
+        }
+    }
+
+    try {
+        $loaded = null;
+        try {
+            $loaded = $env->resolveTemplate($template);
+        } catch (LoaderError $e) {
+            if (!$ignoreMissing) {
+                throw $e;
+            }
+        }
+
+        return $loaded ? $loaded->render($variables) : '';
+    } finally {
+        if ($isSandboxed && !$alreadySandboxed) {
+            $sandbox->disableSandbox();
+        }
+    }
+}
+
+/**
+ * Returns a template content without rendering it.
+ *
+ * @param string $name          The template name
+ * @param bool   $ignoreMissing Whether to ignore missing templates or not
+ *
+ * @return string The template source
+ */
+function twig_source(Environment $env, $name, $ignoreMissing = false)
+{
+    $loader = $env->getLoader();
+    try {
+        return $loader->getSourceContext($name)->getCode();
+    } catch (LoaderError $e) {
+        if (!$ignoreMissing) {
+            throw $e;
+        }
+    }
+}
+
+/**
+ * Provides the ability to get constants from instances as well as class/global constants.
+ *
+ * @param string      $constant The name of the constant
+ * @param object|null $object   The object to get the constant from
+ *
+ * @return string
+ */
+function twig_constant($constant, $object = null)
+{
+    if (null !== $object) {
+        $constant = \get_class($object).'::'.$constant;
+    }
+
+    return \constant($constant);
+}
+
+/**
+ * Checks if a constant exists.
+ *
+ * @param string      $constant The name of the constant
+ * @param object|null $object   The object to get the constant from
+ *
+ * @return bool
+ */
+function twig_constant_is_defined($constant, $object = null)
+{
+    if (null !== $object) {
+        $constant = \get_class($object).'::'.$constant;
+    }
+
+    return \defined($constant);
+}
+
+/**
+ * Batches item.
+ *
+ * @param array $items An array of items
+ * @param int   $size  The size of the batch
+ * @param mixed $fill  A value used to fill missing items
+ *
+ * @return array
+ */
+function twig_array_batch($items, $size, $fill = null, $preserveKeys = true)
+{
+    if (!twig_test_iterable($items)) {
+        throw new RuntimeError(sprintf('The "batch" filter expects an array or "Traversable", got "%s".', \is_object($items) ? \get_class($items) : \gettype($items)));
+    }
+
+    $size = ceil($size);
+
+    $result = array_chunk(twig_to_array($items, $preserveKeys), $size, $preserveKeys);
+
+    if (null !== $fill && $result) {
+        $last = \count($result) - 1;
+        if ($fillCount = $size - \count($result[$last])) {
+            for ($i = 0; $i < $fillCount; ++$i) {
+                $result[$last][] = $fill;
+            }
+        }
+    }
+
+    return $result;
+}
+
+/**
+ * Returns the attribute value for a given array/object.
+ *
+ * @param mixed  $object            The object or array from where to get the item
+ * @param mixed  $item              The item to get from the array or object
+ * @param array  $arguments         An array of arguments to pass if the item is an object method
+ * @param string $type              The type of attribute (@see \Twig\Template constants)
+ * @param bool   $isDefinedTest     Whether this is only a defined check
+ * @param bool   $ignoreStrictCheck Whether to ignore the strict attribute check or not
+ * @param int    $lineno            The template line where the attribute was called
+ *
+ * @return mixed The attribute value, or a Boolean when $isDefinedTest is true, or null when the attribute is not set and $ignoreStrictCheck is true
+ *
+ * @throws RuntimeError if the attribute does not exist and Twig is running in strict mode and $isDefinedTest is false
+ *
+ * @internal
+ */
+function twig_get_attribute(Environment $env, Source $source, $object, $item, array $arguments = [], $type = /* Template::ANY_CALL */ 'any', $isDefinedTest = false, $ignoreStrictCheck = false, $sandboxed = false, int $lineno = -1)
+{
+    // array
+    if (/* Template::METHOD_CALL */ 'method' !== $type) {
+        $arrayItem = \is_bool($item) || \is_float($item) ? (int) $item : $item;
+
+        if (((\is_array($object) || $object instanceof \ArrayObject) && (isset($object[$arrayItem]) || \array_key_exists($arrayItem, (array) $object)))
+            || ($object instanceof ArrayAccess && isset($object[$arrayItem]))
+        ) {
+            if ($isDefinedTest) {
+                return true;
+            }
+
+            return $object[$arrayItem];
+        }
+
+        if (/* Template::ARRAY_CALL */ 'array' === $type || !\is_object($object)) {
+            if ($isDefinedTest) {
+                return false;
+            }
+
+            if ($ignoreStrictCheck || !$env->isStrictVariables()) {
+                return;
+            }
+
+            if ($object instanceof ArrayAccess) {
+                $message = sprintf('Key "%s" in object with ArrayAccess of class "%s" does not exist.', $arrayItem, \get_class($object));
+            } elseif (\is_object($object)) {
+                $message = sprintf('Impossible to access a key "%s" on an object of class "%s" that does not implement ArrayAccess interface.', $item, \get_class($object));
+            } elseif (\is_array($object)) {
+                if (empty($object)) {
+                    $message = sprintf('Key "%s" does not exist as the array is empty.', $arrayItem);
+                } else {
+                    $message = sprintf('Key "%s" for array with keys "%s" does not exist.', $arrayItem, implode(', ', array_keys($object)));
+                }
+            } elseif (/* Template::ARRAY_CALL */ 'array' === $type) {
+                if (null === $object) {
+                    $message = sprintf('Impossible to access a key ("%s") on a null variable.', $item);
+                } else {
+                    $message = sprintf('Impossible to access a key ("%s") on a %s variable ("%s").', $item, \gettype($object), $object);
+                }
+            } elseif (null === $object) {
+                $message = sprintf('Impossible to access an attribute ("%s") on a null variable.', $item);
+            } else {
+                $message = sprintf('Impossible to access an attribute ("%s") on a %s variable ("%s").', $item, \gettype($object), $object);
+            }
+
+            throw new RuntimeError($message, $lineno, $source);
+        }
+    }
+
+    if (!\is_object($object)) {
+        if ($isDefinedTest) {
+            return false;
+        }
+
+        if ($ignoreStrictCheck || !$env->isStrictVariables()) {
+            return;
+        }
+
+        if (null === $object) {
+            $message = sprintf('Impossible to invoke a method ("%s") on a null variable.', $item);
+        } elseif (\is_array($object)) {
+            $message = sprintf('Impossible to invoke a method ("%s") on an array.', $item);
+        } else {
+            $message = sprintf('Impossible to invoke a method ("%s") on a %s variable ("%s").', $item, \gettype($object), $object);
+        }
+
+        throw new RuntimeError($message, $lineno, $source);
+    }
+
+    if ($object instanceof Template) {
+        throw new RuntimeError('Accessing \Twig\Template attributes is forbidden.', $lineno, $source);
+    }
+
+    // object property
+    if (/* Template::METHOD_CALL */ 'method' !== $type) {
+        if (isset($object->$item) || \array_key_exists((string) $item, (array) $object)) {
+            if ($isDefinedTest) {
+                return true;
+            }
+
+            if ($sandboxed) {
+                $env->getExtension(SandboxExtension::class)->checkPropertyAllowed($object, $item, $lineno, $source);
+            }
+
+            return $object->$item;
+        }
+    }
+
+    static $cache = [];
+
+    $class = \get_class($object);
+
+    // object method
+    // precedence: getXxx() > isXxx() > hasXxx()
+    if (!isset($cache[$class])) {
+        $methods = get_class_methods($object);
+        sort($methods);
+        $lcMethods = array_map(function ($value) { return strtr($value, 'ABCDEFGHIJKLMNOPQRSTUVWXYZ', 'abcdefghijklmnopqrstuvwxyz'); }, $methods);
+        $classCache = [];
+        foreach ($methods as $i => $method) {
+            $classCache[$method] = $method;
+            $classCache[$lcName = $lcMethods[$i]] = $method;
+
+            if ('g' === $lcName[0] && 0 === strpos($lcName, 'get')) {
+                $name = substr($method, 3);
+                $lcName = substr($lcName, 3);
+            } elseif ('i' === $lcName[0] && 0 === strpos($lcName, 'is')) {
+                $name = substr($method, 2);
+                $lcName = substr($lcName, 2);
+            } elseif ('h' === $lcName[0] && 0 === strpos($lcName, 'has')) {
+                $name = substr($method, 3);
+                $lcName = substr($lcName, 3);
+                if (\in_array('is'.$lcName, $lcMethods)) {
+                    continue;
+                }
+            } else {
+                continue;
+            }
+
+            // skip get() and is() methods (in which case, $name is empty)
+            if ($name) {
+                if (!isset($classCache[$name])) {
+                    $classCache[$name] = $method;
+                }
+
+                if (!isset($classCache[$lcName])) {
+                    $classCache[$lcName] = $method;
+                }
+            }
+        }
+        $cache[$class] = $classCache;
+    }
+
+    $call = false;
+    if (isset($cache[$class][$item])) {
+        $method = $cache[$class][$item];
+    } elseif (isset($cache[$class][$lcItem = strtr($item, 'ABCDEFGHIJKLMNOPQRSTUVWXYZ', 'abcdefghijklmnopqrstuvwxyz')])) {
+        $method = $cache[$class][$lcItem];
+    } elseif (isset($cache[$class]['__call'])) {
+        $method = $item;
+        $call = true;
+    } else {
+        if ($isDefinedTest) {
+            return false;
+        }
+
+        if ($ignoreStrictCheck || !$env->isStrictVariables()) {
+            return;
+        }
+
+        throw new RuntimeError(sprintf('Neither the property "%1$s" nor one of the methods "%1$s()", "get%1$s()"/"is%1$s()"/"has%1$s()" or "__call()" exist and have public access in class "%2$s".', $item, $class), $lineno, $source);
+    }
+
+    if ($isDefinedTest) {
+        return true;
+    }
+
+    if ($sandboxed) {
+        $env->getExtension(SandboxExtension::class)->checkMethodAllowed($object, $method, $lineno, $source);
+    }
+
+    // Some objects throw exceptions when they have __call, and the method we try
+    // to call is not supported. If ignoreStrictCheck is true, we should return null.
+    try {
+        $ret = $object->$method(...$arguments);
+    } catch (\BadMethodCallException $e) {
+        if ($call && ($ignoreStrictCheck || !$env->isStrictVariables())) {
+            return;
+        }
+        throw $e;
+    }
+
+    return $ret;
+}
+
+/**
+ * Returns the values from a single column in the input array.
+ *
+ * <pre>
+ *  {% set items = [{ 'fruit' : 'apple'}, {'fruit' : 'orange' }] %}
+ *
+ *  {% set fruits = items|column('fruit') %}
+ *
+ *  {# fruits now contains ['apple', 'orange'] #}
+ * </pre>
+ *
+ * @param array|Traversable $array An array
+ * @param mixed             $name  The column name
+ * @param mixed             $index The column to use as the index/keys for the returned array
+ *
+ * @return array The array of values
+ */
+function twig_array_column($array, $name, $index = null): array
+{
+    if ($array instanceof Traversable) {
+        $array = iterator_to_array($array);
+    } elseif (!\is_array($array)) {
+        throw new RuntimeError(sprintf('The column filter only works with arrays or "Traversable", got "%s" as first argument.', \gettype($array)));
+    }
+
+    return array_column($array, $name, $index);
+}
+
+function twig_array_filter(Environment $env, $array, $arrow)
+{
+    if (!twig_test_iterable($array)) {
+        throw new RuntimeError(sprintf('The "filter" filter expects an array or "Traversable", got "%s".', \is_object($array) ? \get_class($array) : \gettype($array)));
+    }
+
+    if (!$arrow instanceof Closure && $env->hasExtension('\Twig\Extension\SandboxExtension') && $env->getExtension('\Twig\Extension\SandboxExtension')->isSandboxed()) {
+        throw new RuntimeError('The callable passed to "filter" filter must be a Closure in sandbox mode.');
+    }
+
+    if (\is_array($array)) {
+        return array_filter($array, $arrow, \ARRAY_FILTER_USE_BOTH);
+    }
+
+    // the IteratorIterator wrapping is needed as some internal PHP classes are \Traversable but do not implement \Iterator
+    return new \CallbackFilterIterator(new \IteratorIterator($array), $arrow);
+}
+
+function twig_array_map(Environment $env, $array, $arrow)
+{
+    if (!$arrow instanceof Closure && $env->hasExtension('\Twig\Extension\SandboxExtension') && $env->getExtension('\Twig\Extension\SandboxExtension')->isSandboxed()) {
+        throw new RuntimeError('The callable passed to the "map" filter must be a Closure in sandbox mode.');
+    }
+
+    $r = [];
+    foreach ($array as $k => $v) {
+        $r[$k] = $arrow($v, $k);
+    }
+
+    return $r;
+}
+
+function twig_array_reduce(Environment $env, $array, $arrow, $initial = null)
+{
+    if (!$arrow instanceof Closure && $env->hasExtension('\Twig\Extension\SandboxExtension') && $env->getExtension('\Twig\Extension\SandboxExtension')->isSandboxed()) {
+        throw new RuntimeError('The callable passed to the "reduce" filter must be a Closure in sandbox mode.');
+    }
+
+    if (!\is_array($array)) {
+        if (!$array instanceof \Traversable) {
+            throw new RuntimeError(sprintf('The "reduce" filter only works with arrays or "Traversable", got "%s" as first argument.', \gettype($array)));
+        }
+
+        $array = iterator_to_array($array);
+    }
+
+    return array_reduce($array, $arrow, $initial);
+}
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Extension/DebugExtension.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Extension/DebugExtension.php
new file mode 100644
index 0000000..bfb23d7
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Extension/DebugExtension.php
@@ -0,0 +1,64 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Extension {
+use Twig\TwigFunction;
+
+final class DebugExtension extends AbstractExtension
+{
+    public function getFunctions(): array
+    {
+        // dump is safe if var_dump is overridden by xdebug
+        $isDumpOutputHtmlSafe = \extension_loaded('xdebug')
+            // false means that it was not set (and the default is on) or it explicitly enabled
+            && (false === ini_get('xdebug.overload_var_dump') || ini_get('xdebug.overload_var_dump'))
+            // false means that it was not set (and the default is on) or it explicitly enabled
+            // xdebug.overload_var_dump produces HTML only when html_errors is also enabled
+            && (false === ini_get('html_errors') || ini_get('html_errors'))
+            || 'cli' === \PHP_SAPI
+        ;
+
+        return [
+            new TwigFunction('dump', 'twig_var_dump', ['is_safe' => $isDumpOutputHtmlSafe ? ['html'] : [], 'needs_context' => true, 'needs_environment' => true, 'is_variadic' => true]),
+        ];
+    }
+}
+}
+
+namespace {
+use Twig\Environment;
+use Twig\Template;
+use Twig\TemplateWrapper;
+
+function twig_var_dump(Environment $env, $context, ...$vars)
+{
+    if (!$env->isDebug()) {
+        return;
+    }
+
+    ob_start();
+
+    if (!$vars) {
+        $vars = [];
+        foreach ($context as $key => $value) {
+            if (!$value instanceof Template && !$value instanceof TemplateWrapper) {
+                $vars[$key] = $value;
+            }
+        }
+
+        var_dump($vars);
+    } else {
+        var_dump(...$vars);
+    }
+
+    return ob_get_clean();
+}
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Extension/EscaperExtension.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Extension/EscaperExtension.php
new file mode 100644
index 0000000..372551f
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Extension/EscaperExtension.php
@@ -0,0 +1,421 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Extension {
+use Twig\FileExtensionEscapingStrategy;
+use Twig\NodeVisitor\EscaperNodeVisitor;
+use Twig\TokenParser\AutoEscapeTokenParser;
+use Twig\TwigFilter;
+
+final class EscaperExtension extends AbstractExtension
+{
+    private $defaultStrategy;
+    private $escapers = [];
+
+    /** @internal */
+    public $safeClasses = [];
+
+    /** @internal */
+    public $safeLookup = [];
+
+    /**
+     * @param string|false|callable $defaultStrategy An escaping strategy
+     *
+     * @see setDefaultStrategy()
+     */
+    public function __construct($defaultStrategy = 'html')
+    {
+        $this->setDefaultStrategy($defaultStrategy);
+    }
+
+    public function getTokenParsers(): array
+    {
+        return [new AutoEscapeTokenParser()];
+    }
+
+    public function getNodeVisitors(): array
+    {
+        return [new EscaperNodeVisitor()];
+    }
+
+    public function getFilters(): array
+    {
+        return [
+            new TwigFilter('escape', 'twig_escape_filter', ['needs_environment' => true, 'is_safe_callback' => 'twig_escape_filter_is_safe']),
+            new TwigFilter('e', 'twig_escape_filter', ['needs_environment' => true, 'is_safe_callback' => 'twig_escape_filter_is_safe']),
+            new TwigFilter('raw', 'twig_raw_filter', ['is_safe' => ['all']]),
+        ];
+    }
+
+    /**
+     * Sets the default strategy to use when not defined by the user.
+     *
+     * The strategy can be a valid PHP callback that takes the template
+     * name as an argument and returns the strategy to use.
+     *
+     * @param string|false|callable $defaultStrategy An escaping strategy
+     */
+    public function setDefaultStrategy($defaultStrategy): void
+    {
+        if ('name' === $defaultStrategy) {
+            $defaultStrategy = [FileExtensionEscapingStrategy::class, 'guess'];
+        }
+
+        $this->defaultStrategy = $defaultStrategy;
+    }
+
+    /**
+     * Gets the default strategy to use when not defined by the user.
+     *
+     * @param string $name The template name
+     *
+     * @return string|false The default strategy to use for the template
+     */
+    public function getDefaultStrategy(string $name)
+    {
+        // disable string callables to avoid calling a function named html or js,
+        // or any other upcoming escaping strategy
+        if (!\is_string($this->defaultStrategy) && false !== $this->defaultStrategy) {
+            return \call_user_func($this->defaultStrategy, $name);
+        }
+
+        return $this->defaultStrategy;
+    }
+
+    /**
+     * Defines a new escaper to be used via the escape filter.
+     *
+     * @param string   $strategy The strategy name that should be used as a strategy in the escape call
+     * @param callable $callable A valid PHP callable
+     */
+    public function setEscaper($strategy, callable $callable)
+    {
+        $this->escapers[$strategy] = $callable;
+    }
+
+    /**
+     * Gets all defined escapers.
+     *
+     * @return callable[] An array of escapers
+     */
+    public function getEscapers()
+    {
+        return $this->escapers;
+    }
+
+    public function setSafeClasses(array $safeClasses = [])
+    {
+        $this->safeClasses = [];
+        $this->safeLookup = [];
+        foreach ($safeClasses as $class => $strategies) {
+            $this->addSafeClass($class, $strategies);
+        }
+    }
+
+    public function addSafeClass(string $class, array $strategies)
+    {
+        $class = ltrim($class, '\\');
+        if (!isset($this->safeClasses[$class])) {
+            $this->safeClasses[$class] = [];
+        }
+        $this->safeClasses[$class] = array_merge($this->safeClasses[$class], $strategies);
+
+        foreach ($strategies as $strategy) {
+            $this->safeLookup[$strategy][$class] = true;
+        }
+    }
+}
+}
+
+namespace {
+use Twig\Environment;
+use Twig\Error\RuntimeError;
+use Twig\Extension\EscaperExtension;
+use Twig\Markup;
+use Twig\Node\Expression\ConstantExpression;
+use Twig\Node\Node;
+
+/**
+ * Marks a variable as being safe.
+ *
+ * @param string $string A PHP variable
+ */
+function twig_raw_filter($string)
+{
+    return $string;
+}
+
+/**
+ * Escapes a string.
+ *
+ * @param mixed  $string     The value to be escaped
+ * @param string $strategy   The escaping strategy
+ * @param string $charset    The charset
+ * @param bool   $autoescape Whether the function is called by the auto-escaping feature (true) or by the developer (false)
+ *
+ * @return string
+ */
+function twig_escape_filter(Environment $env, $string, $strategy = 'html', $charset = null, $autoescape = false)
+{
+    if ($autoescape && $string instanceof Markup) {
+        return $string;
+    }
+
+    if (!\is_string($string)) {
+        if (\is_object($string) && method_exists($string, '__toString')) {
+            if ($autoescape) {
+                $c = \get_class($string);
+                $ext = $env->getExtension(EscaperExtension::class);
+                if (!isset($ext->safeClasses[$c])) {
+                    $ext->safeClasses[$c] = [];
+                    foreach (class_parents($string) + class_implements($string) as $class) {
+                        if (isset($ext->safeClasses[$class])) {
+                            $ext->safeClasses[$c] = array_unique(array_merge($ext->safeClasses[$c], $ext->safeClasses[$class]));
+                            foreach ($ext->safeClasses[$class] as $s) {
+                                $ext->safeLookup[$s][$c] = true;
+                            }
+                        }
+                    }
+                }
+                if (isset($ext->safeLookup[$strategy][$c]) || isset($ext->safeLookup['all'][$c])) {
+                    return (string) $string;
+                }
+            }
+
+            $string = (string) $string;
+        } elseif (\in_array($strategy, ['html', 'js', 'css', 'html_attr', 'url'])) {
+            return $string;
+        }
+    }
+
+    if ('' === $string) {
+        return '';
+    }
+
+    if (null === $charset) {
+        $charset = $env->getCharset();
+    }
+
+    switch ($strategy) {
+        case 'html':
+            // see https://secure.php.net/htmlspecialchars
+
+            // Using a static variable to avoid initializing the array
+            // each time the function is called. Moving the declaration on the
+            // top of the function slow downs other escaping strategies.
+            static $htmlspecialcharsCharsets = [
+                'ISO-8859-1' => true, 'ISO8859-1' => true,
+                'ISO-8859-15' => true, 'ISO8859-15' => true,
+                'utf-8' => true, 'UTF-8' => true,
+                'CP866' => true, 'IBM866' => true, '866' => true,
+                'CP1251' => true, 'WINDOWS-1251' => true, 'WIN-1251' => true,
+                '1251' => true,
+                'CP1252' => true, 'WINDOWS-1252' => true, '1252' => true,
+                'KOI8-R' => true, 'KOI8-RU' => true, 'KOI8R' => true,
+                'BIG5' => true, '950' => true,
+                'GB2312' => true, '936' => true,
+                'BIG5-HKSCS' => true,
+                'SHIFT_JIS' => true, 'SJIS' => true, '932' => true,
+                'EUC-JP' => true, 'EUCJP' => true,
+                'ISO8859-5' => true, 'ISO-8859-5' => true, 'MACROMAN' => true,
+            ];
+
+            if (isset($htmlspecialcharsCharsets[$charset])) {
+                return htmlspecialchars($string, \ENT_QUOTES | \ENT_SUBSTITUTE, $charset);
+            }
+
+            if (isset($htmlspecialcharsCharsets[strtoupper($charset)])) {
+                // cache the lowercase variant for future iterations
+                $htmlspecialcharsCharsets[$charset] = true;
+
+                return htmlspecialchars($string, \ENT_QUOTES | \ENT_SUBSTITUTE, $charset);
+            }
+
+            $string = twig_convert_encoding($string, 'UTF-8', $charset);
+            $string = htmlspecialchars($string, \ENT_QUOTES | \ENT_SUBSTITUTE, 'UTF-8');
+
+            return iconv('UTF-8', $charset, $string);
+
+        case 'js':
+            // escape all non-alphanumeric characters
+            // into their \x or \uHHHH representations
+            if ('UTF-8' !== $charset) {
+                $string = twig_convert_encoding($string, 'UTF-8', $charset);
+            }
+
+            if (!preg_match('//u', $string)) {
+                throw new RuntimeError('The string to escape is not a valid UTF-8 string.');
+            }
+
+            $string = preg_replace_callback('#[^a-zA-Z0-9,\._]#Su', function ($matches) {
+                $char = $matches[0];
+
+                /*
+                 * A few characters have short escape sequences in JSON and JavaScript.
+                 * Escape sequences supported only by JavaScript, not JSON, are omitted.
+                 * \" is also supported but omitted, because the resulting string is not HTML safe.
+                 */
+                static $shortMap = [
+                    '\\' => '\\\\',
+                    '/' => '\\/',
+                    "\x08" => '\b',
+                    "\x0C" => '\f',
+                    "\x0A" => '\n',
+                    "\x0D" => '\r',
+                    "\x09" => '\t',
+                ];
+
+                if (isset($shortMap[$char])) {
+                    return $shortMap[$char];
+                }
+
+                $codepoint = mb_ord($char);
+                if (0x10000 > $codepoint) {
+                    return sprintf('\u%04X', $codepoint);
+                }
+
+                // Split characters outside the BMP into surrogate pairs
+                // https://tools.ietf.org/html/rfc2781.html#section-2.1
+                $u = $codepoint - 0x10000;
+                $high = 0xD800 | ($u >> 10);
+                $low = 0xDC00 | ($u & 0x3FF);
+
+                return sprintf('\u%04X\u%04X', $high, $low);
+            }, $string);
+
+            if ('UTF-8' !== $charset) {
+                $string = iconv('UTF-8', $charset, $string);
+            }
+
+            return $string;
+
+        case 'css':
+            if ('UTF-8' !== $charset) {
+                $string = twig_convert_encoding($string, 'UTF-8', $charset);
+            }
+
+            if (!preg_match('//u', $string)) {
+                throw new RuntimeError('The string to escape is not a valid UTF-8 string.');
+            }
+
+            $string = preg_replace_callback('#[^a-zA-Z0-9]#Su', function ($matches) {
+                $char = $matches[0];
+
+                return sprintf('\\%X ', 1 === \strlen($char) ? \ord($char) : mb_ord($char, 'UTF-8'));
+            }, $string);
+
+            if ('UTF-8' !== $charset) {
+                $string = iconv('UTF-8', $charset, $string);
+            }
+
+            return $string;
+
+        case 'html_attr':
+            if ('UTF-8' !== $charset) {
+                $string = twig_convert_encoding($string, 'UTF-8', $charset);
+            }
+
+            if (!preg_match('//u', $string)) {
+                throw new RuntimeError('The string to escape is not a valid UTF-8 string.');
+            }
+
+            $string = preg_replace_callback('#[^a-zA-Z0-9,\.\-_]#Su', function ($matches) {
+                /**
+                 * This function is adapted from code coming from Zend Framework.
+                 *
+                 * @copyright Copyright (c) 2005-2012 Zend Technologies USA Inc. (https://www.zend.com)
+                 * @license   https://framework.zend.com/license/new-bsd New BSD License
+                 */
+                $chr = $matches[0];
+                $ord = \ord($chr);
+
+                /*
+                 * The following replaces characters undefined in HTML with the
+                 * hex entity for the Unicode replacement character.
+                 */
+                if (($ord <= 0x1f && "\t" != $chr && "\n" != $chr && "\r" != $chr) || ($ord >= 0x7f && $ord <= 0x9f)) {
+                    return '&#xFFFD;';
+                }
+
+                /*
+                 * Check if the current character to escape has a name entity we should
+                 * replace it with while grabbing the hex value of the character.
+                 */
+                if (1 === \strlen($chr)) {
+                    /*
+                     * While HTML supports far more named entities, the lowest common denominator
+                     * has become HTML5's XML Serialisation which is restricted to the those named
+                     * entities that XML supports. Using HTML entities would result in this error:
+                     *     XML Parsing Error: undefined entity
+                     */
+                    static $entityMap = [
+                        34 => '&quot;', /* quotation mark */
+                        38 => '&amp;',  /* ampersand */
+                        60 => '&lt;',   /* less-than sign */
+                        62 => '&gt;',   /* greater-than sign */
+                    ];
+
+                    if (isset($entityMap[$ord])) {
+                        return $entityMap[$ord];
+                    }
+
+                    return sprintf('&#x%02X;', $ord);
+                }
+
+                /*
+                 * Per OWASP recommendations, we'll use hex entities for any other
+                 * characters where a named entity does not exist.
+                 */
+                return sprintf('&#x%04X;', mb_ord($chr, 'UTF-8'));
+            }, $string);
+
+            if ('UTF-8' !== $charset) {
+                $string = iconv('UTF-8', $charset, $string);
+            }
+
+            return $string;
+
+        case 'url':
+            return rawurlencode($string);
+
+        default:
+            static $escapers;
+
+            if (null === $escapers) {
+                $escapers = $env->getExtension(EscaperExtension::class)->getEscapers();
+            }
+
+            if (isset($escapers[$strategy])) {
+                return $escapers[$strategy]($env, $string, $charset);
+            }
+
+            $validStrategies = implode(', ', array_merge(['html', 'js', 'url', 'css', 'html_attr'], array_keys($escapers)));
+
+            throw new RuntimeError(sprintf('Invalid escaping strategy "%s" (valid ones: %s).', $strategy, $validStrategies));
+    }
+}
+
+/**
+ * @internal
+ */
+function twig_escape_filter_is_safe(Node $filterArgs)
+{
+    foreach ($filterArgs as $arg) {
+        if ($arg instanceof ConstantExpression) {
+            return [$arg->getAttribute('value')];
+        }
+
+        return [];
+    }
+
+    return ['html'];
+}
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Extension/ExtensionInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Extension/ExtensionInterface.php
new file mode 100644
index 0000000..75fa237
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Extension/ExtensionInterface.php
@@ -0,0 +1,68 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Extension;
+
+use Twig\NodeVisitor\NodeVisitorInterface;
+use Twig\TokenParser\TokenParserInterface;
+use Twig\TwigFilter;
+use Twig\TwigFunction;
+use Twig\TwigTest;
+
+/**
+ * Interface implemented by extension classes.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+interface ExtensionInterface
+{
+    /**
+     * Returns the token parser instances to add to the existing list.
+     *
+     * @return TokenParserInterface[]
+     */
+    public function getTokenParsers();
+
+    /**
+     * Returns the node visitor instances to add to the existing list.
+     *
+     * @return NodeVisitorInterface[]
+     */
+    public function getNodeVisitors();
+
+    /**
+     * Returns a list of filters to add to the existing list.
+     *
+     * @return TwigFilter[]
+     */
+    public function getFilters();
+
+    /**
+     * Returns a list of tests to add to the existing list.
+     *
+     * @return TwigTest[]
+     */
+    public function getTests();
+
+    /**
+     * Returns a list of functions to add to the existing list.
+     *
+     * @return TwigFunction[]
+     */
+    public function getFunctions();
+
+    /**
+     * Returns a list of operators to add to the existing list.
+     *
+     * @return array<array> First array of unary operators, second array of binary operators
+     */
+    public function getOperators();
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Extension/GlobalsInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Extension/GlobalsInterface.php
new file mode 100644
index 0000000..ec0c682
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Extension/GlobalsInterface.php
@@ -0,0 +1,25 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Extension;
+
+/**
+ * Enables usage of the deprecated Twig\Extension\AbstractExtension::getGlobals() method.
+ *
+ * Explicitly implement this interface if you really need to implement the
+ * deprecated getGlobals() method in your extensions.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+interface GlobalsInterface
+{
+    public function getGlobals(): array;
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Extension/OptimizerExtension.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Extension/OptimizerExtension.php
new file mode 100644
index 0000000..965bfdb
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Extension/OptimizerExtension.php
@@ -0,0 +1,29 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Extension;
+
+use Twig\NodeVisitor\OptimizerNodeVisitor;
+
+final class OptimizerExtension extends AbstractExtension
+{
+    private $optimizers;
+
+    public function __construct(int $optimizers = -1)
+    {
+        $this->optimizers = $optimizers;
+    }
+
+    public function getNodeVisitors(): array
+    {
+        return [new OptimizerNodeVisitor($this->optimizers)];
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Extension/ProfilerExtension.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Extension/ProfilerExtension.php
new file mode 100644
index 0000000..43e4a44
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Extension/ProfilerExtension.php
@@ -0,0 +1,52 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Extension;
+
+use Twig\Profiler\NodeVisitor\ProfilerNodeVisitor;
+use Twig\Profiler\Profile;
+
+class ProfilerExtension extends AbstractExtension
+{
+    private $actives = [];
+
+    public function __construct(Profile $profile)
+    {
+        $this->actives[] = $profile;
+    }
+
+    /**
+     * @return void
+     */
+    public function enter(Profile $profile)
+    {
+        $this->actives[0]->addProfile($profile);
+        array_unshift($this->actives, $profile);
+    }
+
+    /**
+     * @return void
+     */
+    public function leave(Profile $profile)
+    {
+        $profile->leave();
+        array_shift($this->actives);
+
+        if (1 === \count($this->actives)) {
+            $this->actives[0]->leave();
+        }
+    }
+
+    public function getNodeVisitors(): array
+    {
+        return [new ProfilerNodeVisitor(static::class)];
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Extension/RuntimeExtensionInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Extension/RuntimeExtensionInterface.php
new file mode 100644
index 0000000..63bc3b1
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Extension/RuntimeExtensionInterface.php
@@ -0,0 +1,19 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Extension;
+
+/**
+ * @author Grégoire Pineau <lyrixx@lyrixx.info>
+ */
+interface RuntimeExtensionInterface
+{
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Extension/SandboxExtension.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Extension/SandboxExtension.php
new file mode 100644
index 0000000..0a28cab
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Extension/SandboxExtension.php
@@ -0,0 +1,123 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Extension;
+
+use Twig\NodeVisitor\SandboxNodeVisitor;
+use Twig\Sandbox\SecurityNotAllowedMethodError;
+use Twig\Sandbox\SecurityNotAllowedPropertyError;
+use Twig\Sandbox\SecurityPolicyInterface;
+use Twig\Source;
+use Twig\TokenParser\SandboxTokenParser;
+
+final class SandboxExtension extends AbstractExtension
+{
+    private $sandboxedGlobally;
+    private $sandboxed;
+    private $policy;
+
+    public function __construct(SecurityPolicyInterface $policy, $sandboxed = false)
+    {
+        $this->policy = $policy;
+        $this->sandboxedGlobally = $sandboxed;
+    }
+
+    public function getTokenParsers(): array
+    {
+        return [new SandboxTokenParser()];
+    }
+
+    public function getNodeVisitors(): array
+    {
+        return [new SandboxNodeVisitor()];
+    }
+
+    public function enableSandbox(): void
+    {
+        $this->sandboxed = true;
+    }
+
+    public function disableSandbox(): void
+    {
+        $this->sandboxed = false;
+    }
+
+    public function isSandboxed(): bool
+    {
+        return $this->sandboxedGlobally || $this->sandboxed;
+    }
+
+    public function isSandboxedGlobally(): bool
+    {
+        return $this->sandboxedGlobally;
+    }
+
+    public function setSecurityPolicy(SecurityPolicyInterface $policy)
+    {
+        $this->policy = $policy;
+    }
+
+    public function getSecurityPolicy(): SecurityPolicyInterface
+    {
+        return $this->policy;
+    }
+
+    public function checkSecurity($tags, $filters, $functions): void
+    {
+        if ($this->isSandboxed()) {
+            $this->policy->checkSecurity($tags, $filters, $functions);
+        }
+    }
+
+    public function checkMethodAllowed($obj, $method, int $lineno = -1, Source $source = null): void
+    {
+        if ($this->isSandboxed()) {
+            try {
+                $this->policy->checkMethodAllowed($obj, $method);
+            } catch (SecurityNotAllowedMethodError $e) {
+                $e->setSourceContext($source);
+                $e->setTemplateLine($lineno);
+
+                throw $e;
+            }
+        }
+    }
+
+    public function checkPropertyAllowed($obj, $method, int $lineno = -1, Source $source = null): void
+    {
+        if ($this->isSandboxed()) {
+            try {
+                $this->policy->checkPropertyAllowed($obj, $method);
+            } catch (SecurityNotAllowedPropertyError $e) {
+                $e->setSourceContext($source);
+                $e->setTemplateLine($lineno);
+
+                throw $e;
+            }
+        }
+    }
+
+    public function ensureToStringAllowed($obj, int $lineno = -1, Source $source = null)
+    {
+        if ($this->isSandboxed() && \is_object($obj) && method_exists($obj, '__toString')) {
+            try {
+                $this->policy->checkMethodAllowed($obj, '__toString');
+            } catch (SecurityNotAllowedMethodError $e) {
+                $e->setSourceContext($source);
+                $e->setTemplateLine($lineno);
+
+                throw $e;
+            }
+        }
+
+        return $obj;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Extension/StagingExtension.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Extension/StagingExtension.php
new file mode 100644
index 0000000..0ea47f9
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Extension/StagingExtension.php
@@ -0,0 +1,100 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Extension;
+
+use Twig\NodeVisitor\NodeVisitorInterface;
+use Twig\TokenParser\TokenParserInterface;
+use Twig\TwigFilter;
+use Twig\TwigFunction;
+use Twig\TwigTest;
+
+/**
+ * Used by \Twig\Environment as a staging area.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ *
+ * @internal
+ */
+final class StagingExtension extends AbstractExtension
+{
+    private $functions = [];
+    private $filters = [];
+    private $visitors = [];
+    private $tokenParsers = [];
+    private $tests = [];
+
+    public function addFunction(TwigFunction $function): void
+    {
+        if (isset($this->functions[$function->getName()])) {
+            throw new \LogicException(sprintf('Function "%s" is already registered.', $function->getName()));
+        }
+
+        $this->functions[$function->getName()] = $function;
+    }
+
+    public function getFunctions(): array
+    {
+        return $this->functions;
+    }
+
+    public function addFilter(TwigFilter $filter): void
+    {
+        if (isset($this->filters[$filter->getName()])) {
+            throw new \LogicException(sprintf('Filter "%s" is already registered.', $filter->getName()));
+        }
+
+        $this->filters[$filter->getName()] = $filter;
+    }
+
+    public function getFilters(): array
+    {
+        return $this->filters;
+    }
+
+    public function addNodeVisitor(NodeVisitorInterface $visitor): void
+    {
+        $this->visitors[] = $visitor;
+    }
+
+    public function getNodeVisitors(): array
+    {
+        return $this->visitors;
+    }
+
+    public function addTokenParser(TokenParserInterface $parser): void
+    {
+        if (isset($this->tokenParsers[$parser->getTag()])) {
+            throw new \LogicException(sprintf('Tag "%s" is already registered.', $parser->getTag()));
+        }
+
+        $this->tokenParsers[$parser->getTag()] = $parser;
+    }
+
+    public function getTokenParsers(): array
+    {
+        return $this->tokenParsers;
+    }
+
+    public function addTest(TwigTest $test): void
+    {
+        if (isset($this->tests[$test->getName()])) {
+            throw new \LogicException(sprintf('Test "%s" is already registered.', $test->getName()));
+        }
+
+        $this->tests[$test->getName()] = $test;
+    }
+
+    public function getTests(): array
+    {
+        return $this->tests;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Extension/StringLoaderExtension.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Extension/StringLoaderExtension.php
new file mode 100644
index 0000000..7b45147
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Extension/StringLoaderExtension.php
@@ -0,0 +1,42 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Extension {
+use Twig\TwigFunction;
+
+final class StringLoaderExtension extends AbstractExtension
+{
+    public function getFunctions(): array
+    {
+        return [
+            new TwigFunction('template_from_string', 'twig_template_from_string', ['needs_environment' => true]),
+        ];
+    }
+}
+}
+
+namespace {
+use Twig\Environment;
+use Twig\TemplateWrapper;
+
+/**
+ * Loads a template from a string.
+ *
+ *     {{ include(template_from_string("Hello {{ name }}")) }}
+ *
+ * @param string $template A template as a string or object implementing __toString()
+ * @param string $name     An optional name of the template to be used in error messages
+ */
+function twig_template_from_string(Environment $env, $template, string $name = null): TemplateWrapper
+{
+    return $env->createTemplate((string) $template, $name);
+}
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/ExtensionSet.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/ExtensionSet.php
new file mode 100644
index 0000000..36e5bbc
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/ExtensionSet.php
@@ -0,0 +1,463 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig;
+
+use Twig\Error\RuntimeError;
+use Twig\Extension\ExtensionInterface;
+use Twig\Extension\GlobalsInterface;
+use Twig\Extension\StagingExtension;
+use Twig\NodeVisitor\NodeVisitorInterface;
+use Twig\TokenParser\TokenParserInterface;
+
+/**
+ * @author Fabien Potencier <fabien@symfony.com>
+ *
+ * @internal
+ */
+final class ExtensionSet
+{
+    private $extensions;
+    private $initialized = false;
+    private $runtimeInitialized = false;
+    private $staging;
+    private $parsers;
+    private $visitors;
+    private $filters;
+    private $tests;
+    private $functions;
+    private $unaryOperators;
+    private $binaryOperators;
+    private $globals;
+    private $functionCallbacks = [];
+    private $filterCallbacks = [];
+    private $parserCallbacks = [];
+    private $lastModified = 0;
+
+    public function __construct()
+    {
+        $this->staging = new StagingExtension();
+    }
+
+    public function initRuntime()
+    {
+        $this->runtimeInitialized = true;
+    }
+
+    public function hasExtension(string $class): bool
+    {
+        return isset($this->extensions[ltrim($class, '\\')]);
+    }
+
+    public function getExtension(string $class): ExtensionInterface
+    {
+        $class = ltrim($class, '\\');
+
+        if (!isset($this->extensions[$class])) {
+            throw new RuntimeError(sprintf('The "%s" extension is not enabled.', $class));
+        }
+
+        return $this->extensions[$class];
+    }
+
+    /**
+     * @param ExtensionInterface[] $extensions
+     */
+    public function setExtensions(array $extensions): void
+    {
+        foreach ($extensions as $extension) {
+            $this->addExtension($extension);
+        }
+    }
+
+    /**
+     * @return ExtensionInterface[]
+     */
+    public function getExtensions(): array
+    {
+        return $this->extensions;
+    }
+
+    public function getSignature(): string
+    {
+        return json_encode(array_keys($this->extensions));
+    }
+
+    public function isInitialized(): bool
+    {
+        return $this->initialized || $this->runtimeInitialized;
+    }
+
+    public function getLastModified(): int
+    {
+        if (0 !== $this->lastModified) {
+            return $this->lastModified;
+        }
+
+        foreach ($this->extensions as $extension) {
+            $r = new \ReflectionObject($extension);
+            if (is_file($r->getFileName()) && ($extensionTime = filemtime($r->getFileName())) > $this->lastModified) {
+                $this->lastModified = $extensionTime;
+            }
+        }
+
+        return $this->lastModified;
+    }
+
+    public function addExtension(ExtensionInterface $extension): void
+    {
+        $class = \get_class($extension);
+
+        if ($this->initialized) {
+            throw new \LogicException(sprintf('Unable to register extension "%s" as extensions have already been initialized.', $class));
+        }
+
+        if (isset($this->extensions[$class])) {
+            throw new \LogicException(sprintf('Unable to register extension "%s" as it is already registered.', $class));
+        }
+
+        $this->extensions[$class] = $extension;
+    }
+
+    public function addFunction(TwigFunction $function): void
+    {
+        if ($this->initialized) {
+            throw new \LogicException(sprintf('Unable to add function "%s" as extensions have already been initialized.', $function->getName()));
+        }
+
+        $this->staging->addFunction($function);
+    }
+
+    /**
+     * @return TwigFunction[]
+     */
+    public function getFunctions(): array
+    {
+        if (!$this->initialized) {
+            $this->initExtensions();
+        }
+
+        return $this->functions;
+    }
+
+    public function getFunction(string $name): ?TwigFunction
+    {
+        if (!$this->initialized) {
+            $this->initExtensions();
+        }
+
+        if (isset($this->functions[$name])) {
+            return $this->functions[$name];
+        }
+
+        foreach ($this->functions as $pattern => $function) {
+            $pattern = str_replace('\\*', '(.*?)', preg_quote($pattern, '#'), $count);
+
+            if ($count && preg_match('#^'.$pattern.'$#', $name, $matches)) {
+                array_shift($matches);
+                $function->setArguments($matches);
+
+                return $function;
+            }
+        }
+
+        foreach ($this->functionCallbacks as $callback) {
+            if (false !== $function = $callback($name)) {
+                return $function;
+            }
+        }
+
+        return null;
+    }
+
+    public function registerUndefinedFunctionCallback(callable $callable): void
+    {
+        $this->functionCallbacks[] = $callable;
+    }
+
+    public function addFilter(TwigFilter $filter): void
+    {
+        if ($this->initialized) {
+            throw new \LogicException(sprintf('Unable to add filter "%s" as extensions have already been initialized.', $filter->getName()));
+        }
+
+        $this->staging->addFilter($filter);
+    }
+
+    /**
+     * @return TwigFilter[]
+     */
+    public function getFilters(): array
+    {
+        if (!$this->initialized) {
+            $this->initExtensions();
+        }
+
+        return $this->filters;
+    }
+
+    public function getFilter(string $name): ?TwigFilter
+    {
+        if (!$this->initialized) {
+            $this->initExtensions();
+        }
+
+        if (isset($this->filters[$name])) {
+            return $this->filters[$name];
+        }
+
+        foreach ($this->filters as $pattern => $filter) {
+            $pattern = str_replace('\\*', '(.*?)', preg_quote($pattern, '#'), $count);
+
+            if ($count && preg_match('#^'.$pattern.'$#', $name, $matches)) {
+                array_shift($matches);
+                $filter->setArguments($matches);
+
+                return $filter;
+            }
+        }
+
+        foreach ($this->filterCallbacks as $callback) {
+            if (false !== $filter = $callback($name)) {
+                return $filter;
+            }
+        }
+
+        return null;
+    }
+
+    public function registerUndefinedFilterCallback(callable $callable): void
+    {
+        $this->filterCallbacks[] = $callable;
+    }
+
+    public function addNodeVisitor(NodeVisitorInterface $visitor): void
+    {
+        if ($this->initialized) {
+            throw new \LogicException('Unable to add a node visitor as extensions have already been initialized.');
+        }
+
+        $this->staging->addNodeVisitor($visitor);
+    }
+
+    /**
+     * @return NodeVisitorInterface[]
+     */
+    public function getNodeVisitors(): array
+    {
+        if (!$this->initialized) {
+            $this->initExtensions();
+        }
+
+        return $this->visitors;
+    }
+
+    public function addTokenParser(TokenParserInterface $parser): void
+    {
+        if ($this->initialized) {
+            throw new \LogicException('Unable to add a token parser as extensions have already been initialized.');
+        }
+
+        $this->staging->addTokenParser($parser);
+    }
+
+    /**
+     * @return TokenParserInterface[]
+     */
+    public function getTokenParsers(): array
+    {
+        if (!$this->initialized) {
+            $this->initExtensions();
+        }
+
+        return $this->parsers;
+    }
+
+    public function getTokenParser(string $name): ?TokenParserInterface
+    {
+        if (!$this->initialized) {
+            $this->initExtensions();
+        }
+
+        if (isset($this->parsers[$name])) {
+            return $this->parsers[$name];
+        }
+
+        foreach ($this->parserCallbacks as $callback) {
+            if (false !== $parser = $callback($name)) {
+                return $parser;
+            }
+        }
+
+        return null;
+    }
+
+    public function registerUndefinedTokenParserCallback(callable $callable): void
+    {
+        $this->parserCallbacks[] = $callable;
+    }
+
+    public function getGlobals(): array
+    {
+        if (null !== $this->globals) {
+            return $this->globals;
+        }
+
+        $globals = [];
+        foreach ($this->extensions as $extension) {
+            if (!$extension instanceof GlobalsInterface) {
+                continue;
+            }
+
+            $extGlobals = $extension->getGlobals();
+            if (!\is_array($extGlobals)) {
+                throw new \UnexpectedValueException(sprintf('"%s::getGlobals()" must return an array of globals.', \get_class($extension)));
+            }
+
+            $globals = array_merge($globals, $extGlobals);
+        }
+
+        if ($this->initialized) {
+            $this->globals = $globals;
+        }
+
+        return $globals;
+    }
+
+    public function addTest(TwigTest $test): void
+    {
+        if ($this->initialized) {
+            throw new \LogicException(sprintf('Unable to add test "%s" as extensions have already been initialized.', $test->getName()));
+        }
+
+        $this->staging->addTest($test);
+    }
+
+    /**
+     * @return TwigTest[]
+     */
+    public function getTests(): array
+    {
+        if (!$this->initialized) {
+            $this->initExtensions();
+        }
+
+        return $this->tests;
+    }
+
+    public function getTest(string $name): ?TwigTest
+    {
+        if (!$this->initialized) {
+            $this->initExtensions();
+        }
+
+        if (isset($this->tests[$name])) {
+            return $this->tests[$name];
+        }
+
+        foreach ($this->tests as $pattern => $test) {
+            $pattern = str_replace('\\*', '(.*?)', preg_quote($pattern, '#'), $count);
+
+            if ($count) {
+                if (preg_match('#^'.$pattern.'$#', $name, $matches)) {
+                    array_shift($matches);
+                    $test->setArguments($matches);
+
+                    return $test;
+                }
+            }
+        }
+
+        return null;
+    }
+
+    public function getUnaryOperators(): array
+    {
+        if (!$this->initialized) {
+            $this->initExtensions();
+        }
+
+        return $this->unaryOperators;
+    }
+
+    public function getBinaryOperators(): array
+    {
+        if (!$this->initialized) {
+            $this->initExtensions();
+        }
+
+        return $this->binaryOperators;
+    }
+
+    private function initExtensions(): void
+    {
+        $this->parsers = [];
+        $this->filters = [];
+        $this->functions = [];
+        $this->tests = [];
+        $this->visitors = [];
+        $this->unaryOperators = [];
+        $this->binaryOperators = [];
+
+        foreach ($this->extensions as $extension) {
+            $this->initExtension($extension);
+        }
+        $this->initExtension($this->staging);
+        // Done at the end only, so that an exception during initialization does not mark the environment as initialized when catching the exception
+        $this->initialized = true;
+    }
+
+    private function initExtension(ExtensionInterface $extension): void
+    {
+        // filters
+        foreach ($extension->getFilters() as $filter) {
+            $this->filters[$filter->getName()] = $filter;
+        }
+
+        // functions
+        foreach ($extension->getFunctions() as $function) {
+            $this->functions[$function->getName()] = $function;
+        }
+
+        // tests
+        foreach ($extension->getTests() as $test) {
+            $this->tests[$test->getName()] = $test;
+        }
+
+        // token parsers
+        foreach ($extension->getTokenParsers() as $parser) {
+            if (!$parser instanceof TokenParserInterface) {
+                throw new \LogicException('getTokenParsers() must return an array of \Twig\TokenParser\TokenParserInterface.');
+            }
+
+            $this->parsers[$parser->getTag()] = $parser;
+        }
+
+        // node visitors
+        foreach ($extension->getNodeVisitors() as $visitor) {
+            $this->visitors[] = $visitor;
+        }
+
+        // operators
+        if ($operators = $extension->getOperators()) {
+            if (!\is_array($operators)) {
+                throw new \InvalidArgumentException(sprintf('"%s::getOperators()" must return an array with operators, got "%s".', \get_class($extension), \is_object($operators) ? \get_class($operators) : \gettype($operators).(\is_resource($operators) ? '' : '#'.$operators)));
+            }
+
+            if (2 !== \count($operators)) {
+                throw new \InvalidArgumentException(sprintf('"%s::getOperators()" must return an array of 2 elements, got %d.', \get_class($extension), \count($operators)));
+            }
+
+            $this->unaryOperators = array_merge($this->unaryOperators, $operators[0]);
+            $this->binaryOperators = array_merge($this->binaryOperators, $operators[1]);
+        }
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/FileExtensionEscapingStrategy.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/FileExtensionEscapingStrategy.php
new file mode 100644
index 0000000..65198bb
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/FileExtensionEscapingStrategy.php
@@ -0,0 +1,60 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig;
+
+/**
+ * Default autoescaping strategy based on file names.
+ *
+ * This strategy sets the HTML as the default autoescaping strategy,
+ * but changes it based on the template name.
+ *
+ * Note that there is no runtime performance impact as the
+ * default autoescaping strategy is set at compilation time.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class FileExtensionEscapingStrategy
+{
+    /**
+     * Guesses the best autoescaping strategy based on the file name.
+     *
+     * @param string $name The template name
+     *
+     * @return string|false The escaping strategy name to use or false to disable
+     */
+    public static function guess(string $name)
+    {
+        if (\in_array(substr($name, -1), ['/', '\\'])) {
+            return 'html'; // return html for directories
+        }
+
+        if ('.twig' === substr($name, -5)) {
+            $name = substr($name, 0, -5);
+        }
+
+        $extension = pathinfo($name, \PATHINFO_EXTENSION);
+
+        switch ($extension) {
+            case 'js':
+                return 'js';
+
+            case 'css':
+                return 'css';
+
+            case 'txt':
+                return false;
+
+            default:
+                return 'html';
+        }
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Lexer.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Lexer.php
new file mode 100644
index 0000000..9ff028c
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Lexer.php
@@ -0,0 +1,501 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig;
+
+use Twig\Error\SyntaxError;
+
+/**
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class Lexer
+{
+    private $tokens;
+    private $code;
+    private $cursor;
+    private $lineno;
+    private $end;
+    private $state;
+    private $states;
+    private $brackets;
+    private $env;
+    private $source;
+    private $options;
+    private $regexes;
+    private $position;
+    private $positions;
+    private $currentVarBlockLine;
+
+    public const STATE_DATA = 0;
+    public const STATE_BLOCK = 1;
+    public const STATE_VAR = 2;
+    public const STATE_STRING = 3;
+    public const STATE_INTERPOLATION = 4;
+
+    public const REGEX_NAME = '/[a-zA-Z_\x7f-\xff][a-zA-Z0-9_\x7f-\xff]*/A';
+    public const REGEX_NUMBER = '/[0-9]+(?:\.[0-9]+)?([Ee][\+\-][0-9]+)?/A';
+    public const REGEX_STRING = '/"([^#"\\\\]*(?:\\\\.[^#"\\\\]*)*)"|\'([^\'\\\\]*(?:\\\\.[^\'\\\\]*)*)\'/As';
+    public const REGEX_DQ_STRING_DELIM = '/"/A';
+    public const REGEX_DQ_STRING_PART = '/[^#"\\\\]*(?:(?:\\\\.|#(?!\{))[^#"\\\\]*)*/As';
+    public const PUNCTUATION = '()[]{}?:.,|';
+
+    public function __construct(Environment $env, array $options = [])
+    {
+        $this->env = $env;
+
+        $this->options = array_merge([
+            'tag_comment' => ['{#', '#}'],
+            'tag_block' => ['{%', '%}'],
+            'tag_variable' => ['{{', '}}'],
+            'whitespace_trim' => '-',
+            'whitespace_line_trim' => '~',
+            'whitespace_line_chars' => ' \t\0\x0B',
+            'interpolation' => ['#{', '}'],
+        ], $options);
+
+        // when PHP 7.3 is the min version, we will be able to remove the '#' part in preg_quote as it's part of the default
+        $this->regexes = [
+            // }}
+            'lex_var' => '{
+                \s*
+                (?:'.
+                    preg_quote($this->options['whitespace_trim'].$this->options['tag_variable'][1], '#').'\s*'. // -}}\s*
+                    '|'.
+                    preg_quote($this->options['whitespace_line_trim'].$this->options['tag_variable'][1], '#').'['.$this->options['whitespace_line_chars'].']*'. // ~}}[ \t\0\x0B]*
+                    '|'.
+                    preg_quote($this->options['tag_variable'][1], '#'). // }}
+                ')
+            }Ax',
+
+            // %}
+            'lex_block' => '{
+                \s*
+                (?:'.
+                    preg_quote($this->options['whitespace_trim'].$this->options['tag_block'][1], '#').'\s*\n?'. // -%}\s*\n?
+                    '|'.
+                    preg_quote($this->options['whitespace_line_trim'].$this->options['tag_block'][1], '#').'['.$this->options['whitespace_line_chars'].']*'. // ~%}[ \t\0\x0B]*
+                    '|'.
+                    preg_quote($this->options['tag_block'][1], '#').'\n?'. // %}\n?
+                ')
+            }Ax',
+
+            // {% endverbatim %}
+            'lex_raw_data' => '{'.
+                preg_quote($this->options['tag_block'][0], '#'). // {%
+                '('.
+                    $this->options['whitespace_trim']. // -
+                    '|'.
+                    $this->options['whitespace_line_trim']. // ~
+                ')?\s*endverbatim\s*'.
+                '(?:'.
+                    preg_quote($this->options['whitespace_trim'].$this->options['tag_block'][1], '#').'\s*'. // -%}
+                    '|'.
+                    preg_quote($this->options['whitespace_line_trim'].$this->options['tag_block'][1], '#').'['.$this->options['whitespace_line_chars'].']*'. // ~%}[ \t\0\x0B]*
+                    '|'.
+                    preg_quote($this->options['tag_block'][1], '#'). // %}
+                ')
+            }sx',
+
+            'operator' => $this->getOperatorRegex(),
+
+            // #}
+            'lex_comment' => '{
+                (?:'.
+                    preg_quote($this->options['whitespace_trim'].$this->options['tag_comment'][1], '#').'\s*\n?'. // -#}\s*\n?
+                    '|'.
+                    preg_quote($this->options['whitespace_line_trim'].$this->options['tag_comment'][1], '#').'['.$this->options['whitespace_line_chars'].']*'. // ~#}[ \t\0\x0B]*
+                    '|'.
+                    preg_quote($this->options['tag_comment'][1], '#').'\n?'. // #}\n?
+                ')
+            }sx',
+
+            // verbatim %}
+            'lex_block_raw' => '{
+                \s*verbatim\s*
+                (?:'.
+                    preg_quote($this->options['whitespace_trim'].$this->options['tag_block'][1], '#').'\s*'. // -%}\s*
+                    '|'.
+                    preg_quote($this->options['whitespace_line_trim'].$this->options['tag_block'][1], '#').'['.$this->options['whitespace_line_chars'].']*'. // ~%}[ \t\0\x0B]*
+                    '|'.
+                    preg_quote($this->options['tag_block'][1], '#'). // %}
+                ')
+            }Asx',
+
+            'lex_block_line' => '{\s*line\s+(\d+)\s*'.preg_quote($this->options['tag_block'][1], '#').'}As',
+
+            // {{ or {% or {#
+            'lex_tokens_start' => '{
+                ('.
+                    preg_quote($this->options['tag_variable'][0], '#'). // {{
+                    '|'.
+                    preg_quote($this->options['tag_block'][0], '#'). // {%
+                    '|'.
+                    preg_quote($this->options['tag_comment'][0], '#'). // {#
+                ')('.
+                    preg_quote($this->options['whitespace_trim'], '#'). // -
+                    '|'.
+                    preg_quote($this->options['whitespace_line_trim'], '#'). // ~
+                ')?
+            }sx',
+            'interpolation_start' => '{'.preg_quote($this->options['interpolation'][0], '#').'\s*}A',
+            'interpolation_end' => '{\s*'.preg_quote($this->options['interpolation'][1], '#').'}A',
+        ];
+    }
+
+    public function tokenize(Source $source): TokenStream
+    {
+        $this->source = $source;
+        $this->code = str_replace(["\r\n", "\r"], "\n", $source->getCode());
+        $this->cursor = 0;
+        $this->lineno = 1;
+        $this->end = \strlen($this->code);
+        $this->tokens = [];
+        $this->state = self::STATE_DATA;
+        $this->states = [];
+        $this->brackets = [];
+        $this->position = -1;
+
+        // find all token starts in one go
+        preg_match_all($this->regexes['lex_tokens_start'], $this->code, $matches, \PREG_OFFSET_CAPTURE);
+        $this->positions = $matches;
+
+        while ($this->cursor < $this->end) {
+            // dispatch to the lexing functions depending
+            // on the current state
+            switch ($this->state) {
+                case self::STATE_DATA:
+                    $this->lexData();
+                    break;
+
+                case self::STATE_BLOCK:
+                    $this->lexBlock();
+                    break;
+
+                case self::STATE_VAR:
+                    $this->lexVar();
+                    break;
+
+                case self::STATE_STRING:
+                    $this->lexString();
+                    break;
+
+                case self::STATE_INTERPOLATION:
+                    $this->lexInterpolation();
+                    break;
+            }
+        }
+
+        $this->pushToken(/* Token::EOF_TYPE */ -1);
+
+        if (!empty($this->brackets)) {
+            list($expect, $lineno) = array_pop($this->brackets);
+            throw new SyntaxError(sprintf('Unclosed "%s".', $expect), $lineno, $this->source);
+        }
+
+        return new TokenStream($this->tokens, $this->source);
+    }
+
+    private function lexData(): void
+    {
+        // if no matches are left we return the rest of the template as simple text token
+        if ($this->position == \count($this->positions[0]) - 1) {
+            $this->pushToken(/* Token::TEXT_TYPE */ 0, substr($this->code, $this->cursor));
+            $this->cursor = $this->end;
+
+            return;
+        }
+
+        // Find the first token after the current cursor
+        $position = $this->positions[0][++$this->position];
+        while ($position[1] < $this->cursor) {
+            if ($this->position == \count($this->positions[0]) - 1) {
+                return;
+            }
+            $position = $this->positions[0][++$this->position];
+        }
+
+        // push the template text first
+        $text = $textContent = substr($this->code, $this->cursor, $position[1] - $this->cursor);
+
+        // trim?
+        if (isset($this->positions[2][$this->position][0])) {
+            if ($this->options['whitespace_trim'] === $this->positions[2][$this->position][0]) {
+                // whitespace_trim detected ({%-, {{- or {#-)
+                $text = rtrim($text);
+            } elseif ($this->options['whitespace_line_trim'] === $this->positions[2][$this->position][0]) {
+                // whitespace_line_trim detected ({%~, {{~ or {#~)
+                // don't trim \r and \n
+                $text = rtrim($text, " \t\0\x0B");
+            }
+        }
+        $this->pushToken(/* Token::TEXT_TYPE */ 0, $text);
+        $this->moveCursor($textContent.$position[0]);
+
+        switch ($this->positions[1][$this->position][0]) {
+            case $this->options['tag_comment'][0]:
+                $this->lexComment();
+                break;
+
+            case $this->options['tag_block'][0]:
+                // raw data?
+                if (preg_match($this->regexes['lex_block_raw'], $this->code, $match, 0, $this->cursor)) {
+                    $this->moveCursor($match[0]);
+                    $this->lexRawData();
+                // {% line \d+ %}
+                } elseif (preg_match($this->regexes['lex_block_line'], $this->code, $match, 0, $this->cursor)) {
+                    $this->moveCursor($match[0]);
+                    $this->lineno = (int) $match[1];
+                } else {
+                    $this->pushToken(/* Token::BLOCK_START_TYPE */ 1);
+                    $this->pushState(self::STATE_BLOCK);
+                    $this->currentVarBlockLine = $this->lineno;
+                }
+                break;
+
+            case $this->options['tag_variable'][0]:
+                $this->pushToken(/* Token::VAR_START_TYPE */ 2);
+                $this->pushState(self::STATE_VAR);
+                $this->currentVarBlockLine = $this->lineno;
+                break;
+        }
+    }
+
+    private function lexBlock(): void
+    {
+        if (empty($this->brackets) && preg_match($this->regexes['lex_block'], $this->code, $match, 0, $this->cursor)) {
+            $this->pushToken(/* Token::BLOCK_END_TYPE */ 3);
+            $this->moveCursor($match[0]);
+            $this->popState();
+        } else {
+            $this->lexExpression();
+        }
+    }
+
+    private function lexVar(): void
+    {
+        if (empty($this->brackets) && preg_match($this->regexes['lex_var'], $this->code, $match, 0, $this->cursor)) {
+            $this->pushToken(/* Token::VAR_END_TYPE */ 4);
+            $this->moveCursor($match[0]);
+            $this->popState();
+        } else {
+            $this->lexExpression();
+        }
+    }
+
+    private function lexExpression(): void
+    {
+        // whitespace
+        if (preg_match('/\s+/A', $this->code, $match, 0, $this->cursor)) {
+            $this->moveCursor($match[0]);
+
+            if ($this->cursor >= $this->end) {
+                throw new SyntaxError(sprintf('Unclosed "%s".', self::STATE_BLOCK === $this->state ? 'block' : 'variable'), $this->currentVarBlockLine, $this->source);
+            }
+        }
+
+        // arrow function
+        if ('=' === $this->code[$this->cursor] && '>' === $this->code[$this->cursor + 1]) {
+            $this->pushToken(Token::ARROW_TYPE, '=>');
+            $this->moveCursor('=>');
+        }
+        // operators
+        elseif (preg_match($this->regexes['operator'], $this->code, $match, 0, $this->cursor)) {
+            $this->pushToken(/* Token::OPERATOR_TYPE */ 8, preg_replace('/\s+/', ' ', $match[0]));
+            $this->moveCursor($match[0]);
+        }
+        // names
+        elseif (preg_match(self::REGEX_NAME, $this->code, $match, 0, $this->cursor)) {
+            $this->pushToken(/* Token::NAME_TYPE */ 5, $match[0]);
+            $this->moveCursor($match[0]);
+        }
+        // numbers
+        elseif (preg_match(self::REGEX_NUMBER, $this->code, $match, 0, $this->cursor)) {
+            $number = (float) $match[0];  // floats
+            if (ctype_digit($match[0]) && $number <= \PHP_INT_MAX) {
+                $number = (int) $match[0]; // integers lower than the maximum
+            }
+            $this->pushToken(/* Token::NUMBER_TYPE */ 6, $number);
+            $this->moveCursor($match[0]);
+        }
+        // punctuation
+        elseif (false !== strpos(self::PUNCTUATION, $this->code[$this->cursor])) {
+            // opening bracket
+            if (false !== strpos('([{', $this->code[$this->cursor])) {
+                $this->brackets[] = [$this->code[$this->cursor], $this->lineno];
+            }
+            // closing bracket
+            elseif (false !== strpos(')]}', $this->code[$this->cursor])) {
+                if (empty($this->brackets)) {
+                    throw new SyntaxError(sprintf('Unexpected "%s".', $this->code[$this->cursor]), $this->lineno, $this->source);
+                }
+
+                list($expect, $lineno) = array_pop($this->brackets);
+                if ($this->code[$this->cursor] != strtr($expect, '([{', ')]}')) {
+                    throw new SyntaxError(sprintf('Unclosed "%s".', $expect), $lineno, $this->source);
+                }
+            }
+
+            $this->pushToken(/* Token::PUNCTUATION_TYPE */ 9, $this->code[$this->cursor]);
+            ++$this->cursor;
+        }
+        // strings
+        elseif (preg_match(self::REGEX_STRING, $this->code, $match, 0, $this->cursor)) {
+            $this->pushToken(/* Token::STRING_TYPE */ 7, stripcslashes(substr($match[0], 1, -1)));
+            $this->moveCursor($match[0]);
+        }
+        // opening double quoted string
+        elseif (preg_match(self::REGEX_DQ_STRING_DELIM, $this->code, $match, 0, $this->cursor)) {
+            $this->brackets[] = ['"', $this->lineno];
+            $this->pushState(self::STATE_STRING);
+            $this->moveCursor($match[0]);
+        }
+        // unlexable
+        else {
+            throw new SyntaxError(sprintf('Unexpected character "%s".', $this->code[$this->cursor]), $this->lineno, $this->source);
+        }
+    }
+
+    private function lexRawData(): void
+    {
+        if (!preg_match($this->regexes['lex_raw_data'], $this->code, $match, \PREG_OFFSET_CAPTURE, $this->cursor)) {
+            throw new SyntaxError('Unexpected end of file: Unclosed "verbatim" block.', $this->lineno, $this->source);
+        }
+
+        $text = substr($this->code, $this->cursor, $match[0][1] - $this->cursor);
+        $this->moveCursor($text.$match[0][0]);
+
+        // trim?
+        if (isset($match[1][0])) {
+            if ($this->options['whitespace_trim'] === $match[1][0]) {
+                // whitespace_trim detected ({%-, {{- or {#-)
+                $text = rtrim($text);
+            } else {
+                // whitespace_line_trim detected ({%~, {{~ or {#~)
+                // don't trim \r and \n
+                $text = rtrim($text, " \t\0\x0B");
+            }
+        }
+
+        $this->pushToken(/* Token::TEXT_TYPE */ 0, $text);
+    }
+
+    private function lexComment(): void
+    {
+        if (!preg_match($this->regexes['lex_comment'], $this->code, $match, \PREG_OFFSET_CAPTURE, $this->cursor)) {
+            throw new SyntaxError('Unclosed comment.', $this->lineno, $this->source);
+        }
+
+        $this->moveCursor(substr($this->code, $this->cursor, $match[0][1] - $this->cursor).$match[0][0]);
+    }
+
+    private function lexString(): void
+    {
+        if (preg_match($this->regexes['interpolation_start'], $this->code, $match, 0, $this->cursor)) {
+            $this->brackets[] = [$this->options['interpolation'][0], $this->lineno];
+            $this->pushToken(/* Token::INTERPOLATION_START_TYPE */ 10);
+            $this->moveCursor($match[0]);
+            $this->pushState(self::STATE_INTERPOLATION);
+        } elseif (preg_match(self::REGEX_DQ_STRING_PART, $this->code, $match, 0, $this->cursor) && \strlen($match[0]) > 0) {
+            $this->pushToken(/* Token::STRING_TYPE */ 7, stripcslashes($match[0]));
+            $this->moveCursor($match[0]);
+        } elseif (preg_match(self::REGEX_DQ_STRING_DELIM, $this->code, $match, 0, $this->cursor)) {
+            list($expect, $lineno) = array_pop($this->brackets);
+            if ('"' != $this->code[$this->cursor]) {
+                throw new SyntaxError(sprintf('Unclosed "%s".', $expect), $lineno, $this->source);
+            }
+
+            $this->popState();
+            ++$this->cursor;
+        } else {
+            // unlexable
+            throw new SyntaxError(sprintf('Unexpected character "%s".', $this->code[$this->cursor]), $this->lineno, $this->source);
+        }
+    }
+
+    private function lexInterpolation(): void
+    {
+        $bracket = end($this->brackets);
+        if ($this->options['interpolation'][0] === $bracket[0] && preg_match($this->regexes['interpolation_end'], $this->code, $match, 0, $this->cursor)) {
+            array_pop($this->brackets);
+            $this->pushToken(/* Token::INTERPOLATION_END_TYPE */ 11);
+            $this->moveCursor($match[0]);
+            $this->popState();
+        } else {
+            $this->lexExpression();
+        }
+    }
+
+    private function pushToken($type, $value = ''): void
+    {
+        // do not push empty text tokens
+        if (/* Token::TEXT_TYPE */ 0 === $type && '' === $value) {
+            return;
+        }
+
+        $this->tokens[] = new Token($type, $value, $this->lineno);
+    }
+
+    private function moveCursor($text): void
+    {
+        $this->cursor += \strlen($text);
+        $this->lineno += substr_count($text, "\n");
+    }
+
+    private function getOperatorRegex(): string
+    {
+        $operators = array_merge(
+            ['='],
+            array_keys($this->env->getUnaryOperators()),
+            array_keys($this->env->getBinaryOperators())
+        );
+
+        $operators = array_combine($operators, array_map('strlen', $operators));
+        arsort($operators);
+
+        $regex = [];
+        foreach ($operators as $operator => $length) {
+            // an operator that ends with a character must be followed by
+            // a whitespace, a parenthesis, an opening map [ or sequence {
+            $r = preg_quote($operator, '/');
+            if (ctype_alpha($operator[$length - 1])) {
+                $r .= '(?=[\s()\[{])';
+            }
+
+            // an operator that begins with a character must not have a dot or pipe before
+            if (ctype_alpha($operator[0])) {
+                $r = '(?<![\.\|])'.$r;
+            }
+
+            // an operator with a space can be any amount of whitespaces
+            $r = preg_replace('/\s+/', '\s+', $r);
+
+            $regex[] = $r;
+        }
+
+        return '/'.implode('|', $regex).'/A';
+    }
+
+    private function pushState($state): void
+    {
+        $this->states[] = $this->state;
+        $this->state = $state;
+    }
+
+    private function popState(): void
+    {
+        if (0 === \count($this->states)) {
+            throw new \LogicException('Cannot pop state without a previous state.');
+        }
+
+        $this->state = array_pop($this->states);
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Loader/ArrayLoader.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Loader/ArrayLoader.php
new file mode 100644
index 0000000..5d726c3
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Loader/ArrayLoader.php
@@ -0,0 +1,77 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Loader;
+
+use Twig\Error\LoaderError;
+use Twig\Source;
+
+/**
+ * Loads a template from an array.
+ *
+ * When using this loader with a cache mechanism, you should know that a new cache
+ * key is generated each time a template content "changes" (the cache key being the
+ * source code of the template). If you don't want to see your cache grows out of
+ * control, you need to take care of clearing the old cache file by yourself.
+ *
+ * This loader should only be used for unit testing.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+final class ArrayLoader implements LoaderInterface
+{
+    private $templates = [];
+
+    /**
+     * @param array $templates An array of templates (keys are the names, and values are the source code)
+     */
+    public function __construct(array $templates = [])
+    {
+        $this->templates = $templates;
+    }
+
+    public function setTemplate(string $name, string $template): void
+    {
+        $this->templates[$name] = $template;
+    }
+
+    public function getSourceContext(string $name): Source
+    {
+        if (!isset($this->templates[$name])) {
+            throw new LoaderError(sprintf('Template "%s" is not defined.', $name));
+        }
+
+        return new Source($this->templates[$name], $name);
+    }
+
+    public function exists(string $name): bool
+    {
+        return isset($this->templates[$name]);
+    }
+
+    public function getCacheKey(string $name): string
+    {
+        if (!isset($this->templates[$name])) {
+            throw new LoaderError(sprintf('Template "%s" is not defined.', $name));
+        }
+
+        return $name.':'.$this->templates[$name];
+    }
+
+    public function isFresh(string $name, int $time): bool
+    {
+        if (!isset($this->templates[$name])) {
+            throw new LoaderError(sprintf('Template "%s" is not defined.', $name));
+        }
+
+        return true;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Loader/ChainLoader.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Loader/ChainLoader.php
new file mode 100644
index 0000000..fbf4f3a
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Loader/ChainLoader.php
@@ -0,0 +1,119 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Loader;
+
+use Twig\Error\LoaderError;
+use Twig\Source;
+
+/**
+ * Loads templates from other loaders.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+final class ChainLoader implements LoaderInterface
+{
+    private $hasSourceCache = [];
+    private $loaders = [];
+
+    /**
+     * @param LoaderInterface[] $loaders
+     */
+    public function __construct(array $loaders = [])
+    {
+        foreach ($loaders as $loader) {
+            $this->addLoader($loader);
+        }
+    }
+
+    public function addLoader(LoaderInterface $loader): void
+    {
+        $this->loaders[] = $loader;
+        $this->hasSourceCache = [];
+    }
+
+    /**
+     * @return LoaderInterface[]
+     */
+    public function getLoaders(): array
+    {
+        return $this->loaders;
+    }
+
+    public function getSourceContext(string $name): Source
+    {
+        $exceptions = [];
+        foreach ($this->loaders as $loader) {
+            if (!$loader->exists($name)) {
+                continue;
+            }
+
+            try {
+                return $loader->getSourceContext($name);
+            } catch (LoaderError $e) {
+                $exceptions[] = $e->getMessage();
+            }
+        }
+
+        throw new LoaderError(sprintf('Template "%s" is not defined%s.', $name, $exceptions ? ' ('.implode(', ', $exceptions).')' : ''));
+    }
+
+    public function exists(string $name): bool
+    {
+        if (isset($this->hasSourceCache[$name])) {
+            return $this->hasSourceCache[$name];
+        }
+
+        foreach ($this->loaders as $loader) {
+            if ($loader->exists($name)) {
+                return $this->hasSourceCache[$name] = true;
+            }
+        }
+
+        return $this->hasSourceCache[$name] = false;
+    }
+
+    public function getCacheKey(string $name): string
+    {
+        $exceptions = [];
+        foreach ($this->loaders as $loader) {
+            if (!$loader->exists($name)) {
+                continue;
+            }
+
+            try {
+                return $loader->getCacheKey($name);
+            } catch (LoaderError $e) {
+                $exceptions[] = \get_class($loader).': '.$e->getMessage();
+            }
+        }
+
+        throw new LoaderError(sprintf('Template "%s" is not defined%s.', $name, $exceptions ? ' ('.implode(', ', $exceptions).')' : ''));
+    }
+
+    public function isFresh(string $name, int $time): bool
+    {
+        $exceptions = [];
+        foreach ($this->loaders as $loader) {
+            if (!$loader->exists($name)) {
+                continue;
+            }
+
+            try {
+                return $loader->isFresh($name, $time);
+            } catch (LoaderError $e) {
+                $exceptions[] = \get_class($loader).': '.$e->getMessage();
+            }
+        }
+
+        throw new LoaderError(sprintf('Template "%s" is not defined%s.', $name, $exceptions ? ' ('.implode(', ', $exceptions).')' : ''));
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Loader/FilesystemLoader.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Loader/FilesystemLoader.php
new file mode 100644
index 0000000..859a898
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Loader/FilesystemLoader.php
@@ -0,0 +1,283 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Loader;
+
+use Twig\Error\LoaderError;
+use Twig\Source;
+
+/**
+ * Loads template from the filesystem.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class FilesystemLoader implements LoaderInterface
+{
+    /** Identifier of the main namespace. */
+    public const MAIN_NAMESPACE = '__main__';
+
+    protected $paths = [];
+    protected $cache = [];
+    protected $errorCache = [];
+
+    private $rootPath;
+
+    /**
+     * @param string|array $paths    A path or an array of paths where to look for templates
+     * @param string|null  $rootPath The root path common to all relative paths (null for getcwd())
+     */
+    public function __construct($paths = [], string $rootPath = null)
+    {
+        $this->rootPath = (null === $rootPath ? getcwd() : $rootPath).\DIRECTORY_SEPARATOR;
+        if (null !== $rootPath && false !== ($realPath = realpath($rootPath))) {
+            $this->rootPath = $realPath.\DIRECTORY_SEPARATOR;
+        }
+
+        if ($paths) {
+            $this->setPaths($paths);
+        }
+    }
+
+    /**
+     * Returns the paths to the templates.
+     */
+    public function getPaths(string $namespace = self::MAIN_NAMESPACE): array
+    {
+        return $this->paths[$namespace] ?? [];
+    }
+
+    /**
+     * Returns the path namespaces.
+     *
+     * The main namespace is always defined.
+     */
+    public function getNamespaces(): array
+    {
+        return array_keys($this->paths);
+    }
+
+    /**
+     * @param string|array $paths A path or an array of paths where to look for templates
+     */
+    public function setPaths($paths, string $namespace = self::MAIN_NAMESPACE): void
+    {
+        if (!\is_array($paths)) {
+            $paths = [$paths];
+        }
+
+        $this->paths[$namespace] = [];
+        foreach ($paths as $path) {
+            $this->addPath($path, $namespace);
+        }
+    }
+
+    /**
+     * @throws LoaderError
+     */
+    public function addPath(string $path, string $namespace = self::MAIN_NAMESPACE): void
+    {
+        // invalidate the cache
+        $this->cache = $this->errorCache = [];
+
+        $checkPath = $this->isAbsolutePath($path) ? $path : $this->rootPath.$path;
+        if (!is_dir($checkPath)) {
+            throw new LoaderError(sprintf('The "%s" directory does not exist ("%s").', $path, $checkPath));
+        }
+
+        $this->paths[$namespace][] = rtrim($path, '/\\');
+    }
+
+    /**
+     * @throws LoaderError
+     */
+    public function prependPath(string $path, string $namespace = self::MAIN_NAMESPACE): void
+    {
+        // invalidate the cache
+        $this->cache = $this->errorCache = [];
+
+        $checkPath = $this->isAbsolutePath($path) ? $path : $this->rootPath.$path;
+        if (!is_dir($checkPath)) {
+            throw new LoaderError(sprintf('The "%s" directory does not exist ("%s").', $path, $checkPath));
+        }
+
+        $path = rtrim($path, '/\\');
+
+        if (!isset($this->paths[$namespace])) {
+            $this->paths[$namespace][] = $path;
+        } else {
+            array_unshift($this->paths[$namespace], $path);
+        }
+    }
+
+    public function getSourceContext(string $name): Source
+    {
+        if (null === $path = $this->findTemplate($name)) {
+            return new Source('', $name, '');
+        }
+
+        return new Source(file_get_contents($path), $name, $path);
+    }
+
+    public function getCacheKey(string $name): string
+    {
+        if (null === $path = $this->findTemplate($name)) {
+            return '';
+        }
+        $len = \strlen($this->rootPath);
+        if (0 === strncmp($this->rootPath, $path, $len)) {
+            return substr($path, $len);
+        }
+
+        return $path;
+    }
+
+    /**
+     * @return bool
+     */
+    public function exists(string $name)
+    {
+        $name = $this->normalizeName($name);
+
+        if (isset($this->cache[$name])) {
+            return true;
+        }
+
+        return null !== $this->findTemplate($name, false);
+    }
+
+    public function isFresh(string $name, int $time): bool
+    {
+        // false support to be removed in 3.0
+        if (null === $path = $this->findTemplate($name)) {
+            return false;
+        }
+
+        return filemtime($path) < $time;
+    }
+
+    /**
+     * @return string|null
+     */
+    protected function findTemplate(string $name, bool $throw = true)
+    {
+        $name = $this->normalizeName($name);
+
+        if (isset($this->cache[$name])) {
+            return $this->cache[$name];
+        }
+
+        if (isset($this->errorCache[$name])) {
+            if (!$throw) {
+                return null;
+            }
+
+            throw new LoaderError($this->errorCache[$name]);
+        }
+
+        try {
+            $this->validateName($name);
+
+            list($namespace, $shortname) = $this->parseName($name);
+        } catch (LoaderError $e) {
+            if (!$throw) {
+                return null;
+            }
+
+            throw $e;
+        }
+
+        if (!isset($this->paths[$namespace])) {
+            $this->errorCache[$name] = sprintf('There are no registered paths for namespace "%s".', $namespace);
+
+            if (!$throw) {
+                return null;
+            }
+
+            throw new LoaderError($this->errorCache[$name]);
+        }
+
+        foreach ($this->paths[$namespace] as $path) {
+            if (!$this->isAbsolutePath($path)) {
+                $path = $this->rootPath.$path;
+            }
+
+            if (is_file($path.'/'.$shortname)) {
+                if (false !== $realpath = realpath($path.'/'.$shortname)) {
+                    return $this->cache[$name] = $realpath;
+                }
+
+                return $this->cache[$name] = $path.'/'.$shortname;
+            }
+        }
+
+        $this->errorCache[$name] = sprintf('Unable to find template "%s" (looked into: %s).', $name, implode(', ', $this->paths[$namespace]));
+
+        if (!$throw) {
+            return null;
+        }
+
+        throw new LoaderError($this->errorCache[$name]);
+    }
+
+    private function normalizeName(string $name): string
+    {
+        return preg_replace('#/{2,}#', '/', str_replace('\\', '/', $name));
+    }
+
+    private function parseName(string $name, string $default = self::MAIN_NAMESPACE): array
+    {
+        if (isset($name[0]) && '@' == $name[0]) {
+            if (false === $pos = strpos($name, '/')) {
+                throw new LoaderError(sprintf('Malformed namespaced template name "%s" (expecting "@namespace/template_name").', $name));
+            }
+
+            $namespace = substr($name, 1, $pos - 1);
+            $shortname = substr($name, $pos + 1);
+
+            return [$namespace, $shortname];
+        }
+
+        return [$default, $name];
+    }
+
+    private function validateName(string $name): void
+    {
+        if (false !== strpos($name, "\0")) {
+            throw new LoaderError('A template name cannot contain NUL bytes.');
+        }
+
+        $name = ltrim($name, '/');
+        $parts = explode('/', $name);
+        $level = 0;
+        foreach ($parts as $part) {
+            if ('..' === $part) {
+                --$level;
+            } elseif ('.' !== $part) {
+                ++$level;
+            }
+
+            if ($level < 0) {
+                throw new LoaderError(sprintf('Looks like you try to load a template outside configured directories (%s).', $name));
+            }
+        }
+    }
+
+    private function isAbsolutePath(string $file): bool
+    {
+        return strspn($file, '/\\', 0, 1)
+            || (\strlen($file) > 3 && ctype_alpha($file[0])
+                && ':' === $file[1]
+                && strspn($file, '/\\', 2, 1)
+            )
+            || null !== parse_url($file, \PHP_URL_SCHEME)
+        ;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Loader/LoaderInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Loader/LoaderInterface.php
new file mode 100644
index 0000000..fec7e85
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Loader/LoaderInterface.php
@@ -0,0 +1,49 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Loader;
+
+use Twig\Error\LoaderError;
+use Twig\Source;
+
+/**
+ * Interface all loaders must implement.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+interface LoaderInterface
+{
+    /**
+     * Returns the source context for a given template logical name.
+     *
+     * @throws LoaderError When $name is not found
+     */
+    public function getSourceContext(string $name): Source;
+
+    /**
+     * Gets the cache key to use for the cache for a given template name.
+     *
+     * @throws LoaderError When $name is not found
+     */
+    public function getCacheKey(string $name): string;
+
+    /**
+     * @param int $time Timestamp of the last modification time of the cached template
+     *
+     * @throws LoaderError When $name is not found
+     */
+    public function isFresh(string $name, int $time): bool;
+
+    /**
+     * @return bool
+     */
+    public function exists(string $name);
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Markup.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Markup.php
new file mode 100644
index 0000000..c8c5e1a
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Markup.php
@@ -0,0 +1,47 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig;
+
+/**
+ * Marks a content as safe.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class Markup implements \Countable, \JsonSerializable
+{
+    private $content;
+    private $charset;
+
+    public function __construct($content, $charset)
+    {
+        $this->content = (string) $content;
+        $this->charset = $charset;
+    }
+
+    public function __toString()
+    {
+        return $this->content;
+    }
+
+    /**
+     * @return int
+     */
+    public function count()
+    {
+        return mb_strlen($this->content, $this->charset);
+    }
+
+    public function jsonSerialize()
+    {
+        return $this->content;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/AutoEscapeNode.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/AutoEscapeNode.php
new file mode 100644
index 0000000..cd97041
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/AutoEscapeNode.php
@@ -0,0 +1,38 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node;
+
+use Twig\Compiler;
+
+/**
+ * Represents an autoescape node.
+ *
+ * The value is the escaping strategy (can be html, js, ...)
+ *
+ * The true value is equivalent to html.
+ *
+ * If autoescaping is disabled, then the value is false.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class AutoEscapeNode extends Node
+{
+    public function __construct($value, Node $body, int $lineno, string $tag = 'autoescape')
+    {
+        parent::__construct(['body' => $body], ['value' => $value], $lineno, $tag);
+    }
+
+    public function compile(Compiler $compiler): void
+    {
+        $compiler->subcompile($this->getNode('body'));
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/BlockNode.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/BlockNode.php
new file mode 100644
index 0000000..0632ba7
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/BlockNode.php
@@ -0,0 +1,44 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node;
+
+use Twig\Compiler;
+
+/**
+ * Represents a block node.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class BlockNode extends Node
+{
+    public function __construct(string $name, Node $body, int $lineno, string $tag = null)
+    {
+        parent::__construct(['body' => $body], ['name' => $name], $lineno, $tag);
+    }
+
+    public function compile(Compiler $compiler): void
+    {
+        $compiler
+            ->addDebugInfo($this)
+            ->write(sprintf("public function block_%s(\$context, array \$blocks = [])\n", $this->getAttribute('name')), "{\n")
+            ->indent()
+            ->write("\$macros = \$this->macros;\n")
+        ;
+
+        $compiler
+            ->subcompile($this->getNode('body'))
+            ->outdent()
+            ->write("}\n\n")
+        ;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/BlockReferenceNode.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/BlockReferenceNode.php
new file mode 100644
index 0000000..cc8af5b
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/BlockReferenceNode.php
@@ -0,0 +1,36 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node;
+
+use Twig\Compiler;
+
+/**
+ * Represents a block call node.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class BlockReferenceNode extends Node implements NodeOutputInterface
+{
+    public function __construct(string $name, int $lineno, string $tag = null)
+    {
+        parent::__construct([], ['name' => $name], $lineno, $tag);
+    }
+
+    public function compile(Compiler $compiler): void
+    {
+        $compiler
+            ->addDebugInfo($this)
+            ->write(sprintf("\$this->displayBlock('%s', \$context, \$blocks);\n", $this->getAttribute('name')))
+        ;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/BodyNode.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/BodyNode.php
new file mode 100644
index 0000000..041cbf6
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/BodyNode.php
@@ -0,0 +1,21 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node;
+
+/**
+ * Represents a body node.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class BodyNode extends Node
+{
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/CheckSecurityCallNode.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/CheckSecurityCallNode.php
new file mode 100644
index 0000000..a78a38d
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/CheckSecurityCallNode.php
@@ -0,0 +1,28 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node;
+
+use Twig\Compiler;
+
+/**
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class CheckSecurityCallNode extends Node
+{
+    public function compile(Compiler $compiler)
+    {
+        $compiler
+            ->write("\$this->sandbox = \$this->env->getExtension('\Twig\Extension\SandboxExtension');\n")
+            ->write("\$this->checkSecurity();\n")
+        ;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/CheckSecurityNode.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/CheckSecurityNode.php
new file mode 100644
index 0000000..4727327
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/CheckSecurityNode.php
@@ -0,0 +1,88 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node;
+
+use Twig\Compiler;
+
+/**
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class CheckSecurityNode extends Node
+{
+    private $usedFilters;
+    private $usedTags;
+    private $usedFunctions;
+
+    public function __construct(array $usedFilters, array $usedTags, array $usedFunctions)
+    {
+        $this->usedFilters = $usedFilters;
+        $this->usedTags = $usedTags;
+        $this->usedFunctions = $usedFunctions;
+
+        parent::__construct();
+    }
+
+    public function compile(Compiler $compiler): void
+    {
+        $tags = $filters = $functions = [];
+        foreach (['tags', 'filters', 'functions'] as $type) {
+            foreach ($this->{'used'.ucfirst($type)} as $name => $node) {
+                if ($node instanceof Node) {
+                    ${$type}[$name] = $node->getTemplateLine();
+                } else {
+                    ${$type}[$node] = null;
+                }
+            }
+        }
+
+        $compiler
+            ->write("\n")
+            ->write("public function checkSecurity()\n")
+            ->write("{\n")
+            ->indent()
+            ->write('static $tags = ')->repr(array_filter($tags))->raw(";\n")
+            ->write('static $filters = ')->repr(array_filter($filters))->raw(";\n")
+            ->write('static $functions = ')->repr(array_filter($functions))->raw(";\n\n")
+            ->write("try {\n")
+            ->indent()
+            ->write("\$this->sandbox->checkSecurity(\n")
+            ->indent()
+            ->write(!$tags ? "[],\n" : "['".implode("', '", array_keys($tags))."'],\n")
+            ->write(!$filters ? "[],\n" : "['".implode("', '", array_keys($filters))."'],\n")
+            ->write(!$functions ? "[]\n" : "['".implode("', '", array_keys($functions))."']\n")
+            ->outdent()
+            ->write(");\n")
+            ->outdent()
+            ->write("} catch (SecurityError \$e) {\n")
+            ->indent()
+            ->write("\$e->setSourceContext(\$this->source);\n\n")
+            ->write("if (\$e instanceof SecurityNotAllowedTagError && isset(\$tags[\$e->getTagName()])) {\n")
+            ->indent()
+            ->write("\$e->setTemplateLine(\$tags[\$e->getTagName()]);\n")
+            ->outdent()
+            ->write("} elseif (\$e instanceof SecurityNotAllowedFilterError && isset(\$filters[\$e->getFilterName()])) {\n")
+            ->indent()
+            ->write("\$e->setTemplateLine(\$filters[\$e->getFilterName()]);\n")
+            ->outdent()
+            ->write("} elseif (\$e instanceof SecurityNotAllowedFunctionError && isset(\$functions[\$e->getFunctionName()])) {\n")
+            ->indent()
+            ->write("\$e->setTemplateLine(\$functions[\$e->getFunctionName()]);\n")
+            ->outdent()
+            ->write("}\n\n")
+            ->write("throw \$e;\n")
+            ->outdent()
+            ->write("}\n\n")
+            ->outdent()
+            ->write("}\n")
+        ;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/CheckToStringNode.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/CheckToStringNode.php
new file mode 100644
index 0000000..c7a9d69
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/CheckToStringNode.php
@@ -0,0 +1,45 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node;
+
+use Twig\Compiler;
+use Twig\Node\Expression\AbstractExpression;
+
+/**
+ * Checks if casting an expression to __toString() is allowed by the sandbox.
+ *
+ * For instance, when there is a simple Print statement, like {{ article }},
+ * and if the sandbox is enabled, we need to check that the __toString()
+ * method is allowed if 'article' is an object. The same goes for {{ article|upper }}
+ * or {{ random(article) }}
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class CheckToStringNode extends AbstractExpression
+{
+    public function __construct(AbstractExpression $expr)
+    {
+        parent::__construct(['expr' => $expr], [], $expr->getTemplateLine(), $expr->getNodeTag());
+    }
+
+    public function compile(Compiler $compiler): void
+    {
+        $expr = $this->getNode('expr');
+        $compiler
+            ->raw('$this->sandbox->ensureToStringAllowed(')
+            ->subcompile($expr)
+            ->raw(', ')
+            ->repr($expr->getTemplateLine())
+            ->raw(', $this->source)')
+        ;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/DeprecatedNode.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/DeprecatedNode.php
new file mode 100644
index 0000000..5ff4430
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/DeprecatedNode.php
@@ -0,0 +1,53 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node;
+
+use Twig\Compiler;
+use Twig\Node\Expression\AbstractExpression;
+use Twig\Node\Expression\ConstantExpression;
+
+/**
+ * Represents a deprecated node.
+ *
+ * @author Yonel Ceruto <yonelceruto@gmail.com>
+ */
+class DeprecatedNode extends Node
+{
+    public function __construct(AbstractExpression $expr, int $lineno, string $tag = null)
+    {
+        parent::__construct(['expr' => $expr], [], $lineno, $tag);
+    }
+
+    public function compile(Compiler $compiler): void
+    {
+        $compiler->addDebugInfo($this);
+
+        $expr = $this->getNode('expr');
+
+        if ($expr instanceof ConstantExpression) {
+            $compiler->write('@trigger_error(')
+                ->subcompile($expr);
+        } else {
+            $varName = $compiler->getVarName();
+            $compiler->write(sprintf('$%s = ', $varName))
+                ->subcompile($expr)
+                ->raw(";\n")
+                ->write(sprintf('@trigger_error($%s', $varName));
+        }
+
+        $compiler
+            ->raw('.')
+            ->string(sprintf(' ("%s" at line %d).', $this->getTemplateName(), $this->getTemplateLine()))
+            ->raw(", E_USER_DEPRECATED);\n")
+        ;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/DoNode.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/DoNode.php
new file mode 100644
index 0000000..f7783d1
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/DoNode.php
@@ -0,0 +1,38 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node;
+
+use Twig\Compiler;
+use Twig\Node\Expression\AbstractExpression;
+
+/**
+ * Represents a do node.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class DoNode extends Node
+{
+    public function __construct(AbstractExpression $expr, int $lineno, string $tag = null)
+    {
+        parent::__construct(['expr' => $expr], [], $lineno, $tag);
+    }
+
+    public function compile(Compiler $compiler): void
+    {
+        $compiler
+            ->addDebugInfo($this)
+            ->write('')
+            ->subcompile($this->getNode('expr'))
+            ->raw(";\n")
+        ;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/EmbedNode.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/EmbedNode.php
new file mode 100644
index 0000000..903c3f6
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/EmbedNode.php
@@ -0,0 +1,48 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node;
+
+use Twig\Compiler;
+use Twig\Node\Expression\AbstractExpression;
+use Twig\Node\Expression\ConstantExpression;
+
+/**
+ * Represents an embed node.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class EmbedNode extends IncludeNode
+{
+    // we don't inject the module to avoid node visitors to traverse it twice (as it will be already visited in the main module)
+    public function __construct(string $name, int $index, ?AbstractExpression $variables, bool $only, bool $ignoreMissing, int $lineno, string $tag = null)
+    {
+        parent::__construct(new ConstantExpression('not_used', $lineno), $variables, $only, $ignoreMissing, $lineno, $tag);
+
+        $this->setAttribute('name', $name);
+        $this->setAttribute('index', $index);
+    }
+
+    protected function addGetTemplate(Compiler $compiler): void
+    {
+        $compiler
+            ->write('$this->loadTemplate(')
+            ->string($this->getAttribute('name'))
+            ->raw(', ')
+            ->repr($this->getTemplateName())
+            ->raw(', ')
+            ->repr($this->getTemplateLine())
+            ->raw(', ')
+            ->string($this->getAttribute('index'))
+            ->raw(')')
+        ;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/AbstractExpression.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/AbstractExpression.php
new file mode 100644
index 0000000..42da055
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/AbstractExpression.php
@@ -0,0 +1,24 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression;
+
+use Twig\Node\Node;
+
+/**
+ * Abstract class for all nodes that represents an expression.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+abstract class AbstractExpression extends Node
+{
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/ArrayExpression.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/ArrayExpression.php
new file mode 100644
index 0000000..0e25fe4
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/ArrayExpression.php
@@ -0,0 +1,85 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression;
+
+use Twig\Compiler;
+
+class ArrayExpression extends AbstractExpression
+{
+    private $index;
+
+    public function __construct(array $elements, int $lineno)
+    {
+        parent::__construct($elements, [], $lineno);
+
+        $this->index = -1;
+        foreach ($this->getKeyValuePairs() as $pair) {
+            if ($pair['key'] instanceof ConstantExpression && ctype_digit((string) $pair['key']->getAttribute('value')) && $pair['key']->getAttribute('value') > $this->index) {
+                $this->index = $pair['key']->getAttribute('value');
+            }
+        }
+    }
+
+    public function getKeyValuePairs(): array
+    {
+        $pairs = [];
+        foreach (array_chunk($this->nodes, 2) as $pair) {
+            $pairs[] = [
+                'key' => $pair[0],
+                'value' => $pair[1],
+            ];
+        }
+
+        return $pairs;
+    }
+
+    public function hasElement(AbstractExpression $key): bool
+    {
+        foreach ($this->getKeyValuePairs() as $pair) {
+            // we compare the string representation of the keys
+            // to avoid comparing the line numbers which are not relevant here.
+            if ((string) $key === (string) $pair['key']) {
+                return true;
+            }
+        }
+
+        return false;
+    }
+
+    public function addElement(AbstractExpression $value, AbstractExpression $key = null): void
+    {
+        if (null === $key) {
+            $key = new ConstantExpression(++$this->index, $value->getTemplateLine());
+        }
+
+        array_push($this->nodes, $key, $value);
+    }
+
+    public function compile(Compiler $compiler): void
+    {
+        $compiler->raw('[');
+        $first = true;
+        foreach ($this->getKeyValuePairs() as $pair) {
+            if (!$first) {
+                $compiler->raw(', ');
+            }
+            $first = false;
+
+            $compiler
+                ->subcompile($pair['key'])
+                ->raw(' => ')
+                ->subcompile($pair['value'])
+            ;
+        }
+        $compiler->raw(']');
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/ArrowFunctionExpression.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/ArrowFunctionExpression.php
new file mode 100644
index 0000000..eaad03c
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/ArrowFunctionExpression.php
@@ -0,0 +1,64 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression;
+
+use Twig\Compiler;
+use Twig\Node\Node;
+
+/**
+ * Represents an arrow function.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class ArrowFunctionExpression extends AbstractExpression
+{
+    public function __construct(AbstractExpression $expr, Node $names, $lineno, $tag = null)
+    {
+        parent::__construct(['expr' => $expr, 'names' => $names], [], $lineno, $tag);
+    }
+
+    public function compile(Compiler $compiler): void
+    {
+        $compiler
+            ->addDebugInfo($this)
+            ->raw('function (')
+        ;
+        foreach ($this->getNode('names') as $i => $name) {
+            if ($i) {
+                $compiler->raw(', ');
+            }
+
+            $compiler
+                ->raw('$__')
+                ->raw($name->getAttribute('name'))
+                ->raw('__')
+            ;
+        }
+        $compiler
+            ->raw(') use ($context, $macros) { ')
+        ;
+        foreach ($this->getNode('names') as $name) {
+            $compiler
+                ->raw('$context["')
+                ->raw($name->getAttribute('name'))
+                ->raw('"] = $__')
+                ->raw($name->getAttribute('name'))
+                ->raw('__; ')
+            ;
+        }
+        $compiler
+            ->raw('return ')
+            ->subcompile($this->getNode('expr'))
+            ->raw('; }')
+        ;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/AssignNameExpression.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/AssignNameExpression.php
new file mode 100644
index 0000000..7dd1bc4
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/AssignNameExpression.php
@@ -0,0 +1,27 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression;
+
+use Twig\Compiler;
+
+class AssignNameExpression extends NameExpression
+{
+    public function compile(Compiler $compiler): void
+    {
+        $compiler
+            ->raw('$context[')
+            ->string($this->getAttribute('name'))
+            ->raw(']')
+        ;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/AbstractBinary.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/AbstractBinary.php
new file mode 100644
index 0000000..c424e5c
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/AbstractBinary.php
@@ -0,0 +1,42 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression\Binary;
+
+use Twig\Compiler;
+use Twig\Node\Expression\AbstractExpression;
+use Twig\Node\Node;
+
+abstract class AbstractBinary extends AbstractExpression
+{
+    public function __construct(Node $left, Node $right, int $lineno)
+    {
+        parent::__construct(['left' => $left, 'right' => $right], [], $lineno);
+    }
+
+    public function compile(Compiler $compiler): void
+    {
+        $compiler
+            ->raw('(')
+            ->subcompile($this->getNode('left'))
+            ->raw(' ')
+        ;
+        $this->operator($compiler);
+        $compiler
+            ->raw(' ')
+            ->subcompile($this->getNode('right'))
+            ->raw(')')
+        ;
+    }
+
+    abstract public function operator(Compiler $compiler): Compiler;
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/AddBinary.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/AddBinary.php
new file mode 100644
index 0000000..ee4307e
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/AddBinary.php
@@ -0,0 +1,23 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression\Binary;
+
+use Twig\Compiler;
+
+class AddBinary extends AbstractBinary
+{
+    public function operator(Compiler $compiler): Compiler
+    {
+        return $compiler->raw('+');
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/AndBinary.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/AndBinary.php
new file mode 100644
index 0000000..5f2380d
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/AndBinary.php
@@ -0,0 +1,23 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression\Binary;
+
+use Twig\Compiler;
+
+class AndBinary extends AbstractBinary
+{
+    public function operator(Compiler $compiler): Compiler
+    {
+        return $compiler->raw('&&');
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/BitwiseAndBinary.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/BitwiseAndBinary.php
new file mode 100644
index 0000000..db7d6d6
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/BitwiseAndBinary.php
@@ -0,0 +1,23 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression\Binary;
+
+use Twig\Compiler;
+
+class BitwiseAndBinary extends AbstractBinary
+{
+    public function operator(Compiler $compiler): Compiler
+    {
+        return $compiler->raw('&');
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/BitwiseOrBinary.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/BitwiseOrBinary.php
new file mode 100644
index 0000000..ce803dd
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/BitwiseOrBinary.php
@@ -0,0 +1,23 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression\Binary;
+
+use Twig\Compiler;
+
+class BitwiseOrBinary extends AbstractBinary
+{
+    public function operator(Compiler $compiler): Compiler
+    {
+        return $compiler->raw('|');
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/BitwiseXorBinary.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/BitwiseXorBinary.php
new file mode 100644
index 0000000..5c29785
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/BitwiseXorBinary.php
@@ -0,0 +1,23 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression\Binary;
+
+use Twig\Compiler;
+
+class BitwiseXorBinary extends AbstractBinary
+{
+    public function operator(Compiler $compiler): Compiler
+    {
+        return $compiler->raw('^');
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/ConcatBinary.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/ConcatBinary.php
new file mode 100644
index 0000000..f825ab8
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/ConcatBinary.php
@@ -0,0 +1,23 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression\Binary;
+
+use Twig\Compiler;
+
+class ConcatBinary extends AbstractBinary
+{
+    public function operator(Compiler $compiler): Compiler
+    {
+        return $compiler->raw('.');
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/DivBinary.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/DivBinary.php
new file mode 100644
index 0000000..e3817d1
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/DivBinary.php
@@ -0,0 +1,23 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression\Binary;
+
+use Twig\Compiler;
+
+class DivBinary extends AbstractBinary
+{
+    public function operator(Compiler $compiler): Compiler
+    {
+        return $compiler->raw('/');
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/EndsWithBinary.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/EndsWithBinary.php
new file mode 100644
index 0000000..c3516b8
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/EndsWithBinary.php
@@ -0,0 +1,35 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression\Binary;
+
+use Twig\Compiler;
+
+class EndsWithBinary extends AbstractBinary
+{
+    public function compile(Compiler $compiler): void
+    {
+        $left = $compiler->getVarName();
+        $right = $compiler->getVarName();
+        $compiler
+            ->raw(sprintf('(is_string($%s = ', $left))
+            ->subcompile($this->getNode('left'))
+            ->raw(sprintf(') && is_string($%s = ', $right))
+            ->subcompile($this->getNode('right'))
+            ->raw(sprintf(') && (\'\' === $%2$s || $%2$s === substr($%1$s, -strlen($%2$s))))', $left, $right))
+        ;
+    }
+
+    public function operator(Compiler $compiler): Compiler
+    {
+        return $compiler->raw('');
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/EqualBinary.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/EqualBinary.php
new file mode 100644
index 0000000..6b48549
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/EqualBinary.php
@@ -0,0 +1,39 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression\Binary;
+
+use Twig\Compiler;
+
+class EqualBinary extends AbstractBinary
+{
+    public function compile(Compiler $compiler): void
+    {
+        if (\PHP_VERSION_ID >= 80000) {
+            parent::compile($compiler);
+
+            return;
+        }
+
+        $compiler
+            ->raw('(0 === twig_compare(')
+            ->subcompile($this->getNode('left'))
+            ->raw(', ')
+            ->subcompile($this->getNode('right'))
+            ->raw('))')
+        ;
+    }
+
+    public function operator(Compiler $compiler): Compiler
+    {
+        return $compiler->raw('==');
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/FloorDivBinary.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/FloorDivBinary.php
new file mode 100644
index 0000000..d7e7980
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/FloorDivBinary.php
@@ -0,0 +1,29 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression\Binary;
+
+use Twig\Compiler;
+
+class FloorDivBinary extends AbstractBinary
+{
+    public function compile(Compiler $compiler): void
+    {
+        $compiler->raw('(int) floor(');
+        parent::compile($compiler);
+        $compiler->raw(')');
+    }
+
+    public function operator(Compiler $compiler): Compiler
+    {
+        return $compiler->raw('/');
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/GreaterBinary.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/GreaterBinary.php
new file mode 100644
index 0000000..e1dd067
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/GreaterBinary.php
@@ -0,0 +1,39 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression\Binary;
+
+use Twig\Compiler;
+
+class GreaterBinary extends AbstractBinary
+{
+    public function compile(Compiler $compiler): void
+    {
+        if (\PHP_VERSION_ID >= 80000) {
+            parent::compile($compiler);
+
+            return;
+        }
+
+        $compiler
+            ->raw('(1 === twig_compare(')
+            ->subcompile($this->getNode('left'))
+            ->raw(', ')
+            ->subcompile($this->getNode('right'))
+            ->raw('))')
+        ;
+    }
+
+    public function operator(Compiler $compiler): Compiler
+    {
+        return $compiler->raw('>');
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/GreaterEqualBinary.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/GreaterEqualBinary.php
new file mode 100644
index 0000000..df9bfcf
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/GreaterEqualBinary.php
@@ -0,0 +1,39 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression\Binary;
+
+use Twig\Compiler;
+
+class GreaterEqualBinary extends AbstractBinary
+{
+    public function compile(Compiler $compiler): void
+    {
+        if (\PHP_VERSION_ID >= 80000) {
+            parent::compile($compiler);
+
+            return;
+        }
+
+        $compiler
+            ->raw('(0 <= twig_compare(')
+            ->subcompile($this->getNode('left'))
+            ->raw(', ')
+            ->subcompile($this->getNode('right'))
+            ->raw('))')
+        ;
+    }
+
+    public function operator(Compiler $compiler): Compiler
+    {
+        return $compiler->raw('>=');
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/InBinary.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/InBinary.php
new file mode 100644
index 0000000..6dbfa97
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/InBinary.php
@@ -0,0 +1,33 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression\Binary;
+
+use Twig\Compiler;
+
+class InBinary extends AbstractBinary
+{
+    public function compile(Compiler $compiler): void
+    {
+        $compiler
+            ->raw('twig_in_filter(')
+            ->subcompile($this->getNode('left'))
+            ->raw(', ')
+            ->subcompile($this->getNode('right'))
+            ->raw(')')
+        ;
+    }
+
+    public function operator(Compiler $compiler): Compiler
+    {
+        return $compiler->raw('in');
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/LessBinary.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/LessBinary.php
new file mode 100644
index 0000000..598e629
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/LessBinary.php
@@ -0,0 +1,39 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression\Binary;
+
+use Twig\Compiler;
+
+class LessBinary extends AbstractBinary
+{
+    public function compile(Compiler $compiler): void
+    {
+        if (\PHP_VERSION_ID >= 80000) {
+            parent::compile($compiler);
+
+            return;
+        }
+
+        $compiler
+            ->raw('(-1 === twig_compare(')
+            ->subcompile($this->getNode('left'))
+            ->raw(', ')
+            ->subcompile($this->getNode('right'))
+            ->raw('))')
+        ;
+    }
+
+    public function operator(Compiler $compiler): Compiler
+    {
+        return $compiler->raw('<');
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/LessEqualBinary.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/LessEqualBinary.php
new file mode 100644
index 0000000..e3c4af5
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/LessEqualBinary.php
@@ -0,0 +1,39 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression\Binary;
+
+use Twig\Compiler;
+
+class LessEqualBinary extends AbstractBinary
+{
+    public function compile(Compiler $compiler): void
+    {
+        if (\PHP_VERSION_ID >= 80000) {
+            parent::compile($compiler);
+
+            return;
+        }
+
+        $compiler
+            ->raw('(0 >= twig_compare(')
+            ->subcompile($this->getNode('left'))
+            ->raw(', ')
+            ->subcompile($this->getNode('right'))
+            ->raw('))')
+        ;
+    }
+
+    public function operator(Compiler $compiler): Compiler
+    {
+        return $compiler->raw('<=');
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/MatchesBinary.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/MatchesBinary.php
new file mode 100644
index 0000000..bc97292
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/MatchesBinary.php
@@ -0,0 +1,33 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression\Binary;
+
+use Twig\Compiler;
+
+class MatchesBinary extends AbstractBinary
+{
+    public function compile(Compiler $compiler): void
+    {
+        $compiler
+            ->raw('preg_match(')
+            ->subcompile($this->getNode('right'))
+            ->raw(', ')
+            ->subcompile($this->getNode('left'))
+            ->raw(')')
+        ;
+    }
+
+    public function operator(Compiler $compiler): Compiler
+    {
+        return $compiler->raw('');
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/ModBinary.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/ModBinary.php
new file mode 100644
index 0000000..271b45c
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/ModBinary.php
@@ -0,0 +1,23 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression\Binary;
+
+use Twig\Compiler;
+
+class ModBinary extends AbstractBinary
+{
+    public function operator(Compiler $compiler): Compiler
+    {
+        return $compiler->raw('%');
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/MulBinary.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/MulBinary.php
new file mode 100644
index 0000000..6d4c1e0
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/MulBinary.php
@@ -0,0 +1,23 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression\Binary;
+
+use Twig\Compiler;
+
+class MulBinary extends AbstractBinary
+{
+    public function operator(Compiler $compiler): Compiler
+    {
+        return $compiler->raw('*');
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/NotEqualBinary.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/NotEqualBinary.php
new file mode 100644
index 0000000..db47a28
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/NotEqualBinary.php
@@ -0,0 +1,39 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression\Binary;
+
+use Twig\Compiler;
+
+class NotEqualBinary extends AbstractBinary
+{
+    public function compile(Compiler $compiler): void
+    {
+        if (\PHP_VERSION_ID >= 80000) {
+            parent::compile($compiler);
+
+            return;
+        }
+
+        $compiler
+            ->raw('(0 !== twig_compare(')
+            ->subcompile($this->getNode('left'))
+            ->raw(', ')
+            ->subcompile($this->getNode('right'))
+            ->raw('))')
+        ;
+    }
+
+    public function operator(Compiler $compiler): Compiler
+    {
+        return $compiler->raw('!=');
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/NotInBinary.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/NotInBinary.php
new file mode 100644
index 0000000..fcba6cc
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/NotInBinary.php
@@ -0,0 +1,33 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression\Binary;
+
+use Twig\Compiler;
+
+class NotInBinary extends AbstractBinary
+{
+    public function compile(Compiler $compiler): void
+    {
+        $compiler
+            ->raw('!twig_in_filter(')
+            ->subcompile($this->getNode('left'))
+            ->raw(', ')
+            ->subcompile($this->getNode('right'))
+            ->raw(')')
+        ;
+    }
+
+    public function operator(Compiler $compiler): Compiler
+    {
+        return $compiler->raw('not in');
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/OrBinary.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/OrBinary.php
new file mode 100644
index 0000000..21f87c9
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/OrBinary.php
@@ -0,0 +1,23 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression\Binary;
+
+use Twig\Compiler;
+
+class OrBinary extends AbstractBinary
+{
+    public function operator(Compiler $compiler): Compiler
+    {
+        return $compiler->raw('||');
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/PowerBinary.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/PowerBinary.php
new file mode 100644
index 0000000..c9f4c66
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/PowerBinary.php
@@ -0,0 +1,22 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression\Binary;
+
+use Twig\Compiler;
+
+class PowerBinary extends AbstractBinary
+{
+    public function operator(Compiler $compiler): Compiler
+    {
+        return $compiler->raw('**');
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/RangeBinary.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/RangeBinary.php
new file mode 100644
index 0000000..55982c8
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/RangeBinary.php
@@ -0,0 +1,33 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression\Binary;
+
+use Twig\Compiler;
+
+class RangeBinary extends AbstractBinary
+{
+    public function compile(Compiler $compiler): void
+    {
+        $compiler
+            ->raw('range(')
+            ->subcompile($this->getNode('left'))
+            ->raw(', ')
+            ->subcompile($this->getNode('right'))
+            ->raw(')')
+        ;
+    }
+
+    public function operator(Compiler $compiler): Compiler
+    {
+        return $compiler->raw('..');
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/SpaceshipBinary.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/SpaceshipBinary.php
new file mode 100644
index 0000000..ae5a4a4
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/SpaceshipBinary.php
@@ -0,0 +1,22 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression\Binary;
+
+use Twig\Compiler;
+
+class SpaceshipBinary extends AbstractBinary
+{
+    public function operator(Compiler $compiler): Compiler
+    {
+        return $compiler->raw('<=>');
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/StartsWithBinary.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/StartsWithBinary.php
new file mode 100644
index 0000000..d0df1c4
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/StartsWithBinary.php
@@ -0,0 +1,35 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression\Binary;
+
+use Twig\Compiler;
+
+class StartsWithBinary extends AbstractBinary
+{
+    public function compile(Compiler $compiler): void
+    {
+        $left = $compiler->getVarName();
+        $right = $compiler->getVarName();
+        $compiler
+            ->raw(sprintf('(is_string($%s = ', $left))
+            ->subcompile($this->getNode('left'))
+            ->raw(sprintf(') && is_string($%s = ', $right))
+            ->subcompile($this->getNode('right'))
+            ->raw(sprintf(') && (\'\' === $%2$s || 0 === strpos($%1$s, $%2$s)))', $left, $right))
+        ;
+    }
+
+    public function operator(Compiler $compiler): Compiler
+    {
+        return $compiler->raw('');
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/SubBinary.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/SubBinary.php
new file mode 100644
index 0000000..eeb87fa
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/SubBinary.php
@@ -0,0 +1,23 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression\Binary;
+
+use Twig\Compiler;
+
+class SubBinary extends AbstractBinary
+{
+    public function operator(Compiler $compiler): Compiler
+    {
+        return $compiler->raw('-');
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/BlockReferenceExpression.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/BlockReferenceExpression.php
new file mode 100644
index 0000000..b1e2a8f
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/BlockReferenceExpression.php
@@ -0,0 +1,86 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression;
+
+use Twig\Compiler;
+use Twig\Node\Node;
+
+/**
+ * Represents a block call node.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class BlockReferenceExpression extends AbstractExpression
+{
+    public function __construct(Node $name, ?Node $template, int $lineno, string $tag = null)
+    {
+        $nodes = ['name' => $name];
+        if (null !== $template) {
+            $nodes['template'] = $template;
+        }
+
+        parent::__construct($nodes, ['is_defined_test' => false, 'output' => false], $lineno, $tag);
+    }
+
+    public function compile(Compiler $compiler): void
+    {
+        if ($this->getAttribute('is_defined_test')) {
+            $this->compileTemplateCall($compiler, 'hasBlock');
+        } else {
+            if ($this->getAttribute('output')) {
+                $compiler->addDebugInfo($this);
+
+                $this
+                    ->compileTemplateCall($compiler, 'displayBlock')
+                    ->raw(";\n");
+            } else {
+                $this->compileTemplateCall($compiler, 'renderBlock');
+            }
+        }
+    }
+
+    private function compileTemplateCall(Compiler $compiler, string $method): Compiler
+    {
+        if (!$this->hasNode('template')) {
+            $compiler->write('$this');
+        } else {
+            $compiler
+                ->write('$this->loadTemplate(')
+                ->subcompile($this->getNode('template'))
+                ->raw(', ')
+                ->repr($this->getTemplateName())
+                ->raw(', ')
+                ->repr($this->getTemplateLine())
+                ->raw(')')
+            ;
+        }
+
+        $compiler->raw(sprintf('->%s', $method));
+
+        return $this->compileBlockArguments($compiler);
+    }
+
+    private function compileBlockArguments(Compiler $compiler): Compiler
+    {
+        $compiler
+            ->raw('(')
+            ->subcompile($this->getNode('name'))
+            ->raw(', $context');
+
+        if (!$this->hasNode('template')) {
+            $compiler->raw(', $blocks');
+        }
+
+        return $compiler->raw(')');
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/CallExpression.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/CallExpression.php
new file mode 100644
index 0000000..fdf92a8
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/CallExpression.php
@@ -0,0 +1,320 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression;
+
+use Twig\Compiler;
+use Twig\Error\SyntaxError;
+use Twig\Extension\ExtensionInterface;
+use Twig\Node\Node;
+
+abstract class CallExpression extends AbstractExpression
+{
+    private $reflector;
+
+    protected function compileCallable(Compiler $compiler)
+    {
+        $callable = $this->getAttribute('callable');
+
+        $closingParenthesis = false;
+        $isArray = false;
+        if (\is_string($callable) && false === strpos($callable, '::')) {
+            $compiler->raw($callable);
+        } else {
+            list($r, $callable) = $this->reflectCallable($callable);
+            if ($r instanceof \ReflectionMethod && \is_string($callable[0])) {
+                if ($r->isStatic()) {
+                    $compiler->raw(sprintf('%s::%s', $callable[0], $callable[1]));
+                } else {
+                    $compiler->raw(sprintf('$this->env->getRuntime(\'%s\')->%s', $callable[0], $callable[1]));
+                }
+            } elseif ($r instanceof \ReflectionMethod && $callable[0] instanceof ExtensionInterface) {
+                $class = \get_class($callable[0]);
+                if (!$compiler->getEnvironment()->hasExtension($class)) {
+                    // Compile a non-optimized call to trigger a \Twig\Error\RuntimeError, which cannot be a compile-time error
+                    $compiler->raw(sprintf('$this->env->getExtension(\'%s\')', $class));
+                } else {
+                    $compiler->raw(sprintf('$this->extensions[\'%s\']', ltrim($class, '\\')));
+                }
+
+                $compiler->raw(sprintf('->%s', $callable[1]));
+            } else {
+                $closingParenthesis = true;
+                $isArray = true;
+                $compiler->raw(sprintf('call_user_func_array($this->env->get%s(\'%s\')->getCallable(), ', ucfirst($this->getAttribute('type')), $this->getAttribute('name')));
+            }
+        }
+
+        $this->compileArguments($compiler, $isArray);
+
+        if ($closingParenthesis) {
+            $compiler->raw(')');
+        }
+    }
+
+    protected function compileArguments(Compiler $compiler, $isArray = false): void
+    {
+        $compiler->raw($isArray ? '[' : '(');
+
+        $first = true;
+
+        if ($this->hasAttribute('needs_environment') && $this->getAttribute('needs_environment')) {
+            $compiler->raw('$this->env');
+            $first = false;
+        }
+
+        if ($this->hasAttribute('needs_context') && $this->getAttribute('needs_context')) {
+            if (!$first) {
+                $compiler->raw(', ');
+            }
+            $compiler->raw('$context');
+            $first = false;
+        }
+
+        if ($this->hasAttribute('arguments')) {
+            foreach ($this->getAttribute('arguments') as $argument) {
+                if (!$first) {
+                    $compiler->raw(', ');
+                }
+                $compiler->string($argument);
+                $first = false;
+            }
+        }
+
+        if ($this->hasNode('node')) {
+            if (!$first) {
+                $compiler->raw(', ');
+            }
+            $compiler->subcompile($this->getNode('node'));
+            $first = false;
+        }
+
+        if ($this->hasNode('arguments')) {
+            $callable = $this->getAttribute('callable');
+            $arguments = $this->getArguments($callable, $this->getNode('arguments'));
+            foreach ($arguments as $node) {
+                if (!$first) {
+                    $compiler->raw(', ');
+                }
+                $compiler->subcompile($node);
+                $first = false;
+            }
+        }
+
+        $compiler->raw($isArray ? ']' : ')');
+    }
+
+    protected function getArguments($callable, $arguments)
+    {
+        $callType = $this->getAttribute('type');
+        $callName = $this->getAttribute('name');
+
+        $parameters = [];
+        $named = false;
+        foreach ($arguments as $name => $node) {
+            if (!\is_int($name)) {
+                $named = true;
+                $name = $this->normalizeName($name);
+            } elseif ($named) {
+                throw new SyntaxError(sprintf('Positional arguments cannot be used after named arguments for %s "%s".', $callType, $callName), $this->getTemplateLine(), $this->getSourceContext());
+            }
+
+            $parameters[$name] = $node;
+        }
+
+        $isVariadic = $this->hasAttribute('is_variadic') && $this->getAttribute('is_variadic');
+        if (!$named && !$isVariadic) {
+            return $parameters;
+        }
+
+        if (!$callable) {
+            if ($named) {
+                $message = sprintf('Named arguments are not supported for %s "%s".', $callType, $callName);
+            } else {
+                $message = sprintf('Arbitrary positional arguments are not supported for %s "%s".', $callType, $callName);
+            }
+
+            throw new \LogicException($message);
+        }
+
+        list($callableParameters, $isPhpVariadic) = $this->getCallableParameters($callable, $isVariadic);
+        $arguments = [];
+        $names = [];
+        $missingArguments = [];
+        $optionalArguments = [];
+        $pos = 0;
+        foreach ($callableParameters as $callableParameter) {
+            $name = $this->normalizeName($callableParameter->name);
+            if (\PHP_VERSION_ID >= 80000 && 'range' === $callable) {
+                if ('start' === $name) {
+                    $name = 'low';
+                } elseif ('end' === $name) {
+                    $name = 'high';
+                }
+            }
+
+            $names[] = $name;
+
+            if (\array_key_exists($name, $parameters)) {
+                if (\array_key_exists($pos, $parameters)) {
+                    throw new SyntaxError(sprintf('Argument "%s" is defined twice for %s "%s".', $name, $callType, $callName), $this->getTemplateLine(), $this->getSourceContext());
+                }
+
+                if (\count($missingArguments)) {
+                    throw new SyntaxError(sprintf(
+                        'Argument "%s" could not be assigned for %s "%s(%s)" because it is mapped to an internal PHP function which cannot determine default value for optional argument%s "%s".',
+                        $name, $callType, $callName, implode(', ', $names), \count($missingArguments) > 1 ? 's' : '', implode('", "', $missingArguments)
+                    ), $this->getTemplateLine(), $this->getSourceContext());
+                }
+
+                $arguments = array_merge($arguments, $optionalArguments);
+                $arguments[] = $parameters[$name];
+                unset($parameters[$name]);
+                $optionalArguments = [];
+            } elseif (\array_key_exists($pos, $parameters)) {
+                $arguments = array_merge($arguments, $optionalArguments);
+                $arguments[] = $parameters[$pos];
+                unset($parameters[$pos]);
+                $optionalArguments = [];
+                ++$pos;
+            } elseif ($callableParameter->isDefaultValueAvailable()) {
+                $optionalArguments[] = new ConstantExpression($callableParameter->getDefaultValue(), -1);
+            } elseif ($callableParameter->isOptional()) {
+                if (empty($parameters)) {
+                    break;
+                } else {
+                    $missingArguments[] = $name;
+                }
+            } else {
+                throw new SyntaxError(sprintf('Value for argument "%s" is required for %s "%s".', $name, $callType, $callName), $this->getTemplateLine(), $this->getSourceContext());
+            }
+        }
+
+        if ($isVariadic) {
+            $arbitraryArguments = $isPhpVariadic ? new VariadicExpression([], -1) : new ArrayExpression([], -1);
+            foreach ($parameters as $key => $value) {
+                if (\is_int($key)) {
+                    $arbitraryArguments->addElement($value);
+                } else {
+                    $arbitraryArguments->addElement($value, new ConstantExpression($key, -1));
+                }
+                unset($parameters[$key]);
+            }
+
+            if ($arbitraryArguments->count()) {
+                $arguments = array_merge($arguments, $optionalArguments);
+                $arguments[] = $arbitraryArguments;
+            }
+        }
+
+        if (!empty($parameters)) {
+            $unknownParameter = null;
+            foreach ($parameters as $parameter) {
+                if ($parameter instanceof Node) {
+                    $unknownParameter = $parameter;
+                    break;
+                }
+            }
+
+            throw new SyntaxError(
+                sprintf(
+                    'Unknown argument%s "%s" for %s "%s(%s)".',
+                    \count($parameters) > 1 ? 's' : '', implode('", "', array_keys($parameters)), $callType, $callName, implode(', ', $names)
+                ),
+                $unknownParameter ? $unknownParameter->getTemplateLine() : $this->getTemplateLine(),
+                $unknownParameter ? $unknownParameter->getSourceContext() : $this->getSourceContext()
+            );
+        }
+
+        return $arguments;
+    }
+
+    protected function normalizeName(string $name): string
+    {
+        return strtolower(preg_replace(['/([A-Z]+)([A-Z][a-z])/', '/([a-z\d])([A-Z])/'], ['\\1_\\2', '\\1_\\2'], $name));
+    }
+
+    private function getCallableParameters($callable, bool $isVariadic): array
+    {
+        list($r) = $this->reflectCallable($callable);
+        if (null === $r) {
+            return [[], false];
+        }
+
+        $parameters = $r->getParameters();
+        if ($this->hasNode('node')) {
+            array_shift($parameters);
+        }
+        if ($this->hasAttribute('needs_environment') && $this->getAttribute('needs_environment')) {
+            array_shift($parameters);
+        }
+        if ($this->hasAttribute('needs_context') && $this->getAttribute('needs_context')) {
+            array_shift($parameters);
+        }
+        if ($this->hasAttribute('arguments') && null !== $this->getAttribute('arguments')) {
+            foreach ($this->getAttribute('arguments') as $argument) {
+                array_shift($parameters);
+            }
+        }
+        $isPhpVariadic = false;
+        if ($isVariadic) {
+            $argument = end($parameters);
+            $isArray = $argument && $argument->hasType() && 'array' === $argument->getType()->getName();
+            if ($isArray && $argument->isDefaultValueAvailable() && [] === $argument->getDefaultValue()) {
+                array_pop($parameters);
+            } elseif ($argument && $argument->isVariadic()) {
+                array_pop($parameters);
+                $isPhpVariadic = true;
+            } else {
+                $callableName = $r->name;
+                if ($r instanceof \ReflectionMethod) {
+                    $callableName = $r->getDeclaringClass()->name.'::'.$callableName;
+                }
+
+                throw new \LogicException(sprintf('The last parameter of "%s" for %s "%s" must be an array with default value, eg. "array $arg = []".', $callableName, $this->getAttribute('type'), $this->getAttribute('name')));
+            }
+        }
+
+        return [$parameters, $isPhpVariadic];
+    }
+
+    private function reflectCallable($callable)
+    {
+        if (null !== $this->reflector) {
+            return $this->reflector;
+        }
+
+        if (\is_array($callable)) {
+            if (!method_exists($callable[0], $callable[1])) {
+                // __call()
+                return [null, []];
+            }
+            $r = new \ReflectionMethod($callable[0], $callable[1]);
+        } elseif (\is_object($callable) && !$callable instanceof \Closure) {
+            $r = new \ReflectionObject($callable);
+            $r = $r->getMethod('__invoke');
+            $callable = [$callable, '__invoke'];
+        } elseif (\is_string($callable) && false !== $pos = strpos($callable, '::')) {
+            $class = substr($callable, 0, $pos);
+            $method = substr($callable, $pos + 2);
+            if (!method_exists($class, $method)) {
+                // __staticCall()
+                return [null, []];
+            }
+            $r = new \ReflectionMethod($callable);
+            $callable = [$class, $method];
+        } else {
+            $r = new \ReflectionFunction($callable);
+        }
+
+        return $this->reflector = [$r, $callable];
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/ConditionalExpression.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/ConditionalExpression.php
new file mode 100644
index 0000000..2c7bd0a
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/ConditionalExpression.php
@@ -0,0 +1,36 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression;
+
+use Twig\Compiler;
+
+class ConditionalExpression extends AbstractExpression
+{
+    public function __construct(AbstractExpression $expr1, AbstractExpression $expr2, AbstractExpression $expr3, int $lineno)
+    {
+        parent::__construct(['expr1' => $expr1, 'expr2' => $expr2, 'expr3' => $expr3], [], $lineno);
+    }
+
+    public function compile(Compiler $compiler): void
+    {
+        $compiler
+            ->raw('((')
+            ->subcompile($this->getNode('expr1'))
+            ->raw(') ? (')
+            ->subcompile($this->getNode('expr2'))
+            ->raw(') : (')
+            ->subcompile($this->getNode('expr3'))
+            ->raw('))')
+        ;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/ConstantExpression.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/ConstantExpression.php
new file mode 100644
index 0000000..7ddbcc6
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/ConstantExpression.php
@@ -0,0 +1,28 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression;
+
+use Twig\Compiler;
+
+class ConstantExpression extends AbstractExpression
+{
+    public function __construct($value, int $lineno)
+    {
+        parent::__construct([], ['value' => $value], $lineno);
+    }
+
+    public function compile(Compiler $compiler): void
+    {
+        $compiler->repr($this->getAttribute('value'));
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Filter/DefaultFilter.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Filter/DefaultFilter.php
new file mode 100644
index 0000000..6a572d4
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Filter/DefaultFilter.php
@@ -0,0 +1,52 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression\Filter;
+
+use Twig\Compiler;
+use Twig\Node\Expression\ConditionalExpression;
+use Twig\Node\Expression\ConstantExpression;
+use Twig\Node\Expression\FilterExpression;
+use Twig\Node\Expression\GetAttrExpression;
+use Twig\Node\Expression\NameExpression;
+use Twig\Node\Expression\Test\DefinedTest;
+use Twig\Node\Node;
+
+/**
+ * Returns the value or the default value when it is undefined or empty.
+ *
+ *  {{ var.foo|default('foo item on var is not defined') }}
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class DefaultFilter extends FilterExpression
+{
+    public function __construct(Node $node, ConstantExpression $filterName, Node $arguments, int $lineno, string $tag = null)
+    {
+        $default = new FilterExpression($node, new ConstantExpression('default', $node->getTemplateLine()), $arguments, $node->getTemplateLine());
+
+        if ('default' === $filterName->getAttribute('value') && ($node instanceof NameExpression || $node instanceof GetAttrExpression)) {
+            $test = new DefinedTest(clone $node, 'defined', new Node(), $node->getTemplateLine());
+            $false = \count($arguments) ? $arguments->getNode(0) : new ConstantExpression('', $node->getTemplateLine());
+
+            $node = new ConditionalExpression($test, $default, $false, $node->getTemplateLine());
+        } else {
+            $node = $default;
+        }
+
+        parent::__construct($node, $filterName, $arguments, $lineno, $tag);
+    }
+
+    public function compile(Compiler $compiler): void
+    {
+        $compiler->subcompile($this->getNode('node'));
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/FilterExpression.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/FilterExpression.php
new file mode 100644
index 0000000..0fc1588
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/FilterExpression.php
@@ -0,0 +1,40 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression;
+
+use Twig\Compiler;
+use Twig\Node\Node;
+
+class FilterExpression extends CallExpression
+{
+    public function __construct(Node $node, ConstantExpression $filterName, Node $arguments, int $lineno, string $tag = null)
+    {
+        parent::__construct(['node' => $node, 'filter' => $filterName, 'arguments' => $arguments], [], $lineno, $tag);
+    }
+
+    public function compile(Compiler $compiler): void
+    {
+        $name = $this->getNode('filter')->getAttribute('value');
+        $filter = $compiler->getEnvironment()->getFilter($name);
+
+        $this->setAttribute('name', $name);
+        $this->setAttribute('type', 'filter');
+        $this->setAttribute('needs_environment', $filter->needsEnvironment());
+        $this->setAttribute('needs_context', $filter->needsContext());
+        $this->setAttribute('arguments', $filter->getArguments());
+        $this->setAttribute('callable', $filter->getCallable());
+        $this->setAttribute('is_variadic', $filter->isVariadic());
+
+        $this->compileCallable($compiler);
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/FunctionExpression.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/FunctionExpression.php
new file mode 100644
index 0000000..7126977
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/FunctionExpression.php
@@ -0,0 +1,43 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression;
+
+use Twig\Compiler;
+use Twig\Node\Node;
+
+class FunctionExpression extends CallExpression
+{
+    public function __construct(string $name, Node $arguments, int $lineno)
+    {
+        parent::__construct(['arguments' => $arguments], ['name' => $name, 'is_defined_test' => false], $lineno);
+    }
+
+    public function compile(Compiler $compiler)
+    {
+        $name = $this->getAttribute('name');
+        $function = $compiler->getEnvironment()->getFunction($name);
+
+        $this->setAttribute('name', $name);
+        $this->setAttribute('type', 'function');
+        $this->setAttribute('needs_environment', $function->needsEnvironment());
+        $this->setAttribute('needs_context', $function->needsContext());
+        $this->setAttribute('arguments', $function->getArguments());
+        $callable = $function->getCallable();
+        if ('constant' === $name && $this->getAttribute('is_defined_test')) {
+            $callable = 'twig_constant_is_defined';
+        }
+        $this->setAttribute('callable', $callable);
+        $this->setAttribute('is_variadic', $function->isVariadic());
+
+        $this->compileCallable($compiler);
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/GetAttrExpression.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/GetAttrExpression.php
new file mode 100644
index 0000000..e6a75ce
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/GetAttrExpression.php
@@ -0,0 +1,87 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression;
+
+use Twig\Compiler;
+use Twig\Extension\SandboxExtension;
+use Twig\Template;
+
+class GetAttrExpression extends AbstractExpression
+{
+    public function __construct(AbstractExpression $node, AbstractExpression $attribute, ?AbstractExpression $arguments, string $type, int $lineno)
+    {
+        $nodes = ['node' => $node, 'attribute' => $attribute];
+        if (null !== $arguments) {
+            $nodes['arguments'] = $arguments;
+        }
+
+        parent::__construct($nodes, ['type' => $type, 'is_defined_test' => false, 'ignore_strict_check' => false, 'optimizable' => true], $lineno);
+    }
+
+    public function compile(Compiler $compiler): void
+    {
+        $env = $compiler->getEnvironment();
+
+        // optimize array calls
+        if (
+            $this->getAttribute('optimizable')
+            && (!$env->isStrictVariables() || $this->getAttribute('ignore_strict_check'))
+            && !$this->getAttribute('is_defined_test')
+            && Template::ARRAY_CALL === $this->getAttribute('type')
+        ) {
+            $var = '$'.$compiler->getVarName();
+            $compiler
+                ->raw('(('.$var.' = ')
+                ->subcompile($this->getNode('node'))
+                ->raw(') && is_array(')
+                ->raw($var)
+                ->raw(') || ')
+                ->raw($var)
+                ->raw(' instanceof ArrayAccess ? (')
+                ->raw($var)
+                ->raw('[')
+                ->subcompile($this->getNode('attribute'))
+                ->raw('] ?? null) : null)')
+            ;
+
+            return;
+        }
+
+        $compiler->raw('twig_get_attribute($this->env, $this->source, ');
+
+        if ($this->getAttribute('ignore_strict_check')) {
+            $this->getNode('node')->setAttribute('ignore_strict_check', true);
+        }
+
+        $compiler
+            ->subcompile($this->getNode('node'))
+            ->raw(', ')
+            ->subcompile($this->getNode('attribute'))
+        ;
+
+        if ($this->hasNode('arguments')) {
+            $compiler->raw(', ')->subcompile($this->getNode('arguments'));
+        } else {
+            $compiler->raw(', []');
+        }
+
+        $compiler->raw(', ')
+            ->repr($this->getAttribute('type'))
+            ->raw(', ')->repr($this->getAttribute('is_defined_test'))
+            ->raw(', ')->repr($this->getAttribute('ignore_strict_check'))
+            ->raw(', ')->repr($env->hasExtension(SandboxExtension::class))
+            ->raw(', ')->repr($this->getNode('node')->getTemplateLine())
+            ->raw(')')
+        ;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/InlinePrint.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/InlinePrint.php
new file mode 100644
index 0000000..1ad4751
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/InlinePrint.php
@@ -0,0 +1,35 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression;
+
+use Twig\Compiler;
+use Twig\Node\Node;
+
+/**
+ * @internal
+ */
+final class InlinePrint extends AbstractExpression
+{
+    public function __construct(Node $node, int $lineno)
+    {
+        parent::__construct(['node' => $node], [], $lineno);
+    }
+
+    public function compile(Compiler $compiler): void
+    {
+        $compiler
+            ->raw('print (')
+            ->subcompile($this->getNode('node'))
+            ->raw(')')
+        ;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/MethodCallExpression.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/MethodCallExpression.php
new file mode 100644
index 0000000..d5ec0b6
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/MethodCallExpression.php
@@ -0,0 +1,62 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression;
+
+use Twig\Compiler;
+
+class MethodCallExpression extends AbstractExpression
+{
+    public function __construct(AbstractExpression $node, string $method, ArrayExpression $arguments, int $lineno)
+    {
+        parent::__construct(['node' => $node, 'arguments' => $arguments], ['method' => $method, 'safe' => false, 'is_defined_test' => false], $lineno);
+
+        if ($node instanceof NameExpression) {
+            $node->setAttribute('always_defined', true);
+        }
+    }
+
+    public function compile(Compiler $compiler): void
+    {
+        if ($this->getAttribute('is_defined_test')) {
+            $compiler
+                ->raw('method_exists($macros[')
+                ->repr($this->getNode('node')->getAttribute('name'))
+                ->raw('], ')
+                ->repr($this->getAttribute('method'))
+                ->raw(')')
+            ;
+
+            return;
+        }
+
+        $compiler
+            ->raw('twig_call_macro($macros[')
+            ->repr($this->getNode('node')->getAttribute('name'))
+            ->raw('], ')
+            ->repr($this->getAttribute('method'))
+            ->raw(', [')
+        ;
+        $first = true;
+        foreach ($this->getNode('arguments')->getKeyValuePairs() as $pair) {
+            if (!$first) {
+                $compiler->raw(', ');
+            }
+            $first = false;
+
+            $compiler->subcompile($pair['value']);
+        }
+        $compiler
+            ->raw('], ')
+            ->repr($this->getTemplateLine())
+            ->raw(', $context, $this->getSourceContext())');
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/NameExpression.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/NameExpression.php
new file mode 100644
index 0000000..c3563f0
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/NameExpression.php
@@ -0,0 +1,97 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression;
+
+use Twig\Compiler;
+
+class NameExpression extends AbstractExpression
+{
+    private $specialVars = [
+        '_self' => '$this->getTemplateName()',
+        '_context' => '$context',
+        '_charset' => '$this->env->getCharset()',
+    ];
+
+    public function __construct(string $name, int $lineno)
+    {
+        parent::__construct([], ['name' => $name, 'is_defined_test' => false, 'ignore_strict_check' => false, 'always_defined' => false], $lineno);
+    }
+
+    public function compile(Compiler $compiler): void
+    {
+        $name = $this->getAttribute('name');
+
+        $compiler->addDebugInfo($this);
+
+        if ($this->getAttribute('is_defined_test')) {
+            if ($this->isSpecial()) {
+                $compiler->repr(true);
+            } elseif (\PHP_VERSION_ID >= 70400) {
+                $compiler
+                    ->raw('array_key_exists(')
+                    ->string($name)
+                    ->raw(', $context)')
+                ;
+            } else {
+                $compiler
+                    ->raw('(isset($context[')
+                    ->string($name)
+                    ->raw(']) || array_key_exists(')
+                    ->string($name)
+                    ->raw(', $context))')
+                ;
+            }
+        } elseif ($this->isSpecial()) {
+            $compiler->raw($this->specialVars[$name]);
+        } elseif ($this->getAttribute('always_defined')) {
+            $compiler
+                ->raw('$context[')
+                ->string($name)
+                ->raw(']')
+            ;
+        } else {
+            if ($this->getAttribute('ignore_strict_check') || !$compiler->getEnvironment()->isStrictVariables()) {
+                $compiler
+                    ->raw('($context[')
+                    ->string($name)
+                    ->raw('] ?? null)')
+                ;
+            } else {
+                $compiler
+                    ->raw('(isset($context[')
+                    ->string($name)
+                    ->raw(']) || array_key_exists(')
+                    ->string($name)
+                    ->raw(', $context) ? $context[')
+                    ->string($name)
+                    ->raw('] : (function () { throw new RuntimeError(\'Variable ')
+                    ->string($name)
+                    ->raw(' does not exist.\', ')
+                    ->repr($this->lineno)
+                    ->raw(', $this->source); })()')
+                    ->raw(')')
+                ;
+            }
+        }
+    }
+
+    public function isSpecial()
+    {
+        return isset($this->specialVars[$this->getAttribute('name')]);
+    }
+
+    public function isSimple()
+    {
+        return !$this->isSpecial() && !$this->getAttribute('is_defined_test');
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/NullCoalesceExpression.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/NullCoalesceExpression.php
new file mode 100644
index 0000000..a72bc4f
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/NullCoalesceExpression.php
@@ -0,0 +1,60 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression;
+
+use Twig\Compiler;
+use Twig\Node\Expression\Binary\AndBinary;
+use Twig\Node\Expression\Test\DefinedTest;
+use Twig\Node\Expression\Test\NullTest;
+use Twig\Node\Expression\Unary\NotUnary;
+use Twig\Node\Node;
+
+class NullCoalesceExpression extends ConditionalExpression
+{
+    public function __construct(Node $left, Node $right, int $lineno)
+    {
+        $test = new DefinedTest(clone $left, 'defined', new Node(), $left->getTemplateLine());
+        // for "block()", we don't need the null test as the return value is always a string
+        if (!$left instanceof BlockReferenceExpression) {
+            $test = new AndBinary(
+                $test,
+                new NotUnary(new NullTest($left, 'null', new Node(), $left->getTemplateLine()), $left->getTemplateLine()),
+                $left->getTemplateLine()
+            );
+        }
+
+        parent::__construct($test, $left, $right, $lineno);
+    }
+
+    public function compile(Compiler $compiler): void
+    {
+        /*
+         * This optimizes only one case. PHP 7 also supports more complex expressions
+         * that can return null. So, for instance, if log is defined, log("foo") ?? "..." works,
+         * but log($a["foo"]) ?? "..." does not if $a["foo"] is not defined. More advanced
+         * cases might be implemented as an optimizer node visitor, but has not been done
+         * as benefits are probably not worth the added complexity.
+         */
+        if ($this->getNode('expr2') instanceof NameExpression) {
+            $this->getNode('expr2')->setAttribute('always_defined', true);
+            $compiler
+                ->raw('((')
+                ->subcompile($this->getNode('expr2'))
+                ->raw(') ?? (')
+                ->subcompile($this->getNode('expr3'))
+                ->raw('))')
+            ;
+        } else {
+            parent::compile($compiler);
+        }
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/ParentExpression.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/ParentExpression.php
new file mode 100644
index 0000000..2549197
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/ParentExpression.php
@@ -0,0 +1,46 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression;
+
+use Twig\Compiler;
+
+/**
+ * Represents a parent node.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class ParentExpression extends AbstractExpression
+{
+    public function __construct(string $name, int $lineno, string $tag = null)
+    {
+        parent::__construct([], ['output' => false, 'name' => $name], $lineno, $tag);
+    }
+
+    public function compile(Compiler $compiler): void
+    {
+        if ($this->getAttribute('output')) {
+            $compiler
+                ->addDebugInfo($this)
+                ->write('$this->displayParentBlock(')
+                ->string($this->getAttribute('name'))
+                ->raw(", \$context, \$blocks);\n")
+            ;
+        } else {
+            $compiler
+                ->raw('$this->renderParentBlock(')
+                ->string($this->getAttribute('name'))
+                ->raw(', $context, $blocks)')
+            ;
+        }
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/TempNameExpression.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/TempNameExpression.php
new file mode 100644
index 0000000..004c704
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/TempNameExpression.php
@@ -0,0 +1,31 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression;
+
+use Twig\Compiler;
+
+class TempNameExpression extends AbstractExpression
+{
+    public function __construct(string $name, int $lineno)
+    {
+        parent::__construct([], ['name' => $name], $lineno);
+    }
+
+    public function compile(Compiler $compiler): void
+    {
+        $compiler
+            ->raw('$_')
+            ->raw($this->getAttribute('name'))
+            ->raw('_')
+        ;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Test/ConstantTest.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Test/ConstantTest.php
new file mode 100644
index 0000000..57e9319
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Test/ConstantTest.php
@@ -0,0 +1,49 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression\Test;
+
+use Twig\Compiler;
+use Twig\Node\Expression\TestExpression;
+
+/**
+ * Checks if a variable is the exact same value as a constant.
+ *
+ *    {% if post.status is constant('Post::PUBLISHED') %}
+ *      the status attribute is exactly the same as Post::PUBLISHED
+ *    {% endif %}
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class ConstantTest extends TestExpression
+{
+    public function compile(Compiler $compiler): void
+    {
+        $compiler
+            ->raw('(')
+            ->subcompile($this->getNode('node'))
+            ->raw(' === constant(')
+        ;
+
+        if ($this->getNode('arguments')->hasNode(1)) {
+            $compiler
+                ->raw('get_class(')
+                ->subcompile($this->getNode('arguments')->getNode(1))
+                ->raw(')."::".')
+            ;
+        }
+
+        $compiler
+            ->subcompile($this->getNode('arguments')->getNode(0))
+            ->raw('))')
+        ;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Test/DefinedTest.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Test/DefinedTest.php
new file mode 100644
index 0000000..3953bbb
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Test/DefinedTest.php
@@ -0,0 +1,74 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression\Test;
+
+use Twig\Compiler;
+use Twig\Error\SyntaxError;
+use Twig\Node\Expression\ArrayExpression;
+use Twig\Node\Expression\BlockReferenceExpression;
+use Twig\Node\Expression\ConstantExpression;
+use Twig\Node\Expression\FunctionExpression;
+use Twig\Node\Expression\GetAttrExpression;
+use Twig\Node\Expression\MethodCallExpression;
+use Twig\Node\Expression\NameExpression;
+use Twig\Node\Expression\TestExpression;
+use Twig\Node\Node;
+
+/**
+ * Checks if a variable is defined in the current context.
+ *
+ *    {# defined works with variable names and variable attributes #}
+ *    {% if foo is defined %}
+ *        {# ... #}
+ *    {% endif %}
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class DefinedTest extends TestExpression
+{
+    public function __construct(Node $node, string $name, ?Node $arguments, int $lineno)
+    {
+        if ($node instanceof NameExpression) {
+            $node->setAttribute('is_defined_test', true);
+        } elseif ($node instanceof GetAttrExpression) {
+            $node->setAttribute('is_defined_test', true);
+            $this->changeIgnoreStrictCheck($node);
+        } elseif ($node instanceof BlockReferenceExpression) {
+            $node->setAttribute('is_defined_test', true);
+        } elseif ($node instanceof FunctionExpression && 'constant' === $node->getAttribute('name')) {
+            $node->setAttribute('is_defined_test', true);
+        } elseif ($node instanceof ConstantExpression || $node instanceof ArrayExpression) {
+            $node = new ConstantExpression(true, $node->getTemplateLine());
+        } elseif ($node instanceof MethodCallExpression) {
+            $node->setAttribute('is_defined_test', true);
+        } else {
+            throw new SyntaxError('The "defined" test only works with simple variables.', $lineno);
+        }
+
+        parent::__construct($node, $name, $arguments, $lineno);
+    }
+
+    private function changeIgnoreStrictCheck(GetAttrExpression $node)
+    {
+        $node->setAttribute('optimizable', false);
+        $node->setAttribute('ignore_strict_check', true);
+
+        if ($node->getNode('node') instanceof GetAttrExpression) {
+            $this->changeIgnoreStrictCheck($node->getNode('node'));
+        }
+    }
+
+    public function compile(Compiler $compiler): void
+    {
+        $compiler->subcompile($this->getNode('node'));
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Test/DivisiblebyTest.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Test/DivisiblebyTest.php
new file mode 100644
index 0000000..4cb3ee0
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Test/DivisiblebyTest.php
@@ -0,0 +1,36 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression\Test;
+
+use Twig\Compiler;
+use Twig\Node\Expression\TestExpression;
+
+/**
+ * Checks if a variable is divisible by a number.
+ *
+ *  {% if loop.index is divisible by(3) %}
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class DivisiblebyTest extends TestExpression
+{
+    public function compile(Compiler $compiler): void
+    {
+        $compiler
+            ->raw('(0 == ')
+            ->subcompile($this->getNode('node'))
+            ->raw(' % ')
+            ->subcompile($this->getNode('arguments')->getNode(0))
+            ->raw(')')
+        ;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Test/EvenTest.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Test/EvenTest.php
new file mode 100644
index 0000000..a0e3ed6
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Test/EvenTest.php
@@ -0,0 +1,35 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression\Test;
+
+use Twig\Compiler;
+use Twig\Node\Expression\TestExpression;
+
+/**
+ * Checks if a number is even.
+ *
+ *  {{ var is even }}
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class EvenTest extends TestExpression
+{
+    public function compile(Compiler $compiler): void
+    {
+        $compiler
+            ->raw('(')
+            ->subcompile($this->getNode('node'))
+            ->raw(' % 2 == 0')
+            ->raw(')')
+        ;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Test/NullTest.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Test/NullTest.php
new file mode 100644
index 0000000..45b54ae
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Test/NullTest.php
@@ -0,0 +1,34 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression\Test;
+
+use Twig\Compiler;
+use Twig\Node\Expression\TestExpression;
+
+/**
+ * Checks that a variable is null.
+ *
+ *  {{ var is none }}
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class NullTest extends TestExpression
+{
+    public function compile(Compiler $compiler): void
+    {
+        $compiler
+            ->raw('(null === ')
+            ->subcompile($this->getNode('node'))
+            ->raw(')')
+        ;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Test/OddTest.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Test/OddTest.php
new file mode 100644
index 0000000..d56c711
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Test/OddTest.php
@@ -0,0 +1,35 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression\Test;
+
+use Twig\Compiler;
+use Twig\Node\Expression\TestExpression;
+
+/**
+ * Checks if a number is odd.
+ *
+ *  {{ var is odd }}
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class OddTest extends TestExpression
+{
+    public function compile(Compiler $compiler): void
+    {
+        $compiler
+            ->raw('(')
+            ->subcompile($this->getNode('node'))
+            ->raw(' % 2 != 0')
+            ->raw(')')
+        ;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Test/SameasTest.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Test/SameasTest.php
new file mode 100644
index 0000000..c96d2bc
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Test/SameasTest.php
@@ -0,0 +1,34 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression\Test;
+
+use Twig\Compiler;
+use Twig\Node\Expression\TestExpression;
+
+/**
+ * Checks if a variable is the same as another one (=== in PHP).
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class SameasTest extends TestExpression
+{
+    public function compile(Compiler $compiler): void
+    {
+        $compiler
+            ->raw('(')
+            ->subcompile($this->getNode('node'))
+            ->raw(' === ')
+            ->subcompile($this->getNode('arguments')->getNode(0))
+            ->raw(')')
+        ;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/TestExpression.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/TestExpression.php
new file mode 100644
index 0000000..e518bd8
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/TestExpression.php
@@ -0,0 +1,42 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression;
+
+use Twig\Compiler;
+use Twig\Node\Node;
+
+class TestExpression extends CallExpression
+{
+    public function __construct(Node $node, string $name, ?Node $arguments, int $lineno)
+    {
+        $nodes = ['node' => $node];
+        if (null !== $arguments) {
+            $nodes['arguments'] = $arguments;
+        }
+
+        parent::__construct($nodes, ['name' => $name], $lineno);
+    }
+
+    public function compile(Compiler $compiler): void
+    {
+        $name = $this->getAttribute('name');
+        $test = $compiler->getEnvironment()->getTest($name);
+
+        $this->setAttribute('name', $name);
+        $this->setAttribute('type', 'test');
+        $this->setAttribute('arguments', $test->getArguments());
+        $this->setAttribute('callable', $test->getCallable());
+        $this->setAttribute('is_variadic', $test->isVariadic());
+
+        $this->compileCallable($compiler);
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Unary/AbstractUnary.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Unary/AbstractUnary.php
new file mode 100644
index 0000000..e31e3f8
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Unary/AbstractUnary.php
@@ -0,0 +1,34 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression\Unary;
+
+use Twig\Compiler;
+use Twig\Node\Expression\AbstractExpression;
+use Twig\Node\Node;
+
+abstract class AbstractUnary extends AbstractExpression
+{
+    public function __construct(Node $node, int $lineno)
+    {
+        parent::__construct(['node' => $node], [], $lineno);
+    }
+
+    public function compile(Compiler $compiler): void
+    {
+        $compiler->raw(' ');
+        $this->operator($compiler);
+        $compiler->subcompile($this->getNode('node'));
+    }
+
+    abstract public function operator(Compiler $compiler): Compiler;
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Unary/NegUnary.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Unary/NegUnary.php
new file mode 100644
index 0000000..dc2f235
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Unary/NegUnary.php
@@ -0,0 +1,23 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression\Unary;
+
+use Twig\Compiler;
+
+class NegUnary extends AbstractUnary
+{
+    public function operator(Compiler $compiler): Compiler
+    {
+        return $compiler->raw('-');
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Unary/NotUnary.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Unary/NotUnary.php
new file mode 100644
index 0000000..55c11ba
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Unary/NotUnary.php
@@ -0,0 +1,23 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression\Unary;
+
+use Twig\Compiler;
+
+class NotUnary extends AbstractUnary
+{
+    public function operator(Compiler $compiler): Compiler
+    {
+        return $compiler->raw('!');
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Unary/PosUnary.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Unary/PosUnary.php
new file mode 100644
index 0000000..4b0a062
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Unary/PosUnary.php
@@ -0,0 +1,23 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression\Unary;
+
+use Twig\Compiler;
+
+class PosUnary extends AbstractUnary
+{
+    public function operator(Compiler $compiler): Compiler
+    {
+        return $compiler->raw('+');
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/VariadicExpression.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/VariadicExpression.php
new file mode 100644
index 0000000..a1bdb48
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/VariadicExpression.php
@@ -0,0 +1,24 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node\Expression;
+
+use Twig\Compiler;
+
+class VariadicExpression extends ArrayExpression
+{
+    public function compile(Compiler $compiler): void
+    {
+        $compiler->raw('...');
+
+        parent::compile($compiler);
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/FlushNode.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/FlushNode.php
new file mode 100644
index 0000000..fa50a88
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/FlushNode.php
@@ -0,0 +1,35 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node;
+
+use Twig\Compiler;
+
+/**
+ * Represents a flush node.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class FlushNode extends Node
+{
+    public function __construct(int $lineno, string $tag)
+    {
+        parent::__construct([], [], $lineno, $tag);
+    }
+
+    public function compile(Compiler $compiler): void
+    {
+        $compiler
+            ->addDebugInfo($this)
+            ->write("flush();\n")
+        ;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/ForLoopNode.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/ForLoopNode.php
new file mode 100644
index 0000000..d5ce845
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/ForLoopNode.php
@@ -0,0 +1,49 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node;
+
+use Twig\Compiler;
+
+/**
+ * Internal node used by the for node.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class ForLoopNode extends Node
+{
+    public function __construct(int $lineno, string $tag = null)
+    {
+        parent::__construct([], ['with_loop' => false, 'ifexpr' => false, 'else' => false], $lineno, $tag);
+    }
+
+    public function compile(Compiler $compiler): void
+    {
+        if ($this->getAttribute('else')) {
+            $compiler->write("\$context['_iterated'] = true;\n");
+        }
+
+        if ($this->getAttribute('with_loop')) {
+            $compiler
+                ->write("++\$context['loop']['index0'];\n")
+                ->write("++\$context['loop']['index'];\n")
+                ->write("\$context['loop']['first'] = false;\n")
+                ->write("if (isset(\$context['loop']['length'])) {\n")
+                ->indent()
+                ->write("--\$context['loop']['revindex0'];\n")
+                ->write("--\$context['loop']['revindex'];\n")
+                ->write("\$context['loop']['last'] = 0 === \$context['loop']['revindex0'];\n")
+                ->outdent()
+                ->write("}\n")
+            ;
+        }
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/ForNode.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/ForNode.php
new file mode 100644
index 0000000..04addfb
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/ForNode.php
@@ -0,0 +1,107 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node;
+
+use Twig\Compiler;
+use Twig\Node\Expression\AbstractExpression;
+use Twig\Node\Expression\AssignNameExpression;
+
+/**
+ * Represents a for node.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class ForNode extends Node
+{
+    private $loop;
+
+    public function __construct(AssignNameExpression $keyTarget, AssignNameExpression $valueTarget, AbstractExpression $seq, ?Node $ifexpr, Node $body, ?Node $else, int $lineno, string $tag = null)
+    {
+        $body = new Node([$body, $this->loop = new ForLoopNode($lineno, $tag)]);
+
+        $nodes = ['key_target' => $keyTarget, 'value_target' => $valueTarget, 'seq' => $seq, 'body' => $body];
+        if (null !== $else) {
+            $nodes['else'] = $else;
+        }
+
+        parent::__construct($nodes, ['with_loop' => true], $lineno, $tag);
+    }
+
+    public function compile(Compiler $compiler): void
+    {
+        $compiler
+            ->addDebugInfo($this)
+            ->write("\$context['_parent'] = \$context;\n")
+            ->write("\$context['_seq'] = twig_ensure_traversable(")
+            ->subcompile($this->getNode('seq'))
+            ->raw(");\n")
+        ;
+
+        if ($this->hasNode('else')) {
+            $compiler->write("\$context['_iterated'] = false;\n");
+        }
+
+        if ($this->getAttribute('with_loop')) {
+            $compiler
+                ->write("\$context['loop'] = [\n")
+                ->write("  'parent' => \$context['_parent'],\n")
+                ->write("  'index0' => 0,\n")
+                ->write("  'index'  => 1,\n")
+                ->write("  'first'  => true,\n")
+                ->write("];\n")
+                ->write("if (is_array(\$context['_seq']) || (is_object(\$context['_seq']) && \$context['_seq'] instanceof \Countable)) {\n")
+                ->indent()
+                ->write("\$length = count(\$context['_seq']);\n")
+                ->write("\$context['loop']['revindex0'] = \$length - 1;\n")
+                ->write("\$context['loop']['revindex'] = \$length;\n")
+                ->write("\$context['loop']['length'] = \$length;\n")
+                ->write("\$context['loop']['last'] = 1 === \$length;\n")
+                ->outdent()
+                ->write("}\n")
+            ;
+        }
+
+        $this->loop->setAttribute('else', $this->hasNode('else'));
+        $this->loop->setAttribute('with_loop', $this->getAttribute('with_loop'));
+
+        $compiler
+            ->write("foreach (\$context['_seq'] as ")
+            ->subcompile($this->getNode('key_target'))
+            ->raw(' => ')
+            ->subcompile($this->getNode('value_target'))
+            ->raw(") {\n")
+            ->indent()
+            ->subcompile($this->getNode('body'))
+            ->outdent()
+            ->write("}\n")
+        ;
+
+        if ($this->hasNode('else')) {
+            $compiler
+                ->write("if (!\$context['_iterated']) {\n")
+                ->indent()
+                ->subcompile($this->getNode('else'))
+                ->outdent()
+                ->write("}\n")
+            ;
+        }
+
+        $compiler->write("\$_parent = \$context['_parent'];\n");
+
+        // remove some "private" loop variables (needed for nested loops)
+        $compiler->write('unset($context[\'_seq\'], $context[\'_iterated\'], $context[\''.$this->getNode('key_target')->getAttribute('name').'\'], $context[\''.$this->getNode('value_target')->getAttribute('name').'\'], $context[\'_parent\'], $context[\'loop\']);'."\n");
+
+        // keep the values set in the inner context for variables defined in the outer context
+        $compiler->write("\$context = array_intersect_key(\$context, \$_parent) + \$_parent;\n");
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/IfNode.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/IfNode.php
new file mode 100644
index 0000000..5fa2008
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/IfNode.php
@@ -0,0 +1,70 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node;
+
+use Twig\Compiler;
+
+/**
+ * Represents an if node.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class IfNode extends Node
+{
+    public function __construct(Node $tests, ?Node $else, int $lineno, string $tag = null)
+    {
+        $nodes = ['tests' => $tests];
+        if (null !== $else) {
+            $nodes['else'] = $else;
+        }
+
+        parent::__construct($nodes, [], $lineno, $tag);
+    }
+
+    public function compile(Compiler $compiler): void
+    {
+        $compiler->addDebugInfo($this);
+        for ($i = 0, $count = \count($this->getNode('tests')); $i < $count; $i += 2) {
+            if ($i > 0) {
+                $compiler
+                    ->outdent()
+                    ->write('} elseif (')
+                ;
+            } else {
+                $compiler
+                    ->write('if (')
+                ;
+            }
+
+            $compiler
+                ->subcompile($this->getNode('tests')->getNode($i))
+                ->raw(") {\n")
+                ->indent()
+                ->subcompile($this->getNode('tests')->getNode($i + 1))
+            ;
+        }
+
+        if ($this->hasNode('else')) {
+            $compiler
+                ->outdent()
+                ->write("} else {\n")
+                ->indent()
+                ->subcompile($this->getNode('else'))
+            ;
+        }
+
+        $compiler
+            ->outdent()
+            ->write("}\n");
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/ImportNode.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/ImportNode.php
new file mode 100644
index 0000000..5378d79
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/ImportNode.php
@@ -0,0 +1,63 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node;
+
+use Twig\Compiler;
+use Twig\Node\Expression\AbstractExpression;
+use Twig\Node\Expression\NameExpression;
+
+/**
+ * Represents an import node.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class ImportNode extends Node
+{
+    public function __construct(AbstractExpression $expr, AbstractExpression $var, int $lineno, string $tag = null, bool $global = true)
+    {
+        parent::__construct(['expr' => $expr, 'var' => $var], ['global' => $global], $lineno, $tag);
+    }
+
+    public function compile(Compiler $compiler): void
+    {
+        $compiler
+            ->addDebugInfo($this)
+            ->write('$macros[')
+            ->repr($this->getNode('var')->getAttribute('name'))
+            ->raw('] = ')
+        ;
+
+        if ($this->getAttribute('global')) {
+            $compiler
+                ->raw('$this->macros[')
+                ->repr($this->getNode('var')->getAttribute('name'))
+                ->raw('] = ')
+            ;
+        }
+
+        if ($this->getNode('expr') instanceof NameExpression && '_self' === $this->getNode('expr')->getAttribute('name')) {
+            $compiler->raw('$this');
+        } else {
+            $compiler
+                ->raw('$this->loadTemplate(')
+                ->subcompile($this->getNode('expr'))
+                ->raw(', ')
+                ->repr($this->getTemplateName())
+                ->raw(', ')
+                ->repr($this->getTemplateLine())
+                ->raw(')->unwrap()')
+            ;
+        }
+
+        $compiler->raw(";\n");
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/IncludeNode.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/IncludeNode.php
new file mode 100644
index 0000000..d540d6b
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/IncludeNode.php
@@ -0,0 +1,106 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node;
+
+use Twig\Compiler;
+use Twig\Node\Expression\AbstractExpression;
+
+/**
+ * Represents an include node.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class IncludeNode extends Node implements NodeOutputInterface
+{
+    public function __construct(AbstractExpression $expr, ?AbstractExpression $variables, bool $only, bool $ignoreMissing, int $lineno, string $tag = null)
+    {
+        $nodes = ['expr' => $expr];
+        if (null !== $variables) {
+            $nodes['variables'] = $variables;
+        }
+
+        parent::__construct($nodes, ['only' => $only, 'ignore_missing' => $ignoreMissing], $lineno, $tag);
+    }
+
+    public function compile(Compiler $compiler): void
+    {
+        $compiler->addDebugInfo($this);
+
+        if ($this->getAttribute('ignore_missing')) {
+            $template = $compiler->getVarName();
+
+            $compiler
+                ->write(sprintf("$%s = null;\n", $template))
+                ->write("try {\n")
+                ->indent()
+                ->write(sprintf('$%s = ', $template))
+            ;
+
+            $this->addGetTemplate($compiler);
+
+            $compiler
+                ->raw(";\n")
+                ->outdent()
+                ->write("} catch (LoaderError \$e) {\n")
+                ->indent()
+                ->write("// ignore missing template\n")
+                ->outdent()
+                ->write("}\n")
+                ->write(sprintf("if ($%s) {\n", $template))
+                ->indent()
+                ->write(sprintf('$%s->display(', $template))
+            ;
+            $this->addTemplateArguments($compiler);
+            $compiler
+                ->raw(");\n")
+                ->outdent()
+                ->write("}\n")
+            ;
+        } else {
+            $this->addGetTemplate($compiler);
+            $compiler->raw('->display(');
+            $this->addTemplateArguments($compiler);
+            $compiler->raw(");\n");
+        }
+    }
+
+    protected function addGetTemplate(Compiler $compiler)
+    {
+        $compiler
+            ->write('$this->loadTemplate(')
+            ->subcompile($this->getNode('expr'))
+            ->raw(', ')
+            ->repr($this->getTemplateName())
+            ->raw(', ')
+            ->repr($this->getTemplateLine())
+            ->raw(')')
+        ;
+    }
+
+    protected function addTemplateArguments(Compiler $compiler)
+    {
+        if (!$this->hasNode('variables')) {
+            $compiler->raw(false === $this->getAttribute('only') ? '$context' : '[]');
+        } elseif (false === $this->getAttribute('only')) {
+            $compiler
+                ->raw('twig_array_merge($context, ')
+                ->subcompile($this->getNode('variables'))
+                ->raw(')')
+            ;
+        } else {
+            $compiler->raw('twig_to_array(');
+            $compiler->subcompile($this->getNode('variables'));
+            $compiler->raw(')');
+        }
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/MacroNode.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/MacroNode.php
new file mode 100644
index 0000000..7f1b24d
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/MacroNode.php
@@ -0,0 +1,113 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node;
+
+use Twig\Compiler;
+use Twig\Error\SyntaxError;
+
+/**
+ * Represents a macro node.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class MacroNode extends Node
+{
+    public const VARARGS_NAME = 'varargs';
+
+    public function __construct(string $name, Node $body, Node $arguments, int $lineno, string $tag = null)
+    {
+        foreach ($arguments as $argumentName => $argument) {
+            if (self::VARARGS_NAME === $argumentName) {
+                throw new SyntaxError(sprintf('The argument "%s" in macro "%s" cannot be defined because the variable "%s" is reserved for arbitrary arguments.', self::VARARGS_NAME, $name, self::VARARGS_NAME), $argument->getTemplateLine(), $argument->getSourceContext());
+            }
+        }
+
+        parent::__construct(['body' => $body, 'arguments' => $arguments], ['name' => $name], $lineno, $tag);
+    }
+
+    public function compile(Compiler $compiler): void
+    {
+        $compiler
+            ->addDebugInfo($this)
+            ->write(sprintf('public function macro_%s(', $this->getAttribute('name')))
+        ;
+
+        $count = \count($this->getNode('arguments'));
+        $pos = 0;
+        foreach ($this->getNode('arguments') as $name => $default) {
+            $compiler
+                ->raw('$__'.$name.'__ = ')
+                ->subcompile($default)
+            ;
+
+            if (++$pos < $count) {
+                $compiler->raw(', ');
+            }
+        }
+
+        if ($count) {
+            $compiler->raw(', ');
+        }
+
+        $compiler
+            ->raw('...$__varargs__')
+            ->raw(")\n")
+            ->write("{\n")
+            ->indent()
+            ->write("\$macros = \$this->macros;\n")
+            ->write("\$context = \$this->env->mergeGlobals([\n")
+            ->indent()
+        ;
+
+        foreach ($this->getNode('arguments') as $name => $default) {
+            $compiler
+                ->write('')
+                ->string($name)
+                ->raw(' => $__'.$name.'__')
+                ->raw(",\n")
+            ;
+        }
+
+        $compiler
+            ->write('')
+            ->string(self::VARARGS_NAME)
+            ->raw(' => ')
+        ;
+
+        $compiler
+            ->raw("\$__varargs__,\n")
+            ->outdent()
+            ->write("]);\n\n")
+            ->write("\$blocks = [];\n\n")
+        ;
+        if ($compiler->getEnvironment()->isDebug()) {
+            $compiler->write("ob_start();\n");
+        } else {
+            $compiler->write("ob_start(function () { return ''; });\n");
+        }
+        $compiler
+            ->write("try {\n")
+            ->indent()
+            ->subcompile($this->getNode('body'))
+            ->raw("\n")
+            ->write("return ('' === \$tmp = ob_get_contents()) ? '' : new Markup(\$tmp, \$this->env->getCharset());\n")
+            ->outdent()
+            ->write("} finally {\n")
+            ->indent()
+            ->write("ob_end_clean();\n")
+            ->outdent()
+            ->write("}\n")
+            ->outdent()
+            ->write("}\n\n")
+        ;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/ModuleNode.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/ModuleNode.php
new file mode 100644
index 0000000..e972b6b
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/ModuleNode.php
@@ -0,0 +1,464 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node;
+
+use Twig\Compiler;
+use Twig\Node\Expression\AbstractExpression;
+use Twig\Node\Expression\ConstantExpression;
+use Twig\Source;
+
+/**
+ * Represents a module node.
+ *
+ * Consider this class as being final. If you need to customize the behavior of
+ * the generated class, consider adding nodes to the following nodes: display_start,
+ * display_end, constructor_start, constructor_end, and class_end.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+final class ModuleNode extends Node
+{
+    public function __construct(Node $body, ?AbstractExpression $parent, Node $blocks, Node $macros, Node $traits, $embeddedTemplates, Source $source)
+    {
+        $nodes = [
+            'body' => $body,
+            'blocks' => $blocks,
+            'macros' => $macros,
+            'traits' => $traits,
+            'display_start' => new Node(),
+            'display_end' => new Node(),
+            'constructor_start' => new Node(),
+            'constructor_end' => new Node(),
+            'class_end' => new Node(),
+        ];
+        if (null !== $parent) {
+            $nodes['parent'] = $parent;
+        }
+
+        // embedded templates are set as attributes so that they are only visited once by the visitors
+        parent::__construct($nodes, [
+            'index' => null,
+            'embedded_templates' => $embeddedTemplates,
+        ], 1);
+
+        // populate the template name of all node children
+        $this->setSourceContext($source);
+    }
+
+    public function setIndex($index)
+    {
+        $this->setAttribute('index', $index);
+    }
+
+    public function compile(Compiler $compiler): void
+    {
+        $this->compileTemplate($compiler);
+
+        foreach ($this->getAttribute('embedded_templates') as $template) {
+            $compiler->subcompile($template);
+        }
+    }
+
+    protected function compileTemplate(Compiler $compiler)
+    {
+        if (!$this->getAttribute('index')) {
+            $compiler->write('<?php');
+        }
+
+        $this->compileClassHeader($compiler);
+
+        $this->compileConstructor($compiler);
+
+        $this->compileGetParent($compiler);
+
+        $this->compileDisplay($compiler);
+
+        $compiler->subcompile($this->getNode('blocks'));
+
+        $this->compileMacros($compiler);
+
+        $this->compileGetTemplateName($compiler);
+
+        $this->compileIsTraitable($compiler);
+
+        $this->compileDebugInfo($compiler);
+
+        $this->compileGetSourceContext($compiler);
+
+        $this->compileClassFooter($compiler);
+    }
+
+    protected function compileGetParent(Compiler $compiler)
+    {
+        if (!$this->hasNode('parent')) {
+            return;
+        }
+        $parent = $this->getNode('parent');
+
+        $compiler
+            ->write("protected function doGetParent(array \$context)\n", "{\n")
+            ->indent()
+            ->addDebugInfo($parent)
+            ->write('return ')
+        ;
+
+        if ($parent instanceof ConstantExpression) {
+            $compiler->subcompile($parent);
+        } else {
+            $compiler
+                ->raw('$this->loadTemplate(')
+                ->subcompile($parent)
+                ->raw(', ')
+                ->repr($this->getSourceContext()->getName())
+                ->raw(', ')
+                ->repr($parent->getTemplateLine())
+                ->raw(')')
+            ;
+        }
+
+        $compiler
+            ->raw(";\n")
+            ->outdent()
+            ->write("}\n\n")
+        ;
+    }
+
+    protected function compileClassHeader(Compiler $compiler)
+    {
+        $compiler
+            ->write("\n\n")
+        ;
+        if (!$this->getAttribute('index')) {
+            $compiler
+                ->write("use Twig\Environment;\n")
+                ->write("use Twig\Error\LoaderError;\n")
+                ->write("use Twig\Error\RuntimeError;\n")
+                ->write("use Twig\Extension\SandboxExtension;\n")
+                ->write("use Twig\Markup;\n")
+                ->write("use Twig\Sandbox\SecurityError;\n")
+                ->write("use Twig\Sandbox\SecurityNotAllowedTagError;\n")
+                ->write("use Twig\Sandbox\SecurityNotAllowedFilterError;\n")
+                ->write("use Twig\Sandbox\SecurityNotAllowedFunctionError;\n")
+                ->write("use Twig\Source;\n")
+                ->write("use Twig\Template;\n\n")
+            ;
+        }
+        $compiler
+            // if the template name contains */, add a blank to avoid a PHP parse error
+            ->write('/* '.str_replace('*/', '* /', $this->getSourceContext()->getName())." */\n")
+            ->write('class '.$compiler->getEnvironment()->getTemplateClass($this->getSourceContext()->getName(), $this->getAttribute('index')))
+            ->raw(" extends Template\n")
+            ->write("{\n")
+            ->indent()
+            ->write("private \$source;\n")
+            ->write("private \$macros = [];\n\n")
+        ;
+    }
+
+    protected function compileConstructor(Compiler $compiler)
+    {
+        $compiler
+            ->write("public function __construct(Environment \$env)\n", "{\n")
+            ->indent()
+            ->subcompile($this->getNode('constructor_start'))
+            ->write("parent::__construct(\$env);\n\n")
+            ->write("\$this->source = \$this->getSourceContext();\n\n")
+        ;
+
+        // parent
+        if (!$this->hasNode('parent')) {
+            $compiler->write("\$this->parent = false;\n\n");
+        }
+
+        $countTraits = \count($this->getNode('traits'));
+        if ($countTraits) {
+            // traits
+            foreach ($this->getNode('traits') as $i => $trait) {
+                $node = $trait->getNode('template');
+
+                $compiler
+                    ->addDebugInfo($node)
+                    ->write(sprintf('$_trait_%s = $this->loadTemplate(', $i))
+                    ->subcompile($node)
+                    ->raw(', ')
+                    ->repr($node->getTemplateName())
+                    ->raw(', ')
+                    ->repr($node->getTemplateLine())
+                    ->raw(");\n")
+                    ->write(sprintf("if (!\$_trait_%s->isTraitable()) {\n", $i))
+                    ->indent()
+                    ->write("throw new RuntimeError('Template \"'.")
+                    ->subcompile($trait->getNode('template'))
+                    ->raw(".'\" cannot be used as a trait.', ")
+                    ->repr($node->getTemplateLine())
+                    ->raw(", \$this->source);\n")
+                    ->outdent()
+                    ->write("}\n")
+                    ->write(sprintf("\$_trait_%s_blocks = \$_trait_%s->getBlocks();\n\n", $i, $i))
+                ;
+
+                foreach ($trait->getNode('targets') as $key => $value) {
+                    $compiler
+                        ->write(sprintf('if (!isset($_trait_%s_blocks[', $i))
+                        ->string($key)
+                        ->raw("])) {\n")
+                        ->indent()
+                        ->write("throw new RuntimeError('Block ")
+                        ->string($key)
+                        ->raw(' is not defined in trait ')
+                        ->subcompile($trait->getNode('template'))
+                        ->raw(".', ")
+                        ->repr($node->getTemplateLine())
+                        ->raw(", \$this->source);\n")
+                        ->outdent()
+                        ->write("}\n\n")
+
+                        ->write(sprintf('$_trait_%s_blocks[', $i))
+                        ->subcompile($value)
+                        ->raw(sprintf('] = $_trait_%s_blocks[', $i))
+                        ->string($key)
+                        ->raw(sprintf(']; unset($_trait_%s_blocks[', $i))
+                        ->string($key)
+                        ->raw("]);\n\n")
+                    ;
+                }
+            }
+
+            if ($countTraits > 1) {
+                $compiler
+                    ->write("\$this->traits = array_merge(\n")
+                    ->indent()
+                ;
+
+                for ($i = 0; $i < $countTraits; ++$i) {
+                    $compiler
+                        ->write(sprintf('$_trait_%s_blocks'.($i == $countTraits - 1 ? '' : ',')."\n", $i))
+                    ;
+                }
+
+                $compiler
+                    ->outdent()
+                    ->write(");\n\n")
+                ;
+            } else {
+                $compiler
+                    ->write("\$this->traits = \$_trait_0_blocks;\n\n")
+                ;
+            }
+
+            $compiler
+                ->write("\$this->blocks = array_merge(\n")
+                ->indent()
+                ->write("\$this->traits,\n")
+                ->write("[\n")
+            ;
+        } else {
+            $compiler
+                ->write("\$this->blocks = [\n")
+            ;
+        }
+
+        // blocks
+        $compiler
+            ->indent()
+        ;
+
+        foreach ($this->getNode('blocks') as $name => $node) {
+            $compiler
+                ->write(sprintf("'%s' => [\$this, 'block_%s'],\n", $name, $name))
+            ;
+        }
+
+        if ($countTraits) {
+            $compiler
+                ->outdent()
+                ->write("]\n")
+                ->outdent()
+                ->write(");\n")
+            ;
+        } else {
+            $compiler
+                ->outdent()
+                ->write("];\n")
+            ;
+        }
+
+        $compiler
+            ->subcompile($this->getNode('constructor_end'))
+            ->outdent()
+            ->write("}\n\n")
+        ;
+    }
+
+    protected function compileDisplay(Compiler $compiler)
+    {
+        $compiler
+            ->write("protected function doDisplay(array \$context, array \$blocks = [])\n", "{\n")
+            ->indent()
+            ->write("\$macros = \$this->macros;\n")
+            ->subcompile($this->getNode('display_start'))
+            ->subcompile($this->getNode('body'))
+        ;
+
+        if ($this->hasNode('parent')) {
+            $parent = $this->getNode('parent');
+
+            $compiler->addDebugInfo($parent);
+            if ($parent instanceof ConstantExpression) {
+                $compiler
+                    ->write('$this->parent = $this->loadTemplate(')
+                    ->subcompile($parent)
+                    ->raw(', ')
+                    ->repr($this->getSourceContext()->getName())
+                    ->raw(', ')
+                    ->repr($parent->getTemplateLine())
+                    ->raw(");\n")
+                ;
+                $compiler->write('$this->parent');
+            } else {
+                $compiler->write('$this->getParent($context)');
+            }
+            $compiler->raw("->display(\$context, array_merge(\$this->blocks, \$blocks));\n");
+        }
+
+        $compiler
+            ->subcompile($this->getNode('display_end'))
+            ->outdent()
+            ->write("}\n\n")
+        ;
+    }
+
+    protected function compileClassFooter(Compiler $compiler)
+    {
+        $compiler
+            ->subcompile($this->getNode('class_end'))
+            ->outdent()
+            ->write("}\n")
+        ;
+    }
+
+    protected function compileMacros(Compiler $compiler)
+    {
+        $compiler->subcompile($this->getNode('macros'));
+    }
+
+    protected function compileGetTemplateName(Compiler $compiler)
+    {
+        $compiler
+            ->write("public function getTemplateName()\n", "{\n")
+            ->indent()
+            ->write('return ')
+            ->repr($this->getSourceContext()->getName())
+            ->raw(";\n")
+            ->outdent()
+            ->write("}\n\n")
+        ;
+    }
+
+    protected function compileIsTraitable(Compiler $compiler)
+    {
+        // A template can be used as a trait if:
+        //   * it has no parent
+        //   * it has no macros
+        //   * it has no body
+        //
+        // Put another way, a template can be used as a trait if it
+        // only contains blocks and use statements.
+        $traitable = !$this->hasNode('parent') && 0 === \count($this->getNode('macros'));
+        if ($traitable) {
+            if ($this->getNode('body') instanceof BodyNode) {
+                $nodes = $this->getNode('body')->getNode(0);
+            } else {
+                $nodes = $this->getNode('body');
+            }
+
+            if (!\count($nodes)) {
+                $nodes = new Node([$nodes]);
+            }
+
+            foreach ($nodes as $node) {
+                if (!\count($node)) {
+                    continue;
+                }
+
+                if ($node instanceof TextNode && ctype_space($node->getAttribute('data'))) {
+                    continue;
+                }
+
+                if ($node instanceof BlockReferenceNode) {
+                    continue;
+                }
+
+                $traitable = false;
+                break;
+            }
+        }
+
+        if ($traitable) {
+            return;
+        }
+
+        $compiler
+            ->write("public function isTraitable()\n", "{\n")
+            ->indent()
+            ->write(sprintf("return %s;\n", $traitable ? 'true' : 'false'))
+            ->outdent()
+            ->write("}\n\n")
+        ;
+    }
+
+    protected function compileDebugInfo(Compiler $compiler)
+    {
+        $compiler
+            ->write("public function getDebugInfo()\n", "{\n")
+            ->indent()
+            ->write(sprintf("return %s;\n", str_replace("\n", '', var_export(array_reverse($compiler->getDebugInfo(), true), true))))
+            ->outdent()
+            ->write("}\n\n")
+        ;
+    }
+
+    protected function compileGetSourceContext(Compiler $compiler)
+    {
+        $compiler
+            ->write("public function getSourceContext()\n", "{\n")
+            ->indent()
+            ->write('return new Source(')
+            ->string($compiler->getEnvironment()->isDebug() ? $this->getSourceContext()->getCode() : '')
+            ->raw(', ')
+            ->string($this->getSourceContext()->getName())
+            ->raw(', ')
+            ->string($this->getSourceContext()->getPath())
+            ->raw(");\n")
+            ->outdent()
+            ->write("}\n")
+        ;
+    }
+
+    protected function compileLoadTemplate(Compiler $compiler, $node, $var)
+    {
+        if ($node instanceof ConstantExpression) {
+            $compiler
+                ->write(sprintf('%s = $this->loadTemplate(', $var))
+                ->subcompile($node)
+                ->raw(', ')
+                ->repr($node->getTemplateName())
+                ->raw(', ')
+                ->repr($node->getTemplateLine())
+                ->raw(");\n")
+            ;
+        } else {
+            throw new \LogicException('Trait templates can only be constant nodes.');
+        }
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Node.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Node.php
new file mode 100644
index 0000000..e974b49
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Node.php
@@ -0,0 +1,178 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node;
+
+use Twig\Compiler;
+use Twig\Source;
+
+/**
+ * Represents a node in the AST.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class Node implements \Countable, \IteratorAggregate
+{
+    protected $nodes;
+    protected $attributes;
+    protected $lineno;
+    protected $tag;
+
+    private $name;
+    private $sourceContext;
+
+    /**
+     * @param array  $nodes      An array of named nodes
+     * @param array  $attributes An array of attributes (should not be nodes)
+     * @param int    $lineno     The line number
+     * @param string $tag        The tag name associated with the Node
+     */
+    public function __construct(array $nodes = [], array $attributes = [], int $lineno = 0, string $tag = null)
+    {
+        foreach ($nodes as $name => $node) {
+            if (!$node instanceof self) {
+                throw new \InvalidArgumentException(sprintf('Using "%s" for the value of node "%s" of "%s" is not supported. You must pass a \Twig\Node\Node instance.', \is_object($node) ? \get_class($node) : (null === $node ? 'null' : \gettype($node)), $name, static::class));
+            }
+        }
+        $this->nodes = $nodes;
+        $this->attributes = $attributes;
+        $this->lineno = $lineno;
+        $this->tag = $tag;
+    }
+
+    public function __toString()
+    {
+        $attributes = [];
+        foreach ($this->attributes as $name => $value) {
+            $attributes[] = sprintf('%s: %s', $name, str_replace("\n", '', var_export($value, true)));
+        }
+
+        $repr = [static::class.'('.implode(', ', $attributes)];
+
+        if (\count($this->nodes)) {
+            foreach ($this->nodes as $name => $node) {
+                $len = \strlen($name) + 4;
+                $noderepr = [];
+                foreach (explode("\n", (string) $node) as $line) {
+                    $noderepr[] = str_repeat(' ', $len).$line;
+                }
+
+                $repr[] = sprintf('  %s: %s', $name, ltrim(implode("\n", $noderepr)));
+            }
+
+            $repr[] = ')';
+        } else {
+            $repr[0] .= ')';
+        }
+
+        return implode("\n", $repr);
+    }
+
+    /**
+     * @return void
+     */
+    public function compile(Compiler $compiler)
+    {
+        foreach ($this->nodes as $node) {
+            $node->compile($compiler);
+        }
+    }
+
+    public function getTemplateLine(): int
+    {
+        return $this->lineno;
+    }
+
+    public function getNodeTag(): ?string
+    {
+        return $this->tag;
+    }
+
+    public function hasAttribute(string $name): bool
+    {
+        return \array_key_exists($name, $this->attributes);
+    }
+
+    public function getAttribute(string $name)
+    {
+        if (!\array_key_exists($name, $this->attributes)) {
+            throw new \LogicException(sprintf('Attribute "%s" does not exist for Node "%s".', $name, static::class));
+        }
+
+        return $this->attributes[$name];
+    }
+
+    public function setAttribute(string $name, $value): void
+    {
+        $this->attributes[$name] = $value;
+    }
+
+    public function removeAttribute(string $name): void
+    {
+        unset($this->attributes[$name]);
+    }
+
+    public function hasNode(string $name): bool
+    {
+        return isset($this->nodes[$name]);
+    }
+
+    public function getNode(string $name): self
+    {
+        if (!isset($this->nodes[$name])) {
+            throw new \LogicException(sprintf('Node "%s" does not exist for Node "%s".', $name, static::class));
+        }
+
+        return $this->nodes[$name];
+    }
+
+    public function setNode(string $name, self $node): void
+    {
+        $this->nodes[$name] = $node;
+    }
+
+    public function removeNode(string $name): void
+    {
+        unset($this->nodes[$name]);
+    }
+
+    /**
+     * @return int
+     */
+    public function count()
+    {
+        return \count($this->nodes);
+    }
+
+    public function getIterator(): \Traversable
+    {
+        return new \ArrayIterator($this->nodes);
+    }
+
+    public function getTemplateName(): ?string
+    {
+        return $this->sourceContext ? $this->sourceContext->getName() : null;
+    }
+
+    public function setSourceContext(Source $source): void
+    {
+        $this->sourceContext = $source;
+        foreach ($this->nodes as $node) {
+            $node->setSourceContext($source);
+        }
+    }
+
+    public function getSourceContext(): ?Source
+    {
+        return $this->sourceContext;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/NodeCaptureInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/NodeCaptureInterface.php
new file mode 100644
index 0000000..9fb6a0c
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/NodeCaptureInterface.php
@@ -0,0 +1,21 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node;
+
+/**
+ * Represents a node that captures any nested displayable nodes.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+interface NodeCaptureInterface
+{
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/NodeOutputInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/NodeOutputInterface.php
new file mode 100644
index 0000000..5e35b40
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/NodeOutputInterface.php
@@ -0,0 +1,21 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node;
+
+/**
+ * Represents a displayable node in the AST.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+interface NodeOutputInterface
+{
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/PrintNode.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/PrintNode.php
new file mode 100644
index 0000000..60386d2
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/PrintNode.php
@@ -0,0 +1,39 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node;
+
+use Twig\Compiler;
+use Twig\Node\Expression\AbstractExpression;
+
+/**
+ * Represents a node that outputs an expression.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class PrintNode extends Node implements NodeOutputInterface
+{
+    public function __construct(AbstractExpression $expr, int $lineno, string $tag = null)
+    {
+        parent::__construct(['expr' => $expr], [], $lineno, $tag);
+    }
+
+    public function compile(Compiler $compiler): void
+    {
+        $compiler
+            ->addDebugInfo($this)
+            ->write('echo ')
+            ->subcompile($this->getNode('expr'))
+            ->raw(";\n")
+        ;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/SandboxNode.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/SandboxNode.php
new file mode 100644
index 0000000..4d5666b
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/SandboxNode.php
@@ -0,0 +1,52 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node;
+
+use Twig\Compiler;
+
+/**
+ * Represents a sandbox node.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class SandboxNode extends Node
+{
+    public function __construct(Node $body, int $lineno, string $tag = null)
+    {
+        parent::__construct(['body' => $body], [], $lineno, $tag);
+    }
+
+    public function compile(Compiler $compiler): void
+    {
+        $compiler
+            ->addDebugInfo($this)
+            ->write("if (!\$alreadySandboxed = \$this->sandbox->isSandboxed()) {\n")
+            ->indent()
+            ->write("\$this->sandbox->enableSandbox();\n")
+            ->outdent()
+            ->write("}\n")
+            ->write("try {\n")
+            ->indent()
+            ->subcompile($this->getNode('body'))
+            ->outdent()
+            ->write("} finally {\n")
+            ->indent()
+            ->write("if (!\$alreadySandboxed) {\n")
+            ->indent()
+            ->write("\$this->sandbox->disableSandbox();\n")
+            ->outdent()
+            ->write("}\n")
+            ->outdent()
+            ->write("}\n")
+        ;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/SetNode.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/SetNode.php
new file mode 100644
index 0000000..96b6bd8
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/SetNode.php
@@ -0,0 +1,105 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node;
+
+use Twig\Compiler;
+use Twig\Node\Expression\ConstantExpression;
+
+/**
+ * Represents a set node.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class SetNode extends Node implements NodeCaptureInterface
+{
+    public function __construct(bool $capture, Node $names, Node $values, int $lineno, string $tag = null)
+    {
+        parent::__construct(['names' => $names, 'values' => $values], ['capture' => $capture, 'safe' => false], $lineno, $tag);
+
+        /*
+         * Optimizes the node when capture is used for a large block of text.
+         *
+         * {% set foo %}foo{% endset %} is compiled to $context['foo'] = new Twig\Markup("foo");
+         */
+        if ($this->getAttribute('capture')) {
+            $this->setAttribute('safe', true);
+
+            $values = $this->getNode('values');
+            if ($values instanceof TextNode) {
+                $this->setNode('values', new ConstantExpression($values->getAttribute('data'), $values->getTemplateLine()));
+                $this->setAttribute('capture', false);
+            }
+        }
+    }
+
+    public function compile(Compiler $compiler): void
+    {
+        $compiler->addDebugInfo($this);
+
+        if (\count($this->getNode('names')) > 1) {
+            $compiler->write('list(');
+            foreach ($this->getNode('names') as $idx => $node) {
+                if ($idx) {
+                    $compiler->raw(', ');
+                }
+
+                $compiler->subcompile($node);
+            }
+            $compiler->raw(')');
+        } else {
+            if ($this->getAttribute('capture')) {
+                if ($compiler->getEnvironment()->isDebug()) {
+                    $compiler->write("ob_start();\n");
+                } else {
+                    $compiler->write("ob_start(function () { return ''; });\n");
+                }
+                $compiler
+                    ->subcompile($this->getNode('values'))
+                ;
+            }
+
+            $compiler->subcompile($this->getNode('names'), false);
+
+            if ($this->getAttribute('capture')) {
+                $compiler->raw(" = ('' === \$tmp = ob_get_clean()) ? '' : new Markup(\$tmp, \$this->env->getCharset())");
+            }
+        }
+
+        if (!$this->getAttribute('capture')) {
+            $compiler->raw(' = ');
+
+            if (\count($this->getNode('names')) > 1) {
+                $compiler->write('[');
+                foreach ($this->getNode('values') as $idx => $value) {
+                    if ($idx) {
+                        $compiler->raw(', ');
+                    }
+
+                    $compiler->subcompile($value);
+                }
+                $compiler->raw(']');
+            } else {
+                if ($this->getAttribute('safe')) {
+                    $compiler
+                        ->raw("('' === \$tmp = ")
+                        ->subcompile($this->getNode('values'))
+                        ->raw(") ? '' : new Markup(\$tmp, \$this->env->getCharset())")
+                    ;
+                } else {
+                    $compiler->subcompile($this->getNode('values'));
+                }
+            }
+        }
+
+        $compiler->raw(";\n");
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/TextNode.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/TextNode.php
new file mode 100644
index 0000000..d74ebe6
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/TextNode.php
@@ -0,0 +1,38 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node;
+
+use Twig\Compiler;
+
+/**
+ * Represents a text node.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class TextNode extends Node implements NodeOutputInterface
+{
+    public function __construct(string $data, int $lineno)
+    {
+        parent::__construct([], ['data' => $data], $lineno);
+    }
+
+    public function compile(Compiler $compiler): void
+    {
+        $compiler
+            ->addDebugInfo($this)
+            ->write('echo ')
+            ->string($this->getAttribute('data'))
+            ->raw(";\n")
+        ;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/WithNode.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/WithNode.php
new file mode 100644
index 0000000..56a3344
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/WithNode.php
@@ -0,0 +1,70 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Node;
+
+use Twig\Compiler;
+
+/**
+ * Represents a nested "with" scope.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class WithNode extends Node
+{
+    public function __construct(Node $body, ?Node $variables, bool $only, int $lineno, string $tag = null)
+    {
+        $nodes = ['body' => $body];
+        if (null !== $variables) {
+            $nodes['variables'] = $variables;
+        }
+
+        parent::__construct($nodes, ['only' => $only], $lineno, $tag);
+    }
+
+    public function compile(Compiler $compiler): void
+    {
+        $compiler->addDebugInfo($this);
+
+        $parentContextName = $compiler->getVarName();
+
+        $compiler->write(sprintf("\$%s = \$context;\n", $parentContextName));
+
+        if ($this->hasNode('variables')) {
+            $node = $this->getNode('variables');
+            $varsName = $compiler->getVarName();
+            $compiler
+                ->write(sprintf('$%s = ', $varsName))
+                ->subcompile($node)
+                ->raw(";\n")
+                ->write(sprintf("if (!twig_test_iterable(\$%s)) {\n", $varsName))
+                ->indent()
+                ->write("throw new RuntimeError('Variables passed to the \"with\" tag must be a hash.', ")
+                ->repr($node->getTemplateLine())
+                ->raw(", \$this->getSourceContext());\n")
+                ->outdent()
+                ->write("}\n")
+                ->write(sprintf("\$%s = twig_to_array(\$%s);\n", $varsName, $varsName))
+            ;
+
+            if ($this->getAttribute('only')) {
+                $compiler->write("\$context = [];\n");
+            }
+
+            $compiler->write(sprintf("\$context = \$this->env->mergeGlobals(array_merge(\$context, \$%s));\n", $varsName));
+        }
+
+        $compiler
+            ->subcompile($this->getNode('body'))
+            ->write(sprintf("\$context = \$%s;\n", $parentContextName))
+        ;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/NodeTraverser.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/NodeTraverser.php
new file mode 100644
index 0000000..47a2d5c
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/NodeTraverser.php
@@ -0,0 +1,76 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig;
+
+use Twig\Node\Node;
+use Twig\NodeVisitor\NodeVisitorInterface;
+
+/**
+ * A node traverser.
+ *
+ * It visits all nodes and their children and calls the given visitor for each.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+final class NodeTraverser
+{
+    private $env;
+    private $visitors = [];
+
+    /**
+     * @param NodeVisitorInterface[] $visitors
+     */
+    public function __construct(Environment $env, array $visitors = [])
+    {
+        $this->env = $env;
+        foreach ($visitors as $visitor) {
+            $this->addVisitor($visitor);
+        }
+    }
+
+    public function addVisitor(NodeVisitorInterface $visitor): void
+    {
+        $this->visitors[$visitor->getPriority()][] = $visitor;
+    }
+
+    /**
+     * Traverses a node and calls the registered visitors.
+     */
+    public function traverse(Node $node): Node
+    {
+        ksort($this->visitors);
+        foreach ($this->visitors as $visitors) {
+            foreach ($visitors as $visitor) {
+                $node = $this->traverseForVisitor($visitor, $node);
+            }
+        }
+
+        return $node;
+    }
+
+    private function traverseForVisitor(NodeVisitorInterface $visitor, Node $node): ?Node
+    {
+        $node = $visitor->enterNode($node, $this->env);
+
+        foreach ($node as $k => $n) {
+            if (null !== $m = $this->traverseForVisitor($visitor, $n)) {
+                if ($m !== $n) {
+                    $node->setNode($k, $m);
+                }
+            } else {
+                $node->removeNode($k);
+            }
+        }
+
+        return $visitor->leaveNode($node, $this->env);
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/NodeVisitor/AbstractNodeVisitor.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/NodeVisitor/AbstractNodeVisitor.php
new file mode 100644
index 0000000..d7036ae
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/NodeVisitor/AbstractNodeVisitor.php
@@ -0,0 +1,49 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\NodeVisitor;
+
+use Twig\Environment;
+use Twig\Node\Node;
+
+/**
+ * Used to make node visitors compatible with Twig 1.x and 2.x.
+ *
+ * To be removed in Twig 3.1.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+abstract class AbstractNodeVisitor implements NodeVisitorInterface
+{
+    final public function enterNode(Node $node, Environment $env): Node
+    {
+        return $this->doEnterNode($node, $env);
+    }
+
+    final public function leaveNode(Node $node, Environment $env): ?Node
+    {
+        return $this->doLeaveNode($node, $env);
+    }
+
+    /**
+     * Called before child nodes are visited.
+     *
+     * @return Node The modified node
+     */
+    abstract protected function doEnterNode(Node $node, Environment $env);
+
+    /**
+     * Called after child nodes are visited.
+     *
+     * @return Node|null The modified node or null if the node must be removed
+     */
+    abstract protected function doLeaveNode(Node $node, Environment $env);
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/NodeVisitor/EscaperNodeVisitor.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/NodeVisitor/EscaperNodeVisitor.php
new file mode 100644
index 0000000..fe56ea3
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/NodeVisitor/EscaperNodeVisitor.php
@@ -0,0 +1,208 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\NodeVisitor;
+
+use Twig\Environment;
+use Twig\Extension\EscaperExtension;
+use Twig\Node\AutoEscapeNode;
+use Twig\Node\BlockNode;
+use Twig\Node\BlockReferenceNode;
+use Twig\Node\DoNode;
+use Twig\Node\Expression\ConditionalExpression;
+use Twig\Node\Expression\ConstantExpression;
+use Twig\Node\Expression\FilterExpression;
+use Twig\Node\Expression\InlinePrint;
+use Twig\Node\ImportNode;
+use Twig\Node\ModuleNode;
+use Twig\Node\Node;
+use Twig\Node\PrintNode;
+use Twig\NodeTraverser;
+
+/**
+ * @author Fabien Potencier <fabien@symfony.com>
+ *
+ * @internal
+ */
+final class EscaperNodeVisitor implements NodeVisitorInterface
+{
+    private $statusStack = [];
+    private $blocks = [];
+    private $safeAnalysis;
+    private $traverser;
+    private $defaultStrategy = false;
+    private $safeVars = [];
+
+    public function __construct()
+    {
+        $this->safeAnalysis = new SafeAnalysisNodeVisitor();
+    }
+
+    public function enterNode(Node $node, Environment $env): Node
+    {
+        if ($node instanceof ModuleNode) {
+            if ($env->hasExtension(EscaperExtension::class) && $defaultStrategy = $env->getExtension(EscaperExtension::class)->getDefaultStrategy($node->getTemplateName())) {
+                $this->defaultStrategy = $defaultStrategy;
+            }
+            $this->safeVars = [];
+            $this->blocks = [];
+        } elseif ($node instanceof AutoEscapeNode) {
+            $this->statusStack[] = $node->getAttribute('value');
+        } elseif ($node instanceof BlockNode) {
+            $this->statusStack[] = isset($this->blocks[$node->getAttribute('name')]) ? $this->blocks[$node->getAttribute('name')] : $this->needEscaping($env);
+        } elseif ($node instanceof ImportNode) {
+            $this->safeVars[] = $node->getNode('var')->getAttribute('name');
+        }
+
+        return $node;
+    }
+
+    public function leaveNode(Node $node, Environment $env): ?Node
+    {
+        if ($node instanceof ModuleNode) {
+            $this->defaultStrategy = false;
+            $this->safeVars = [];
+            $this->blocks = [];
+        } elseif ($node instanceof FilterExpression) {
+            return $this->preEscapeFilterNode($node, $env);
+        } elseif ($node instanceof PrintNode && false !== $type = $this->needEscaping($env)) {
+            $expression = $node->getNode('expr');
+            if ($expression instanceof ConditionalExpression && $this->shouldUnwrapConditional($expression, $env, $type)) {
+                return new DoNode($this->unwrapConditional($expression, $env, $type), $expression->getTemplateLine());
+            }
+
+            return $this->escapePrintNode($node, $env, $type);
+        }
+
+        if ($node instanceof AutoEscapeNode || $node instanceof BlockNode) {
+            array_pop($this->statusStack);
+        } elseif ($node instanceof BlockReferenceNode) {
+            $this->blocks[$node->getAttribute('name')] = $this->needEscaping($env);
+        }
+
+        return $node;
+    }
+
+    private function shouldUnwrapConditional(ConditionalExpression $expression, Environment $env, string $type): bool
+    {
+        $expr2Safe = $this->isSafeFor($type, $expression->getNode('expr2'), $env);
+        $expr3Safe = $this->isSafeFor($type, $expression->getNode('expr3'), $env);
+
+        return $expr2Safe !== $expr3Safe;
+    }
+
+    private function unwrapConditional(ConditionalExpression $expression, Environment $env, string $type): ConditionalExpression
+    {
+        // convert "echo a ? b : c" to "a ? echo b : echo c" recursively
+        $expr2 = $expression->getNode('expr2');
+        if ($expr2 instanceof ConditionalExpression && $this->shouldUnwrapConditional($expr2, $env, $type)) {
+            $expr2 = $this->unwrapConditional($expr2, $env, $type);
+        } else {
+            $expr2 = $this->escapeInlinePrintNode(new InlinePrint($expr2, $expr2->getTemplateLine()), $env, $type);
+        }
+        $expr3 = $expression->getNode('expr3');
+        if ($expr3 instanceof ConditionalExpression && $this->shouldUnwrapConditional($expr3, $env, $type)) {
+            $expr3 = $this->unwrapConditional($expr3, $env, $type);
+        } else {
+            $expr3 = $this->escapeInlinePrintNode(new InlinePrint($expr3, $expr3->getTemplateLine()), $env, $type);
+        }
+
+        return new ConditionalExpression($expression->getNode('expr1'), $expr2, $expr3, $expression->getTemplateLine());
+    }
+
+    private function escapeInlinePrintNode(InlinePrint $node, Environment $env, string $type): Node
+    {
+        $expression = $node->getNode('node');
+
+        if ($this->isSafeFor($type, $expression, $env)) {
+            return $node;
+        }
+
+        return new InlinePrint($this->getEscaperFilter($type, $expression), $node->getTemplateLine());
+    }
+
+    private function escapePrintNode(PrintNode $node, Environment $env, string $type): Node
+    {
+        if (false === $type) {
+            return $node;
+        }
+
+        $expression = $node->getNode('expr');
+
+        if ($this->isSafeFor($type, $expression, $env)) {
+            return $node;
+        }
+
+        $class = \get_class($node);
+
+        return new $class($this->getEscaperFilter($type, $expression), $node->getTemplateLine());
+    }
+
+    private function preEscapeFilterNode(FilterExpression $filter, Environment $env): FilterExpression
+    {
+        $name = $filter->getNode('filter')->getAttribute('value');
+
+        $type = $env->getFilter($name)->getPreEscape();
+        if (null === $type) {
+            return $filter;
+        }
+
+        $node = $filter->getNode('node');
+        if ($this->isSafeFor($type, $node, $env)) {
+            return $filter;
+        }
+
+        $filter->setNode('node', $this->getEscaperFilter($type, $node));
+
+        return $filter;
+    }
+
+    private function isSafeFor(string $type, Node $expression, Environment $env): bool
+    {
+        $safe = $this->safeAnalysis->getSafe($expression);
+
+        if (null === $safe) {
+            if (null === $this->traverser) {
+                $this->traverser = new NodeTraverser($env, [$this->safeAnalysis]);
+            }
+
+            $this->safeAnalysis->setSafeVars($this->safeVars);
+
+            $this->traverser->traverse($expression);
+            $safe = $this->safeAnalysis->getSafe($expression);
+        }
+
+        return \in_array($type, $safe) || \in_array('all', $safe);
+    }
+
+    private function needEscaping(Environment $env)
+    {
+        if (\count($this->statusStack)) {
+            return $this->statusStack[\count($this->statusStack) - 1];
+        }
+
+        return $this->defaultStrategy ? $this->defaultStrategy : false;
+    }
+
+    private function getEscaperFilter(string $type, Node $node): FilterExpression
+    {
+        $line = $node->getTemplateLine();
+        $name = new ConstantExpression('escape', $line);
+        $args = new Node([new ConstantExpression($type, $line), new ConstantExpression(null, $line), new ConstantExpression(true, $line)]);
+
+        return new FilterExpression($node, $name, $args, $line);
+    }
+
+    public function getPriority(): int
+    {
+        return 0;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/NodeVisitor/MacroAutoImportNodeVisitor.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/NodeVisitor/MacroAutoImportNodeVisitor.php
new file mode 100644
index 0000000..af477e6
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/NodeVisitor/MacroAutoImportNodeVisitor.php
@@ -0,0 +1,74 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\NodeVisitor;
+
+use Twig\Environment;
+use Twig\Node\Expression\AssignNameExpression;
+use Twig\Node\Expression\ConstantExpression;
+use Twig\Node\Expression\GetAttrExpression;
+use Twig\Node\Expression\MethodCallExpression;
+use Twig\Node\Expression\NameExpression;
+use Twig\Node\ImportNode;
+use Twig\Node\ModuleNode;
+use Twig\Node\Node;
+
+/**
+ * @author Fabien Potencier <fabien@symfony.com>
+ *
+ * @internal
+ */
+final class MacroAutoImportNodeVisitor implements NodeVisitorInterface
+{
+    private $inAModule = false;
+    private $hasMacroCalls = false;
+
+    public function enterNode(Node $node, Environment $env): Node
+    {
+        if ($node instanceof ModuleNode) {
+            $this->inAModule = true;
+            $this->hasMacroCalls = false;
+        }
+
+        return $node;
+    }
+
+    public function leaveNode(Node $node, Environment $env): Node
+    {
+        if ($node instanceof ModuleNode) {
+            $this->inAModule = false;
+            if ($this->hasMacroCalls) {
+                $node->getNode('constructor_end')->setNode('_auto_macro_import', new ImportNode(new NameExpression('_self', 0), new AssignNameExpression('_self', 0), 0, 'import', true));
+            }
+        } elseif ($this->inAModule) {
+            if (
+                $node instanceof GetAttrExpression &&
+                $node->getNode('node') instanceof NameExpression &&
+                '_self' === $node->getNode('node')->getAttribute('name') &&
+                $node->getNode('attribute') instanceof ConstantExpression
+            ) {
+                $this->hasMacroCalls = true;
+
+                $name = $node->getNode('attribute')->getAttribute('value');
+                $node = new MethodCallExpression($node->getNode('node'), 'macro_'.$name, $node->getNode('arguments'), $node->getTemplateLine());
+                $node->setAttribute('safe', true);
+            }
+        }
+
+        return $node;
+    }
+
+    public function getPriority(): int
+    {
+        // we must be ran before auto-escaping
+        return -10;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/NodeVisitor/NodeVisitorInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/NodeVisitor/NodeVisitorInterface.php
new file mode 100644
index 0000000..59e836d
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/NodeVisitor/NodeVisitorInterface.php
@@ -0,0 +1,46 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\NodeVisitor;
+
+use Twig\Environment;
+use Twig\Node\Node;
+
+/**
+ * Interface for node visitor classes.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+interface NodeVisitorInterface
+{
+    /**
+     * Called before child nodes are visited.
+     *
+     * @return Node The modified node
+     */
+    public function enterNode(Node $node, Environment $env): Node;
+
+    /**
+     * Called after child nodes are visited.
+     *
+     * @return Node|null The modified node or null if the node must be removed
+     */
+    public function leaveNode(Node $node, Environment $env): ?Node;
+
+    /**
+     * Returns the priority for this visitor.
+     *
+     * Priority should be between -10 and 10 (0 is the default).
+     *
+     * @return int The priority level
+     */
+    public function getPriority();
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/NodeVisitor/OptimizerNodeVisitor.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/NodeVisitor/OptimizerNodeVisitor.php
new file mode 100644
index 0000000..7ac75e4
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/NodeVisitor/OptimizerNodeVisitor.php
@@ -0,0 +1,217 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\NodeVisitor;
+
+use Twig\Environment;
+use Twig\Node\BlockReferenceNode;
+use Twig\Node\Expression\BlockReferenceExpression;
+use Twig\Node\Expression\ConstantExpression;
+use Twig\Node\Expression\FilterExpression;
+use Twig\Node\Expression\FunctionExpression;
+use Twig\Node\Expression\GetAttrExpression;
+use Twig\Node\Expression\NameExpression;
+use Twig\Node\Expression\ParentExpression;
+use Twig\Node\ForNode;
+use Twig\Node\IncludeNode;
+use Twig\Node\Node;
+use Twig\Node\PrintNode;
+
+/**
+ * Tries to optimize the AST.
+ *
+ * This visitor is always the last registered one.
+ *
+ * You can configure which optimizations you want to activate via the
+ * optimizer mode.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ *
+ * @internal
+ */
+final class OptimizerNodeVisitor implements NodeVisitorInterface
+{
+    public const OPTIMIZE_ALL = -1;
+    public const OPTIMIZE_NONE = 0;
+    public const OPTIMIZE_FOR = 2;
+    public const OPTIMIZE_RAW_FILTER = 4;
+
+    private $loops = [];
+    private $loopsTargets = [];
+    private $optimizers;
+
+    /**
+     * @param int $optimizers The optimizer mode
+     */
+    public function __construct(int $optimizers = -1)
+    {
+        if ($optimizers > (self::OPTIMIZE_FOR | self::OPTIMIZE_RAW_FILTER)) {
+            throw new \InvalidArgumentException(sprintf('Optimizer mode "%s" is not valid.', $optimizers));
+        }
+
+        $this->optimizers = $optimizers;
+    }
+
+    public function enterNode(Node $node, Environment $env): Node
+    {
+        if (self::OPTIMIZE_FOR === (self::OPTIMIZE_FOR & $this->optimizers)) {
+            $this->enterOptimizeFor($node, $env);
+        }
+
+        return $node;
+    }
+
+    public function leaveNode(Node $node, Environment $env): ?Node
+    {
+        if (self::OPTIMIZE_FOR === (self::OPTIMIZE_FOR & $this->optimizers)) {
+            $this->leaveOptimizeFor($node, $env);
+        }
+
+        if (self::OPTIMIZE_RAW_FILTER === (self::OPTIMIZE_RAW_FILTER & $this->optimizers)) {
+            $node = $this->optimizeRawFilter($node, $env);
+        }
+
+        $node = $this->optimizePrintNode($node, $env);
+
+        return $node;
+    }
+
+    /**
+     * Optimizes print nodes.
+     *
+     * It replaces:
+     *
+     *   * "echo $this->render(Parent)Block()" with "$this->display(Parent)Block()"
+     */
+    private function optimizePrintNode(Node $node, Environment $env): Node
+    {
+        if (!$node instanceof PrintNode) {
+            return $node;
+        }
+
+        $exprNode = $node->getNode('expr');
+        if (
+            $exprNode instanceof BlockReferenceExpression ||
+            $exprNode instanceof ParentExpression
+        ) {
+            $exprNode->setAttribute('output', true);
+
+            return $exprNode;
+        }
+
+        return $node;
+    }
+
+    /**
+     * Removes "raw" filters.
+     */
+    private function optimizeRawFilter(Node $node, Environment $env): Node
+    {
+        if ($node instanceof FilterExpression && 'raw' == $node->getNode('filter')->getAttribute('value')) {
+            return $node->getNode('node');
+        }
+
+        return $node;
+    }
+
+    /**
+     * Optimizes "for" tag by removing the "loop" variable creation whenever possible.
+     */
+    private function enterOptimizeFor(Node $node, Environment $env): void
+    {
+        if ($node instanceof ForNode) {
+            // disable the loop variable by default
+            $node->setAttribute('with_loop', false);
+            array_unshift($this->loops, $node);
+            array_unshift($this->loopsTargets, $node->getNode('value_target')->getAttribute('name'));
+            array_unshift($this->loopsTargets, $node->getNode('key_target')->getAttribute('name'));
+        } elseif (!$this->loops) {
+            // we are outside a loop
+            return;
+        }
+
+        // when do we need to add the loop variable back?
+
+        // the loop variable is referenced for the current loop
+        elseif ($node instanceof NameExpression && 'loop' === $node->getAttribute('name')) {
+            $node->setAttribute('always_defined', true);
+            $this->addLoopToCurrent();
+        }
+
+        // optimize access to loop targets
+        elseif ($node instanceof NameExpression && \in_array($node->getAttribute('name'), $this->loopsTargets)) {
+            $node->setAttribute('always_defined', true);
+        }
+
+        // block reference
+        elseif ($node instanceof BlockReferenceNode || $node instanceof BlockReferenceExpression) {
+            $this->addLoopToCurrent();
+        }
+
+        // include without the only attribute
+        elseif ($node instanceof IncludeNode && !$node->getAttribute('only')) {
+            $this->addLoopToAll();
+        }
+
+        // include function without the with_context=false parameter
+        elseif ($node instanceof FunctionExpression
+            && 'include' === $node->getAttribute('name')
+            && (!$node->getNode('arguments')->hasNode('with_context')
+                 || false !== $node->getNode('arguments')->getNode('with_context')->getAttribute('value')
+               )
+        ) {
+            $this->addLoopToAll();
+        }
+
+        // the loop variable is referenced via an attribute
+        elseif ($node instanceof GetAttrExpression
+            && (!$node->getNode('attribute') instanceof ConstantExpression
+                || 'parent' === $node->getNode('attribute')->getAttribute('value')
+               )
+            && (true === $this->loops[0]->getAttribute('with_loop')
+                || ($node->getNode('node') instanceof NameExpression
+                    && 'loop' === $node->getNode('node')->getAttribute('name')
+                   )
+               )
+        ) {
+            $this->addLoopToAll();
+        }
+    }
+
+    /**
+     * Optimizes "for" tag by removing the "loop" variable creation whenever possible.
+     */
+    private function leaveOptimizeFor(Node $node, Environment $env): void
+    {
+        if ($node instanceof ForNode) {
+            array_shift($this->loops);
+            array_shift($this->loopsTargets);
+            array_shift($this->loopsTargets);
+        }
+    }
+
+    private function addLoopToCurrent(): void
+    {
+        $this->loops[0]->setAttribute('with_loop', true);
+    }
+
+    private function addLoopToAll(): void
+    {
+        foreach ($this->loops as $loop) {
+            $loop->setAttribute('with_loop', true);
+        }
+    }
+
+    public function getPriority(): int
+    {
+        return 255;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/NodeVisitor/SafeAnalysisNodeVisitor.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/NodeVisitor/SafeAnalysisNodeVisitor.php
new file mode 100644
index 0000000..90d6f2e
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/NodeVisitor/SafeAnalysisNodeVisitor.php
@@ -0,0 +1,160 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\NodeVisitor;
+
+use Twig\Environment;
+use Twig\Node\Expression\BlockReferenceExpression;
+use Twig\Node\Expression\ConditionalExpression;
+use Twig\Node\Expression\ConstantExpression;
+use Twig\Node\Expression\FilterExpression;
+use Twig\Node\Expression\FunctionExpression;
+use Twig\Node\Expression\GetAttrExpression;
+use Twig\Node\Expression\MethodCallExpression;
+use Twig\Node\Expression\NameExpression;
+use Twig\Node\Expression\ParentExpression;
+use Twig\Node\Node;
+
+/**
+ * @internal
+ */
+final class SafeAnalysisNodeVisitor implements NodeVisitorInterface
+{
+    private $data = [];
+    private $safeVars = [];
+
+    public function setSafeVars(array $safeVars): void
+    {
+        $this->safeVars = $safeVars;
+    }
+
+    public function getSafe(Node $node)
+    {
+        $hash = spl_object_hash($node);
+        if (!isset($this->data[$hash])) {
+            return;
+        }
+
+        foreach ($this->data[$hash] as $bucket) {
+            if ($bucket['key'] !== $node) {
+                continue;
+            }
+
+            if (\in_array('html_attr', $bucket['value'])) {
+                $bucket['value'][] = 'html';
+            }
+
+            return $bucket['value'];
+        }
+    }
+
+    private function setSafe(Node $node, array $safe): void
+    {
+        $hash = spl_object_hash($node);
+        if (isset($this->data[$hash])) {
+            foreach ($this->data[$hash] as &$bucket) {
+                if ($bucket['key'] === $node) {
+                    $bucket['value'] = $safe;
+
+                    return;
+                }
+            }
+        }
+        $this->data[$hash][] = [
+            'key' => $node,
+            'value' => $safe,
+        ];
+    }
+
+    public function enterNode(Node $node, Environment $env): Node
+    {
+        return $node;
+    }
+
+    public function leaveNode(Node $node, Environment $env): ?Node
+    {
+        if ($node instanceof ConstantExpression) {
+            // constants are marked safe for all
+            $this->setSafe($node, ['all']);
+        } elseif ($node instanceof BlockReferenceExpression) {
+            // blocks are safe by definition
+            $this->setSafe($node, ['all']);
+        } elseif ($node instanceof ParentExpression) {
+            // parent block is safe by definition
+            $this->setSafe($node, ['all']);
+        } elseif ($node instanceof ConditionalExpression) {
+            // intersect safeness of both operands
+            $safe = $this->intersectSafe($this->getSafe($node->getNode('expr2')), $this->getSafe($node->getNode('expr3')));
+            $this->setSafe($node, $safe);
+        } elseif ($node instanceof FilterExpression) {
+            // filter expression is safe when the filter is safe
+            $name = $node->getNode('filter')->getAttribute('value');
+            $args = $node->getNode('arguments');
+            if ($filter = $env->getFilter($name)) {
+                $safe = $filter->getSafe($args);
+                if (null === $safe) {
+                    $safe = $this->intersectSafe($this->getSafe($node->getNode('node')), $filter->getPreservesSafety());
+                }
+                $this->setSafe($node, $safe);
+            } else {
+                $this->setSafe($node, []);
+            }
+        } elseif ($node instanceof FunctionExpression) {
+            // function expression is safe when the function is safe
+            $name = $node->getAttribute('name');
+            $args = $node->getNode('arguments');
+            if ($function = $env->getFunction($name)) {
+                $this->setSafe($node, $function->getSafe($args));
+            } else {
+                $this->setSafe($node, []);
+            }
+        } elseif ($node instanceof MethodCallExpression) {
+            if ($node->getAttribute('safe')) {
+                $this->setSafe($node, ['all']);
+            } else {
+                $this->setSafe($node, []);
+            }
+        } elseif ($node instanceof GetAttrExpression && $node->getNode('node') instanceof NameExpression) {
+            $name = $node->getNode('node')->getAttribute('name');
+            if (\in_array($name, $this->safeVars)) {
+                $this->setSafe($node, ['all']);
+            } else {
+                $this->setSafe($node, []);
+            }
+        } else {
+            $this->setSafe($node, []);
+        }
+
+        return $node;
+    }
+
+    private function intersectSafe(array $a = null, array $b = null): array
+    {
+        if (null === $a || null === $b) {
+            return [];
+        }
+
+        if (\in_array('all', $a)) {
+            return $b;
+        }
+
+        if (\in_array('all', $b)) {
+            return $a;
+        }
+
+        return array_intersect($a, $b);
+    }
+
+    public function getPriority(): int
+    {
+        return 0;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/NodeVisitor/SandboxNodeVisitor.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/NodeVisitor/SandboxNodeVisitor.php
new file mode 100644
index 0000000..1446cee
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/NodeVisitor/SandboxNodeVisitor.php
@@ -0,0 +1,136 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\NodeVisitor;
+
+use Twig\Environment;
+use Twig\Node\CheckSecurityCallNode;
+use Twig\Node\CheckSecurityNode;
+use Twig\Node\CheckToStringNode;
+use Twig\Node\Expression\Binary\ConcatBinary;
+use Twig\Node\Expression\Binary\RangeBinary;
+use Twig\Node\Expression\FilterExpression;
+use Twig\Node\Expression\FunctionExpression;
+use Twig\Node\Expression\GetAttrExpression;
+use Twig\Node\Expression\NameExpression;
+use Twig\Node\ModuleNode;
+use Twig\Node\Node;
+use Twig\Node\PrintNode;
+use Twig\Node\SetNode;
+
+/**
+ * @author Fabien Potencier <fabien@symfony.com>
+ *
+ * @internal
+ */
+final class SandboxNodeVisitor implements NodeVisitorInterface
+{
+    private $inAModule = false;
+    private $tags;
+    private $filters;
+    private $functions;
+    private $needsToStringWrap = false;
+
+    public function enterNode(Node $node, Environment $env): Node
+    {
+        if ($node instanceof ModuleNode) {
+            $this->inAModule = true;
+            $this->tags = [];
+            $this->filters = [];
+            $this->functions = [];
+
+            return $node;
+        } elseif ($this->inAModule) {
+            // look for tags
+            if ($node->getNodeTag() && !isset($this->tags[$node->getNodeTag()])) {
+                $this->tags[$node->getNodeTag()] = $node;
+            }
+
+            // look for filters
+            if ($node instanceof FilterExpression && !isset($this->filters[$node->getNode('filter')->getAttribute('value')])) {
+                $this->filters[$node->getNode('filter')->getAttribute('value')] = $node;
+            }
+
+            // look for functions
+            if ($node instanceof FunctionExpression && !isset($this->functions[$node->getAttribute('name')])) {
+                $this->functions[$node->getAttribute('name')] = $node;
+            }
+
+            // the .. operator is equivalent to the range() function
+            if ($node instanceof RangeBinary && !isset($this->functions['range'])) {
+                $this->functions['range'] = $node;
+            }
+
+            if ($node instanceof PrintNode) {
+                $this->needsToStringWrap = true;
+                $this->wrapNode($node, 'expr');
+            }
+
+            if ($node instanceof SetNode && !$node->getAttribute('capture')) {
+                $this->needsToStringWrap = true;
+            }
+
+            // wrap outer nodes that can implicitly call __toString()
+            if ($this->needsToStringWrap) {
+                if ($node instanceof ConcatBinary) {
+                    $this->wrapNode($node, 'left');
+                    $this->wrapNode($node, 'right');
+                }
+                if ($node instanceof FilterExpression) {
+                    $this->wrapNode($node, 'node');
+                    $this->wrapArrayNode($node, 'arguments');
+                }
+                if ($node instanceof FunctionExpression) {
+                    $this->wrapArrayNode($node, 'arguments');
+                }
+            }
+        }
+
+        return $node;
+    }
+
+    public function leaveNode(Node $node, Environment $env): ?Node
+    {
+        if ($node instanceof ModuleNode) {
+            $this->inAModule = false;
+
+            $node->setNode('constructor_end', new Node([new CheckSecurityCallNode(), $node->getNode('constructor_end')]));
+            $node->setNode('class_end', new Node([new CheckSecurityNode($this->filters, $this->tags, $this->functions), $node->getNode('class_end')]));
+        } elseif ($this->inAModule) {
+            if ($node instanceof PrintNode || $node instanceof SetNode) {
+                $this->needsToStringWrap = false;
+            }
+        }
+
+        return $node;
+    }
+
+    private function wrapNode(Node $node, string $name): void
+    {
+        $expr = $node->getNode($name);
+        if ($expr instanceof NameExpression || $expr instanceof GetAttrExpression) {
+            $node->setNode($name, new CheckToStringNode($expr));
+        }
+    }
+
+    private function wrapArrayNode(Node $node, string $name): void
+    {
+        $args = $node->getNode($name);
+        foreach ($args as $name => $_) {
+            $this->wrapNode($args, $name);
+        }
+    }
+
+    public function getPriority(): int
+    {
+        return 0;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Parser.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Parser.php
new file mode 100644
index 0000000..6103695
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Parser.php
@@ -0,0 +1,349 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig;
+
+use Twig\Error\SyntaxError;
+use Twig\Node\BlockNode;
+use Twig\Node\BlockReferenceNode;
+use Twig\Node\BodyNode;
+use Twig\Node\Expression\AbstractExpression;
+use Twig\Node\MacroNode;
+use Twig\Node\ModuleNode;
+use Twig\Node\Node;
+use Twig\Node\NodeCaptureInterface;
+use Twig\Node\NodeOutputInterface;
+use Twig\Node\PrintNode;
+use Twig\Node\TextNode;
+use Twig\TokenParser\TokenParserInterface;
+
+/**
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class Parser
+{
+    private $stack = [];
+    private $stream;
+    private $parent;
+    private $visitors;
+    private $expressionParser;
+    private $blocks;
+    private $blockStack;
+    private $macros;
+    private $env;
+    private $importedSymbols;
+    private $traits;
+    private $embeddedTemplates = [];
+    private $varNameSalt = 0;
+
+    public function __construct(Environment $env)
+    {
+        $this->env = $env;
+    }
+
+    public function getVarName(): string
+    {
+        return sprintf('__internal_%s', hash('sha256', __METHOD__.$this->stream->getSourceContext()->getCode().$this->varNameSalt++));
+    }
+
+    public function parse(TokenStream $stream, $test = null, bool $dropNeedle = false): ModuleNode
+    {
+        $vars = get_object_vars($this);
+        unset($vars['stack'], $vars['env'], $vars['handlers'], $vars['visitors'], $vars['expressionParser'], $vars['reservedMacroNames']);
+        $this->stack[] = $vars;
+
+        // node visitors
+        if (null === $this->visitors) {
+            $this->visitors = $this->env->getNodeVisitors();
+        }
+
+        if (null === $this->expressionParser) {
+            $this->expressionParser = new ExpressionParser($this, $this->env);
+        }
+
+        $this->stream = $stream;
+        $this->parent = null;
+        $this->blocks = [];
+        $this->macros = [];
+        $this->traits = [];
+        $this->blockStack = [];
+        $this->importedSymbols = [[]];
+        $this->embeddedTemplates = [];
+        $this->varNameSalt = 0;
+
+        try {
+            $body = $this->subparse($test, $dropNeedle);
+
+            if (null !== $this->parent && null === $body = $this->filterBodyNodes($body)) {
+                $body = new Node();
+            }
+        } catch (SyntaxError $e) {
+            if (!$e->getSourceContext()) {
+                $e->setSourceContext($this->stream->getSourceContext());
+            }
+
+            if (!$e->getTemplateLine()) {
+                $e->setTemplateLine($this->stream->getCurrent()->getLine());
+            }
+
+            throw $e;
+        }
+
+        $node = new ModuleNode(new BodyNode([$body]), $this->parent, new Node($this->blocks), new Node($this->macros), new Node($this->traits), $this->embeddedTemplates, $stream->getSourceContext());
+
+        $traverser = new NodeTraverser($this->env, $this->visitors);
+
+        $node = $traverser->traverse($node);
+
+        // restore previous stack so previous parse() call can resume working
+        foreach (array_pop($this->stack) as $key => $val) {
+            $this->$key = $val;
+        }
+
+        return $node;
+    }
+
+    public function subparse($test, bool $dropNeedle = false): Node
+    {
+        $lineno = $this->getCurrentToken()->getLine();
+        $rv = [];
+        while (!$this->stream->isEOF()) {
+            switch ($this->getCurrentToken()->getType()) {
+                case /* Token::TEXT_TYPE */ 0:
+                    $token = $this->stream->next();
+                    $rv[] = new TextNode($token->getValue(), $token->getLine());
+                    break;
+
+                case /* Token::VAR_START_TYPE */ 2:
+                    $token = $this->stream->next();
+                    $expr = $this->expressionParser->parseExpression();
+                    $this->stream->expect(/* Token::VAR_END_TYPE */ 4);
+                    $rv[] = new PrintNode($expr, $token->getLine());
+                    break;
+
+                case /* Token::BLOCK_START_TYPE */ 1:
+                    $this->stream->next();
+                    $token = $this->getCurrentToken();
+
+                    if (/* Token::NAME_TYPE */ 5 !== $token->getType()) {
+                        throw new SyntaxError('A block must start with a tag name.', $token->getLine(), $this->stream->getSourceContext());
+                    }
+
+                    if (null !== $test && $test($token)) {
+                        if ($dropNeedle) {
+                            $this->stream->next();
+                        }
+
+                        if (1 === \count($rv)) {
+                            return $rv[0];
+                        }
+
+                        return new Node($rv, [], $lineno);
+                    }
+
+                    if (!$subparser = $this->env->getTokenParser($token->getValue())) {
+                        if (null !== $test) {
+                            $e = new SyntaxError(sprintf('Unexpected "%s" tag', $token->getValue()), $token->getLine(), $this->stream->getSourceContext());
+
+                            if (\is_array($test) && isset($test[0]) && $test[0] instanceof TokenParserInterface) {
+                                $e->appendMessage(sprintf(' (expecting closing tag for the "%s" tag defined near line %s).', $test[0]->getTag(), $lineno));
+                            }
+                        } else {
+                            $e = new SyntaxError(sprintf('Unknown "%s" tag.', $token->getValue()), $token->getLine(), $this->stream->getSourceContext());
+                            $e->addSuggestions($token->getValue(), array_keys($this->env->getTokenParsers()));
+                        }
+
+                        throw $e;
+                    }
+
+                    $this->stream->next();
+
+                    $subparser->setParser($this);
+                    $node = $subparser->parse($token);
+                    if (null !== $node) {
+                        $rv[] = $node;
+                    }
+                    break;
+
+                default:
+                    throw new SyntaxError('Lexer or parser ended up in unsupported state.', $this->getCurrentToken()->getLine(), $this->stream->getSourceContext());
+            }
+        }
+
+        if (1 === \count($rv)) {
+            return $rv[0];
+        }
+
+        return new Node($rv, [], $lineno);
+    }
+
+    public function getBlockStack(): array
+    {
+        return $this->blockStack;
+    }
+
+    public function peekBlockStack()
+    {
+        return $this->blockStack[\count($this->blockStack) - 1] ?? null;
+    }
+
+    public function popBlockStack(): void
+    {
+        array_pop($this->blockStack);
+    }
+
+    public function pushBlockStack($name): void
+    {
+        $this->blockStack[] = $name;
+    }
+
+    public function hasBlock(string $name): bool
+    {
+        return isset($this->blocks[$name]);
+    }
+
+    public function getBlock(string $name): Node
+    {
+        return $this->blocks[$name];
+    }
+
+    public function setBlock(string $name, BlockNode $value): void
+    {
+        $this->blocks[$name] = new BodyNode([$value], [], $value->getTemplateLine());
+    }
+
+    public function hasMacro(string $name): bool
+    {
+        return isset($this->macros[$name]);
+    }
+
+    public function setMacro(string $name, MacroNode $node): void
+    {
+        $this->macros[$name] = $node;
+    }
+
+    public function addTrait($trait): void
+    {
+        $this->traits[] = $trait;
+    }
+
+    public function hasTraits(): bool
+    {
+        return \count($this->traits) > 0;
+    }
+
+    public function embedTemplate(ModuleNode $template)
+    {
+        $template->setIndex(mt_rand());
+
+        $this->embeddedTemplates[] = $template;
+    }
+
+    public function addImportedSymbol(string $type, string $alias, string $name = null, AbstractExpression $node = null): void
+    {
+        $this->importedSymbols[0][$type][$alias] = ['name' => $name, 'node' => $node];
+    }
+
+    public function getImportedSymbol(string $type, string $alias)
+    {
+        // if the symbol does not exist in the current scope (0), try in the main/global scope (last index)
+        return $this->importedSymbols[0][$type][$alias] ?? ($this->importedSymbols[\count($this->importedSymbols) - 1][$type][$alias] ?? null);
+    }
+
+    public function isMainScope(): bool
+    {
+        return 1 === \count($this->importedSymbols);
+    }
+
+    public function pushLocalScope(): void
+    {
+        array_unshift($this->importedSymbols, []);
+    }
+
+    public function popLocalScope(): void
+    {
+        array_shift($this->importedSymbols);
+    }
+
+    public function getExpressionParser(): ExpressionParser
+    {
+        return $this->expressionParser;
+    }
+
+    public function getParent(): ?Node
+    {
+        return $this->parent;
+    }
+
+    public function setParent(?Node $parent): void
+    {
+        $this->parent = $parent;
+    }
+
+    public function getStream(): TokenStream
+    {
+        return $this->stream;
+    }
+
+    public function getCurrentToken(): Token
+    {
+        return $this->stream->getCurrent();
+    }
+
+    private function filterBodyNodes(Node $node, bool $nested = false): ?Node
+    {
+        // check that the body does not contain non-empty output nodes
+        if (
+            ($node instanceof TextNode && !ctype_space($node->getAttribute('data')))
+            ||
+            (!$node instanceof TextNode && !$node instanceof BlockReferenceNode && $node instanceof NodeOutputInterface)
+        ) {
+            if (false !== strpos((string) $node, \chr(0xEF).\chr(0xBB).\chr(0xBF))) {
+                $t = substr($node->getAttribute('data'), 3);
+                if ('' === $t || ctype_space($t)) {
+                    // bypass empty nodes starting with a BOM
+                    return null;
+                }
+            }
+
+            throw new SyntaxError('A template that extends another one cannot include content outside Twig blocks. Did you forget to put the content inside a {% block %} tag?', $node->getTemplateLine(), $this->stream->getSourceContext());
+        }
+
+        // bypass nodes that "capture" the output
+        if ($node instanceof NodeCaptureInterface) {
+            // a "block" tag in such a node will serve as a block definition AND be displayed in place as well
+            return $node;
+        }
+
+        // "block" tags that are not captured (see above) are only used for defining
+        // the content of the block. In such a case, nesting it does not work as
+        // expected as the definition is not part of the default template code flow.
+        if ($nested && $node instanceof BlockReferenceNode) {
+            throw new SyntaxError('A block definition cannot be nested under non-capturing nodes.', $node->getTemplateLine(), $this->stream->getSourceContext());
+        }
+
+        if ($node instanceof NodeOutputInterface) {
+            return null;
+        }
+
+        // here, $nested means "being at the root level of a child template"
+        // we need to discard the wrapping "Node" for the "body" node
+        $nested = $nested || Node::class !== \get_class($node);
+        foreach ($node as $k => $n) {
+            if (null !== $n && null === $this->filterBodyNodes($n, $nested)) {
+                $node->removeNode($k);
+            }
+        }
+
+        return $node;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Profiler/Dumper/BaseDumper.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Profiler/Dumper/BaseDumper.php
new file mode 100644
index 0000000..4da43e4
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Profiler/Dumper/BaseDumper.php
@@ -0,0 +1,63 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Profiler\Dumper;
+
+use Twig\Profiler\Profile;
+
+/**
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+abstract class BaseDumper
+{
+    private $root;
+
+    public function dump(Profile $profile): string
+    {
+        return $this->dumpProfile($profile);
+    }
+
+    abstract protected function formatTemplate(Profile $profile, $prefix): string;
+
+    abstract protected function formatNonTemplate(Profile $profile, $prefix): string;
+
+    abstract protected function formatTime(Profile $profile, $percent): string;
+
+    private function dumpProfile(Profile $profile, $prefix = '', $sibling = false): string
+    {
+        if ($profile->isRoot()) {
+            $this->root = $profile->getDuration();
+            $start = $profile->getName();
+        } else {
+            if ($profile->isTemplate()) {
+                $start = $this->formatTemplate($profile, $prefix);
+            } else {
+                $start = $this->formatNonTemplate($profile, $prefix);
+            }
+            $prefix .= $sibling ? '│ ' : '  ';
+        }
+
+        $percent = $this->root ? $profile->getDuration() / $this->root * 100 : 0;
+
+        if ($profile->getDuration() * 1000 < 1) {
+            $str = $start."\n";
+        } else {
+            $str = sprintf("%s %s\n", $start, $this->formatTime($profile, $percent));
+        }
+
+        $nCount = \count($profile->getProfiles());
+        foreach ($profile as $i => $p) {
+            $str .= $this->dumpProfile($p, $prefix, $i + 1 !== $nCount);
+        }
+
+        return $str;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Profiler/Dumper/BlackfireDumper.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Profiler/Dumper/BlackfireDumper.php
new file mode 100644
index 0000000..03abe0f
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Profiler/Dumper/BlackfireDumper.php
@@ -0,0 +1,72 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Profiler\Dumper;
+
+use Twig\Profiler\Profile;
+
+/**
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+final class BlackfireDumper
+{
+    public function dump(Profile $profile): string
+    {
+        $data = [];
+        $this->dumpProfile('main()', $profile, $data);
+        $this->dumpChildren('main()', $profile, $data);
+
+        $start = sprintf('%f', microtime(true));
+        $str = <<<EOF
+file-format: BlackfireProbe
+cost-dimensions: wt mu pmu
+request-start: $start
+
+
+EOF;
+
+        foreach ($data as $name => $values) {
+            $str .= "$name//{$values['ct']} {$values['wt']} {$values['mu']} {$values['pmu']}\n";
+        }
+
+        return $str;
+    }
+
+    private function dumpChildren(string $parent, Profile $profile, &$data)
+    {
+        foreach ($profile as $p) {
+            if ($p->isTemplate()) {
+                $name = $p->getTemplate();
+            } else {
+                $name = sprintf('%s::%s(%s)', $p->getTemplate(), $p->getType(), $p->getName());
+            }
+            $this->dumpProfile(sprintf('%s==>%s', $parent, $name), $p, $data);
+            $this->dumpChildren($name, $p, $data);
+        }
+    }
+
+    private function dumpProfile(string $edge, Profile $profile, &$data)
+    {
+        if (isset($data[$edge])) {
+            ++$data[$edge]['ct'];
+            $data[$edge]['wt'] += floor($profile->getDuration() * 1000000);
+            $data[$edge]['mu'] += $profile->getMemoryUsage();
+            $data[$edge]['pmu'] += $profile->getPeakMemoryUsage();
+        } else {
+            $data[$edge] = [
+                'ct' => 1,
+                'wt' => floor($profile->getDuration() * 1000000),
+                'mu' => $profile->getMemoryUsage(),
+                'pmu' => $profile->getPeakMemoryUsage(),
+            ];
+        }
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Profiler/Dumper/HtmlDumper.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Profiler/Dumper/HtmlDumper.php
new file mode 100644
index 0000000..1f2433b
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Profiler/Dumper/HtmlDumper.php
@@ -0,0 +1,47 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Profiler\Dumper;
+
+use Twig\Profiler\Profile;
+
+/**
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+final class HtmlDumper extends BaseDumper
+{
+    private static $colors = [
+        'block' => '#dfd',
+        'macro' => '#ddf',
+        'template' => '#ffd',
+        'big' => '#d44',
+    ];
+
+    public function dump(Profile $profile): string
+    {
+        return '<pre>'.parent::dump($profile).'</pre>';
+    }
+
+    protected function formatTemplate(Profile $profile, $prefix): string
+    {
+        return sprintf('%s└ <span style="background-color: %s">%s</span>', $prefix, self::$colors['template'], $profile->getTemplate());
+    }
+
+    protected function formatNonTemplate(Profile $profile, $prefix): string
+    {
+        return sprintf('%s└ %s::%s(<span style="background-color: %s">%s</span>)', $prefix, $profile->getTemplate(), $profile->getType(), isset(self::$colors[$profile->getType()]) ? self::$colors[$profile->getType()] : 'auto', $profile->getName());
+    }
+
+    protected function formatTime(Profile $profile, $percent): string
+    {
+        return sprintf('<span style="color: %s">%.2fms/%.0f%%</span>', $percent > 20 ? self::$colors['big'] : 'auto', $profile->getDuration() * 1000, $percent);
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Profiler/Dumper/TextDumper.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Profiler/Dumper/TextDumper.php
new file mode 100644
index 0000000..31561c4
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Profiler/Dumper/TextDumper.php
@@ -0,0 +1,35 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Profiler\Dumper;
+
+use Twig\Profiler\Profile;
+
+/**
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+final class TextDumper extends BaseDumper
+{
+    protected function formatTemplate(Profile $profile, $prefix): string
+    {
+        return sprintf('%s└ %s', $prefix, $profile->getTemplate());
+    }
+
+    protected function formatNonTemplate(Profile $profile, $prefix): string
+    {
+        return sprintf('%s└ %s::%s(%s)', $prefix, $profile->getTemplate(), $profile->getType(), $profile->getName());
+    }
+
+    protected function formatTime(Profile $profile, $percent): string
+    {
+        return sprintf('%.2fms/%.0f%%', $profile->getDuration() * 1000, $percent);
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Profiler/Node/EnterProfileNode.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Profiler/Node/EnterProfileNode.php
new file mode 100644
index 0000000..1494baf
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Profiler/Node/EnterProfileNode.php
@@ -0,0 +1,42 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Profiler\Node;
+
+use Twig\Compiler;
+use Twig\Node\Node;
+
+/**
+ * Represents a profile enter node.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class EnterProfileNode extends Node
+{
+    public function __construct(string $extensionName, string $type, string $name, string $varName)
+    {
+        parent::__construct([], ['extension_name' => $extensionName, 'name' => $name, 'type' => $type, 'var_name' => $varName]);
+    }
+
+    public function compile(Compiler $compiler): void
+    {
+        $compiler
+            ->write(sprintf('$%s = $this->extensions[', $this->getAttribute('var_name')))
+            ->repr($this->getAttribute('extension_name'))
+            ->raw("];\n")
+            ->write(sprintf('$%s->enter($%s = new \Twig\Profiler\Profile($this->getTemplateName(), ', $this->getAttribute('var_name'), $this->getAttribute('var_name').'_prof'))
+            ->repr($this->getAttribute('type'))
+            ->raw(', ')
+            ->repr($this->getAttribute('name'))
+            ->raw("));\n\n")
+        ;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Profiler/Node/LeaveProfileNode.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Profiler/Node/LeaveProfileNode.php
new file mode 100644
index 0000000..94cebba
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Profiler/Node/LeaveProfileNode.php
@@ -0,0 +1,36 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Profiler\Node;
+
+use Twig\Compiler;
+use Twig\Node\Node;
+
+/**
+ * Represents a profile leave node.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class LeaveProfileNode extends Node
+{
+    public function __construct(string $varName)
+    {
+        parent::__construct([], ['var_name' => $varName]);
+    }
+
+    public function compile(Compiler $compiler): void
+    {
+        $compiler
+            ->write("\n")
+            ->write(sprintf("\$%s->leave(\$%s);\n\n", $this->getAttribute('var_name'), $this->getAttribute('var_name').'_prof'))
+        ;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Profiler/NodeVisitor/ProfilerNodeVisitor.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Profiler/NodeVisitor/ProfilerNodeVisitor.php
new file mode 100644
index 0000000..bd23b20
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Profiler/NodeVisitor/ProfilerNodeVisitor.php
@@ -0,0 +1,76 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Profiler\NodeVisitor;
+
+use Twig\Environment;
+use Twig\Node\BlockNode;
+use Twig\Node\BodyNode;
+use Twig\Node\MacroNode;
+use Twig\Node\ModuleNode;
+use Twig\Node\Node;
+use Twig\NodeVisitor\NodeVisitorInterface;
+use Twig\Profiler\Node\EnterProfileNode;
+use Twig\Profiler\Node\LeaveProfileNode;
+use Twig\Profiler\Profile;
+
+/**
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+final class ProfilerNodeVisitor implements NodeVisitorInterface
+{
+    private $extensionName;
+
+    public function __construct(string $extensionName)
+    {
+        $this->extensionName = $extensionName;
+    }
+
+    public function enterNode(Node $node, Environment $env): Node
+    {
+        return $node;
+    }
+
+    public function leaveNode(Node $node, Environment $env): ?Node
+    {
+        if ($node instanceof ModuleNode) {
+            $varName = $this->getVarName();
+            $node->setNode('display_start', new Node([new EnterProfileNode($this->extensionName, Profile::TEMPLATE, $node->getTemplateName(), $varName), $node->getNode('display_start')]));
+            $node->setNode('display_end', new Node([new LeaveProfileNode($varName), $node->getNode('display_end')]));
+        } elseif ($node instanceof BlockNode) {
+            $varName = $this->getVarName();
+            $node->setNode('body', new BodyNode([
+                new EnterProfileNode($this->extensionName, Profile::BLOCK, $node->getAttribute('name'), $varName),
+                $node->getNode('body'),
+                new LeaveProfileNode($varName),
+            ]));
+        } elseif ($node instanceof MacroNode) {
+            $varName = $this->getVarName();
+            $node->setNode('body', new BodyNode([
+                new EnterProfileNode($this->extensionName, Profile::MACRO, $node->getAttribute('name'), $varName),
+                $node->getNode('body'),
+                new LeaveProfileNode($varName),
+            ]));
+        }
+
+        return $node;
+    }
+
+    private function getVarName(): string
+    {
+        return sprintf('__internal_%s', hash('sha256', $this->extensionName));
+    }
+
+    public function getPriority(): int
+    {
+        return 0;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Profiler/Profile.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Profiler/Profile.php
new file mode 100644
index 0000000..252ca9b
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Profiler/Profile.php
@@ -0,0 +1,181 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Profiler;
+
+/**
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+final class Profile implements \IteratorAggregate, \Serializable
+{
+    public const ROOT = 'ROOT';
+    public const BLOCK = 'block';
+    public const TEMPLATE = 'template';
+    public const MACRO = 'macro';
+
+    private $template;
+    private $name;
+    private $type;
+    private $starts = [];
+    private $ends = [];
+    private $profiles = [];
+
+    public function __construct(string $template = 'main', string $type = self::ROOT, string $name = 'main')
+    {
+        $this->template = $template;
+        $this->type = $type;
+        $this->name = 0 === strpos($name, '__internal_') ? 'INTERNAL' : $name;
+        $this->enter();
+    }
+
+    public function getTemplate(): string
+    {
+        return $this->template;
+    }
+
+    public function getType(): string
+    {
+        return $this->type;
+    }
+
+    public function getName(): string
+    {
+        return $this->name;
+    }
+
+    public function isRoot(): bool
+    {
+        return self::ROOT === $this->type;
+    }
+
+    public function isTemplate(): bool
+    {
+        return self::TEMPLATE === $this->type;
+    }
+
+    public function isBlock(): bool
+    {
+        return self::BLOCK === $this->type;
+    }
+
+    public function isMacro(): bool
+    {
+        return self::MACRO === $this->type;
+    }
+
+    /**
+     * @return Profile[]
+     */
+    public function getProfiles(): array
+    {
+        return $this->profiles;
+    }
+
+    public function addProfile(self $profile): void
+    {
+        $this->profiles[] = $profile;
+    }
+
+    /**
+     * Returns the duration in microseconds.
+     */
+    public function getDuration(): float
+    {
+        if ($this->isRoot() && $this->profiles) {
+            // for the root node with children, duration is the sum of all child durations
+            $duration = 0;
+            foreach ($this->profiles as $profile) {
+                $duration += $profile->getDuration();
+            }
+
+            return $duration;
+        }
+
+        return isset($this->ends['wt']) && isset($this->starts['wt']) ? $this->ends['wt'] - $this->starts['wt'] : 0;
+    }
+
+    /**
+     * Returns the memory usage in bytes.
+     */
+    public function getMemoryUsage(): int
+    {
+        return isset($this->ends['mu']) && isset($this->starts['mu']) ? $this->ends['mu'] - $this->starts['mu'] : 0;
+    }
+
+    /**
+     * Returns the peak memory usage in bytes.
+     */
+    public function getPeakMemoryUsage(): int
+    {
+        return isset($this->ends['pmu']) && isset($this->starts['pmu']) ? $this->ends['pmu'] - $this->starts['pmu'] : 0;
+    }
+
+    /**
+     * Starts the profiling.
+     */
+    public function enter(): void
+    {
+        $this->starts = [
+            'wt' => microtime(true),
+            'mu' => memory_get_usage(),
+            'pmu' => memory_get_peak_usage(),
+        ];
+    }
+
+    /**
+     * Stops the profiling.
+     */
+    public function leave(): void
+    {
+        $this->ends = [
+            'wt' => microtime(true),
+            'mu' => memory_get_usage(),
+            'pmu' => memory_get_peak_usage(),
+        ];
+    }
+
+    public function reset(): void
+    {
+        $this->starts = $this->ends = $this->profiles = [];
+        $this->enter();
+    }
+
+    public function getIterator(): \Traversable
+    {
+        return new \ArrayIterator($this->profiles);
+    }
+
+    public function serialize(): string
+    {
+        return serialize($this->__serialize());
+    }
+
+    public function unserialize($data): void
+    {
+        $this->__unserialize(unserialize($data));
+    }
+
+    /**
+     * @internal
+     */
+    public function __serialize(): array
+    {
+        return [$this->template, $this->name, $this->type, $this->starts, $this->ends, $this->profiles];
+    }
+
+    /**
+     * @internal
+     */
+    public function __unserialize(array $data): void
+    {
+        list($this->template, $this->name, $this->type, $this->starts, $this->ends, $this->profiles) = $data;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/RuntimeLoader/ContainerRuntimeLoader.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/RuntimeLoader/ContainerRuntimeLoader.php
new file mode 100644
index 0000000..b360d7b
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/RuntimeLoader/ContainerRuntimeLoader.php
@@ -0,0 +1,37 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\RuntimeLoader;
+
+use Psr\Container\ContainerInterface;
+
+/**
+ * Lazily loads Twig runtime implementations from a PSR-11 container.
+ *
+ * Note that the runtime services MUST use their class names as identifiers.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ * @author Robin Chalas <robin.chalas@gmail.com>
+ */
+class ContainerRuntimeLoader implements RuntimeLoaderInterface
+{
+    private $container;
+
+    public function __construct(ContainerInterface $container)
+    {
+        $this->container = $container;
+    }
+
+    public function load(string $class)
+    {
+        return $this->container->has($class) ? $this->container->get($class) : null;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/RuntimeLoader/FactoryRuntimeLoader.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/RuntimeLoader/FactoryRuntimeLoader.php
new file mode 100644
index 0000000..1306483
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/RuntimeLoader/FactoryRuntimeLoader.php
@@ -0,0 +1,41 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\RuntimeLoader;
+
+/**
+ * Lazy loads the runtime implementations for a Twig element.
+ *
+ * @author Robin Chalas <robin.chalas@gmail.com>
+ */
+class FactoryRuntimeLoader implements RuntimeLoaderInterface
+{
+    private $map;
+
+    /**
+     * @param array $map An array where keys are class names and values factory callables
+     */
+    public function __construct(array $map = [])
+    {
+        $this->map = $map;
+    }
+
+    public function load(string $class)
+    {
+        if (!isset($this->map[$class])) {
+            return null;
+        }
+
+        $runtimeFactory = $this->map[$class];
+
+        return $runtimeFactory();
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/RuntimeLoader/RuntimeLoaderInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/RuntimeLoader/RuntimeLoaderInterface.php
new file mode 100644
index 0000000..9e5b204
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/RuntimeLoader/RuntimeLoaderInterface.php
@@ -0,0 +1,27 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\RuntimeLoader;
+
+/**
+ * Creates runtime implementations for Twig elements (filters/functions/tests).
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+interface RuntimeLoaderInterface
+{
+    /**
+     * Creates the runtime implementation of a Twig element (filter/function/test).
+     *
+     * @return object|null The runtime instance or null if the loader does not know how to create the runtime for this class
+     */
+    public function load(string $class);
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Sandbox/SecurityError.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Sandbox/SecurityError.php
new file mode 100644
index 0000000..30a404f
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Sandbox/SecurityError.php
@@ -0,0 +1,23 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Sandbox;
+
+use Twig\Error\Error;
+
+/**
+ * Exception thrown when a security error occurs at runtime.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class SecurityError extends Error
+{
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Sandbox/SecurityNotAllowedFilterError.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Sandbox/SecurityNotAllowedFilterError.php
new file mode 100644
index 0000000..02d3063
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Sandbox/SecurityNotAllowedFilterError.php
@@ -0,0 +1,33 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Sandbox;
+
+/**
+ * Exception thrown when a not allowed filter is used in a template.
+ *
+ * @author Martin Hasoň <martin.hason@gmail.com>
+ */
+final class SecurityNotAllowedFilterError extends SecurityError
+{
+    private $filterName;
+
+    public function __construct(string $message, string $functionName)
+    {
+        parent::__construct($message);
+        $this->filterName = $functionName;
+    }
+
+    public function getFilterName(): string
+    {
+        return $this->filterName;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Sandbox/SecurityNotAllowedFunctionError.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Sandbox/SecurityNotAllowedFunctionError.php
new file mode 100644
index 0000000..4f76dc6
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Sandbox/SecurityNotAllowedFunctionError.php
@@ -0,0 +1,33 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Sandbox;
+
+/**
+ * Exception thrown when a not allowed function is used in a template.
+ *
+ * @author Martin Hasoň <martin.hason@gmail.com>
+ */
+final class SecurityNotAllowedFunctionError extends SecurityError
+{
+    private $functionName;
+
+    public function __construct(string $message, string $functionName)
+    {
+        parent::__construct($message);
+        $this->functionName = $functionName;
+    }
+
+    public function getFunctionName(): string
+    {
+        return $this->functionName;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Sandbox/SecurityNotAllowedMethodError.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Sandbox/SecurityNotAllowedMethodError.php
new file mode 100644
index 0000000..8df9d0b
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Sandbox/SecurityNotAllowedMethodError.php
@@ -0,0 +1,40 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Sandbox;
+
+/**
+ * Exception thrown when a not allowed class method is used in a template.
+ *
+ * @author Kit Burton-Senior <mail@kitbs.com>
+ */
+final class SecurityNotAllowedMethodError extends SecurityError
+{
+    private $className;
+    private $methodName;
+
+    public function __construct(string $message, string $className, string $methodName)
+    {
+        parent::__construct($message);
+        $this->className = $className;
+        $this->methodName = $methodName;
+    }
+
+    public function getClassName(): string
+    {
+        return $this->className;
+    }
+
+    public function getMethodName()
+    {
+        return $this->methodName;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Sandbox/SecurityNotAllowedPropertyError.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Sandbox/SecurityNotAllowedPropertyError.php
new file mode 100644
index 0000000..42ec4f3
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Sandbox/SecurityNotAllowedPropertyError.php
@@ -0,0 +1,40 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Sandbox;
+
+/**
+ * Exception thrown when a not allowed class property is used in a template.
+ *
+ * @author Kit Burton-Senior <mail@kitbs.com>
+ */
+final class SecurityNotAllowedPropertyError extends SecurityError
+{
+    private $className;
+    private $propertyName;
+
+    public function __construct(string $message, string $className, string $propertyName)
+    {
+        parent::__construct($message);
+        $this->className = $className;
+        $this->propertyName = $propertyName;
+    }
+
+    public function getClassName(): string
+    {
+        return $this->className;
+    }
+
+    public function getPropertyName()
+    {
+        return $this->propertyName;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Sandbox/SecurityNotAllowedTagError.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Sandbox/SecurityNotAllowedTagError.php
new file mode 100644
index 0000000..4522150
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Sandbox/SecurityNotAllowedTagError.php
@@ -0,0 +1,33 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Sandbox;
+
+/**
+ * Exception thrown when a not allowed tag is used in a template.
+ *
+ * @author Martin Hasoň <martin.hason@gmail.com>
+ */
+final class SecurityNotAllowedTagError extends SecurityError
+{
+    private $tagName;
+
+    public function __construct(string $message, string $tagName)
+    {
+        parent::__construct($message);
+        $this->tagName = $tagName;
+    }
+
+    public function getTagName(): string
+    {
+        return $this->tagName;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Sandbox/SecurityPolicy.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Sandbox/SecurityPolicy.php
new file mode 100644
index 0000000..2fc0d01
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Sandbox/SecurityPolicy.php
@@ -0,0 +1,126 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Sandbox;
+
+use Twig\Markup;
+use Twig\Template;
+
+/**
+ * Represents a security policy which need to be enforced when sandbox mode is enabled.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+final class SecurityPolicy implements SecurityPolicyInterface
+{
+    private $allowedTags;
+    private $allowedFilters;
+    private $allowedMethods;
+    private $allowedProperties;
+    private $allowedFunctions;
+
+    public function __construct(array $allowedTags = [], array $allowedFilters = [], array $allowedMethods = [], array $allowedProperties = [], array $allowedFunctions = [])
+    {
+        $this->allowedTags = $allowedTags;
+        $this->allowedFilters = $allowedFilters;
+        $this->setAllowedMethods($allowedMethods);
+        $this->allowedProperties = $allowedProperties;
+        $this->allowedFunctions = $allowedFunctions;
+    }
+
+    public function setAllowedTags(array $tags): void
+    {
+        $this->allowedTags = $tags;
+    }
+
+    public function setAllowedFilters(array $filters): void
+    {
+        $this->allowedFilters = $filters;
+    }
+
+    public function setAllowedMethods(array $methods): void
+    {
+        $this->allowedMethods = [];
+        foreach ($methods as $class => $m) {
+            $this->allowedMethods[$class] = array_map(function ($value) { return strtr($value, 'ABCDEFGHIJKLMNOPQRSTUVWXYZ', 'abcdefghijklmnopqrstuvwxyz'); }, \is_array($m) ? $m : [$m]);
+        }
+    }
+
+    public function setAllowedProperties(array $properties): void
+    {
+        $this->allowedProperties = $properties;
+    }
+
+    public function setAllowedFunctions(array $functions): void
+    {
+        $this->allowedFunctions = $functions;
+    }
+
+    public function checkSecurity($tags, $filters, $functions): void
+    {
+        foreach ($tags as $tag) {
+            if (!\in_array($tag, $this->allowedTags)) {
+                throw new SecurityNotAllowedTagError(sprintf('Tag "%s" is not allowed.', $tag), $tag);
+            }
+        }
+
+        foreach ($filters as $filter) {
+            if (!\in_array($filter, $this->allowedFilters)) {
+                throw new SecurityNotAllowedFilterError(sprintf('Filter "%s" is not allowed.', $filter), $filter);
+            }
+        }
+
+        foreach ($functions as $function) {
+            if (!\in_array($function, $this->allowedFunctions)) {
+                throw new SecurityNotAllowedFunctionError(sprintf('Function "%s" is not allowed.', $function), $function);
+            }
+        }
+    }
+
+    public function checkMethodAllowed($obj, $method): void
+    {
+        if ($obj instanceof Template || $obj instanceof Markup) {
+            return;
+        }
+
+        $allowed = false;
+        $method = strtr($method, 'ABCDEFGHIJKLMNOPQRSTUVWXYZ', 'abcdefghijklmnopqrstuvwxyz');
+        foreach ($this->allowedMethods as $class => $methods) {
+            if ($obj instanceof $class) {
+                $allowed = \in_array($method, $methods);
+
+                break;
+            }
+        }
+
+        if (!$allowed) {
+            $class = \get_class($obj);
+            throw new SecurityNotAllowedMethodError(sprintf('Calling "%s" method on a "%s" object is not allowed.', $method, $class), $class, $method);
+        }
+    }
+
+    public function checkPropertyAllowed($obj, $property): void
+    {
+        $allowed = false;
+        foreach ($this->allowedProperties as $class => $properties) {
+            if ($obj instanceof $class) {
+                $allowed = \in_array($property, \is_array($properties) ? $properties : [$properties]);
+
+                break;
+            }
+        }
+
+        if (!$allowed) {
+            $class = \get_class($obj);
+            throw new SecurityNotAllowedPropertyError(sprintf('Calling "%s" property on a "%s" object is not allowed.', $property, $class), $class, $property);
+        }
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Sandbox/SecurityPolicyInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Sandbox/SecurityPolicyInterface.php
new file mode 100644
index 0000000..4cb479d
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Sandbox/SecurityPolicyInterface.php
@@ -0,0 +1,35 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Sandbox;
+
+/**
+ * Interface that all security policy classes must implements.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+interface SecurityPolicyInterface
+{
+    /**
+     * @throws SecurityError
+     */
+    public function checkSecurity($tags, $filters, $functions): void;
+
+    /**
+     * @throws SecurityNotAllowedMethodError
+     */
+    public function checkMethodAllowed($obj, $method): void;
+
+    /**
+     * @throws SecurityNotAllowedPropertyError
+     */
+    public function checkPropertyAllowed($obj, $method): void;
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Source.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Source.php
new file mode 100644
index 0000000..3cb0240
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Source.php
@@ -0,0 +1,51 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig;
+
+/**
+ * Holds information about a non-compiled Twig template.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+final class Source
+{
+    private $code;
+    private $name;
+    private $path;
+
+    /**
+     * @param string $code The template source code
+     * @param string $name The template logical name
+     * @param string $path The filesystem path of the template if any
+     */
+    public function __construct(string $code, string $name, string $path = '')
+    {
+        $this->code = $code;
+        $this->name = $name;
+        $this->path = $path;
+    }
+
+    public function getCode(): string
+    {
+        return $this->code;
+    }
+
+    public function getName(): string
+    {
+        return $this->name;
+    }
+
+    public function getPath(): string
+    {
+        return $this->path;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Template.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Template.php
new file mode 100644
index 0000000..e04bd04
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Template.php
@@ -0,0 +1,422 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig;
+
+use Twig\Error\Error;
+use Twig\Error\LoaderError;
+use Twig\Error\RuntimeError;
+
+/**
+ * Default base class for compiled templates.
+ *
+ * This class is an implementation detail of how template compilation currently
+ * works, which might change. It should never be used directly. Use $twig->load()
+ * instead, which returns an instance of \Twig\TemplateWrapper.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ *
+ * @internal
+ */
+abstract class Template
+{
+    public const ANY_CALL = 'any';
+    public const ARRAY_CALL = 'array';
+    public const METHOD_CALL = 'method';
+
+    protected $parent;
+    protected $parents = [];
+    protected $env;
+    protected $blocks = [];
+    protected $traits = [];
+    protected $extensions = [];
+    protected $sandbox;
+
+    public function __construct(Environment $env)
+    {
+        $this->env = $env;
+        $this->extensions = $env->getExtensions();
+    }
+
+    /**
+     * Returns the template name.
+     *
+     * @return string The template name
+     */
+    abstract public function getTemplateName();
+
+    /**
+     * Returns debug information about the template.
+     *
+     * @return array Debug information
+     */
+    abstract public function getDebugInfo();
+
+    /**
+     * Returns information about the original template source code.
+     *
+     * @return Source
+     */
+    abstract public function getSourceContext();
+
+    /**
+     * Returns the parent template.
+     *
+     * This method is for internal use only and should never be called
+     * directly.
+     *
+     * @return Template|TemplateWrapper|false The parent template or false if there is no parent
+     */
+    public function getParent(array $context)
+    {
+        if (null !== $this->parent) {
+            return $this->parent;
+        }
+
+        try {
+            $parent = $this->doGetParent($context);
+
+            if (false === $parent) {
+                return false;
+            }
+
+            if ($parent instanceof self || $parent instanceof TemplateWrapper) {
+                return $this->parents[$parent->getSourceContext()->getName()] = $parent;
+            }
+
+            if (!isset($this->parents[$parent])) {
+                $this->parents[$parent] = $this->loadTemplate($parent);
+            }
+        } catch (LoaderError $e) {
+            $e->setSourceContext(null);
+            $e->guess();
+
+            throw $e;
+        }
+
+        return $this->parents[$parent];
+    }
+
+    protected function doGetParent(array $context)
+    {
+        return false;
+    }
+
+    public function isTraitable()
+    {
+        return true;
+    }
+
+    /**
+     * Displays a parent block.
+     *
+     * This method is for internal use only and should never be called
+     * directly.
+     *
+     * @param string $name    The block name to display from the parent
+     * @param array  $context The context
+     * @param array  $blocks  The current set of blocks
+     */
+    public function displayParentBlock($name, array $context, array $blocks = [])
+    {
+        if (isset($this->traits[$name])) {
+            $this->traits[$name][0]->displayBlock($name, $context, $blocks, false);
+        } elseif (false !== $parent = $this->getParent($context)) {
+            $parent->displayBlock($name, $context, $blocks, false);
+        } else {
+            throw new RuntimeError(sprintf('The template has no parent and no traits defining the "%s" block.', $name), -1, $this->getSourceContext());
+        }
+    }
+
+    /**
+     * Displays a block.
+     *
+     * This method is for internal use only and should never be called
+     * directly.
+     *
+     * @param string $name      The block name to display
+     * @param array  $context   The context
+     * @param array  $blocks    The current set of blocks
+     * @param bool   $useBlocks Whether to use the current set of blocks
+     */
+    public function displayBlock($name, array $context, array $blocks = [], $useBlocks = true, self $templateContext = null)
+    {
+        if ($useBlocks && isset($blocks[$name])) {
+            $template = $blocks[$name][0];
+            $block = $blocks[$name][1];
+        } elseif (isset($this->blocks[$name])) {
+            $template = $this->blocks[$name][0];
+            $block = $this->blocks[$name][1];
+        } else {
+            $template = null;
+            $block = null;
+        }
+
+        // avoid RCEs when sandbox is enabled
+        if (null !== $template && !$template instanceof self) {
+            throw new \LogicException('A block must be a method on a \Twig\Template instance.');
+        }
+
+        if (null !== $template) {
+            try {
+                $template->$block($context, $blocks);
+            } catch (Error $e) {
+                if (!$e->getSourceContext()) {
+                    $e->setSourceContext($template->getSourceContext());
+                }
+
+                // this is mostly useful for \Twig\Error\LoaderError exceptions
+                // see \Twig\Error\LoaderError
+                if (-1 === $e->getTemplateLine()) {
+                    $e->guess();
+                }
+
+                throw $e;
+            } catch (\Exception $e) {
+                $e = new RuntimeError(sprintf('An exception has been thrown during the rendering of a template ("%s").', $e->getMessage()), -1, $template->getSourceContext(), $e);
+                $e->guess();
+
+                throw $e;
+            }
+        } elseif (false !== $parent = $this->getParent($context)) {
+            $parent->displayBlock($name, $context, array_merge($this->blocks, $blocks), false, $templateContext ?? $this);
+        } elseif (isset($blocks[$name])) {
+            throw new RuntimeError(sprintf('Block "%s" should not call parent() in "%s" as the block does not exist in the parent template "%s".', $name, $blocks[$name][0]->getTemplateName(), $this->getTemplateName()), -1, $blocks[$name][0]->getSourceContext());
+        } else {
+            throw new RuntimeError(sprintf('Block "%s" on template "%s" does not exist.', $name, $this->getTemplateName()), -1, ($templateContext ?? $this)->getSourceContext());
+        }
+    }
+
+    /**
+     * Renders a parent block.
+     *
+     * This method is for internal use only and should never be called
+     * directly.
+     *
+     * @param string $name    The block name to render from the parent
+     * @param array  $context The context
+     * @param array  $blocks  The current set of blocks
+     *
+     * @return string The rendered block
+     */
+    public function renderParentBlock($name, array $context, array $blocks = [])
+    {
+        if ($this->env->isDebug()) {
+            ob_start();
+        } else {
+            ob_start(function () { return ''; });
+        }
+        $this->displayParentBlock($name, $context, $blocks);
+
+        return ob_get_clean();
+    }
+
+    /**
+     * Renders a block.
+     *
+     * This method is for internal use only and should never be called
+     * directly.
+     *
+     * @param string $name      The block name to render
+     * @param array  $context   The context
+     * @param array  $blocks    The current set of blocks
+     * @param bool   $useBlocks Whether to use the current set of blocks
+     *
+     * @return string The rendered block
+     */
+    public function renderBlock($name, array $context, array $blocks = [], $useBlocks = true)
+    {
+        if ($this->env->isDebug()) {
+            ob_start();
+        } else {
+            ob_start(function () { return ''; });
+        }
+        $this->displayBlock($name, $context, $blocks, $useBlocks);
+
+        return ob_get_clean();
+    }
+
+    /**
+     * Returns whether a block exists or not in the current context of the template.
+     *
+     * This method checks blocks defined in the current template
+     * or defined in "used" traits or defined in parent templates.
+     *
+     * @param string $name    The block name
+     * @param array  $context The context
+     * @param array  $blocks  The current set of blocks
+     *
+     * @return bool true if the block exists, false otherwise
+     */
+    public function hasBlock($name, array $context, array $blocks = [])
+    {
+        if (isset($blocks[$name])) {
+            return $blocks[$name][0] instanceof self;
+        }
+
+        if (isset($this->blocks[$name])) {
+            return true;
+        }
+
+        if (false !== $parent = $this->getParent($context)) {
+            return $parent->hasBlock($name, $context);
+        }
+
+        return false;
+    }
+
+    /**
+     * Returns all block names in the current context of the template.
+     *
+     * This method checks blocks defined in the current template
+     * or defined in "used" traits or defined in parent templates.
+     *
+     * @param array $context The context
+     * @param array $blocks  The current set of blocks
+     *
+     * @return array An array of block names
+     */
+    public function getBlockNames(array $context, array $blocks = [])
+    {
+        $names = array_merge(array_keys($blocks), array_keys($this->blocks));
+
+        if (false !== $parent = $this->getParent($context)) {
+            $names = array_merge($names, $parent->getBlockNames($context));
+        }
+
+        return array_unique($names);
+    }
+
+    /**
+     * @return Template|TemplateWrapper
+     */
+    protected function loadTemplate($template, $templateName = null, $line = null, $index = null)
+    {
+        try {
+            if (\is_array($template)) {
+                return $this->env->resolveTemplate($template);
+            }
+
+            if ($template instanceof self || $template instanceof TemplateWrapper) {
+                return $template;
+            }
+
+            if ($template === $this->getTemplateName()) {
+                $class = static::class;
+                if (false !== $pos = strrpos($class, '___', -1)) {
+                    $class = substr($class, 0, $pos);
+                }
+            } else {
+                $class = $this->env->getTemplateClass($template);
+            }
+
+            return $this->env->loadTemplate($class, $template, $index);
+        } catch (Error $e) {
+            if (!$e->getSourceContext()) {
+                $e->setSourceContext($templateName ? new Source('', $templateName) : $this->getSourceContext());
+            }
+
+            if ($e->getTemplateLine() > 0) {
+                throw $e;
+            }
+
+            if (!$line) {
+                $e->guess();
+            } else {
+                $e->setTemplateLine($line);
+            }
+
+            throw $e;
+        }
+    }
+
+    /**
+     * @internal
+     *
+     * @return Template
+     */
+    public function unwrap()
+    {
+        return $this;
+    }
+
+    /**
+     * Returns all blocks.
+     *
+     * This method is for internal use only and should never be called
+     * directly.
+     *
+     * @return array An array of blocks
+     */
+    public function getBlocks()
+    {
+        return $this->blocks;
+    }
+
+    public function display(array $context, array $blocks = [])
+    {
+        $this->displayWithErrorHandling($this->env->mergeGlobals($context), array_merge($this->blocks, $blocks));
+    }
+
+    public function render(array $context)
+    {
+        $level = ob_get_level();
+        if ($this->env->isDebug()) {
+            ob_start();
+        } else {
+            ob_start(function () { return ''; });
+        }
+        try {
+            $this->display($context);
+        } catch (\Throwable $e) {
+            while (ob_get_level() > $level) {
+                ob_end_clean();
+            }
+
+            throw $e;
+        }
+
+        return ob_get_clean();
+    }
+
+    protected function displayWithErrorHandling(array $context, array $blocks = [])
+    {
+        try {
+            $this->doDisplay($context, $blocks);
+        } catch (Error $e) {
+            if (!$e->getSourceContext()) {
+                $e->setSourceContext($this->getSourceContext());
+            }
+
+            // this is mostly useful for \Twig\Error\LoaderError exceptions
+            // see \Twig\Error\LoaderError
+            if (-1 === $e->getTemplateLine()) {
+                $e->guess();
+            }
+
+            throw $e;
+        } catch (\Exception $e) {
+            $e = new RuntimeError(sprintf('An exception has been thrown during the rendering of a template ("%s").', $e->getMessage()), -1, $this->getSourceContext(), $e);
+            $e->guess();
+
+            throw $e;
+        }
+    }
+
+    /**
+     * Auto-generated method to display the template with the given context.
+     *
+     * @param array $context An array of parameters to pass to the template
+     * @param array $blocks  An array of blocks to pass to the template
+     */
+    abstract protected function doDisplay(array $context, array $blocks = []);
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TemplateWrapper.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TemplateWrapper.php
new file mode 100644
index 0000000..c9c6b07
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TemplateWrapper.php
@@ -0,0 +1,109 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig;
+
+/**
+ * Exposes a template to userland.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+final class TemplateWrapper
+{
+    private $env;
+    private $template;
+
+    /**
+     * This method is for internal use only and should never be called
+     * directly (use Twig\Environment::load() instead).
+     *
+     * @internal
+     */
+    public function __construct(Environment $env, Template $template)
+    {
+        $this->env = $env;
+        $this->template = $template;
+    }
+
+    public function render(array $context = []): string
+    {
+        // using func_get_args() allows to not expose the blocks argument
+        // as it should only be used by internal code
+        return $this->template->render($context, \func_get_args()[1] ?? []);
+    }
+
+    public function display(array $context = [])
+    {
+        // using func_get_args() allows to not expose the blocks argument
+        // as it should only be used by internal code
+        $this->template->display($context, \func_get_args()[1] ?? []);
+    }
+
+    public function hasBlock(string $name, array $context = []): bool
+    {
+        return $this->template->hasBlock($name, $context);
+    }
+
+    /**
+     * @return string[] An array of defined template block names
+     */
+    public function getBlockNames(array $context = []): array
+    {
+        return $this->template->getBlockNames($context);
+    }
+
+    public function renderBlock(string $name, array $context = []): string
+    {
+        $context = $this->env->mergeGlobals($context);
+        $level = ob_get_level();
+        if ($this->env->isDebug()) {
+            ob_start();
+        } else {
+            ob_start(function () { return ''; });
+        }
+        try {
+            $this->template->displayBlock($name, $context);
+        } catch (\Throwable $e) {
+            while (ob_get_level() > $level) {
+                ob_end_clean();
+            }
+
+            throw $e;
+        }
+
+        return ob_get_clean();
+    }
+
+    public function displayBlock(string $name, array $context = [])
+    {
+        $this->template->displayBlock($name, $this->env->mergeGlobals($context));
+    }
+
+    public function getSourceContext(): Source
+    {
+        return $this->template->getSourceContext();
+    }
+
+    public function getTemplateName(): string
+    {
+        return $this->template->getTemplateName();
+    }
+
+    /**
+     * @internal
+     *
+     * @return Template
+     */
+    public function unwrap()
+    {
+        return $this->template;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Test/IntegrationTestCase.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Test/IntegrationTestCase.php
new file mode 100644
index 0000000..7d7d590
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Test/IntegrationTestCase.php
@@ -0,0 +1,265 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Test;
+
+use PHPUnit\Framework\TestCase;
+use Twig\Environment;
+use Twig\Error\Error;
+use Twig\Extension\ExtensionInterface;
+use Twig\Loader\ArrayLoader;
+use Twig\RuntimeLoader\RuntimeLoaderInterface;
+use Twig\TwigFilter;
+use Twig\TwigFunction;
+use Twig\TwigTest;
+
+/**
+ * Integration test helper.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ * @author Karma Dordrak <drak@zikula.org>
+ */
+abstract class IntegrationTestCase extends TestCase
+{
+    /**
+     * @return string
+     */
+    abstract protected function getFixturesDir();
+
+    /**
+     * @return RuntimeLoaderInterface[]
+     */
+    protected function getRuntimeLoaders()
+    {
+        return [];
+    }
+
+    /**
+     * @return ExtensionInterface[]
+     */
+    protected function getExtensions()
+    {
+        return [];
+    }
+
+    /**
+     * @return TwigFilter[]
+     */
+    protected function getTwigFilters()
+    {
+        return [];
+    }
+
+    /**
+     * @return TwigFunction[]
+     */
+    protected function getTwigFunctions()
+    {
+        return [];
+    }
+
+    /**
+     * @return TwigTest[]
+     */
+    protected function getTwigTests()
+    {
+        return [];
+    }
+
+    /**
+     * @dataProvider getTests
+     */
+    public function testIntegration($file, $message, $condition, $templates, $exception, $outputs, $deprecation = '')
+    {
+        $this->doIntegrationTest($file, $message, $condition, $templates, $exception, $outputs, $deprecation);
+    }
+
+    /**
+     * @dataProvider getLegacyTests
+     * @group legacy
+     */
+    public function testLegacyIntegration($file, $message, $condition, $templates, $exception, $outputs, $deprecation = '')
+    {
+        $this->doIntegrationTest($file, $message, $condition, $templates, $exception, $outputs, $deprecation);
+    }
+
+    public function getTests($name, $legacyTests = false)
+    {
+        $fixturesDir = realpath($this->getFixturesDir());
+        $tests = [];
+
+        foreach (new \RecursiveIteratorIterator(new \RecursiveDirectoryIterator($fixturesDir), \RecursiveIteratorIterator::LEAVES_ONLY) as $file) {
+            if (!preg_match('/\.test$/', $file)) {
+                continue;
+            }
+
+            if ($legacyTests xor false !== strpos($file->getRealpath(), '.legacy.test')) {
+                continue;
+            }
+
+            $test = file_get_contents($file->getRealpath());
+
+            if (preg_match('/--TEST--\s*(.*?)\s*(?:--CONDITION--\s*(.*))?\s*(?:--DEPRECATION--\s*(.*?))?\s*((?:--TEMPLATE(?:\(.*?\))?--(?:.*?))+)\s*(?:--DATA--\s*(.*))?\s*--EXCEPTION--\s*(.*)/sx', $test, $match)) {
+                $message = $match[1];
+                $condition = $match[2];
+                $deprecation = $match[3];
+                $templates = self::parseTemplates($match[4]);
+                $exception = $match[6];
+                $outputs = [[null, $match[5], null, '']];
+            } elseif (preg_match('/--TEST--\s*(.*?)\s*(?:--CONDITION--\s*(.*))?\s*(?:--DEPRECATION--\s*(.*?))?\s*((?:--TEMPLATE(?:\(.*?\))?--(?:.*?))+)--DATA--.*?--EXPECT--.*/s', $test, $match)) {
+                $message = $match[1];
+                $condition = $match[2];
+                $deprecation = $match[3];
+                $templates = self::parseTemplates($match[4]);
+                $exception = false;
+                preg_match_all('/--DATA--(.*?)(?:--CONFIG--(.*?))?--EXPECT--(.*?)(?=\-\-DATA\-\-|$)/s', $test, $outputs, \PREG_SET_ORDER);
+            } else {
+                throw new \InvalidArgumentException(sprintf('Test "%s" is not valid.', str_replace($fixturesDir.'/', '', $file)));
+            }
+
+            $tests[] = [str_replace($fixturesDir.'/', '', $file), $message, $condition, $templates, $exception, $outputs, $deprecation];
+        }
+
+        if ($legacyTests && empty($tests)) {
+            // add a dummy test to avoid a PHPUnit message
+            return [['not', '-', '', [], '', []]];
+        }
+
+        return $tests;
+    }
+
+    public function getLegacyTests()
+    {
+        return $this->getTests('testLegacyIntegration', true);
+    }
+
+    protected function doIntegrationTest($file, $message, $condition, $templates, $exception, $outputs, $deprecation = '')
+    {
+        if (!$outputs) {
+            $this->markTestSkipped('no tests to run');
+        }
+
+        if ($condition) {
+            eval('$ret = '.$condition.';');
+            if (!$ret) {
+                $this->markTestSkipped($condition);
+            }
+        }
+
+        $loader = new ArrayLoader($templates);
+
+        foreach ($outputs as $i => $match) {
+            $config = array_merge([
+                'cache' => false,
+                'strict_variables' => true,
+            ], $match[2] ? eval($match[2].';') : []);
+            $twig = new Environment($loader, $config);
+            $twig->addGlobal('global', 'global');
+            foreach ($this->getRuntimeLoaders() as $runtimeLoader) {
+                $twig->addRuntimeLoader($runtimeLoader);
+            }
+
+            foreach ($this->getExtensions() as $extension) {
+                $twig->addExtension($extension);
+            }
+
+            foreach ($this->getTwigFilters() as $filter) {
+                $twig->addFilter($filter);
+            }
+
+            foreach ($this->getTwigTests() as $test) {
+                $twig->addTest($test);
+            }
+
+            foreach ($this->getTwigFunctions() as $function) {
+                $twig->addFunction($function);
+            }
+
+            // avoid using the same PHP class name for different cases
+            $p = new \ReflectionProperty($twig, 'templateClassPrefix');
+            $p->setAccessible(true);
+            $p->setValue($twig, '__TwigTemplate_'.hash('sha256', uniqid(mt_rand(), true), false).'_');
+
+            $deprecations = [];
+            try {
+                $prevHandler = set_error_handler(function ($type, $msg, $file, $line, $context = []) use (&$deprecations, &$prevHandler) {
+                    if (\E_USER_DEPRECATED === $type) {
+                        $deprecations[] = $msg;
+
+                        return true;
+                    }
+
+                    return $prevHandler ? $prevHandler($type, $msg, $file, $line, $context) : false;
+                });
+
+                $template = $twig->load('index.twig');
+            } catch (\Exception $e) {
+                if (false !== $exception) {
+                    $message = $e->getMessage();
+                    $this->assertSame(trim($exception), trim(sprintf('%s: %s', \get_class($e), $message)));
+                    $last = substr($message, \strlen($message) - 1);
+                    $this->assertTrue('.' === $last || '?' === $last, 'Exception message must end with a dot or a question mark.');
+
+                    return;
+                }
+
+                throw new Error(sprintf('%s: %s', \get_class($e), $e->getMessage()), -1, null, $e);
+            } finally {
+                restore_error_handler();
+            }
+
+            $this->assertSame($deprecation, implode("\n", $deprecations));
+
+            try {
+                $output = trim($template->render(eval($match[1].';')), "\n ");
+            } catch (\Exception $e) {
+                if (false !== $exception) {
+                    $this->assertSame(trim($exception), trim(sprintf('%s: %s', \get_class($e), $e->getMessage())));
+
+                    return;
+                }
+
+                $e = new Error(sprintf('%s: %s', \get_class($e), $e->getMessage()), -1, null, $e);
+
+                $output = trim(sprintf('%s: %s', \get_class($e), $e->getMessage()));
+            }
+
+            if (false !== $exception) {
+                list($class) = explode(':', $exception);
+                $constraintClass = class_exists('PHPUnit\Framework\Constraint\Exception') ? 'PHPUnit\Framework\Constraint\Exception' : 'PHPUnit_Framework_Constraint_Exception';
+                $this->assertThat(null, new $constraintClass($class));
+            }
+
+            $expected = trim($match[3], "\n ");
+
+            if ($expected !== $output) {
+                printf("Compiled templates that failed on case %d:\n", $i + 1);
+
+                foreach (array_keys($templates) as $name) {
+                    echo "Template: $name\n";
+                    echo $twig->compile($twig->parse($twig->tokenize($twig->getLoader()->getSourceContext($name))));
+                }
+            }
+            $this->assertEquals($expected, $output, $message.' (in '.$file.')');
+        }
+    }
+
+    protected static function parseTemplates($test)
+    {
+        $templates = [];
+        preg_match_all('/--TEMPLATE(?:\((.*?)\))?--(.*?)(?=\-\-TEMPLATE|$)/s', $test, $matches, \PREG_SET_ORDER);
+        foreach ($matches as $match) {
+            $templates[($match[1] ?: 'index.twig')] = $match[2];
+        }
+
+        return $templates;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Test/NodeTestCase.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Test/NodeTestCase.php
new file mode 100644
index 0000000..3b8b2c8
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Test/NodeTestCase.php
@@ -0,0 +1,65 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Test;
+
+use PHPUnit\Framework\TestCase;
+use Twig\Compiler;
+use Twig\Environment;
+use Twig\Loader\ArrayLoader;
+use Twig\Node\Node;
+
+abstract class NodeTestCase extends TestCase
+{
+    abstract public function getTests();
+
+    /**
+     * @dataProvider getTests
+     */
+    public function testCompile($node, $source, $environment = null, $isPattern = false)
+    {
+        $this->assertNodeCompilation($source, $node, $environment, $isPattern);
+    }
+
+    public function assertNodeCompilation($source, Node $node, Environment $environment = null, $isPattern = false)
+    {
+        $compiler = $this->getCompiler($environment);
+        $compiler->compile($node);
+
+        if ($isPattern) {
+            $this->assertStringMatchesFormat($source, trim($compiler->getSource()));
+        } else {
+            $this->assertEquals($source, trim($compiler->getSource()));
+        }
+    }
+
+    protected function getCompiler(Environment $environment = null)
+    {
+        return new Compiler(null === $environment ? $this->getEnvironment() : $environment);
+    }
+
+    protected function getEnvironment()
+    {
+        return new Environment(new ArrayLoader([]));
+    }
+
+    protected function getVariableGetter($name, $line = false)
+    {
+        $line = $line > 0 ? "// line $line\n" : '';
+
+        return sprintf('%s($context["%s"] ?? null)', $line, $name);
+    }
+
+    protected function getAttributeGetter()
+    {
+        return 'twig_get_attribute($this->env, $this->source, ';
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Token.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Token.php
new file mode 100644
index 0000000..53a6caf
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Token.php
@@ -0,0 +1,178 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig;
+
+/**
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+final class Token
+{
+    private $value;
+    private $type;
+    private $lineno;
+
+    public const EOF_TYPE = -1;
+    public const TEXT_TYPE = 0;
+    public const BLOCK_START_TYPE = 1;
+    public const VAR_START_TYPE = 2;
+    public const BLOCK_END_TYPE = 3;
+    public const VAR_END_TYPE = 4;
+    public const NAME_TYPE = 5;
+    public const NUMBER_TYPE = 6;
+    public const STRING_TYPE = 7;
+    public const OPERATOR_TYPE = 8;
+    public const PUNCTUATION_TYPE = 9;
+    public const INTERPOLATION_START_TYPE = 10;
+    public const INTERPOLATION_END_TYPE = 11;
+    public const ARROW_TYPE = 12;
+
+    public function __construct(int $type, $value, int $lineno)
+    {
+        $this->type = $type;
+        $this->value = $value;
+        $this->lineno = $lineno;
+    }
+
+    public function __toString()
+    {
+        return sprintf('%s(%s)', self::typeToString($this->type, true), $this->value);
+    }
+
+    /**
+     * Tests the current token for a type and/or a value.
+     *
+     * Parameters may be:
+     *  * just type
+     *  * type and value (or array of possible values)
+     *  * just value (or array of possible values) (NAME_TYPE is used as type)
+     *
+     * @param array|string|int  $type   The type to test
+     * @param array|string|null $values The token value
+     */
+    public function test($type, $values = null): bool
+    {
+        if (null === $values && !\is_int($type)) {
+            $values = $type;
+            $type = self::NAME_TYPE;
+        }
+
+        return ($this->type === $type) && (
+            null === $values ||
+            (\is_array($values) && \in_array($this->value, $values)) ||
+            $this->value == $values
+        );
+    }
+
+    public function getLine(): int
+    {
+        return $this->lineno;
+    }
+
+    public function getType(): int
+    {
+        return $this->type;
+    }
+
+    public function getValue()
+    {
+        return $this->value;
+    }
+
+    public static function typeToString(int $type, bool $short = false): string
+    {
+        switch ($type) {
+            case self::EOF_TYPE:
+                $name = 'EOF_TYPE';
+                break;
+            case self::TEXT_TYPE:
+                $name = 'TEXT_TYPE';
+                break;
+            case self::BLOCK_START_TYPE:
+                $name = 'BLOCK_START_TYPE';
+                break;
+            case self::VAR_START_TYPE:
+                $name = 'VAR_START_TYPE';
+                break;
+            case self::BLOCK_END_TYPE:
+                $name = 'BLOCK_END_TYPE';
+                break;
+            case self::VAR_END_TYPE:
+                $name = 'VAR_END_TYPE';
+                break;
+            case self::NAME_TYPE:
+                $name = 'NAME_TYPE';
+                break;
+            case self::NUMBER_TYPE:
+                $name = 'NUMBER_TYPE';
+                break;
+            case self::STRING_TYPE:
+                $name = 'STRING_TYPE';
+                break;
+            case self::OPERATOR_TYPE:
+                $name = 'OPERATOR_TYPE';
+                break;
+            case self::PUNCTUATION_TYPE:
+                $name = 'PUNCTUATION_TYPE';
+                break;
+            case self::INTERPOLATION_START_TYPE:
+                $name = 'INTERPOLATION_START_TYPE';
+                break;
+            case self::INTERPOLATION_END_TYPE:
+                $name = 'INTERPOLATION_END_TYPE';
+                break;
+            case self::ARROW_TYPE:
+                $name = 'ARROW_TYPE';
+                break;
+            default:
+                throw new \LogicException(sprintf('Token of type "%s" does not exist.', $type));
+        }
+
+        return $short ? $name : 'Twig\Token::'.$name;
+    }
+
+    public static function typeToEnglish(int $type): string
+    {
+        switch ($type) {
+            case self::EOF_TYPE:
+                return 'end of template';
+            case self::TEXT_TYPE:
+                return 'text';
+            case self::BLOCK_START_TYPE:
+                return 'begin of statement block';
+            case self::VAR_START_TYPE:
+                return 'begin of print statement';
+            case self::BLOCK_END_TYPE:
+                return 'end of statement block';
+            case self::VAR_END_TYPE:
+                return 'end of print statement';
+            case self::NAME_TYPE:
+                return 'name';
+            case self::NUMBER_TYPE:
+                return 'number';
+            case self::STRING_TYPE:
+                return 'string';
+            case self::OPERATOR_TYPE:
+                return 'operator';
+            case self::PUNCTUATION_TYPE:
+                return 'punctuation';
+            case self::INTERPOLATION_START_TYPE:
+                return 'begin of string interpolation';
+            case self::INTERPOLATION_END_TYPE:
+                return 'end of string interpolation';
+            case self::ARROW_TYPE:
+                return 'arrow function';
+            default:
+                throw new \LogicException(sprintf('Token of type "%s" does not exist.', $type));
+        }
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/AbstractTokenParser.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/AbstractTokenParser.php
new file mode 100644
index 0000000..720ea67
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/AbstractTokenParser.php
@@ -0,0 +1,32 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\TokenParser;
+
+use Twig\Parser;
+
+/**
+ * Base class for all token parsers.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+abstract class AbstractTokenParser implements TokenParserInterface
+{
+    /**
+     * @var Parser
+     */
+    protected $parser;
+
+    public function setParser(Parser $parser): void
+    {
+        $this->parser = $parser;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/ApplyTokenParser.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/ApplyTokenParser.php
new file mode 100644
index 0000000..4dbf304
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/ApplyTokenParser.php
@@ -0,0 +1,60 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\TokenParser;
+
+use Twig\Node\Expression\TempNameExpression;
+use Twig\Node\Node;
+use Twig\Node\PrintNode;
+use Twig\Node\SetNode;
+use Twig\Token;
+
+/**
+ * Applies filters on a section of a template.
+ *
+ *   {% apply upper %}
+ *      This text becomes uppercase
+ *   {% endapply %}
+ *
+ * @internal
+ */
+final class ApplyTokenParser extends AbstractTokenParser
+{
+    public function parse(Token $token): Node
+    {
+        $lineno = $token->getLine();
+        $name = $this->parser->getVarName();
+
+        $ref = new TempNameExpression($name, $lineno);
+        $ref->setAttribute('always_defined', true);
+
+        $filter = $this->parser->getExpressionParser()->parseFilterExpressionRaw($ref, $this->getTag());
+
+        $this->parser->getStream()->expect(Token::BLOCK_END_TYPE);
+        $body = $this->parser->subparse([$this, 'decideApplyEnd'], true);
+        $this->parser->getStream()->expect(Token::BLOCK_END_TYPE);
+
+        return new Node([
+            new SetNode(true, $ref, $body, $lineno, $this->getTag()),
+            new PrintNode($filter, $lineno, $this->getTag()),
+        ]);
+    }
+
+    public function decideApplyEnd(Token $token): bool
+    {
+        return $token->test('endapply');
+    }
+
+    public function getTag(): string
+    {
+        return 'apply';
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/AutoEscapeTokenParser.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/AutoEscapeTokenParser.php
new file mode 100644
index 0000000..b674bea
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/AutoEscapeTokenParser.php
@@ -0,0 +1,58 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\TokenParser;
+
+use Twig\Error\SyntaxError;
+use Twig\Node\AutoEscapeNode;
+use Twig\Node\Expression\ConstantExpression;
+use Twig\Node\Node;
+use Twig\Token;
+
+/**
+ * Marks a section of a template to be escaped or not.
+ *
+ * @internal
+ */
+final class AutoEscapeTokenParser extends AbstractTokenParser
+{
+    public function parse(Token $token): Node
+    {
+        $lineno = $token->getLine();
+        $stream = $this->parser->getStream();
+
+        if ($stream->test(/* Token::BLOCK_END_TYPE */ 3)) {
+            $value = 'html';
+        } else {
+            $expr = $this->parser->getExpressionParser()->parseExpression();
+            if (!$expr instanceof ConstantExpression) {
+                throw new SyntaxError('An escaping strategy must be a string or false.', $stream->getCurrent()->getLine(), $stream->getSourceContext());
+            }
+            $value = $expr->getAttribute('value');
+        }
+
+        $stream->expect(/* Token::BLOCK_END_TYPE */ 3);
+        $body = $this->parser->subparse([$this, 'decideBlockEnd'], true);
+        $stream->expect(/* Token::BLOCK_END_TYPE */ 3);
+
+        return new AutoEscapeNode($value, $body, $lineno, $this->getTag());
+    }
+
+    public function decideBlockEnd(Token $token): bool
+    {
+        return $token->test('endautoescape');
+    }
+
+    public function getTag(): string
+    {
+        return 'autoescape';
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/BlockTokenParser.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/BlockTokenParser.php
new file mode 100644
index 0000000..5878131
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/BlockTokenParser.php
@@ -0,0 +1,78 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\TokenParser;
+
+use Twig\Error\SyntaxError;
+use Twig\Node\BlockNode;
+use Twig\Node\BlockReferenceNode;
+use Twig\Node\Node;
+use Twig\Node\PrintNode;
+use Twig\Token;
+
+/**
+ * Marks a section of a template as being reusable.
+ *
+ *  {% block head %}
+ *    <link rel="stylesheet" href="style.css" />
+ *    <title>{% block title %}{% endblock %} - My Webpage</title>
+ *  {% endblock %}
+ *
+ * @internal
+ */
+final class BlockTokenParser extends AbstractTokenParser
+{
+    public function parse(Token $token): Node
+    {
+        $lineno = $token->getLine();
+        $stream = $this->parser->getStream();
+        $name = $stream->expect(/* Token::NAME_TYPE */ 5)->getValue();
+        if ($this->parser->hasBlock($name)) {
+            throw new SyntaxError(sprintf("The block '%s' has already been defined line %d.", $name, $this->parser->getBlock($name)->getTemplateLine()), $stream->getCurrent()->getLine(), $stream->getSourceContext());
+        }
+        $this->parser->setBlock($name, $block = new BlockNode($name, new Node([]), $lineno));
+        $this->parser->pushLocalScope();
+        $this->parser->pushBlockStack($name);
+
+        if ($stream->nextIf(/* Token::BLOCK_END_TYPE */ 3)) {
+            $body = $this->parser->subparse([$this, 'decideBlockEnd'], true);
+            if ($token = $stream->nextIf(/* Token::NAME_TYPE */ 5)) {
+                $value = $token->getValue();
+
+                if ($value != $name) {
+                    throw new SyntaxError(sprintf('Expected endblock for block "%s" (but "%s" given).', $name, $value), $stream->getCurrent()->getLine(), $stream->getSourceContext());
+                }
+            }
+        } else {
+            $body = new Node([
+                new PrintNode($this->parser->getExpressionParser()->parseExpression(), $lineno),
+            ]);
+        }
+        $stream->expect(/* Token::BLOCK_END_TYPE */ 3);
+
+        $block->setNode('body', $body);
+        $this->parser->popBlockStack();
+        $this->parser->popLocalScope();
+
+        return new BlockReferenceNode($name, $lineno, $this->getTag());
+    }
+
+    public function decideBlockEnd(Token $token): bool
+    {
+        return $token->test('endblock');
+    }
+
+    public function getTag(): string
+    {
+        return 'block';
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/DeprecatedTokenParser.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/DeprecatedTokenParser.php
new file mode 100644
index 0000000..31416c7
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/DeprecatedTokenParser.php
@@ -0,0 +1,43 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\TokenParser;
+
+use Twig\Node\DeprecatedNode;
+use Twig\Node\Node;
+use Twig\Token;
+
+/**
+ * Deprecates a section of a template.
+ *
+ *    {% deprecated 'The "base.twig" template is deprecated, use "layout.twig" instead.' %}
+ *    {% extends 'layout.html.twig' %}
+ *
+ * @author Yonel Ceruto <yonelceruto@gmail.com>
+ *
+ * @internal
+ */
+final class DeprecatedTokenParser extends AbstractTokenParser
+{
+    public function parse(Token $token): Node
+    {
+        $expr = $this->parser->getExpressionParser()->parseExpression();
+
+        $this->parser->getStream()->expect(Token::BLOCK_END_TYPE);
+
+        return new DeprecatedNode($expr, $token->getLine(), $this->getTag());
+    }
+
+    public function getTag(): string
+    {
+        return 'deprecated';
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/DoTokenParser.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/DoTokenParser.php
new file mode 100644
index 0000000..32c8f12
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/DoTokenParser.php
@@ -0,0 +1,38 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\TokenParser;
+
+use Twig\Node\DoNode;
+use Twig\Node\Node;
+use Twig\Token;
+
+/**
+ * Evaluates an expression, discarding the returned value.
+ *
+ * @internal
+ */
+final class DoTokenParser extends AbstractTokenParser
+{
+    public function parse(Token $token): Node
+    {
+        $expr = $this->parser->getExpressionParser()->parseExpression();
+
+        $this->parser->getStream()->expect(/* Token::BLOCK_END_TYPE */ 3);
+
+        return new DoNode($expr, $token->getLine(), $this->getTag());
+    }
+
+    public function getTag(): string
+    {
+        return 'do';
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/EmbedTokenParser.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/EmbedTokenParser.php
new file mode 100644
index 0000000..64b4f29
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/EmbedTokenParser.php
@@ -0,0 +1,73 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\TokenParser;
+
+use Twig\Node\EmbedNode;
+use Twig\Node\Expression\ConstantExpression;
+use Twig\Node\Expression\NameExpression;
+use Twig\Node\Node;
+use Twig\Token;
+
+/**
+ * Embeds a template.
+ *
+ * @internal
+ */
+final class EmbedTokenParser extends IncludeTokenParser
+{
+    public function parse(Token $token): Node
+    {
+        $stream = $this->parser->getStream();
+
+        $parent = $this->parser->getExpressionParser()->parseExpression();
+
+        list($variables, $only, $ignoreMissing) = $this->parseArguments();
+
+        $parentToken = $fakeParentToken = new Token(/* Token::STRING_TYPE */ 7, '__parent__', $token->getLine());
+        if ($parent instanceof ConstantExpression) {
+            $parentToken = new Token(/* Token::STRING_TYPE */ 7, $parent->getAttribute('value'), $token->getLine());
+        } elseif ($parent instanceof NameExpression) {
+            $parentToken = new Token(/* Token::NAME_TYPE */ 5, $parent->getAttribute('name'), $token->getLine());
+        }
+
+        // inject a fake parent to make the parent() function work
+        $stream->injectTokens([
+            new Token(/* Token::BLOCK_START_TYPE */ 1, '', $token->getLine()),
+            new Token(/* Token::NAME_TYPE */ 5, 'extends', $token->getLine()),
+            $parentToken,
+            new Token(/* Token::BLOCK_END_TYPE */ 3, '', $token->getLine()),
+        ]);
+
+        $module = $this->parser->parse($stream, [$this, 'decideBlockEnd'], true);
+
+        // override the parent with the correct one
+        if ($fakeParentToken === $parentToken) {
+            $module->setNode('parent', $parent);
+        }
+
+        $this->parser->embedTemplate($module);
+
+        $stream->expect(/* Token::BLOCK_END_TYPE */ 3);
+
+        return new EmbedNode($module->getTemplateName(), $module->getAttribute('index'), $variables, $only, $ignoreMissing, $token->getLine(), $this->getTag());
+    }
+
+    public function decideBlockEnd(Token $token): bool
+    {
+        return $token->test('endembed');
+    }
+
+    public function getTag(): string
+    {
+        return 'embed';
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/ExtendsTokenParser.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/ExtendsTokenParser.php
new file mode 100644
index 0000000..0ca46dd
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/ExtendsTokenParser.php
@@ -0,0 +1,52 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\TokenParser;
+
+use Twig\Error\SyntaxError;
+use Twig\Node\Node;
+use Twig\Token;
+
+/**
+ * Extends a template by another one.
+ *
+ *  {% extends "base.html" %}
+ *
+ * @internal
+ */
+final class ExtendsTokenParser extends AbstractTokenParser
+{
+    public function parse(Token $token): Node
+    {
+        $stream = $this->parser->getStream();
+
+        if ($this->parser->peekBlockStack()) {
+            throw new SyntaxError('Cannot use "extend" in a block.', $token->getLine(), $stream->getSourceContext());
+        } elseif (!$this->parser->isMainScope()) {
+            throw new SyntaxError('Cannot use "extend" in a macro.', $token->getLine(), $stream->getSourceContext());
+        }
+
+        if (null !== $this->parser->getParent()) {
+            throw new SyntaxError('Multiple extends tags are forbidden.', $token->getLine(), $stream->getSourceContext());
+        }
+        $this->parser->setParent($this->parser->getExpressionParser()->parseExpression());
+
+        $stream->expect(/* Token::BLOCK_END_TYPE */ 3);
+
+        return new Node();
+    }
+
+    public function getTag(): string
+    {
+        return 'extends';
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/FlushTokenParser.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/FlushTokenParser.php
new file mode 100644
index 0000000..02c74aa
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/FlushTokenParser.php
@@ -0,0 +1,38 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\TokenParser;
+
+use Twig\Node\FlushNode;
+use Twig\Node\Node;
+use Twig\Token;
+
+/**
+ * Flushes the output to the client.
+ *
+ * @see flush()
+ *
+ * @internal
+ */
+final class FlushTokenParser extends AbstractTokenParser
+{
+    public function parse(Token $token): Node
+    {
+        $this->parser->getStream()->expect(/* Token::BLOCK_END_TYPE */ 3);
+
+        return new FlushNode($token->getLine(), $this->getTag());
+    }
+
+    public function getTag(): string
+    {
+        return 'flush';
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/ForTokenParser.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/ForTokenParser.php
new file mode 100644
index 0000000..bac8ba2
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/ForTokenParser.php
@@ -0,0 +1,78 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\TokenParser;
+
+use Twig\Node\Expression\AssignNameExpression;
+use Twig\Node\ForNode;
+use Twig\Node\Node;
+use Twig\Token;
+
+/**
+ * Loops over each item of a sequence.
+ *
+ *   <ul>
+ *    {% for user in users %}
+ *      <li>{{ user.username|e }}</li>
+ *    {% endfor %}
+ *   </ul>
+ *
+ * @internal
+ */
+final class ForTokenParser extends AbstractTokenParser
+{
+    public function parse(Token $token): Node
+    {
+        $lineno = $token->getLine();
+        $stream = $this->parser->getStream();
+        $targets = $this->parser->getExpressionParser()->parseAssignmentExpression();
+        $stream->expect(/* Token::OPERATOR_TYPE */ 8, 'in');
+        $seq = $this->parser->getExpressionParser()->parseExpression();
+
+        $stream->expect(/* Token::BLOCK_END_TYPE */ 3);
+        $body = $this->parser->subparse([$this, 'decideForFork']);
+        if ('else' == $stream->next()->getValue()) {
+            $stream->expect(/* Token::BLOCK_END_TYPE */ 3);
+            $else = $this->parser->subparse([$this, 'decideForEnd'], true);
+        } else {
+            $else = null;
+        }
+        $stream->expect(/* Token::BLOCK_END_TYPE */ 3);
+
+        if (\count($targets) > 1) {
+            $keyTarget = $targets->getNode(0);
+            $keyTarget = new AssignNameExpression($keyTarget->getAttribute('name'), $keyTarget->getTemplateLine());
+            $valueTarget = $targets->getNode(1);
+        } else {
+            $keyTarget = new AssignNameExpression('_key', $lineno);
+            $valueTarget = $targets->getNode(0);
+        }
+        $valueTarget = new AssignNameExpression($valueTarget->getAttribute('name'), $valueTarget->getTemplateLine());
+
+        return new ForNode($keyTarget, $valueTarget, $seq, null, $body, $else, $lineno, $this->getTag());
+    }
+
+    public function decideForFork(Token $token): bool
+    {
+        return $token->test(['else', 'endfor']);
+    }
+
+    public function decideForEnd(Token $token): bool
+    {
+        return $token->test('endfor');
+    }
+
+    public function getTag(): string
+    {
+        return 'for';
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/FromTokenParser.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/FromTokenParser.php
new file mode 100644
index 0000000..35098c2
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/FromTokenParser.php
@@ -0,0 +1,66 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\TokenParser;
+
+use Twig\Node\Expression\AssignNameExpression;
+use Twig\Node\ImportNode;
+use Twig\Node\Node;
+use Twig\Token;
+
+/**
+ * Imports macros.
+ *
+ *   {% from 'forms.html' import forms %}
+ *
+ * @internal
+ */
+final class FromTokenParser extends AbstractTokenParser
+{
+    public function parse(Token $token): Node
+    {
+        $macro = $this->parser->getExpressionParser()->parseExpression();
+        $stream = $this->parser->getStream();
+        $stream->expect(/* Token::NAME_TYPE */ 5, 'import');
+
+        $targets = [];
+        do {
+            $name = $stream->expect(/* Token::NAME_TYPE */ 5)->getValue();
+
+            $alias = $name;
+            if ($stream->nextIf('as')) {
+                $alias = $stream->expect(/* Token::NAME_TYPE */ 5)->getValue();
+            }
+
+            $targets[$name] = $alias;
+
+            if (!$stream->nextIf(/* Token::PUNCTUATION_TYPE */ 9, ',')) {
+                break;
+            }
+        } while (true);
+
+        $stream->expect(/* Token::BLOCK_END_TYPE */ 3);
+
+        $var = new AssignNameExpression($this->parser->getVarName(), $token->getLine());
+        $node = new ImportNode($macro, $var, $token->getLine(), $this->getTag(), $this->parser->isMainScope());
+
+        foreach ($targets as $name => $alias) {
+            $this->parser->addImportedSymbol('function', $alias, 'macro_'.$name, $var);
+        }
+
+        return $node;
+    }
+
+    public function getTag(): string
+    {
+        return 'from';
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/IfTokenParser.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/IfTokenParser.php
new file mode 100644
index 0000000..c0fe6df
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/IfTokenParser.php
@@ -0,0 +1,89 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\TokenParser;
+
+use Twig\Error\SyntaxError;
+use Twig\Node\IfNode;
+use Twig\Node\Node;
+use Twig\Token;
+
+/**
+ * Tests a condition.
+ *
+ *   {% if users %}
+ *    <ul>
+ *      {% for user in users %}
+ *        <li>{{ user.username|e }}</li>
+ *      {% endfor %}
+ *    </ul>
+ *   {% endif %}
+ *
+ * @internal
+ */
+final class IfTokenParser extends AbstractTokenParser
+{
+    public function parse(Token $token): Node
+    {
+        $lineno = $token->getLine();
+        $expr = $this->parser->getExpressionParser()->parseExpression();
+        $stream = $this->parser->getStream();
+        $stream->expect(/* Token::BLOCK_END_TYPE */ 3);
+        $body = $this->parser->subparse([$this, 'decideIfFork']);
+        $tests = [$expr, $body];
+        $else = null;
+
+        $end = false;
+        while (!$end) {
+            switch ($stream->next()->getValue()) {
+                case 'else':
+                    $stream->expect(/* Token::BLOCK_END_TYPE */ 3);
+                    $else = $this->parser->subparse([$this, 'decideIfEnd']);
+                    break;
+
+                case 'elseif':
+                    $expr = $this->parser->getExpressionParser()->parseExpression();
+                    $stream->expect(/* Token::BLOCK_END_TYPE */ 3);
+                    $body = $this->parser->subparse([$this, 'decideIfFork']);
+                    $tests[] = $expr;
+                    $tests[] = $body;
+                    break;
+
+                case 'endif':
+                    $end = true;
+                    break;
+
+                default:
+                    throw new SyntaxError(sprintf('Unexpected end of template. Twig was looking for the following tags "else", "elseif", or "endif" to close the "if" block started at line %d).', $lineno), $stream->getCurrent()->getLine(), $stream->getSourceContext());
+            }
+        }
+
+        $stream->expect(/* Token::BLOCK_END_TYPE */ 3);
+
+        return new IfNode(new Node($tests), $else, $lineno, $this->getTag());
+    }
+
+    public function decideIfFork(Token $token): bool
+    {
+        return $token->test(['elseif', 'else', 'endif']);
+    }
+
+    public function decideIfEnd(Token $token): bool
+    {
+        return $token->test(['endif']);
+    }
+
+    public function getTag(): string
+    {
+        return 'if';
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/ImportTokenParser.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/ImportTokenParser.php
new file mode 100644
index 0000000..44cb4da
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/ImportTokenParser.php
@@ -0,0 +1,44 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\TokenParser;
+
+use Twig\Node\Expression\AssignNameExpression;
+use Twig\Node\ImportNode;
+use Twig\Node\Node;
+use Twig\Token;
+
+/**
+ * Imports macros.
+ *
+ *   {% import 'forms.html' as forms %}
+ *
+ * @internal
+ */
+final class ImportTokenParser extends AbstractTokenParser
+{
+    public function parse(Token $token): Node
+    {
+        $macro = $this->parser->getExpressionParser()->parseExpression();
+        $this->parser->getStream()->expect(/* Token::NAME_TYPE */ 5, 'as');
+        $var = new AssignNameExpression($this->parser->getStream()->expect(/* Token::NAME_TYPE */ 5)->getValue(), $token->getLine());
+        $this->parser->getStream()->expect(/* Token::BLOCK_END_TYPE */ 3);
+
+        $this->parser->addImportedSymbol('template', $var->getAttribute('name'));
+
+        return new ImportNode($macro, $var, $token->getLine(), $this->getTag(), $this->parser->isMainScope());
+    }
+
+    public function getTag(): string
+    {
+        return 'import';
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/IncludeTokenParser.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/IncludeTokenParser.php
new file mode 100644
index 0000000..28beb8a
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/IncludeTokenParser.php
@@ -0,0 +1,69 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\TokenParser;
+
+use Twig\Node\IncludeNode;
+use Twig\Node\Node;
+use Twig\Token;
+
+/**
+ * Includes a template.
+ *
+ *   {% include 'header.html' %}
+ *     Body
+ *   {% include 'footer.html' %}
+ *
+ * @internal
+ */
+class IncludeTokenParser extends AbstractTokenParser
+{
+    public function parse(Token $token): Node
+    {
+        $expr = $this->parser->getExpressionParser()->parseExpression();
+
+        list($variables, $only, $ignoreMissing) = $this->parseArguments();
+
+        return new IncludeNode($expr, $variables, $only, $ignoreMissing, $token->getLine(), $this->getTag());
+    }
+
+    protected function parseArguments()
+    {
+        $stream = $this->parser->getStream();
+
+        $ignoreMissing = false;
+        if ($stream->nextIf(/* Token::NAME_TYPE */ 5, 'ignore')) {
+            $stream->expect(/* Token::NAME_TYPE */ 5, 'missing');
+
+            $ignoreMissing = true;
+        }
+
+        $variables = null;
+        if ($stream->nextIf(/* Token::NAME_TYPE */ 5, 'with')) {
+            $variables = $this->parser->getExpressionParser()->parseExpression();
+        }
+
+        $only = false;
+        if ($stream->nextIf(/* Token::NAME_TYPE */ 5, 'only')) {
+            $only = true;
+        }
+
+        $stream->expect(/* Token::BLOCK_END_TYPE */ 3);
+
+        return [$variables, $only, $ignoreMissing];
+    }
+
+    public function getTag(): string
+    {
+        return 'include';
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/MacroTokenParser.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/MacroTokenParser.php
new file mode 100644
index 0000000..f584927
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/MacroTokenParser.php
@@ -0,0 +1,66 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\TokenParser;
+
+use Twig\Error\SyntaxError;
+use Twig\Node\BodyNode;
+use Twig\Node\MacroNode;
+use Twig\Node\Node;
+use Twig\Token;
+
+/**
+ * Defines a macro.
+ *
+ *   {% macro input(name, value, type, size) %}
+ *      <input type="{{ type|default('text') }}" name="{{ name }}" value="{{ value|e }}" size="{{ size|default(20) }}" />
+ *   {% endmacro %}
+ *
+ * @internal
+ */
+final class MacroTokenParser extends AbstractTokenParser
+{
+    public function parse(Token $token): Node
+    {
+        $lineno = $token->getLine();
+        $stream = $this->parser->getStream();
+        $name = $stream->expect(/* Token::NAME_TYPE */ 5)->getValue();
+
+        $arguments = $this->parser->getExpressionParser()->parseArguments(true, true);
+
+        $stream->expect(/* Token::BLOCK_END_TYPE */ 3);
+        $this->parser->pushLocalScope();
+        $body = $this->parser->subparse([$this, 'decideBlockEnd'], true);
+        if ($token = $stream->nextIf(/* Token::NAME_TYPE */ 5)) {
+            $value = $token->getValue();
+
+            if ($value != $name) {
+                throw new SyntaxError(sprintf('Expected endmacro for macro "%s" (but "%s" given).', $name, $value), $stream->getCurrent()->getLine(), $stream->getSourceContext());
+            }
+        }
+        $this->parser->popLocalScope();
+        $stream->expect(/* Token::BLOCK_END_TYPE */ 3);
+
+        $this->parser->setMacro($name, new MacroNode($name, new BodyNode([$body]), $arguments, $lineno, $this->getTag()));
+
+        return new Node();
+    }
+
+    public function decideBlockEnd(Token $token): bool
+    {
+        return $token->test('endmacro');
+    }
+
+    public function getTag(): string
+    {
+        return 'macro';
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/SandboxTokenParser.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/SandboxTokenParser.php
new file mode 100644
index 0000000..c919556
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/SandboxTokenParser.php
@@ -0,0 +1,66 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\TokenParser;
+
+use Twig\Error\SyntaxError;
+use Twig\Node\IncludeNode;
+use Twig\Node\Node;
+use Twig\Node\SandboxNode;
+use Twig\Node\TextNode;
+use Twig\Token;
+
+/**
+ * Marks a section of a template as untrusted code that must be evaluated in the sandbox mode.
+ *
+ *    {% sandbox %}
+ *        {% include 'user.html' %}
+ *    {% endsandbox %}
+ *
+ * @see https://twig.symfony.com/doc/api.html#sandbox-extension for details
+ *
+ * @internal
+ */
+final class SandboxTokenParser extends AbstractTokenParser
+{
+    public function parse(Token $token): Node
+    {
+        $stream = $this->parser->getStream();
+        $stream->expect(/* Token::BLOCK_END_TYPE */ 3);
+        $body = $this->parser->subparse([$this, 'decideBlockEnd'], true);
+        $stream->expect(/* Token::BLOCK_END_TYPE */ 3);
+
+        // in a sandbox tag, only include tags are allowed
+        if (!$body instanceof IncludeNode) {
+            foreach ($body as $node) {
+                if ($node instanceof TextNode && ctype_space($node->getAttribute('data'))) {
+                    continue;
+                }
+
+                if (!$node instanceof IncludeNode) {
+                    throw new SyntaxError('Only "include" tags are allowed within a "sandbox" section.', $node->getTemplateLine(), $stream->getSourceContext());
+                }
+            }
+        }
+
+        return new SandboxNode($body, $token->getLine(), $this->getTag());
+    }
+
+    public function decideBlockEnd(Token $token): bool
+    {
+        return $token->test('endsandbox');
+    }
+
+    public function getTag(): string
+    {
+        return 'sandbox';
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/SetTokenParser.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/SetTokenParser.php
new file mode 100644
index 0000000..2fbdfe0
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/SetTokenParser.php
@@ -0,0 +1,73 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\TokenParser;
+
+use Twig\Error\SyntaxError;
+use Twig\Node\Node;
+use Twig\Node\SetNode;
+use Twig\Token;
+
+/**
+ * Defines a variable.
+ *
+ *  {% set foo = 'foo' %}
+ *  {% set foo = [1, 2] %}
+ *  {% set foo = {'foo': 'bar'} %}
+ *  {% set foo = 'foo' ~ 'bar' %}
+ *  {% set foo, bar = 'foo', 'bar' %}
+ *  {% set foo %}Some content{% endset %}
+ *
+ * @internal
+ */
+final class SetTokenParser extends AbstractTokenParser
+{
+    public function parse(Token $token): Node
+    {
+        $lineno = $token->getLine();
+        $stream = $this->parser->getStream();
+        $names = $this->parser->getExpressionParser()->parseAssignmentExpression();
+
+        $capture = false;
+        if ($stream->nextIf(/* Token::OPERATOR_TYPE */ 8, '=')) {
+            $values = $this->parser->getExpressionParser()->parseMultitargetExpression();
+
+            $stream->expect(/* Token::BLOCK_END_TYPE */ 3);
+
+            if (\count($names) !== \count($values)) {
+                throw new SyntaxError('When using set, you must have the same number of variables and assignments.', $stream->getCurrent()->getLine(), $stream->getSourceContext());
+            }
+        } else {
+            $capture = true;
+
+            if (\count($names) > 1) {
+                throw new SyntaxError('When using set with a block, you cannot have a multi-target.', $stream->getCurrent()->getLine(), $stream->getSourceContext());
+            }
+
+            $stream->expect(/* Token::BLOCK_END_TYPE */ 3);
+
+            $values = $this->parser->subparse([$this, 'decideBlockEnd'], true);
+            $stream->expect(/* Token::BLOCK_END_TYPE */ 3);
+        }
+
+        return new SetNode($capture, $names, $values, $lineno, $this->getTag());
+    }
+
+    public function decideBlockEnd(Token $token): bool
+    {
+        return $token->test('endset');
+    }
+
+    public function getTag(): string
+    {
+        return 'set';
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/TokenParserInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/TokenParserInterface.php
new file mode 100644
index 0000000..bb8db3e
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/TokenParserInterface.php
@@ -0,0 +1,46 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\TokenParser;
+
+use Twig\Error\SyntaxError;
+use Twig\Node\Node;
+use Twig\Parser;
+use Twig\Token;
+
+/**
+ * Interface implemented by token parsers.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+interface TokenParserInterface
+{
+    /**
+     * Sets the parser associated with this token parser.
+     */
+    public function setParser(Parser $parser): void;
+
+    /**
+     * Parses a token and returns a node.
+     *
+     * @return Node
+     *
+     * @throws SyntaxError
+     */
+    public function parse(Token $token);
+
+    /**
+     * Gets the tag name associated with this token parser.
+     *
+     * @return string
+     */
+    public function getTag();
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/UseTokenParser.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/UseTokenParser.php
new file mode 100644
index 0000000..d0a2de4
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/UseTokenParser.php
@@ -0,0 +1,73 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\TokenParser;
+
+use Twig\Error\SyntaxError;
+use Twig\Node\Expression\ConstantExpression;
+use Twig\Node\Node;
+use Twig\Token;
+
+/**
+ * Imports blocks defined in another template into the current template.
+ *
+ *    {% extends "base.html" %}
+ *
+ *    {% use "blocks.html" %}
+ *
+ *    {% block title %}{% endblock %}
+ *    {% block content %}{% endblock %}
+ *
+ * @see https://twig.symfony.com/doc/templates.html#horizontal-reuse for details.
+ *
+ * @internal
+ */
+final class UseTokenParser extends AbstractTokenParser
+{
+    public function parse(Token $token): Node
+    {
+        $template = $this->parser->getExpressionParser()->parseExpression();
+        $stream = $this->parser->getStream();
+
+        if (!$template instanceof ConstantExpression) {
+            throw new SyntaxError('The template references in a "use" statement must be a string.', $stream->getCurrent()->getLine(), $stream->getSourceContext());
+        }
+
+        $targets = [];
+        if ($stream->nextIf('with')) {
+            do {
+                $name = $stream->expect(/* Token::NAME_TYPE */ 5)->getValue();
+
+                $alias = $name;
+                if ($stream->nextIf('as')) {
+                    $alias = $stream->expect(/* Token::NAME_TYPE */ 5)->getValue();
+                }
+
+                $targets[$name] = new ConstantExpression($alias, -1);
+
+                if (!$stream->nextIf(/* Token::PUNCTUATION_TYPE */ 9, ',')) {
+                    break;
+                }
+            } while (true);
+        }
+
+        $stream->expect(/* Token::BLOCK_END_TYPE */ 3);
+
+        $this->parser->addTrait(new Node(['template' => $template, 'targets' => new Node($targets)]));
+
+        return new Node();
+    }
+
+    public function getTag(): string
+    {
+        return 'use';
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/WithTokenParser.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/WithTokenParser.php
new file mode 100644
index 0000000..7d8cbe2
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/WithTokenParser.php
@@ -0,0 +1,56 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\TokenParser;
+
+use Twig\Node\Node;
+use Twig\Node\WithNode;
+use Twig\Token;
+
+/**
+ * Creates a nested scope.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ *
+ * @internal
+ */
+final class WithTokenParser extends AbstractTokenParser
+{
+    public function parse(Token $token): Node
+    {
+        $stream = $this->parser->getStream();
+
+        $variables = null;
+        $only = false;
+        if (!$stream->test(/* Token::BLOCK_END_TYPE */ 3)) {
+            $variables = $this->parser->getExpressionParser()->parseExpression();
+            $only = (bool) $stream->nextIf(/* Token::NAME_TYPE */ 5, 'only');
+        }
+
+        $stream->expect(/* Token::BLOCK_END_TYPE */ 3);
+
+        $body = $this->parser->subparse([$this, 'decideWithEnd'], true);
+
+        $stream->expect(/* Token::BLOCK_END_TYPE */ 3);
+
+        return new WithNode($body, $variables, $only, $token->getLine(), $this->getTag());
+    }
+
+    public function decideWithEnd(Token $token): bool
+    {
+        return $token->test('endwith');
+    }
+
+    public function getTag(): string
+    {
+        return 'with';
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenStream.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenStream.php
new file mode 100644
index 0000000..1eac11a
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenStream.php
@@ -0,0 +1,132 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ * (c) Armin Ronacher
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig;
+
+use Twig\Error\SyntaxError;
+
+/**
+ * Represents a token stream.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+final class TokenStream
+{
+    private $tokens;
+    private $current = 0;
+    private $source;
+
+    public function __construct(array $tokens, Source $source = null)
+    {
+        $this->tokens = $tokens;
+        $this->source = $source ?: new Source('', '');
+    }
+
+    public function __toString()
+    {
+        return implode("\n", $this->tokens);
+    }
+
+    public function injectTokens(array $tokens)
+    {
+        $this->tokens = array_merge(\array_slice($this->tokens, 0, $this->current), $tokens, \array_slice($this->tokens, $this->current));
+    }
+
+    /**
+     * Sets the pointer to the next token and returns the old one.
+     */
+    public function next(): Token
+    {
+        if (!isset($this->tokens[++$this->current])) {
+            throw new SyntaxError('Unexpected end of template.', $this->tokens[$this->current - 1]->getLine(), $this->source);
+        }
+
+        return $this->tokens[$this->current - 1];
+    }
+
+    /**
+     * Tests a token, sets the pointer to the next one and returns it or throws a syntax error.
+     *
+     * @return Token|null The next token if the condition is true, null otherwise
+     */
+    public function nextIf($primary, $secondary = null)
+    {
+        if ($this->tokens[$this->current]->test($primary, $secondary)) {
+            return $this->next();
+        }
+    }
+
+    /**
+     * Tests a token and returns it or throws a syntax error.
+     */
+    public function expect($type, $value = null, string $message = null): Token
+    {
+        $token = $this->tokens[$this->current];
+        if (!$token->test($type, $value)) {
+            $line = $token->getLine();
+            throw new SyntaxError(sprintf('%sUnexpected token "%s"%s ("%s" expected%s).',
+                $message ? $message.'. ' : '',
+                Token::typeToEnglish($token->getType()),
+                $token->getValue() ? sprintf(' of value "%s"', $token->getValue()) : '',
+                Token::typeToEnglish($type), $value ? sprintf(' with value "%s"', $value) : ''),
+                $line,
+                $this->source
+            );
+        }
+        $this->next();
+
+        return $token;
+    }
+
+    /**
+     * Looks at the next token.
+     */
+    public function look(int $number = 1): Token
+    {
+        if (!isset($this->tokens[$this->current + $number])) {
+            throw new SyntaxError('Unexpected end of template.', $this->tokens[$this->current + $number - 1]->getLine(), $this->source);
+        }
+
+        return $this->tokens[$this->current + $number];
+    }
+
+    /**
+     * Tests the current token.
+     */
+    public function test($primary, $secondary = null): bool
+    {
+        return $this->tokens[$this->current]->test($primary, $secondary);
+    }
+
+    /**
+     * Checks if end of stream was reached.
+     */
+    public function isEOF(): bool
+    {
+        return /* Token::EOF_TYPE */ -1 === $this->tokens[$this->current]->getType();
+    }
+
+    public function getCurrent(): Token
+    {
+        return $this->tokens[$this->current];
+    }
+
+    /**
+     * Gets the source associated with this stream.
+     *
+     * @internal
+     */
+    public function getSourceContext(): Source
+    {
+        return $this->source;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TwigFilter.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TwigFilter.php
new file mode 100644
index 0000000..94e5f9b
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TwigFilter.php
@@ -0,0 +1,134 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig;
+
+use Twig\Node\Expression\FilterExpression;
+use Twig\Node\Node;
+
+/**
+ * Represents a template filter.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ *
+ * @see https://twig.symfony.com/doc/templates.html#filters
+ */
+final class TwigFilter
+{
+    private $name;
+    private $callable;
+    private $options;
+    private $arguments = [];
+
+    /**
+     * @param callable|null $callable A callable implementing the filter. If null, you need to overwrite the "node_class" option to customize compilation.
+     */
+    public function __construct(string $name, $callable = null, array $options = [])
+    {
+        $this->name = $name;
+        $this->callable = $callable;
+        $this->options = array_merge([
+            'needs_environment' => false,
+            'needs_context' => false,
+            'is_variadic' => false,
+            'is_safe' => null,
+            'is_safe_callback' => null,
+            'pre_escape' => null,
+            'preserves_safety' => null,
+            'node_class' => FilterExpression::class,
+            'deprecated' => false,
+            'alternative' => null,
+        ], $options);
+    }
+
+    public function getName(): string
+    {
+        return $this->name;
+    }
+
+    /**
+     * Returns the callable to execute for this filter.
+     *
+     * @return callable|null
+     */
+    public function getCallable()
+    {
+        return $this->callable;
+    }
+
+    public function getNodeClass(): string
+    {
+        return $this->options['node_class'];
+    }
+
+    public function setArguments(array $arguments): void
+    {
+        $this->arguments = $arguments;
+    }
+
+    public function getArguments(): array
+    {
+        return $this->arguments;
+    }
+
+    public function needsEnvironment(): bool
+    {
+        return $this->options['needs_environment'];
+    }
+
+    public function needsContext(): bool
+    {
+        return $this->options['needs_context'];
+    }
+
+    public function getSafe(Node $filterArgs): ?array
+    {
+        if (null !== $this->options['is_safe']) {
+            return $this->options['is_safe'];
+        }
+
+        if (null !== $this->options['is_safe_callback']) {
+            return $this->options['is_safe_callback']($filterArgs);
+        }
+
+        return null;
+    }
+
+    public function getPreservesSafety(): ?array
+    {
+        return $this->options['preserves_safety'];
+    }
+
+    public function getPreEscape(): ?string
+    {
+        return $this->options['pre_escape'];
+    }
+
+    public function isVariadic(): bool
+    {
+        return $this->options['is_variadic'];
+    }
+
+    public function isDeprecated(): bool
+    {
+        return (bool) $this->options['deprecated'];
+    }
+
+    public function getDeprecatedVersion(): string
+    {
+        return \is_bool($this->options['deprecated']) ? '' : $this->options['deprecated'];
+    }
+
+    public function getAlternative(): ?string
+    {
+        return $this->options['alternative'];
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TwigFunction.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TwigFunction.php
new file mode 100644
index 0000000..494d45b
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TwigFunction.php
@@ -0,0 +1,122 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig;
+
+use Twig\Node\Expression\FunctionExpression;
+use Twig\Node\Node;
+
+/**
+ * Represents a template function.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ *
+ * @see https://twig.symfony.com/doc/templates.html#functions
+ */
+final class TwigFunction
+{
+    private $name;
+    private $callable;
+    private $options;
+    private $arguments = [];
+
+    /**
+     * @param callable|null $callable A callable implementing the function. If null, you need to overwrite the "node_class" option to customize compilation.
+     */
+    public function __construct(string $name, $callable = null, array $options = [])
+    {
+        $this->name = $name;
+        $this->callable = $callable;
+        $this->options = array_merge([
+            'needs_environment' => false,
+            'needs_context' => false,
+            'is_variadic' => false,
+            'is_safe' => null,
+            'is_safe_callback' => null,
+            'node_class' => FunctionExpression::class,
+            'deprecated' => false,
+            'alternative' => null,
+        ], $options);
+    }
+
+    public function getName(): string
+    {
+        return $this->name;
+    }
+
+    /**
+     * Returns the callable to execute for this function.
+     *
+     * @return callable|null
+     */
+    public function getCallable()
+    {
+        return $this->callable;
+    }
+
+    public function getNodeClass(): string
+    {
+        return $this->options['node_class'];
+    }
+
+    public function setArguments(array $arguments): void
+    {
+        $this->arguments = $arguments;
+    }
+
+    public function getArguments(): array
+    {
+        return $this->arguments;
+    }
+
+    public function needsEnvironment(): bool
+    {
+        return $this->options['needs_environment'];
+    }
+
+    public function needsContext(): bool
+    {
+        return $this->options['needs_context'];
+    }
+
+    public function getSafe(Node $functionArgs): ?array
+    {
+        if (null !== $this->options['is_safe']) {
+            return $this->options['is_safe'];
+        }
+
+        if (null !== $this->options['is_safe_callback']) {
+            return $this->options['is_safe_callback']($functionArgs);
+        }
+
+        return [];
+    }
+
+    public function isVariadic(): bool
+    {
+        return (bool) $this->options['is_variadic'];
+    }
+
+    public function isDeprecated(): bool
+    {
+        return (bool) $this->options['deprecated'];
+    }
+
+    public function getDeprecatedVersion(): string
+    {
+        return \is_bool($this->options['deprecated']) ? '' : $this->options['deprecated'];
+    }
+
+    public function getAlternative(): ?string
+    {
+        return $this->options['alternative'];
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TwigTest.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TwigTest.php
new file mode 100644
index 0000000..4c18632
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TwigTest.php
@@ -0,0 +1,100 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig;
+
+use Twig\Node\Expression\TestExpression;
+
+/**
+ * Represents a template test.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ *
+ * @see https://twig.symfony.com/doc/templates.html#test-operator
+ */
+final class TwigTest
+{
+    private $name;
+    private $callable;
+    private $options;
+    private $arguments = [];
+
+    /**
+     * @param callable|null $callable A callable implementing the test. If null, you need to overwrite the "node_class" option to customize compilation.
+     */
+    public function __construct(string $name, $callable = null, array $options = [])
+    {
+        $this->name = $name;
+        $this->callable = $callable;
+        $this->options = array_merge([
+            'is_variadic' => false,
+            'node_class' => TestExpression::class,
+            'deprecated' => false,
+            'alternative' => null,
+            'one_mandatory_argument' => false,
+        ], $options);
+    }
+
+    public function getName(): string
+    {
+        return $this->name;
+    }
+
+    /**
+     * Returns the callable to execute for this test.
+     *
+     * @return callable|null
+     */
+    public function getCallable()
+    {
+        return $this->callable;
+    }
+
+    public function getNodeClass(): string
+    {
+        return $this->options['node_class'];
+    }
+
+    public function setArguments(array $arguments): void
+    {
+        $this->arguments = $arguments;
+    }
+
+    public function getArguments(): array
+    {
+        return $this->arguments;
+    }
+
+    public function isVariadic(): bool
+    {
+        return (bool) $this->options['is_variadic'];
+    }
+
+    public function isDeprecated(): bool
+    {
+        return (bool) $this->options['deprecated'];
+    }
+
+    public function getDeprecatedVersion(): string
+    {
+        return \is_bool($this->options['deprecated']) ? '' : $this->options['deprecated'];
+    }
+
+    public function getAlternative(): ?string
+    {
+        return $this->options['alternative'];
+    }
+
+    public function hasOneMandatoryArgument(): bool
+    {
+        return (bool) $this->options['one_mandatory_argument'];
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Util/DeprecationCollector.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Util/DeprecationCollector.php
new file mode 100644
index 0000000..378b666
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Util/DeprecationCollector.php
@@ -0,0 +1,77 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Util;
+
+use Twig\Environment;
+use Twig\Error\SyntaxError;
+use Twig\Source;
+
+/**
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+final class DeprecationCollector
+{
+    private $twig;
+
+    public function __construct(Environment $twig)
+    {
+        $this->twig = $twig;
+    }
+
+    /**
+     * Returns deprecations for templates contained in a directory.
+     *
+     * @param string $dir A directory where templates are stored
+     * @param string $ext Limit the loaded templates by extension
+     *
+     * @return array An array of deprecations
+     */
+    public function collectDir(string $dir, string $ext = '.twig'): array
+    {
+        $iterator = new \RegexIterator(
+            new \RecursiveIteratorIterator(
+                new \RecursiveDirectoryIterator($dir), \RecursiveIteratorIterator::LEAVES_ONLY
+            ), '{'.preg_quote($ext).'$}'
+        );
+
+        return $this->collect(new TemplateDirIterator($iterator));
+    }
+
+    /**
+     * Returns deprecations for passed templates.
+     *
+     * @param \Traversable $iterator An iterator of templates (where keys are template names and values the contents of the template)
+     *
+     * @return array An array of deprecations
+     */
+    public function collect(\Traversable $iterator): array
+    {
+        $deprecations = [];
+        set_error_handler(function ($type, $msg) use (&$deprecations) {
+            if (\E_USER_DEPRECATED === $type) {
+                $deprecations[] = $msg;
+            }
+        });
+
+        foreach ($iterator as $name => $contents) {
+            try {
+                $this->twig->parse($this->twig->tokenize(new Source($contents, $name)));
+            } catch (SyntaxError $e) {
+                // ignore templates containing syntax errors
+            }
+        }
+
+        restore_error_handler();
+
+        return $deprecations;
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Util/TemplateDirIterator.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Util/TemplateDirIterator.php
new file mode 100644
index 0000000..c7339fd
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Util/TemplateDirIterator.php
@@ -0,0 +1,28 @@
+<?php
+
+/*
+ * This file is part of Twig.
+ *
+ * (c) Fabien Potencier
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Twig\Util;
+
+/**
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class TemplateDirIterator extends \IteratorIterator
+{
+    public function current()
+    {
+        return file_get_contents(parent::current());
+    }
+
+    public function key()
+    {
+        return (string) parent::key();
+    }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/prerequisites.inc.php b/mailcow/src/mailcow-dockerized/data/web/inc/prerequisites.inc.php
index 0cbd05a..a5eb2c8 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/prerequisites.inc.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/prerequisites.inc.php
@@ -1,5 +1,8 @@
 <?php
 
+// check for development mode
+$DEV_MODE = (getenv('DEV_MODE') == 'y');
+
 // Slave does not serve UI
 /* if (!preg_match('/y|yes/i', getenv('MASTER'))) {
   header('Location: /SOGo', true, 307);
@@ -169,7 +172,9 @@
       return false;
     }
 }
-set_exception_handler('exception_handler');
+if(!$DEV_MODE) {
+  set_exception_handler('exception_handler');
+}
 
 // TODO: Move function
 function get_remote_ip() {
@@ -242,6 +247,7 @@
 require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/functions.transports.inc.php';
 require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/init_db.inc.php';
 require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/triggers.inc.php';
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/twig.inc.php';
 init_db_schema();
 if (isset($_SESSION['mailcow_cc_role'])) {
   // if ($_SESSION['mailcow_cc_role'] == 'user') {
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/twig.inc.php b/mailcow/src/mailcow-dockerized/data/web/inc/twig.inc.php
new file mode 100644
index 0000000..081ca31
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/twig.inc.php
@@ -0,0 +1,27 @@
+<?php
+
+use Twig\Environment;
+use Twig\Loader\FilesystemLoader;
+use Twig\TwigFilter;
+use Twig\TwigFunction;
+
+$loader = new FilesystemLoader($_SERVER['DOCUMENT_ROOT'].'/templates');
+$twig = new Environment($loader, [
+  'debug' => $DEV_MODE,
+  'cache' => $_SERVER['DOCUMENT_ROOT'].'/templates/cache',
+]);
+
+// functions
+$twig->addFunction(new TwigFunction('query_string', function (array $params = []) {
+  return http_build_query(array_merge($_GET, $params));
+}));
+
+$twig->addFunction(new TwigFunction('is_uri', function (string $uri, string $where = null) {
+  if (is_null($where)) $where = $_SERVER['REQUEST_URI'];
+  return preg_match('/'.$uri.'/i', $where);
+}));
+
+// filters
+$twig->addFilter(new TwigFilter('rot13', 'str_rot13'));
+$twig->addFilter(new TwigFilter('base64_encode', 'base64_encode'));
+$twig->addFilter(new TwigFilter('formatBytes', 'formatBytes'));
